YosefLab / Cassiopeia

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

Cleanup filtering code and behavior in preprocess #137

Closed Lioscro closed 3 years ago

Lioscro commented 3 years ago

I noticed there were a few inconsistencies between the variable name & docstring vs the actual filtering behavior in pp.utilities.filter_cells and pp.utilities.filter_umis. This PR addresses these inconsistencies.

Overall, these changes result in around 10x speedup of the pp.filter_molecule_table function.

codecov[bot] commented 3 years ago

Codecov Report

Merging #137 (af4997e) into master (53e705b) will decrease coverage by 0.04%. The diff coverage is 82.85%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #137      +/-   ##
==========================================
- Coverage   86.28%   86.24%   -0.05%     
==========================================
  Files          65       65              
  Lines        4536     4530       -6     
==========================================
- Hits         3914     3907       -7     
- Misses        622      623       +1     
Impacted Files Coverage Δ
cassiopeia/preprocess/cassiopeia_preprocess.py 23.07% <0.00%> (ø)
cassiopeia/preprocess/constants.py 100.00% <ø> (ø)
cassiopeia/preprocess/UMI_utils.py 95.25% <50.00%> (-0.42%) :arrow_down:
cassiopeia/preprocess/pipeline.py 71.01% <77.77%> (-0.16%) :arrow_down:
cassiopeia/preprocess/utilities.py 96.56% <100.00%> (-0.07%) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 53e705b...af4997e. Read the comment docs.