scverse / scverse/rapids-singlecell

[FEA] Dask Array Support for rsc.pp.scrublet: A Straightforward implementation

Open
#388 4 comments 0 reactions 0 assignees View on GitHub

@Intron7 is already working on this.

Since Jul 14, 2025.

  • #405 by @Intron7 — open
enhancement
Dominant language
Python
Stars
394
Forks
52
Avg merge
22h 5m
Merged PRs (30d)
20

Description

Right now, rsc.pp.scrublet doesn't support Dask arrays, and there's a relatively straightforward path to implement one (at least, from what I know).

Background:

  1. Scrublet only really needs to run within a sample, or batch. This is provided to the function as a 'batch_key'
  2. These samples/batches are typically on the order of < 100k cells for batches, or < 10,000 for samples, meaning that they can fit within a typical GPU's memory.

Implementation concept:

  1. Check the the anndata object has a Dask array. If so, require a batch_key be provided.
  2. Rechunk the dask array by batch_key - one dask array for each batch_key
  3. Run scrublet in memory on each GPU (.compute_chunk_sizes())
  4. Save results in obs as normal.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start from the rsc.pp.scrublet entry point and inspect how it currently handles AnnData inputs and batch_key. Check the linked pull request before starting, then verify that Dask-backed arrays are processed per batch and that scrublet results are saved in obs as usual.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
bioinformatics
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.