<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">
Hello,
<div class=""><br class="">
</div>
<div class="">After a recent change to ITK some random sampling is now being seeded by the wall clock instead of a fixed integer[1]. While one can globally set the seed to a fixed value. I am thinking it would be best to allow the user to control which components
 are “fixed” random verses “wall clock” random, to aid in reproducibility and what not.</div>
<div class=""><br class="">
</div>
<div class="">In SimpleITK I have a test for the Optimizer’s scales estimator that began failing to my surprise[1] with the ITK updated locally. I expected some registration related to random sampling of the virtual domain to change but I was surprised about
 the Optimizer’s scales. So what is interesting:</div>
<div class=""><br class="">
</div>
<div class="">1) The Euler2DTransform is not being classified as an Affine transform by the parameter estimator.</div>
<div class="">2) The random sampling strategy is used for the parameter scale estimator.</div>
<div class="">3) There is no way to set the specific seed used for this random image iteration. The further oddity is that the ImageRandomIterators use a global singleton, so if you did set a seed for the iterator, it modified the global singleton, there by
 having global side effects.</div>
<div class=""><br class="">
</div>
<div class="">The parameters estimator is an interesting case for “wall clock” randomness. The small differences in the parameter scales due to randomness get amplified over the optimization process of registration.</div>
<div class=""><br class="">
</div>
<div class="">What to do? How can we provide control of the scales estimator’s randomness?</div>
<div class=""><br class="">
</div>
<div class="">Thanks,</div>
<div class="">Brad</div>
<div class=""><br class="">
</div>
<div class=""><br class="">
</div>
<div class=""><br class="">
</div>
<div class=""><br class="">
</div>
<div class=""><br class="">
</div>
<div class="">[1] <a href="https://github.com/InsightSoftwareConsortium/ITK/commit/4e6c5bd69a8c24181fee18901ea232084f6ab785" class="">https://github.com/InsightSoftwareConsortium/ITK/commit/4e6c5bd69a8c24181fee18901ea232084f6ab785</a></div>
<div class="">[2] <a href="https://github.com/SimpleITK/SimpleITK/blob/69bb27bde3250a0db591bfa111a5bd2f44de0ef5/Testing/Unit/sitkImageRegistrationMethodTests.cxx#L844-L873" class="">https://github.com/SimpleITK/SimpleITK/blob/69bb27bde3250a0db591bfa111a5bd2f44de0ef5/Testing/Unit/sitkImageRegistrationMethodTests.cxx#L844-L873</a></div>
<div class="">[3] <a href="https://github.com/InsightSoftwareConsortium/ITK/blob/6b8108dd6a05cd32dee20e5f1fd29e47d7f31a77/Modules/Numerics/Optimizersv4/include/itkRegistrationParameterScalesEstimator.hxx#L397" class="">https://github.com/InsightSoftwareConsortium/ITK/blob/6b8108dd6a05cd32dee20e5f1fd29e47d7f31a77/Modules/Numerics/Optimizersv4/include/itkRegistrationParameterScalesEstimator.hxx#L397</a></div>
</body>
</html>