nadeemlab / SPT

Spatial profiling toolbox for spatial characterization of tumor immune microenvironment in multiplex images (https://oncopathtk.org)
https://oncopathtk.org
Other
21 stars 2 forks source link

Speed up with C extensions #340

Open jimmymathews opened 1 month ago

jimmymathews commented 1 month ago

In #338 we saw that there is an opportunity to speed up very specific computations -- in that case bitmasking in a long loop -- by delegation from our primary Python package to a C extension.

For this issue, implement this C extension (guide) and to replace a certain numpy call used in #338. This can serve as a template for further speedup of other specific computations in the future.