Skip to content

Commit 5ee7988

Browse files
authored
Merge pull request #349 from SpatialHackathon/docs
Update Docs
2 parents 44faff9 + 49defa8 commit 5ee7988

14 files changed

Lines changed: 491 additions & 270 deletions

File tree

.github/workflows/build_mkdocs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,6 @@ jobs:
1919
- name: Install dependencies
2020
run: |
2121
python -m pip install --upgrade pip
22-
pip install mkdocs
22+
pip install -r docs/requirements.txt
2323
- name: Build and deploy MkDocs
2424
run: mkdocs gh-deploy --force

CONTRIBUTING.md

Lines changed: 27 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -8,31 +8,34 @@ SpaceHack 2023 is an open source project and we love to receive contributions fr
88

99
# Getting started
1010

11-
## Creating new modules
12-
13-
1. First create or claim a **GitHub issue** from the [SpaceHack issue board.](https://github.com/SpatialHackathon/SpaceHack2023/issues) that describes the module you want to implement and add the appropriate **tags**, and **assign** the task to yourself.
14-
2. Add **metadata** to our metadata [spreadsheet](https://docs.google.com/spreadsheets/d/1QCeAF4yQG4bhZSGPQwwVBj_XF7ADY_2mK5xivAIfHsc/edit). Please fill in as much as you can as metadata is helpful! If you feel the need, please also add new columns or add additional notes. The metadata should be added to the appropriate tabs:
15-
- [datasets](https://docs.google.com/spreadsheets/d/1QCeAF4yQG4bhZSGPQwwVBj_XF7ADY_2mK5xivAIfHsc/edit#gid=1453488771)
16-
- [computational methods](https://docs.google.com/spreadsheets/d/1QCeAF4yQG4bhZSGPQwwVBj_XF7ADY_2mK5xivAIfHsc/edit#gid=0)
17-
- [evaluation metrics](https://docs.google.com/spreadsheets/d/1QCeAF4yQG4bhZSGPQwwVBj_XF7ADY_2mK5xivAIfHsc/edit#gid=4776337)
18-
- [simulations and technical evaluation](https://docs.google.com/spreadsheets/d/1QCeAF4yQG4bhZSGPQwwVBj_XF7ADY_2mK5xivAIfHsc/edit#gid=640974611)
19-
3. Now you are ready to create a new git **[branch](https://learngitbranching.js.org/)**. Try to give your new branch an intuitive prefix such as `data_...`, `method_...` or `metric_..`. You can create a new branch in several ways: (i) [create a branch directly from the issue board](https://docs.github.com/en/issues/tracking-your-work-with-issues/creating-a-branch-for-an-issue) and then `git checkout` that branch, or (ii) via the command line:
20-
```
21-
# clone the template repository
22-
git clone https://github.com/SpatialHackathon/SpaceHack2023.git
23-
# create and switch to a new branch for your e.g. method "X"
24-
git branch method_x_naveedishaque # try to make the branch name unique!
25-
git checkout method_x_naveedishaque
26-
# link the branch to the issue via the issue board: https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue
27-
```
28-
4. Modify the files, filenames, and code in `template/`, referring to the examples in the `data`, `method`, or `metric` subfolder. If your method requires a specific type or preprocessing, please reach out to the organisers!
29-
5. Test. We are currently working on validators and automatic testing scripts... but this is tricky. Reach out to Niklas Muller-Botticher when you are ready to test!
30-
6. Create a [pull request](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request?tool=cli)
31-
7. Code review (by whom?) and merge your contributed module into the GitHub main branch!
11+
Our workflow is set up to allow everyone to contribute "modules" in their preferred programming language (.. as long as that is either R or Python). A module can either be a dataset, a computational method, or an evaluation metric.
12+
![Workflow](img/workflow.svg)
13+
14+
This repository contains some templates and examples of how to implement your module so that it interfaces seamlessly with other modules in the workflow. For example, if you want to implement a new method, you do not need to worry about input data or evaluation metrics as long as you follow the template for reading input and writing output - if you correctly adhere to the input and output guidelines, you should be able to interface with our default data modules and default evaluation metrics modules. The default modules are:
15+
16+
- data: LIBD Visium DLPFC dataset (4 samples, each with 3 replicates)
17+
- methods: BayesSpace and SpaGCN
18+
- evaluation metrics: ARI and V_measure
19+
20+
## How to contribute a module
21+
22+
Module contribution will be managed via GitHub. The steps to contribute a module are:
23+
24+
1. Fork (or if you are part of the SpaceHack community branch) the latest version of the [SpaceHack repository](https://github.com/SpatialHackathon/SpaceHack2023)
25+
26+
2. Make a copy of a [template]({{ repo_branch_url }}/templates/) depending on whether you are implementing a data, method, or metric module. You can have a look at existing modules if you are unsure what to do.
27+
28+
3. Modify the files, filenames, and code in your copied template and move it to the correct module directory.
29+
30+
4. Test. Before you make a pull request make sure that you can run the default modules. If it is a dataset, try to run e.g. SpaGCN or BayesSpace (or any other implemented method). If you implemented a method, try to run it on a dataset, and then test your output with an existing method.
31+
32+
5. Create a [pull request](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request?tool=cli).
33+
34+
6. Wait for code review and your module being merged into the workflow.
3235

3336
Easy!
3437

35-
# How to report a bug
38+
## How to report a bug
3639

3740
When filing an issue, make sure to answer these five questions:
3841

@@ -42,12 +45,11 @@ When filing an issue, make sure to answer these five questions:
4245
4. What did you expect to see?
4346
5. What did you see instead?
4447

45-
### Feature requests
48+
## Feature requests
4649

4750
If you find yourself wishing for a feature or modules that don't exist in SpaceHack 2023, you are probably not alone. There are bound to be others out there with similar needs. Many of the features that SpaceHack 2023 has today have been added because our users saw the need. Open an issue on our issues list on GitHub that describes the feature you would like to see, why you need it, and how it should work.
4851

49-
50-
# Code review process
52+
## Code review process
5153

5254
The core team looks at Pull Requests on an ad-hoc basis.
5355
After feedback has been given we expect responses within four weeks. After four weeks we may close the pull request if it isn't showing any activity.

README.md

Lines changed: 122 additions & 108 deletions
Original file line numberDiff line numberDiff line change
@@ -1,100 +1,114 @@
1-
# SACCELERATOR - a flexible framework for applying spatially aware clustering methods
2-
3-
Spatial omics have transformed tissue architecture and cellular heterogeneity analysis by integrating molecular data with spatial localization. In spatially resolved transcriptomics, identifying spatial domains is critical for analysis of anatomical regions within heterogeneous datasets and understanding tissue function. Since 2020, more than 50 spatially aware clustering methods have been developed for this task. However, the reliability of existing benchmarks is undermined by their narrow focus on Visium and brain tissue datasets, as well as the dependence on questionable ground truth annotations. Here, we implemented a consensus framework that surpasses traditional benchmarking practices.
4-
5-
Our framework comprises a community-driven benchmark-like platform that streamlines data formatting, method integration, and metric evaluation while accommodating new methods and datasets. Currently, the platform includes 22 spatially aware clustering methods across 15 datasets spanning 9 technologies and diverse tissue types. The benchmark approach uncovered significant limitations in generalizability and reproducibility where methods that perform well on healthy tissues often falter on cancer samples. We also found that anatomical labels commonly used as ground truths are often biased, potentially error-prone, and in some cases, unsuitable for benchmarking efforts.
6-
7-
In light of these issues, we adopt a flexible expert-in-the-loop consensus-driven approach. This goes beyond traditional ensemble/consensus methods, and allows researchers to interact with intermediate results to determine which tools should be used to generate a consensus. We believe that the inclusion of an expert-in-the-loop is critical to ensure that the computational analysis matches the biological question at hand, and we believe that when the focus of the analysis is to uncover novel biological discoveries, tissue experts are accessible more often than not.
8-
9-
# General setup
10-
11-
This framework has established (and allows users to contribute) "modules" in their preferred programming language (.. as long as that is either R or Python). A module is a set of scripts set up something in one of the following categories: a dataset, a computational method, or an evaluation metric. Interfaces between each category enable seamless integration of new data, methods, or metrics, thus enabling an extensible and community-driven framework.
12-
13-
![image](https://github.com/user-attachments/assets/ed55184d-d43f-4546-bee5-7b12e9ff8154)
14-
15-
## Modules
16-
17-
This repository contains some templates and examples of how to implement your module so that it interfaces seamlessly with other modules in the workflow. For example, if you want to implement a new method, you do not need to worry about input data or evaluation metrics as long as you follow the template for reading input and writing output - if you correctly adhere to the input and output guidelines, you should be able to interface with our default data modules and default evaluation metrics modules.
18-
19-
The existing modules are:
20-
- data (currently 28)
21-
- LIBD Visium DLPFC dataset (4 samples, each with 3 replicates)
22-
- SEA_AD_data
23-
- STARmap-2018-mouse-cortex
24-
- STARmap_plus
25-
- abc_atlas_wmb_thalamus
26-
- cosmx_liver
27-
- cosmx_lung
28-
- her2st-breast-cancer
29-
- locus_coeruleus
30-
- merfish_devheart
31-
- mouse_brain_sagittal_anterior
32-
- mouse_brain_sagittal_posterior
33-
- mouse_kidney_coronal
34-
- osmfish_Ssp
35-
- pachter_simulation
36-
- slideseq2_olfactory_bulb
37-
- sotip_simulation
38-
- spatialDLPFC
39-
- stereoseq_developing_Drosophila_embryos_larvae
40-
- stereoseq_liver
41-
- stereoseq_mouse_embryo
42-
- stereoseq_olfactory_bulb
43-
- visium_breast_cancer_SEDR
44-
- visium_chicken_heart
45-
- visium_hd_cancer_colon
46-
- xenium-breast-cancer
47-
- xenium-mouse-brain-SergioSalas
48-
- methods (currently 24):
49-
- BANKSY
50-
- BayesSpace
51-
- CellCharter
52-
- DRSC
53-
- DeepST
54-
- Giotto
55-
- GraphST
56-
- SCAN-IT
57-
- SC_MEB
58-
- SEDR
59-
- SOTIP
60-
- STAGATE
61-
- SpaceFlow
62-
- SpiceMix
63-
- bass
64-
- conST
65-
- maple
66-
- meringue
67-
- precast
68-
- scanpy
69-
- seurat
70-
- spaGCN
71-
- spatialGE
72-
- stardust
73-
- evaluation metrics (currently 17)
74-
- ARI
75-
- CHAOS
76-
- Calinski-Harabasz
77-
- Completeness
78-
- Davies-Bouldin
79-
- Entropy
80-
- FMI
81-
- Homogeneity
82-
- LISI
83-
- MCC
84-
- NMI
85-
- PAS
86-
- SpatialARI
87-
- V_measure
88-
- cluster-specific-silhouette
89-
- domain-specific-f1
90-
- jaccard
91-
92-
# Contributing and Code of Conduct
93-
94-
Read our [Contributing Guide](CONTRIBUTING.md) and [Code of Conduct](CODE_OF_CONDUCT.md).
95-
96-
# Contributors
97-
1+
# SACCELERATOR - a flexible framework for applying spatially aware clustering methods
2+
3+
Spatial omics have transformed tissue architecture and cellular heterogeneity analysis by integrating molecular data with spatial localization. In spatially resolved transcriptomics, identifying spatial domains is critical for analysis of anatomical regions within heterogeneous datasets and understanding tissue function. Since 2020, more than 50 spatially aware clustering methods have been developed for this task. However, the reliability of existing benchmarks is undermined by their narrow focus on Visium and brain tissue datasets, as well as the dependence on questionable ground truth annotations. Here, we implemented a consensus framework that surpasses traditional benchmarking practices.
4+
5+
Our framework comprises a community-driven benchmark-like platform that streamlines data formatting, method integration, and metric evaluation while accommodating new methods and datasets. Currently, the platform includes 22 spatially aware clustering methods across 15 datasets spanning 9 technologies and diverse tissue types. The benchmark approach uncovered significant limitations in generalizability and reproducibility where methods that perform well on healthy tissues often falter on cancer samples. We also found that anatomical labels commonly used as ground truths are often biased, potentially error-prone, and in some cases, unsuitable for benchmarking efforts.
6+
7+
In light of these issues, we adopt a flexible expert-in-the-loop consensus-driven approach. This goes beyond traditional ensemble/consensus methods, and allows researchers to interact with intermediate results to determine which tools should be used to generate a consensus. We believe that the inclusion of an expert-in-the-loop is critical to ensure that the computational analysis matches the biological question at hand, and we believe that when the focus of the analysis is to uncover novel biological discoveries, tissue experts are accessible more often than not.
8+
9+
# General setup
10+
11+
This framework has established (and allows users to contribute) "modules" in their preferred programming language (.. as long as that is either R or Python). A module is a set of scripts set up something in one of the following categories: a dataset, a computational method, or an evaluation metric. Interfaces between each category enable seamless integration of new data, methods, or metrics, thus enabling an extensible and community-driven framework.
12+
13+
![image](https://github.com/user-attachments/assets/ed55184d-d43f-4546-bee5-7b12e9ff8154)
14+
15+
## Modules
16+
17+
This repository contains some templates and examples of how to implement your module so that it interfaces seamlessly with other modules in the workflow. For example, if you want to implement a new method, you do not need to worry about input data or evaluation metrics as long as you follow the template for reading input and writing output - if you correctly adhere to the input and output guidelines, you should be able to interface with our default data modules and default evaluation metrics modules.
18+
19+
The existing modules are:
20+
- data (currently 28)
21+
- LIBD Visium DLPFC dataset (4 samples, each with 3 replicates)
22+
- SEA_AD_data
23+
- STARmap-2018-mouse-cortex
24+
- STARmap_plus
25+
- abc_atlas_wmb_thalamus
26+
- cosmx_liver
27+
- cosmx_lung
28+
- her2st-breast-cancer
29+
- locus_coeruleus
30+
- merfish_devheart
31+
- mouse_brain_sagittal_anterior
32+
- mouse_brain_sagittal_posterior
33+
- mouse_kidney_coronal
34+
- osmfish_Ssp
35+
- pachter_simulation
36+
- slideseq2_olfactory_bulb
37+
- sotip_simulation
38+
- spatialDLPFC
39+
- stereoseq_developing_Drosophila_embryos_larvae
40+
- stereoseq_liver
41+
- stereoseq_mouse_embryo
42+
- stereoseq_olfactory_bulb
43+
- visium_breast_cancer_SEDR
44+
- visium_chicken_heart
45+
- visium_hd_cancer_colon
46+
- xenium-breast-cancer
47+
- xenium-mouse-brain-SergioSalas
48+
- methods (currently 24):
49+
- BANKSY
50+
- BayesSpace
51+
- CellCharter
52+
- DRSC
53+
- DeepST
54+
- Giotto
55+
- GraphST
56+
- SCAN-IT
57+
- SC_MEB
58+
- SEDR
59+
- SOTIP
60+
- STAGATE
61+
- SpaceFlow
62+
- SpiceMix
63+
- bass
64+
- conST
65+
- maple
66+
- meringue
67+
- precast
68+
- scanpy
69+
- seurat
70+
- spaGCN
71+
- spatialGE
72+
- stardust
73+
- evaluation metrics (currently 17)
74+
- ARI
75+
- CHAOS
76+
- Calinski-Harabasz
77+
- Completeness
78+
- Davies-Bouldin
79+
- Entropy
80+
- FMI
81+
- Homogeneity
82+
- LISI
83+
- MCC
84+
- NMI
85+
- PAS
86+
- SpatialARI
87+
- V_measure
88+
- cluster-specific-silhouette
89+
- domain-specific-f1
90+
- jaccard
91+
92+
93+
# Contributions
94+
95+
Our workflow is set up to allow everyone to contribute "modules", whether it is a dataset, a computational method, or an evaluation metric.
96+
![image](https://github.com/SpatialHackathon/SpaceHack2023/assets/114547/7c002916-0a90-4fe7-8745-489313bc0192)
97+
98+
This repository contains some templates and examples of how to implement your module so that it interfaces seamlessly with other modules in the workflow.
99+
Please refer to our
100+
[Contribution guide](https://spatialhackathon.github.io/SpaceHack2023/contributing/) and the
101+
[Module documentation](https://spatialhackathon.github.io/SpaceHack2023/modules/)
102+
for more details.
103+
104+
105+
## Contributing and Code of Conduct
106+
107+
Read our [Contributing Guide](CONTRIBUTING.md) and [Code of Conduct](CODE_OF_CONDUCT.md).
108+
109+
110+
## Contributors
111+
98112
<!-- readme: contributors -start -->
99113
<table>
100114
<tbody>
@@ -248,14 +262,14 @@ Read our [Contributing Guide](CONTRIBUTING.md) and [Code of Conduct](CODE_OF_CON
248262
</tr>
249263
<tbody>
250264
</table>
251-
<!-- readme: contributors -end -->
252-
253-
# Citation
254-
255-
We are close to releasing a preprint. Until then, please cite us as follows:
256-
257-
> SpaceHack 2.0. Participants. SpaceHack 2.0: an expert in the loop consensus driven framework for spatially aware clustering [Computer software]. https://github.com/SpatialHackathon/SpaceHack2023
258-
259-
# License
260-
261-
We have adopted the "MIT No Attribution" (MIT-0) License. It is currently attributed to the "SpaceHack organizers", but please also make sure to add your name to your contributions. More on MIT-0 [here](https://github.com/aws/mit-0)
265+
<!-- readme: contributors -end -->
266+
267+
# Citation
268+
269+
We are close to releasing a preprint. Until then, please cite us as follows:
270+
271+
> SpaceHack 2.0. Participants. SpaceHack 2.0: an expert in the loop consensus driven framework for spatially aware clustering [Computer software]. https://github.com/SpatialHackathon/SpaceHack2023
272+
273+
# License
274+
275+
We have adopted the "MIT No Attribution" (MIT-0) License. It is currently attributed to the "SpaceHack organizers", but please also make sure to add your name to your contributions. More on MIT-0 [here](https://github.com/aws/mit-0)

0 commit comments

Comments
 (0)