name: stereo-seq-3d-reconstruction description: Use when Stereo-seq or STOmics serial sections need multi-slice registration, 3D coordinate reconstruction, slice-to-atlas alignment, shape/contour matching, SABench-informed alignment method choice, or 3D-ready visualization and mapping.
Stereo-seq 3D Reconstruction
Use This For
- Aligning serial Stereo-seq slices or histology masks into a shared coordinate frame.
- Mapping spatial coordinates through thin-plate-spline or other slice-registration transforms.
- Preparing registered coordinates for 3D reconstruction, atlas projection, or cross-section comparison.
- Selecting or auditing 3D spatial alignment methods using the Nature Computational Science 2026 SABench benchmark guidance.
Default Requirements
- Use bundled article-derived scripts in
scripts/before writing new registration or plotting code. - Read source_code.md first for curated templates and SABench alignment-method guidance; if no curated entry fits, search code_candidates.tsv for additional article-linked repositories and reusable files.
- Inspect local Python/R environments first. Prefer
conda run -n stereo-skills-py python ...for Python scripts andconda run -n stereo-skills-r Rscript ...for R scripts. spatiAlign is configured instereo-skills-py; it can also be isolated withenvs/environment-python-spatialign.yml. If a dependency is missing, stop that step and report the missing package and blocked script. - Use equal-aspect spatial plots, readable Arial text, non-overlapping legends, and export PDF/300 dpi diagnostic figures.
- In the final response, state the reused paper, DOI, code repository/source file, and what was changed for the current dataset.
Workflow
- Identify section order, coordinate units, tissue masks, anchors, and whether registration is pairwise or to a shared atlas.
- Read source_code.md, then decide whether the task is method selection/audit or production coordinate transformation.
- For method selection/audit, use SABench guidance to document why the chosen method matches the data context: serial sections, cross-platform slices, large-scale/high-resolution data, partial overlap, rotation sensitivity, landmarks available, or 3D-coordinate ground truth available.
- For production coordinate transformation, adapt the closest local script:
scripts/sabench_alignment_runner_template.pyfor SABench-style PASTE, SLAT, STalign, or QC-only alignment/evaluation from serial h5ad slices.scripts/zebrafish_tps_slice_registration_template.pyfor mask/anchor-based TPS coordinate mapping and QC plots.scripts/spatialign_multislice_alignment_template.pyfor spatiAlign-style multi-slice spatial alignment when that package is installed.scripts/multislice_spatial_qc_template.pyfor SLAT/SPACEL-style multi-slice coordinate QC panels and 3D-ready stacked previews before or after registration.
- Export transformed coordinates and a registration QC plot for every slice pair or atlas mapping.
- Validate registration with landmarks, tissue contours, known anatomical layers, gene-expression similarity, and non-overlap of impossible tissue regions.
- Keep biological interpretation separate from registration quality.
Output Expectations
- Registration method and required inputs.
- Transformed coordinate tables.
- SABench-style runtime/memory/QC/provenance tables when alignment is run through the SABench template.
- QC plots with anchors/contours and equal aspect ratio.
- Caveats for scale, orientation, missing tissue, and manual anchors.
- Reused article code source, paper DOI, repository URL, original file name, and dataset-specific edits.