Visium HD captures gene expression data at a subcellular 2um resolution. It should be possible to use this data to reconstruct cells more accurately than just using the next resolution up (8um), especially if additionally using the available high resolution morphology images.
Bin2cell proposes 2um bin to cell groupings based on segmentation, which can be done on the H&E image and/or a visualisation of the gene expression. The package also corrects for a novel technical effect in the data stemming from variable bin dimensions. The end result is an object with cells, created from grouped 2um bins assigned to the same object after segmentation, carrying spatial information and sharper H&E images for visualisation. More details in the demo notebook.
pip install bin2cell
Additionally, TensorFlow needs to be installed for StarDist to perform segmentation. The CPU version (installed via pip install tensorflow
) should suffice for the scale of work performed here.
Please refer to the demo notebook. Function docstrings are available on ReadTheDocs.
The repository also has notebooks comparing bin2cell output to standard 8um SpaceRanger output:
- Mouse brain bin2cell and downstream analysis
- Human colorectal cancer bin2cell and downstream analysis
Please cite our preprint.