YosefLab / Cassiopeia

A Package for Cas9-Enabled Single Cell Lineage Tracing Tree Reconstruction
https://cassiopeia-lineage.readthedocs.io/en/latest/
MIT License
75 stars 24 forks source link

Spatial leaf subsampler #215

Closed colganwi closed 1 year ago

colganwi commented 1 year ago

New SpatialLeafSubsampler class uniformly samples leaves within a region of interest defined by a bounding box or mask using the 'spatial' attribute stored in the tree. The number of leaves to sample can be set explicitly or as a ratio of the number of cells in the region. This class is useful for sampling adjacent slices from a 3D spatial simulation.

codecov[bot] commented 1 year ago

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.29% :tada:

Comparison is base (03198eb) 78.82% compared to head (a9ff681) 79.12%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #215 +/- ## ========================================== + Coverage 78.82% 79.12% +0.29% ========================================== Files 88 89 +1 Lines 7782 7893 +111 ========================================== + Hits 6134 6245 +111 Misses 1648 1648 ``` | [Files Changed](https://app.codecov.io/gh/YosefLab/Cassiopeia/pull/215?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=YosefLab) | Coverage Δ | | |---|---|---| | [cassiopeia/mixins/warnings.py](https://app.codecov.io/gh/YosefLab/Cassiopeia/pull/215?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=YosefLab#diff-Y2Fzc2lvcGVpYS9taXhpbnMvd2FybmluZ3MucHk=) | `100.00% <100.00%> (ø)` | | | [cassiopeia/simulator/LeafSubsampler.py](https://app.codecov.io/gh/YosefLab/Cassiopeia/pull/215?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=YosefLab#diff-Y2Fzc2lvcGVpYS9zaW11bGF0b3IvTGVhZlN1YnNhbXBsZXIucHk=) | `100.00% <100.00%> (ø)` | | | [cassiopeia/simulator/SpatialLeafSubsampler.py](https://app.codecov.io/gh/YosefLab/Cassiopeia/pull/215?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=YosefLab#diff-Y2Fzc2lvcGVpYS9zaW11bGF0b3IvU3BhdGlhbExlYWZTdWJzYW1wbGVyLnB5) | `100.00% <100.00%> (ø)` | | | [cassiopeia/simulator/\_\_init\_\_.py](https://app.codecov.io/gh/YosefLab/Cassiopeia/pull/215?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=YosefLab#diff-Y2Fzc2lvcGVpYS9zaW11bGF0b3IvX19pbml0X18ucHk=) | `100.00% <100.00%> (ø)` | |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.