diff --git a/.gitignore b/.gitignore
index c18220f..903efe9 100644
--- a/.gitignore
+++ b/.gitignore
@@ -48,3 +48,6 @@ tests/data/
tests/results/
tests/baseline_staging/
test_output.txt
+
+# docs
+docs_buildhtml
diff --git a/AGENTS.md b/AGENTS.md
index 821b2c4..293e4dc 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -42,43 +42,51 @@ Non-Python tools used by contributor workflows:
## Common Commands
-Use `py` on this Windows system, not `python`.
+Prefer the repository-local virtual environment at `.\venv`. Activate it before
+issuing Python commands so `python`, console scripts, and `uv pip` all use that
+environment. If activation is not possible, invoke
+`.\venv\Scripts\python.exe -m ...` directly. Use `uv run ...` only when the
+local `venv` is unavailable and you need uv to create or sync an environment.
+
+```powershell
+# Create the repo-local environment if it does not already exist
+uv venv venv
+.\venv\Scripts\Activate.ps1
-```bash
# Install in editable mode
uv pip install -e .
# Lint and format
-ruff check . --fix && ruff format .
+python -m ruff check . --fix && python -m ruff format .
# Type checking
-mypy src/ tests/
+python -m mypy src/ tests/
# All pre-commit hooks
-pre-commit run --all-files
+python -m pre_commit run --all-files
# Fast tests
-py -m pytest tests/ -v
+python -m pytest tests/ -v
# Single test file or test by name
-py -m pytest tests/test_contour_tools.py -v
-py -m pytest tests/test_contour_tools.py::test_extract_surface -v
+python -m pytest tests/test_contour_tools.py -v
+python -m pytest tests/test_contour_tools.py::test_extract_surface -v
# Opt-in test buckets
-py -m pytest tests/ -v --run-slow
-py -m pytest tests/ -v --run-gpu
-py -m pytest tests/ -v --run-simpleware
-py -m pytest tests/ -v --run-experiments
-py -m pytest tests/ -v --run-tutorials
+python -m pytest tests/ -v --run-slow
+python -m pytest tests/ -v --run-gpu
+python -m pytest tests/ -v --run-simpleware
+python -m pytest tests/ -v --run-experiments
+python -m pytest tests/ -v --run-tutorials
# Typical local GPU profile
-py -m pytest tests/ -v --run-gpu --run-slow
+python -m pytest tests/ -v --run-gpu --run-slow
# Coverage
-py -m pytest tests/ --cov=src/physiomotion4d --cov-report=html
+python -m pytest tests/ --cov=src/physiomotion4d --cov-report=html
# Create missing baselines
-py -m pytest tests/ --create-baselines
+python -m pytest tests/ --create-baselines
```
Version bumping: `bumpver update --patch`, `--minor`, or `--major`.
@@ -95,7 +103,8 @@ Version bumping: `bumpver update --patch`, `--minor`, or `--major`.
below 88 characters.
- Full type hints are required under strict mypy. Use `Optional[X]`, not
`X | None`.
-- Run `py -m pytest tests/ -v` to verify changes. Slow, GPU, Simpleware,
+- Run `python -m pytest tests/ -v` from the active `.\venv` to verify changes.
+ Slow, GPU, Simpleware,
experiment, and tutorial tests are auto-skipped unless their opt-in flag is
passed.
- The `requires_data` marker no longer exists. Tests that need external data
@@ -172,8 +181,8 @@ Version bumping: `bumpver update --patch`, `--minor`, or `--major`.
- Update docstrings for every changed public method. Keep claims factual.
- Document with docstrings and inline comments.
- Do not create new `.md` files unless explicitly requested.
-- Regenerate `docs/API_MAP.md` after any public API change:
- `py utils/generate_api_map.py`.
+- Regenerate `docs/API_MAP.md` after any public API change from the active
+ `.\venv`: `python utils/generate_api_map.py`.
## Architecture Role
diff --git a/docs/API_MAP.md b/docs/API_MAP.md
index 2bdc798..d434243 100644
--- a/docs/API_MAP.md
+++ b/docs/API_MAP.md
@@ -5,9 +5,9 @@ _Re-run `py utils/generate_api_map.py` whenever public APIs change._
## docs/conf.py
-- **class Mock** (line 20)
-- `def autodoc_skip_member(app, what, name, obj, skip, options)` (line 222): Custom function to skip certain members during autodoc processing.
-- `def setup(app)` (line 230): Custom setup function for Sphinx.
+- **class Mock** (line 22)
+- `def autodoc_skip_member(app, what, name, obj, skip, options)` (line 227): Custom function to skip certain members during autodoc processing.
+- `def setup(app)` (line 239): Custom setup function for Sphinx.
## experiments/Colormap-VTK_To_USD/colormap_vtk_to_usd.py
@@ -428,6 +428,10 @@ _Re-run `py utils/generate_api_map.py` whenever public APIs change._
- `def main()` (line 19): Command-line interface for create statistical model workflow.
+## src/physiomotion4d/cli/download_data.py
+
+- `def main(argv=None)` (line 16): Download a supported PhysioMotion4D example dataset.
+
## src/physiomotion4d/cli/fit_statistical_model_to_patient.py
- `def main()` (line 17): Command-line interface for heart model to patient registration.
@@ -870,7 +874,7 @@ _Re-run `py utils/generate_api_map.py` whenever public APIs change._
## tests/test_cli_smoke.py
-- `def test_cli_help(module_name, monkeypatch, capsys)` (line 24): Each CLI module exits successfully for --help.
+- `def test_cli_help(module_name, monkeypatch, capsys)` (line 25): Each CLI module exits successfully for --help.
## tests/test_contour_tools.py
@@ -916,6 +920,11 @@ _Re-run `py utils/generate_api_map.py` whenever public APIs change._
- `def test_mask_ids_missing_boundary_labels_falls_back(self, tmp_path)` (line 562): Mesh without boundary_labels array falls back to a 'default' prim.
- `def test_mask_ids_groups_by_segmenter_type(self, tmp_path)` (line 577): When a segmenter is supplied, labels are grouped under their
+## tests/test_download_data_cli.py
+
+- `def test_download_data_cli_uses_default_dataset_and_directory(monkeypatch, capsys)` (line 14): Default CLI arguments route Slicer-Heart-CT to data/Slicer-Heart-CT.
+- `def test_download_data_cli_uses_requested_directory(monkeypatch, tmp_path)` (line 34): The --directory option controls where Slicer-Heart-CT is stored.
+
## tests/test_download_heart_data.py
- **class TestDataDownloadTools** (line 16): Synthetic tests for dataset verification helpers.
diff --git a/docs/_static/custom.css b/docs/_static/custom.css
index d32439e..69f6eb8 100644
--- a/docs/_static/custom.css
+++ b/docs/_static/custom.css
@@ -268,13 +268,21 @@ dt.sig {
line-height: 1.08;
}
-.pm4d-hero p:not(.pm4d-kicker) {
+.pm4d-hero p:not(.pm4d-kicker):not(.pm4d-hero__version) {
max-width: 760px;
margin: 0;
color: #d8dde6;
font-size: 1.1rem;
}
+.pm4d-hero p.pm4d-hero__version {
+ max-width: 760px;
+ margin: 1.9rem 0 0;
+ color: #ffffff;
+ font-size: 0.78rem;
+ font-weight: 700;
+}
+
.pm4d-card-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
diff --git a/docs/api/cli/download_data.rst b/docs/api/cli/download_data.rst
new file mode 100644
index 0000000..409c1c5
--- /dev/null
+++ b/docs/api/cli/download_data.rst
@@ -0,0 +1,10 @@
+===================
+download_data (CLI)
+===================
+
+.. automodule:: physiomotion4d.cli.download_data
+ :members:
+ :undoc-members:
+ :show-inheritance:
+
+See :doc:`../../cli_scripts/download_data` for usage examples.
diff --git a/docs/api/cli/index.rst b/docs/api/cli/index.rst
index 1e57083..b6440d1 100644
--- a/docs/api/cli/index.rst
+++ b/docs/api/cli/index.rst
@@ -22,6 +22,7 @@ Module Index.
convert_image_to_vtk
convert_vtk_to_usd
create_statistical_model
+ download_data
fit_statistical_model_to_patient
reconstruct_highres_4d_ct
visualize_pca_modes
diff --git a/docs/architecture.rst b/docs/architecture.rst
index 7524cd8..58d09aa 100644
--- a/docs/architecture.rst
+++ b/docs/architecture.rst
@@ -9,8 +9,8 @@ configuration.
.. warning::
- PhysioMotion4D 2026.05.07 beta is not validated for clinical use. It is a
- research and visualization toolkit, not a medical device.
+ PhysioMotion4D {{ pm4d_project_version }} beta is not validated for clinical
+ use. It is a research and visualization toolkit, not a medical device.
Data Flow
=========
diff --git a/docs/cli_scripts/best_practices.rst b/docs/cli_scripts/best_practices.rst
index 532839e..2bd2a4c 100644
--- a/docs/cli_scripts/best_practices.rst
+++ b/docs/cli_scripts/best_practices.rst
@@ -242,7 +242,7 @@ Ensuring Reproducible Results
# processing_metadata.yaml
patient_id: patient_001
- physiomotion4d_version: 2026.05.07
+ physiomotion4d_version: {{ pm4d_project_version }}
script: heart-gated-ct
date: 2026-01-08
diff --git a/docs/cli_scripts/byod_tutorials.rst b/docs/cli_scripts/byod_tutorials.rst
index 22881f2..ec43132 100644
--- a/docs/cli_scripts/byod_tutorials.rst
+++ b/docs/cli_scripts/byod_tutorials.rst
@@ -1,19 +1,18 @@
.. _byod_tutorials:
-Bring Your Own Data — DICOM & VTK to USD
-=========================================
+Bring Your Own Data - DICOM, Images & VTK to USD
+================================================
-PhysioMotion4D lets you convert your own medical imaging data — whether
-DICOM-derived NIfTI volumes or VTK surface meshes — into OpenUSD for
-interactive visualization in NVIDIA Omniverse. Both 3D (single
-volume/mesh) and 4D (time-series) inputs are supported. The CLI and
-Python API are **identical** for 3D and 4D inputs; the only difference
-is how many files you pass in.
+PhysioMotion4D lets you convert your own medical imaging data into OpenUSD for
+interactive visualization in NVIDIA Omniverse. Image inputs may be a directory
+of 3D or 4D DICOM data, a single 3D or 4D file in a common medical image format
+such as MHA, NRRD, or NIfTI, or a list of 3D image files representing a time
+series. VTK inputs may be one mesh file or a mesh sequence.
.. note::
PhysioMotion4D is a research tool and has **not** been validated for
- clinical use. Outputs must not be used for diagnostic or therapeutic
+ clinical use. Outputs must not be used for diagnostic or therapeutic
decisions without independent validation.
Installation
@@ -24,41 +23,66 @@ or the CPU-only variant:
.. code-block:: bash
- # Recommended — CUDA-enabled
+ # Recommended - CUDA-enabled
pip install physiomotion4d[cuda13]
# CPU-only
pip install physiomotion4d
-Verify that both relevant CLI entry-points are available after installation:
+Verify that all three relevant CLI entry-points are available after installation:
.. code-block:: bash
+ physiomotion4d-download-data --help
physiomotion4d-convert-image-to-usd --help
physiomotion4d-convert-vtk-to-usd --help
See :doc:`/installation` for prerequisites, CUDA version requirements, and
source-based installation.
-DICOM to USD
-------------
+Download Demonstration Data
+---------------------------
+
+Use the installed download CLI to fetch the public Slicer-Heart 4D CT sample:
+
+.. code-block:: bash
+
+ physiomotion4d-download-data
-Raw DICOM images must first be converted to NIfTI with a tool such as
-`dcm2niix
Version {{ pm4d_project_version }}
Use production command-line workflows for conversion, reconstruction, modeling, and USD export.
+ +Find PhysioMotion4D workflows and assets for Isaac for Healthcare use cases.
+Browse classes and modules for workflows, segmentation, registration, USD, and utilities.
@@ -136,6 +135,7 @@ per-tutorial implementation details. :hidden: cli_scripts/overview + cli_scripts/download_data cli_scripts/heart_gated_ct cli_scripts/create_statistical_model cli_scripts/fit_statistical_model_to_patient @@ -173,6 +173,14 @@ per-tutorial implementation details. contributing testing +.. toctree:: + :maxdepth: 2 + :caption: Isaac for Healthcare + :hidden: + + isaac_for_healthcare + cli_scripts/byod_tutorials + .. toctree:: :maxdepth: 1 :caption: Additional Resources @@ -183,6 +191,13 @@ per-tutorial implementation details. references changelog +Clinical Use +============ + +Not validated for clinical use. PhysioMotion4D {{ pm4d_project_version }} beta +is a research and visualization toolkit, not a medical device. Do not use it +for diagnosis, treatment planning, or clinical decision-making. + Indices and tables ================== diff --git a/docs/installation.rst b/docs/installation.rst index 8fa03d8..f63ce96 100644 --- a/docs/installation.rst +++ b/docs/installation.rst @@ -171,7 +171,7 @@ Expected output: .. code-block:: text - PhysioMotion4D version: 2026.05.07 + PhysioMotion4D version: {{ pm4d_project_version }} WorkflowConvertImageToUSD Command-Line Tools diff --git a/docs/isaac_for_healthcare.rst b/docs/isaac_for_healthcare.rst new file mode 100644 index 0000000..b860a96 --- /dev/null +++ b/docs/isaac_for_healthcare.rst @@ -0,0 +1,20 @@ +Isaac for Healthcare +==================== + +Use these resources to create, inspect, and download PhysioMotion4D assets for +Isaac for Healthcare workflows. + +.. raw:: html + +