[Insight-users] simultaneous mapping of two regions in the 1st
image to the 2nd image
Ming Chao
mingchao2005 at gmail.com
Fri Jan 13 14:13:22 EST 2006
Hi Luis,
Thanks very much for your excellent answers. Actually Andinet provided me a
similar answer yesterday already. Here I encountered another question
though. Since I need to create this spatial object with more than one
regions in the new image, how do I add thse subregions to the new image.
I tried to add them one by one but at the end of the day, only the last one
was added.
Iterator it( image, insideRegion );
it.GoToBegin();
while( !it.IsAtEnd() )
{
it.Set( itk::NumericTraits< PixelType >::max() );
++it;
}
Here insideRegion is just a single region. Thanks for any hints.
Ming
On 1/13/06, Luis Ibanez <luis.ibanez at kitware.com> wrote:
>
>
> Hi Ming,
>
> Thanks for adding a couple of details to the
> description of the problem that you are facing.
>
>
> Please read the ITK Software Guide
>
> http://www.itk.org/ItkSoftwareGuide.pdf
>
>
> In particular the chapter on "Image Registration".
>
> and section: 8.11.3
>
> "Registration using masks constructed
> with Spatial objects"
>
> in pdf-pages 464-466.
>
> The source code of the example is in
>
> Examples/
> Registration/
> ImageRegistration12.cxx
>
>
> You will find that it is possible to use a binary
> Mask on top of the Fixed Image, and in that way,
> to restrict the computation of the Metric to use
> only the pixels from the FixedImage that are under
> the ON pixels in the Mask.
>
> If you define the binary mask to have ON pixels
> only on top of the two regions that you want to use
> from your image, then the registration process will
> be equivalent sot using just those two regions.
>
> Note that this is not the fastest possible approach.
> In particular if your fixed image is large, and the
> two regions are relatively small. If computation
> time is an issue, please let us know and we could
> suggest you other options. Note that the advantage
> with using the Mask is that you can do it right now
> without having to modify ITK code in any way.
>
>
> Regards,
>
>
>
> Luis
>
>
>
> --------------------
> Ming Chao wrote:
> > Hi Luis,
> >
> > Yes, it is actually registration. Basically I want to find the
> > corresponding two regions in the 2nd image. I think one solution might
> > be to create a new image which contains only the two regions from the
> > 1st image and then do registration (mapping) to find the corresponding
> > two regions in the 2nd image. Does that sound reasonable?
> > Thanks,
> > Ming
> >
> >
> >
> > On 1/12/06, *Luis Ibanez* <luis.ibanez at kitware.com
> > <mailto:luis.ibanez at kitware.com >> wrote:
> >
> >
> > Hi Ming,
> >
> > When you say "mapping" do you mean "registration" ?
> >
> > or do you mean "copy/pasting" image regions ?
> >
> >
> > Please be more generous on the description of your problem,
> >
> >
> > Thanks
> >
> >
> > Luis
> >
> >
> > ----------------
> > Ming Chao wrote:
> > > Hi,
> > >
> > > I have a question about mapping of two regions from one image to
> > a 2nd
> > > image simultaneously. It is fairly straightforward to map the two
>
> > > regions one by one, but how do I map them at the same time?
> > >
> > > Many thanks for any hints in advance,
> > > Ming
> > >
> > >
> > >
> > >
> >
> ------------------------------------------------------------------------
> > >
> > > _______________________________________________
> > > Insight-users mailing list
> > > Insight-users at itk.org <mailto:Insight-users at itk.org>
> > > http://www.itk.org/mailman/listinfo/insight-users
> >
> >
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://public.kitware.com/pipermail/insight-users/attachments/20060113/2e9039aa/attachment.html
More information about the Insight-users
mailing list