Skip to content

Conversation

N-Dekker
Copy link
Contributor

@N-Dekker N-Dekker commented Oct 2, 2025

Replaced for loops with equivalent calls to Size::CalculateProductOfElements().

Most cases were found by the following regular expression:

^([ ]+)for .+\r\n\1{\r\n\1  .+\*= .+Size.+;\r\n\1}

Replaced a `for` loop with a call to `Size::CalculateProductOfElements()`.
Replaced a `for` loop with a call to `CalculateProductOfElements()`, in both
ImagePCADecompositionCalculator and ImagePCAShapeModelEstimator.
Replaced a `for` loop with a call to `CalculateProductOfElements()`, in each
of the three large image write/read tests.
@github-actions github-actions bot added type:Testing Ensure that the purpose of a class is met/the results on a wide set of test cases are correct area:Filtering Issues affecting the Filtering module area:IO Issues affecting the IO module labels Oct 2, 2025
@N-Dekker
Copy link
Contributor Author

N-Dekker commented Oct 3, 2025

The ITK.Linux CI failures appear unrelated to this pull request:


Internal ctest changing into directory: /home/vsts/work/1/s-build/Testing/Temporary/ITKImageFeature
CMake Error: Unable to read from file 'itkHessianRecursiveGaussianFilterTest.txt': Can't lstat itkHessianRecursiveGaussianFilterTest.txt
Error creating tar while encoding file: /home/vsts/work/1/s-build/Testing/Temporary/ITKImageFeature/itkHessianRecursiveGaussianFilterTest.txt
...

@N-Dekker N-Dekker marked this pull request as ready for review October 3, 2025 08:56
@N-Dekker
Copy link
Contributor Author

N-Dekker commented Oct 3, 2025

/azp run ITK.Linux

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:Filtering Issues affecting the Filtering module area:IO Issues affecting the IO module type:Testing Ensure that the purpose of a class is met/the results on a wide set of test cases are correct
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants