Skip to content

Commit e5afa43

Browse files
authored
Fix tests/test_warp.py (#7794)
Fixes #7793 ### Description The Update() method in ITK is used to trigger the execution of the pipeline. Add it to checks if the output data is up-to-date. If it is not (for example, if the input data or parameters have changed), it will recompute the output. ### Types of changes <!--- Put an `x` in all the boxes that apply, and remove the not applicable items --> - [x] Non-breaking change (fix or new feature that would not break existing functionality). - [ ] Breaking change (fix or new feature that would cause existing functionality to change). - [ ] New tests added to cover the changes. - [ ] Integration tests passed locally by running `./runtests.sh -f -u --net --coverage`. - [x] Quick tests passed locally by running `./runtests.sh --quick --unittests --disttests`. - [ ] In-line docstrings updated. - [ ] Documentation updated, tested `make html` command in the `docs/` folder. Signed-off-by: YunLiu <55491388+KumoLiu@users.noreply.github.com>
1 parent 373c003 commit e5afa43

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

tests/test_warp.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,6 +217,7 @@ def itk_warp(img, ddf):
217217
# warp
218218
warp_filter.SetDisplacementField(displacement_field)
219219
warp_filter.SetInput(itk_img)
220+
warp_filter.Update()
220221
warped_img = warp_filter.GetOutput()
221222
warped_img = np.asarray(warped_img)
222223

0 commit comments

Comments
 (0)