Convert Stereo-seq data to 10X Genomics Xenium format.
Project description
install
conda activate
pip install stereo2xenium
usage
inDir="/media/dell/data2/Stereo/eyeball/mmEyeBall/outs/feature_expression"
outDir="/media/dell/data2/Stereo/eyeball/toXenium"
SN=C04687E314
stereo2xenium convert --input ${inDir} --output ${outDir} --sample ${SN} --genome GRCm39 --cellbin_gem
stereo2xenium viewh5 --h5file ${inDir}/C04687E314.adjusted.cellbin.gef
rotate and flip
# determine the rotation angle 调整旋转角度
file="/media/dell/scRNA/spatial/Stereo/brainC04042E3/outs/visualization/C04042E3.adjusted.cellbin.gef"
outDir="/media/dell/scRNA/spatial/Stereo/brainC04042E3/toXenium"
# plot cell centroids without rotation
stereo2xenium plotRotation --file ${file} --output ${outDir}
# try different theta value to rotate the image clockwisely or anticlockwisely.
stereo2xenium plotRotation --file ${file} --output ${outDir} --theta 138 --anticlockwise
# Run stereo2xenium with proper theta values.
# All of the coordination, including cell centroids, cell boundaries, and transcripts, will be rotated.
inDir="/media/dell/scRNA/spatial/Stereo/brainC04042E3/outs/visualization"
outDir="/media/dell/scRNA/spatial/Stereo/brainC04042E3/toXenium"
SN="C04042E3"
stereo2xenium convert --input ${inDir} --output ${outDir} --sample ${SN} --segmentation 'HE' --genome mm10 --anticlockwise --theta 130
Mapping molecules to cells
-
The stereo-seq output data typically does not include the cellbin.gem file, which is required for mapping molecules to cells.
-
To generate this file, first run
saw convertto retrieve the cellbin.gem. Then, runstereo2xenium convertto process the data. -
If
stereo2xenium converthas already been executed, you can runstereo2xenium getTranscriptsseparately to complete the mapping of molecules to cells. -
Warning:
Mapping molecules to cells is time- and memory-intensive and is not required for downstream analysis.
You can skip it by running
stereo2xenium convertwithout--cellbin_gem.
inDir=/media/dell/scRNA/spatial/Stereo/brainC04042E3/outs/visualization
SN=C04042E3
saw convert --threads-num 16 gef2gem --bin-size 1 \
--gef ${inDir}/${SN}.tissue.gef \
--cellbin-gef ${inDir}/${SN}.adjusted.cellbin.gef \
--cellbin-gem ${inDir}/${SN}.adjusted.cellbin.gem
gzip ${inDir}/${SN}.adjusted.cellbin.gem
stereo2xenium convert --input ${inDir} --output ${outDir} --sample ${SN} --segmentation 'HE' --genome mm10 --cellbin_gem --anticlockwise --theta 130
stereo2xenium getTranscripts --input ${inDir} --sample ${SN} --output ${outDir} --cellbin_gem --theta 130 --anticlockwise
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file stereo2xenium-0.2.3.tar.gz.
File metadata
- Download URL: stereo2xenium-0.2.3.tar.gz
- Upload date:
- Size: 10.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.8.20
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
25ade799f2f680c8c04b76e6d548cdedd93cd3db7657ff146ba1edb671e05705
|
|
| MD5 |
68d01726ae7b229153919519c8ecc29c
|
|
| BLAKE2b-256 |
6a43d56910b1062a2a5209920beb76a60cd1f62bd788e3f16aea858543a97b79
|
File details
Details for the file stereo2xenium-0.2.3-py3-none-any.whl.
File metadata
- Download URL: stereo2xenium-0.2.3-py3-none-any.whl
- Upload date:
- Size: 10.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.8.20
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6a96cfa6cc6eb2bc8c54f1f0101e13193e3f683d722d18dbaf09b6bd4ec3e4b5
|
|
| MD5 |
accfb018bff5b5b66cd8b1a297baa8dd
|
|
| BLAKE2b-256 |
2d6100dd51208912dcf0ee06a882c9c628601590c8d3d939654de19498c24539
|