[Insight-users] ITK 4.0 migration problem with Amoeba optimizer and cardinal metrics
Ziv Yaniv
zyaniv at childrensnational.org
Tue Jan 24 14:26:29 EST 2012
Yann,
This is fine. ITK software is pretty complex and currently everything is
changing, so there are many possible changes that can potentially be
blamed for results varying.
cheers
Ziv
On 1/24/2012 2:22 PM, asertyuio wrote:
> Dear Ziv,
>
> I found the cause of the problem. It comes from a possible change
> (improvement) in tiff reading. Before, b&w (2bit) tiff images were
> read as 0 and 1. Now it seems to be 0 and 255.
>
> Sorry for the lost time !
>
> Yann
>
>
> Le 20/01/2012 21:55, Ziv Yaniv a écrit :
>> Dear Yann,
>>
>> Can you replicate the problem in a small program? Something similar
>> to itkAmoebaOptimizerTest.cxx (Modules\Numerics\Optimizers\test).
>>
>> When I run this test and look at the reason the optimizer stops
>> (GetStopConditionDescription()) it does terminate before reaching the
>> maximum number of iterations.
>>
>> regards
>> Ziv
>>
>> On 1/20/2012 12:50 PM, asertyuio wrote:
>>> Thanks for ansering !
>>>
>>> I haven't found any solution to my problem. Itk code seems to be the
>>> problem.
>>> I can give my source and images if needed !
>>>
>>> Yann
>>>
>>>
>>> Le 18/01/2012 21:46, Cory Quammen a écrit :
>>>> Yann,
>>>>
>>>> Ziv Yaniv did a lot of refactoring of this class for the ITK 4.0
>>>> effort. Ziv, can you comment?
>>>>
>>>> - Cory
>>>>
>>>> On Tue, Jan 17, 2012 at 8:30 AM, asertyuio<asertyuio at yahoo.fr> wrote:
>>>>> Hi all,
>>>>>
>>>>> I'm migrating from ITK 3.2 to ITK 4.0, and after fixing some
>>>>> litle
>>>>> trouble around cmake, I'm on something that seems more problematic.
>>>>> I write for ITK 3.2 a registration process, that was, for part of
>>>>> it, using
>>>>> Amoeba optimizer, and cardinal matching metric.
>>>>> It worked perfectly.
>>>>> After migrating to ITK 4.0, Amoeba optimizer seems to stop only at
>>>>> the
>>>>> maximum iteration number, and do not take account of other stop
>>>>> conditions,
>>>>> like ParametersConvergenceTolerance or FunctionConvergenceTolerance.
>>>>> The optimizer is still converging on a good solution.
>>>>> An other thing that seems to be related, is that when I'm printing
>>>>> the
>>>>> registration progress,
>>>>> the metric value is shown as -1.#IND, so Not A Number. I get this
>>>>> value with
>>>>> the following code :
>>>>>
>>>>> itk::SingleValuedCostFunction::MeasureType Value;
>>>>>
>>>>> Value = optimizer->GetCachedValue();
>>>>>
>>>>>
>>>>> if (Value!=Value){
>>>>> std::cout<< "ok";
>>>>> }
>>>>> if (count>=5) {
>>>>> count=0;
>>>>> std::cout<< IterationNumber<< " ";
>>>>> std::cout<< Value<< " ";
>>>>> std::cout<< parameters<< std::endl;
>>>>> }
>>>>>
>>>>> I've try to set Value as double, to print directly
>>>>> optimizer->GetCachedValue() but it's giving the same result.
>>>>>
>>>>> Does someone have any idea of where it comes from ?
>>>>>
>>>>> In my code, I also use OnePlusOneEvolutionaryOptimizer, and MI metric
>>>>> without these problems.
>>>>>
>>>>> Thanks a lot !
>>>>>
>>>>> Yann
>>>>> _____________________________________
>>>>> Powered by www.kitware.com
>>>>>
>>>>> Visit other Kitware open-source projects at
>>>>> http://www.kitware.com/opensource/opensource.html
>>>>>
>>>>> Kitware offers ITK Training Courses, for more information visit:
>>>>> http://www.kitware.com/products/protraining.html
>>>>>
>>>>> Please keep messages on-topic and check the ITK FAQ at:
>>>>> http://www.itk.org/Wiki/ITK_FAQ
>>>>>
>>>>> Follow this link to subscribe/unsubscribe:
>>>>> http://www.itk.org/mailman/listinfo/insight-users
>>>>
>>>>
>>>
>>>
>>>
>>> -----
>>> No virus found in this message.
>>> Checked by AVG - www.avg.com
>>> Version: 2012.0.1901 / Virus Database: 2109/4755 - Release Date:
>>> 01/20/12
>>
>>
>
>
>
> -----
> No virus found in this message.
> Checked by AVG - www.avg.com
> Version: 2012.0.1901 / Virus Database: 2109/4763 - Release Date: 01/24/12
--
Ziv Yaniv, PhD.,
Principal Investigator,
The Sheikh Zayed Institute for Pediatric Surgical Innovation
Children's National Medical Center
6th Floor Main Hospital, Room M7740
111 Michigan Ave., N.W
Washington, D.C 20010
Phone: 202-476-1288
email: zyaniv at childrensnational.org
web: http://isiswiki.georgetown.edu/zivy/
More information about the Insight-users
mailing list