builds-and-wrapping
Install SimpleITK binaries, choose source or SuperBuild builds, inspect CMake wrapping options, and run safe contributor checks.
- License 许可
- Apache-2.0
- 最近更新
- 2026-09-03
- Stars
- ★ 351
- Forks
- 27
01 前言 Front Matter
- name
- builds-and-wrapping
- license
- Apache 2.0
- metadata
- { "disco-role": "operating" }
- description
- Install SimpleITK binaries, choose source or SuperBuild builds, inspect CMake wrapping options, and run safe contributor checks.
- disable-model-invocation
- true
02 资源文件 5
- 参考文档references/cmake-wrapping.md7.3 KB
- 参考文档references/install-build.md6.6 KB
- 参考文档references/maintainer-checks.md5.4 KB
- 参考文档references/troubleshooting.md6.7 KB
- 脚本scripts/check_build_metadata.py6.3 KB
03 SKILL.md 正文
SimpleITK Builds and Wrapping
Use this sub-skill when a task mentions installing SimpleITK, building from source, configuring the SuperBuild, choosing CMake or WRAP_* options, packaging Python wheels, enabling optional elastix/transformix wrappers, or running maintainer-oriented checks.
Start Here
- Read references/install-build.md to choose PyPI, conda-forge, pre-release wheels,
pip install ., direct CMake, or SuperBuild. - Read references/cmake-wrapping.md for CMake options,
WRAP_*language flags, Python packaging, Python limited API, SWIG-generated wrappers, andSimpleITK_USE_ELASTIX. - Read references/maintainer-checks.md for safe docs, tests, pre-commit, and metadata checks, plus release-heavy exclusions.
- Read references/troubleshooting.md when a wheel is not selected, conda environments mix channels, CMake/SWIG/compiler detection fails, language dependencies are missing, or elastix classes are absent.
- Run scripts/check_build_metadata.py from a SimpleITK source checkout, or pass a checkout path, to print read-only JSON about build metadata files and key flags.
Decision Rules
- Prefer a binary install unless the user needs development-branch code, an unsupported language/platform binary, C++ integration, custom ITK modules, optional elastix wrappers, or maintainer work.
- Prefer
pip install simpleitkfor ordinary Python use; import withimport SimpleITK as sitk, even though the distribution name issimpleitk. - Prefer conda-forge in isolated conda environments; avoid mixing
defaultswithconda-forgefor SimpleITK dependencies. - Prefer SuperBuild for full source builds because it pins/fetches matching ITK, SWIG, GTest, and build support; use direct CMake only when supplying dependencies yourself.
- Treat
pip install .from the source tree as a Python source build: it usesscikit-build-core, CMake, SWIG, and native compilation, so it can be slow and platform-sensitive. - Treat
ElastixImageFilterandTransformixImageFilteras optional build-dependent APIs. They were absent from the inspected wheel, while the source tree contains wrappers and examples.
Route Elsewhere
- For public image construction, spatial metadata, pixel types, and NumPy array conversion, route to ../image-core/SKILL.md.
- For file formats, ImageIO discovery, DICOM series, or transform IO, route to ../io-and-data/SKILL.md.
- For filters, segmentation, smoothing, thresholding, statistics, or N4 bias correction, route to ../filtering-segmentation/SKILL.md.
- For registration, transforms, resampling, or using elastix/transformix after the wrappers exist, route to ../registration-transforms/SKILL.md.
Safety Guardrails
- Mark full source builds, SuperBuilds,
pip install ., docs builds with dependency installation, and broadctestruns as expensive or environment-mutating before running them. - Use the bundled helper only for read-only inspection; it never configures CMake, installs packages, downloads dependencies, or edits generated files.
- Do not rely on source checkout paths at runtime. Copy or write any future helper needed by this skill under this subtree and link it from the nearest
SKILL.md. - Do not use source release automation or download-statistics scripts for ordinary install/build answers; those are release-heavy maintainer tasks outside this sub-skill.
04 同仓库更多 Skills
passnet-triton-opt
Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.
passnet-solve
END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.
passnet-skill
PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.
passnet-pattern-fusion
Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.
passnet-orchestrate
Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.
passnet-feedback
Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).