what is the role of workers with locally_exlusive_torch or locally_exclusive_cl?

Open
#4,273 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

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

Research direction

No files, tests, or entry points are named. Start by tracing how workers are handled by locally_exclusive and locally_exclusive_torch, then compare their CPU and GPU execution paths; document what workers mean for each mode, whether changing the count matters, and how the observed performance should be interpreted.

Written by the indexing model from the issue text.

Description

concurrency question

I'm getting back in to motion correction, and I am testing out some new options.

I ran a test on 10 minutes of NPX 1.0 data. I used the locally_exclusive peak detection and completed the run in 212 seconds (timed using python's perf_counter) with 12 workers using a 28-logical processors ~3.7 GHz CPU (2024 i7). I then tested locally_exclusive_torch and completed the run in 216 seconds using the same settings on a 4000 Ada GPU. My task manager shows essentially 100% utilization of either CPU or GPU during these runs.

I noticed on the progress bar that the torch version also said it was using 12 workers.

What is the meaning of workers when we run something on the GPU? My understanding is that this is not typical language for the parallel processing on the GPU, and that typically we just let cuda run its magic "beneath the hood"

Would you recommend changing the number of workers when running these steps on GPU? Or does that not have a meaningful impact? If a process is parallelizable I would expect more of a performance improvement moving from CPU to GPU. Do you have any ideas if the performance I observed is expected?

Dominant language
Python
Stars
847
Forks
280
Avg merge
3d 9h
Merged PRs (30d)
29

Contributor guide

No contributing guide indexed for this repository

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.

More from SpikeInterface/spikeinterface

All issues in SpikeInterface/spikeinterface

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.