Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -407,8 +407,8 @@ jobs:
# The following tests are excluded from CI and should be run locally:
#
# Slow/GPU-intensive tests:
# - tests/test_register_images_ants.py (slow, computationally intensive)
# - tests/test_register_images_icon.py (requires CUDA for ICON)
# - tests/test_register_images_ANTS.py (slow, computationally intensive)
# - tests/test_register_images_ICON.py (requires CUDA for ICON)
Comment on lines +410 to +411
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Fix excluded-test note filenames to match real paths.

Line 410, Line 411, and Line 424 reference uppercase test filenames. The repository test files are lowercase, so these examples are misleading and can fail when copied.

Suggested fix
-# - tests/test_register_images_ANTS.py (slow, computationally intensive)
-# - tests/test_register_images_ICON.py (requires CUDA for ICON)
+# - tests/test_register_images_ants.py (slow, computationally intensive)
+# - tests/test_register_images_icon.py (requires CUDA for ICON)
...
-#   pytest tests/test_register_images_ANTS.py -v --run-slow
+#   pytest tests/test_register_images_ants.py -v --run-slow

Also applies to: 424-424

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/ci.yml around lines 410 - 411, The excluded-test example
filenames in the CI config use uppercase names
(tests/test_register_images_ANTS.py and tests/test_register_images_ICON.py) that
don't match the actual lowercase test files; update these occurrences (including
the additional occurrence noted around the later reference) to the real
lowercase filenames (tests/test_register_images_ants.py and
tests/test_register_images_icon.py) so examples match repository paths and won't
mislead or break copy/paste.

# - tests/test_transform_tools.py (depends on slow registration tests)
# - tests/test_segment_chest_total_segmentator.py (requires CUDA for TotalSegmentator)
#
Expand All @@ -421,7 +421,7 @@ jobs:
# pytest tests/ -v --run-slow # Run all slow tests
# pytest tests/ -v --run-gpu --run-slow # GPU + slow (typical local dev profile)
# pytest tests/ -v --run-simpleware --run-gpu --run-slow # Full Simpleware coverage
# pytest tests/test_register_images_ants.py -v --run-slow
# pytest tests/test_register_images_ANTS.py -v --run-slow
#
# Self-hosted GPU runner enables ALL buckets via --run-all
# (--run-gpu --run-slow --run-simpleware --run-physicsnemo --run-experiments --run-tutorials).
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ network_weights
*.gz
*.mat
*.mhd
*.raw
*.zip
*.nii
*.tfm
Expand Down
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ print(WorkflowConvertImageToUSD.__name__)
- **Registration Classes**: Multiple registration methods for different use cases
- Image-to-Image Registration:
- `RegisterImagesICON`: Deep learning-based registration using Icon algorithm
- `RegisterImagesANTs`: Classical deformable registration using ANTs
- `RegisterImagesANTS`: Classical deformable registration using ANTs
- `RegisterTimeSeriesImages`: Specialized time series registration for 4D CT
- Model-to-Image/Model Registration:
- `RegisterModelsPCA`: PCA-based statistical shape model registration
Expand Down Expand Up @@ -354,7 +354,7 @@ if "lung" in masks:
### Image Registration

```python
from physiomotion4d import RegisterImagesICON, RegisterImagesANTs, RegisterTimeSeriesImages
from physiomotion4d import RegisterImagesICON, RegisterImagesANTS, RegisterTimeSeriesImages
import itk

# Option 1: Icon deep learning registration (GPU-accelerated)
Expand All @@ -364,14 +364,14 @@ registerer.set_fixed_image(itk.imread("reference_frame.mha"))
results = registerer.register(itk.imread("target_frame.mha"))

# Option 2: ANTs classical registration
registerer = RegisterImagesANTs()
registerer = RegisterImagesANTS()
registerer.set_fixed_image(itk.imread("reference_frame.mha"))
results = registerer.register(itk.imread("target_frame.mha"))

# Option 3: Time series registration for 4D CT
time_series_reg = RegisterTimeSeriesImages(
reference_index=0,
registration_method='icon' # or 'ants'
registration_method='ICON' # or 'ANTS'
)
transforms = time_series_reg.register_time_series(
image_filenames=["time00.mha", "time01.mha", "time02.mha"]
Expand Down Expand Up @@ -663,9 +663,9 @@ pytest tests/ -v --run-gpu --run-slow
# Run specific test categories
pytest tests/test_usd_merge.py -v # USD merge functionality
pytest tests/test_usd_time_preservation.py -v # Time-varying data preservation
pytest tests/test_register_images_ants.py -v --run-slow # ANTs registration
pytest tests/test_register_images_ANTS.py -v --run-slow # ANTs registration
pytest tests/test_register_images_greedy.py -v # Greedy registration
pytest tests/test_register_images_icon.py -v --run-gpu --run-slow # Icon registration (GPU)
pytest tests/test_register_images_ICON.py -v --run-gpu --run-slow # Icon registration (GPU)
pytest tests/test_register_time_series_images.py -v --run-slow # Time series registration
Comment thread
aylward marked this conversation as resolved.
pytest tests/test_segment_chest_total_segmentator.py -v --run-slow # TotalSegmentator
pytest tests/test_contour_tools.py -v # Mesh and contour tools
Expand Down Expand Up @@ -735,7 +735,7 @@ will change, and flag any coordinate-system or shape implications.
Use `/impl` for end-to-end implementation: read → summarize → plan → diff → lint.

```text
/impl add set_regularization_weight() to RegisterImagesANTs
/impl add set_regularization_weight() to RegisterImagesANTS
```

```text
Expand All @@ -757,7 +757,7 @@ Use `/test-feature` to get a test plan and a complete pytest file using syntheti
```

```text
/test-feature RegisterImagesANTs with a pair of small synthetic ITK images
/test-feature RegisterImagesANTS with a pair of small synthetic ITK images
```

The agent will state image shapes and axis orders in every test docstring, wire
Expand All @@ -772,7 +772,7 @@ Use `/doc-feature` after modifying a public API to refresh docstrings and regene
the API map.

```text
/doc-feature update docstrings for RegisterImagesANTs after adding set_regularization_weight
/doc-feature update docstrings for RegisterImagesANTS after adding set_regularization_weight
```

The agent will update affected docstrings in NumPy style, add shape/axis annotations
Expand Down
Loading
Loading