소스 정보
- 저장소
- BrainStOrmics/Spateo-Skills
- 최근 소스 활동
- 2026년 6월 15일 12:13
- 감지된 SKILL.md 언어
- 영어
- 스타
- 1
- 포크
- 0
설치 방법
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
소스 파일 검토
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
메뉴
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
직접 명령은 검토 Prompt를 거치지 않습니다. 실행하기 전에 소스를 확인하세요.
npx skills add https://github.com/BrainStOrmics/Spateo-Skills --skill spateo-slice-alignment명령은 한 줄로 유지됩니다. 복사하기 전에 가로로 스크롤해 전체 내용을 확인하세요.
로컬 사본을 원하시나요? SkillsMP에서 현재 제공할 수 있는 파일을 다운로드하세요.
SOC 직업 분류 기준
SKILL.md 표시 중
| name | spateo-slice-alignment |
| description | Spatial alignment of tissue slices — 2D→3D registration |
Register multiple tissue slices into a common coordinate space using morpho_align and morpho_align_ref.
# Align two slices
python -m skills.02_slice_alignment.two_slice \
--slice1 ./data/slice_a.h5ad --slice2 ./data/slice_b.h5ad
# Align multiple slices (z-splitting + 3D concat)
python -m skills.02_slice_alignment.multi_slice \
--input ./data/slices_dir/ --outdir ./output/
# Two-stage 3D alignment (point cloud + reference-based)
python -m skills.02_slice_alignment.two_stage_3d \
--stage1 ./data/stage1.h5ad --stage2 ./data/stage2.h5ad
two_slice.py — Two-slice alignmentfrom skills.02_slice_alignment.two_slice import (
TwoSliceConfig, TwoSliceResult, run_two_slice_pipeline,
)
config = TwoSliceConfig(
slice1_path="./data/slice_a.h5ad",
slice2_path="./data/slice_b.h5ad",
preprocess=True,
use_downsampling=False,
max_iter=300,
)
result = run_two_slice_pipeline(config)
Key APIs: st.align.morpho_align, st.align.morpho_align_ref
multi_slice.py — Multi-slice continuous alignmentSplits data by z-coordinate, aligns consecutive pairs, concatenates in 3D.
from skills.02_slice_alignment.multi_slice import (
MultiSliceConfig, run_multi_slice_pipeline,
)
config = MultiSliceConfig(
input_path="./data/slices/",
z_key="z_coord",
groupby="tissue_type",
max_iter=300,
)
result = run_multi_slice_pipeline(config)
two_stage_3d.py — Two-stage 3D reconstruction + alignmentStage 1: Build point cloud/mesh from individual slices.
Stage 2: Align using reference-based morpho_align_ref.
from skills.02_slice_alignment.two_stage_3d import (
TwoStage3DConfig, run_two_stage_3d_pipeline,
)
Input: AnnData files with .obsm["spatial"] (2D coordinates per slice).
Output: AnnData with .obsm["align_spatial"] (registered coordinates) or concatenated 3D AnnData.
| Parameter | Purpose | Default |
|---|---|---|
slice1_path, slice2_path | Input slice paths | — |
preprocess | Run spateo preprocessing pipeline | True |
spatial_key | Key for input coordinates | "spatial" |
key_added | Key for output coordinates | "align_spatial" |
max_iter | Alignment iterations | 300 |
use_downsampling | Use reference-based alignment | False |
beta | Spatial smoothness weight | 1.0 |
lambdaVF | Vector field regularization | 1.0 |
device | CPU/GPU device | Auto-detected |
| Problem | Fix |
|---|---|
| OOM on GPU | Set use_downsampling=True or device="cpu" |
| Missing spatial key | Verify .obsm["spatial"] exists in input |
| NaN in aligned coords | Check for NaN/Inf in input spatial coords |