ankurankan huggingbahl21 commited on
Commit
3040359
·
1 Parent(s): debeee3

Add prepared CausalBench K562 and RPE1 datasets (#3)

Browse files

- Add prepared CausalBench K562 and RPE1 datasets (a022bb677232a6ec032987afc3ec4615d8887b44)
- Simplify CausalBench sources, preprocessing, and verification notes (b7e3f569407dd8bc653cd2c61ce3a3092da4a1a0)
- Simplify CausalBench sources, preprocessing, and verification notes (2e19ab996dff3490444f62dbd10b376cc4298348)


Co-authored-by: aryaman bahl <huggingbahl21@users.noreply.huggingface.co>

real/causalbench/README.md ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # CausalBench K562 and RPE1
2
+
3
+ Filtered single-cell CRISPRi data from [Replogle et al. (2022)](https://doi.org/10.25452/figshare.plus.20029387.v1), prepared following [CausalBench](https://doi.org/10.1038/s42003-025-07764-y). Data license: CC BY 4.0, credited to Replogle et al.
4
+
5
+ | Dataset | Cells | Genes | Prepared table |
6
+ | --- | ---: | ---: | --- |
7
+ | K562 | 162,751 | 622 | [causalbench_k562.tsv.gz](data/causalbench_k562.tsv.gz) |
8
+ | RPE1 | 162,733 | 383 | [causalbench_rpe1.tsv.gz](data/causalbench_rpe1.tsv.gz) |
9
+
10
+ Each gzip TSV contains gene-expression columns (Ensembl IDs) and an `intervention` column: a targeted gene ID, `non-targeting` for controls, or `excluded` for targets not retained by preprocessing. `excluded` cells are not controls.
11
+
12
+ ## Sources and preprocessing
13
+
14
+ The downloaded inputs were:
15
+
16
+ - `k562.h5ad`: [K562 count matrix from Figshare, file 35773219](https://ndownloader.figshare.com/files/35773219).
17
+ - `rpe1.h5ad`: [RPE1 count matrix from Figshare, file 35775606](https://ndownloader.figshare.com/files/35775606).
18
+ - `summary_stats.xlsx`: [Replogle et al. supplementary workbook (`1-s2.0-S0092867422005979-mmc2.xlsx`)](https://ars.els-cdn.com/content/image/1-s2.0-S0092867422005979-mmc2.xlsx), using sheets `TabB_K562_day6_summary_stat` and `TabC_RPE1_summary_statistic`.
19
+
20
+ The names above are the local filenames used during preparation.
21
+
22
+ The reference is the authors' [preprocessing implementation at commit 1a2143c](https://github.com/causalbench/causalbench/blob/1a2143cffdc85f835b41ce8d52034be1bf903e71/causalscbench/data_access/utils/preprocessing.py), with strong-perturbation filtering enabled:
23
+
24
+ 1. Keep controls and perturbations with >50 differentially expressed genes, knockdown <= -0.3, and >25 filtered cells in the summary.
25
+ 2. For measured targets, keep perturbed cells whose target expression is at or below the control 10th percentile.
26
+ 3. Remove zero-total cells, normalize cell totals to the retained-cell median using all original genes, and apply natural `log1p`.
27
+ 4. Keep measured genes targeted in >100 retained cells; relabel unsupported targets `excluded` without dropping their rows.
28
+
29
+ K562 used the original function. RPE1 used a memory-saving implementation of the same rules. [Raw inputs, preparation code, and environment](https://huggingface.co/datasets/huggingbahl21/causalbench) are available for reproduction.
30
+
31
+ ## Comparison with CausalBench
32
+
33
+ These tables use the original input datasets and follow the authors' filtered preprocessing linked above. They are our prepared exports, not processed files downloaded from the CausalBench authors. An exact match to author-provided processed matrices has not been verified.
34
+
35
+ Both downloaded count matrices matched Figshare's checksums. Rebuilding from the raw inputs reproduced the saved expression arrays and gene/intervention labels; exporting to TSV changed numerical values by at most `2.3841e-7`. The [preparation code and inputs](https://huggingface.co/datasets/huggingbahl21/causalbench) are available to reproduce the tables.
real/causalbench/data/causalbench_k562.tsv.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:455024efc9f40b877f7f9c1d55f9eaaf957c7995c6289ffbcd65251fc856fee5
3
+ size 119111966
real/causalbench/data/causalbench_rpe1.tsv.gz ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:6ddd100eff9dbcab65ff94b662a87e9eb50de6401b5242c0f0108692c92cc408
3
+ size 56774957