scverse / scverse/spatialdata

Parallel computation

Open
#694 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

question ❓
Dominant language
Python
Stars
394
Forks
95
Avg merge
4d 3h
Merged PRs (30d)
7

Description

I retrieving the Visium spot from a mask.

I found the procedure a little bit slow.
Is it possible to parallelize the following code?

# Determine which spots are within the mask
points_within_mask = points_df.apply(lambda row: mask_geometry.contains(Point(row['x'], row['y'])), axis=1)
spots_in_mask = points_df[points_within_mask]

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 by locating the implementation corresponding to the shown points_df.apply call and inspect how the mask and spot data are represented. Measure the current operation, then define completion as equivalent spots_in_mask results with a demonstrated improvement from parallel computation; the issue names no test or file to run.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
data, performance
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.