D'Isidoro Fabio
2017-05-12 12:26:46 UTC
Hallo,
is it possible to initialize the same metric object multiple times (i.e. 50 times), with different fixed images and/or different masks?
For example:
metric = MattesMutualInformationImageToImageMetricv4[ImageType,ImageType].New()
metric.SetTransform(identityTransform)
metric.SetFixedImage( FixedImage1 )
metric.SetFixedImageMask(spatialObjectMask1 )
metric.SetMovingImage(MovingImage)
metric.Initialize()
metric.GetValue()
...
...
metric.SetFixedImage( FixedImage2 )
metric.SetFixedImageMask(spatialObjectMask2 )
metric.Initialize()
metric.GetValue()
...
...
metric.SetFixedImage( FixedImage3 )
metric.SetFixedImageMask(spatialObjectMask3 )
metric.Initialize()
metric.GetValue()
I read on the manual that "initialize() is for one-time initialization", but I m not sure what that means.
Thank you,
Fabio.
is it possible to initialize the same metric object multiple times (i.e. 50 times), with different fixed images and/or different masks?
For example:
metric = MattesMutualInformationImageToImageMetricv4[ImageType,ImageType].New()
metric.SetTransform(identityTransform)
metric.SetFixedImage( FixedImage1 )
metric.SetFixedImageMask(spatialObjectMask1 )
metric.SetMovingImage(MovingImage)
metric.Initialize()
metric.GetValue()
...
...
metric.SetFixedImage( FixedImage2 )
metric.SetFixedImageMask(spatialObjectMask2 )
metric.Initialize()
metric.GetValue()
...
...
metric.SetFixedImage( FixedImage3 )
metric.SetFixedImageMask(spatialObjectMask3 )
metric.Initialize()
metric.GetValue()
I read on the manual that "initialize() is for one-time initialization", but I m not sure what that means.
Thank you,
Fabio.