Remove Spatial Enrichment + Bootstrapping Cython
Closed this issue · 0 comments
srivarra commented
This is for internal use only; if you'd like to open an issue or request a new feature, please open a bug or enhancement issue
Spatial enrichment has been issue prone and difficult to use. For now it would be ideal to remove it.
We can remove _bootstrapping.pyx. And the functions used by it downstream.
Here is a visual representation:
---
title: Bootstrapping
---
flowchart TB
subgraph src/ark [src/ark]
subgraph _bootstrapping.pyx [_bootstrapping.pyx]
compute_close_num_rand
end
subgraph spatial_analysis_utils.py [spatial_analysis_utils.py]
compute_close_cell_num_random
end
subgraph spatial_enrichment.py [spatial_enrichment.py]
calculate_channel_spatial_enrichment --> generate_channel_spatial_enrichment_stats
calculate_cluster_spatial_enrichment --> generate_cluster_spatial_enrichment_stats
end
end
subgraph Tests [Tests]
subgraph spatial_enrichment_test.py [spatial_enrichment_test.py]
test_calculate_channel_spatial_enrichment
test_calculate_cluster_spatial_enrichment
test_generate_channel_spatial_enrichment_stats
test_generate_cluster_spatial_enrichment_stats
end
subgraph spatial_analysis_utils_test.py [spatial_analysis_utils_test.py]
test_compute_close_cell_num_random
end
end
%% code dependency links
_bootstrapping.pyx --> spatial_analysis_utils.py
spatial_analysis_utils.py --> spatial_enrichment.py
%% test dependency links
compute_close_cell_num_random --> test_compute_close_cell_num_random
calculate_channel_spatial_enrichment --> test_calculate_channel_spatial_enrichment
calculate_cluster_spatial_enrichment --> test_calculate_cluster_spatial_enrichment
generate_channel_spatial_enrichment_stats --> test_generate_channel_spatial_enrichment_stats
generate_cluster_spatial_enrichment_stats --> test_generate_cluster_spatial_enrichment_stats
%% hrefs
click compute_close_num_rand href "https://github.com/angelolab/ark-analysis/blob/301e344f0ffbedafaad282c52c801e7713272f85/src/ark/utils/_bootstrapping.pyx#L248"
click compute_close_cell_num_random href "https://github.com/angelolab/ark-analysis/blob/301e344f0ffbedafaad282c52c801e7713272f85/src/ark/analysis/spatial_analysis_utils.py#L287"
click calculate_channel_spatial_enrichment href "https://github.com/angelolab/ark-analysis/blob/301e344f0ffbedafaad282c52c801e7713272f85/src/ark/analysis/spatial_enrichment.py#L102"
click calculate_cluster_spatial_enrichment href "https://github.com/angelolab/ark-analysis/blob/301e344f0ffbedafaad282c52c801e7713272f85/src/ark/analysis/spatial_enrichment.py#L325"
click generate_channel_spatial_enrichment_stats href "https://github.com/angelolab/ark-analysis/blob/301e344f0ffbedafaad282c52c801e7713272f85/src/ark/analysis/spatial_enrichment.py#L13"
click generate_cluster_spatial_enrichment_stats href "https://github.com/angelolab/ark-analysis/blob/301e344f0ffbedafaad282c52c801e7713272f85/src/ark/analysis/spatial_enrichment.py#L243"
click test_compute_close_cell_num_random href "https://github.com/angelolab/ark-analysis/blob/301e344f0ffbedafaad282c52c801e7713272f85/tests/analysis/spatial_analysis_utils_test.py#L201"
click test_calculate_channel_spatial_enrichment href "https://github.com/angelolab/ark-analysis/blob/301e344f0ffbedafaad282c52c801e7713272f85/tests/analysis/spatial_enrichment_test.py#L111"
click test_calculate_cluster_spatial_enrichment href "https://github.com/angelolab/ark-analysis/blob/301e344f0ffbedafaad282c52c801e7713272f85/tests/analysis/spatial_enrichment_test.py#L247"
click test_generate_channel_spatial_enrichment_stats href "https://github.com/angelolab/ark-analysis/blob/301e344f0ffbedafaad282c52c801e7713272f85/tests/analysis/spatial_enrichment_test.py#L37"
click test_generate_cluster_spatial_enrichment_stats href "https://github.com/angelolab/ark-analysis/blob/301e344f0ffbedafaad282c52c801e7713272f85/tests/analysis/spatial_enrichment_test.py#L76"
In addition this will allow the following:
- Removal of the
setup.py
file - Simplified build system on CI
- only need one OS for building
- No need for cibuildwheel
- Simplified user experience (no need for Visual Studio toolchains on Windows)