[upgrade] Baysor: migrate Julia v0.7.1 → C++ cpp-0.8.2 (eliminates PARQUET_TO_CSV for Baysor paths)
Open
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 46
- Forks
- 23
- PR merge metrics
- No merged PRs in 30d
Description
Current state
- Pinned: Baysor v0.7.1 (Julia) at modules/local/baysor/run/main.nf:5
- Source: https://github.com/kharchenkolab/Baysor
masterbranch - Distribution: Julia binary, containerised via community.wave.seqera.io
- Modules:
baysor/{preprocess, create_dataset, run, preview, segfree} - Pipeline modes:
image(cellpose → baysor),coordinate(proseg/segger → baysor),preview,segfree
Proposed upgrade
- Target: Baysor
cpp-0.8.2(C++ port) — released 2026-04-30 - Source: https://github.com/kharchenkolab/Baysor
cppbranch — https://github.com/kharchenkolab/Baysor/releases/tag/cpp-0.8.2 - Distribution: Native C++ binary via CMake, or Docker (image TBD)
- Project description: "a faithful C++ implementation of the current Baysor algorithm with a more efficient runtime and broader modern I/O support"
- Release notes for 0.8.2: "improves cross-platform builds, adds some optimizations for large runs (e.g. Xenium 5K)"
Why upgrade
- Direct parquet support — the C++ port natively reads parquet (no Julia
Parquet.jlZstd issue). This would let us delete thePARQUET_TO_CSVstep inBAYSOR_GENERATE_PREVIEWandBAYSOR_RUN_TRANSCRIPTS_PARQUET(tiled). That step OOMs on the Atera (Xenium WTA 18k-target) at default memory — see the Atera compatibility report (docs/2026-05-28_REVIEW_atera-on-spatialaxe-compatibility.md). - Performance — C++ rewrite is "much more efficient" per project description. Optimizations explicitly target Xenium 5K-panel scale, which is directly relevant to Atera ~18k-target workloads.
- Direct
experiment.xeniuminput — could simplify bundle-staging logic for image- and coordinate-mode subworkflows. - Algorithmic continuity — cpp port preserves the v0.7.1 algorithm, so segmentation behavior should match.
Migration plan
- Identify or build official container for
cpp-0.8.2(binary build vs Docker) - Update containers in
baysor/run,baysor/preview,baysor/segfree,baysor/preprocess,baysor/create_dataset - Audit CLI argument compatibility — cpp may differ from Julia (e.g., column flag names, --scale)
- Drop or refactor
PARQUET_TO_CSVcalls inbaysor_generate_previewandbaysor_run_transcripts_parquetsubworkflows - If
experiment.xeniumdirect input works, simplifyBAYSOR_PREPROCESS_TRANSCRIPTSaccordingly - End-to-end tests on a Xenium v1 bundle (XOA 4.x) and Atera Cell Pellet
Risks
- CLI compatibility: needs per-command verification
- Output format compatibility: cpp may emit different polygon / transcript-assignment file structures; downstream XR import needs validation
- Container ecosystem: no Wave container yet known — may need a request to Seqera or a custom build
Cross-links
- Related (paired): Punkst / Ficture C++ migration — together these eliminate
PARQUET_TO_CSVentirely from the pipeline. - Triggered by: Atera compatibility session 2026-05-28.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with modules/local/baysor/run/main.nf and the baysor/{preprocess, create_dataset, run, preview, segfree} modules. Audit CLI and output compatibility, then review the PARQUET_TO_CSV calls in baysor_generate_preview and baysor_run_transcripts_parquet. Done means a working cpp-0.8.2 container, validated downstream outputs, and successful Xenium and Atera end-to-end tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cmake, cpp, docker, julia
- Domain
- bioinformatics, build-system, data, devops
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100