<table cellspacing="0" cellpadding="0" border="0" ><tr><td valign="top" style="font: inherit;">Bonjour à tous le monde.<div>j'ai deux problèmes, et je demande votre aide. Je sais pas comment accéder à un pixel d'une image en utilisant itk seulement et comment je peut séparer chaque région tous seul en utilisant l'algorithme d'EM-expectation maximisation.</div><div>je vous remerci d'avance.<br><br>--- En date de : <b>Sam 23.5.09, insight-users-request@itk.org <i><insight-users-request@itk.org></i></b> a écrit :<br><blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px;"><br>De: insight-users-request@itk.org <insight-users-request@itk.org><br>Objet: Insight-users Digest, Vol 61, Issue 92<br>À: insight-users@itk.org<br>Date: Samedi 23 Mai 2009, 2h57<br><br><div class="plainMail">Send Insight-users mailing list submissions to<br> <a ymailto="mailto:insight-users@itk.org"
href="/mc/compose?to=insight-users@itk.org">insight-users@itk.org</a><br><br>To subscribe or unsubscribe via the World Wide Web, visit<br> <a href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>or, via email, send a message with subject or body 'help' to<br> <a ymailto="mailto:insight-users-request@itk.org" href="/mc/compose?to=insight-users-request@itk.org">insight-users-request@itk.org</a><br><br>You can reach the person managing the list at<br> <a ymailto="mailto:insight-users-owner@itk.org" href="/mc/compose?to=insight-users-owner@itk.org">insight-users-owner@itk.org</a><br><br>When replying, please edit your Subject line so it is more specific<br>than "Re: Contents of Insight-users digest..."<br><br><br>Today's Topics:<br><br> 1. Re: itk.PyBuffer memory leak (Ga?tan Lehmann)<br> 2. Processing of median filter in debug (Ivan Macia)<br> 3.
Re: Processing of median filter in debug (John Drescher)<br> 4. Re: Processing of median filter in debug (Bill Lorensen)<br> 5. dependency on imview (Darren Weber)<br> 6. Attending? RSVP please, ITK Code Review, May 28-29, 2009 at<br> NLM (Terry Yoo)<br> 7. Re: dependency on imview (Richard Beare)<br><br><br>----------------------------------------------------------------------<br><br>Message: 1<br>Date: Fri, 22 May 2009 18:56:35 +0200<br>From: Ga?tan Lehmann <<a ymailto="mailto:gaetan.lehmann@jouy.inra.fr" href="/mc/compose?to=gaetan.lehmann@jouy.inra.fr">gaetan.lehmann@jouy.inra.fr</a>><br>Subject: Re: [Insight-users] itk.PyBuffer memory leak<br>To: Rick Giuly <<a ymailto="mailto:rgiuly@gmail.com" href="/mc/compose?to=rgiuly@gmail.com">rgiuly@gmail.com</a>><br>Cc: ITK Users <<a ymailto="mailto:insight-users@itk.org" href="/mc/compose?to=insight-users@itk.org">insight-users@itk.org</a>><br>Message-ID: <<a
ymailto="mailto:69B55A56-B590-47FC-8363-3F0ED14C7863@jouy.inra.fr" href="/mc/compose?to=69B55A56-B590-47FC-8363-3F0ED14C7863@jouy.inra.fr">69B55A56-B590-47FC-8363-3F0ED14C7863@jouy.inra.fr</a>><br>Content-Type: text/plain; charset="iso-8859-1"; Format="flowed";<br> DelSp="yes"<br><br><br>My test also work on the stable version of wrapitk (with a few changes <br>in command manipulation).<br><br>I tried with the test you provided, and this time I get an error:<br><br> RuntimeError: Contiguous array couldn't be created from input <br>python object<br><br>This error is sent from PyBuffer when it can't convert the input <br>python object to the expected type. Maybe the array returned by <br>numpy.ones() is not a contigus array?<br><br>Ga?tan<br><br><br>Le 22 mai 09 ? 15:56, Ga?tan Lehmann a ?crit :<br><br>><br>> Hi Rick,<br>><br>> Yes, I looked at it in wrapitk *unstable* - it may not be the one <br>> you're using.<br>> I can't reproduce
the problem you have. Here is the test I've run:<br>><br>> #!/usr/bin/env python<br>><br>> import itk, sys, gc<br>> itk.auto_progress()<br>><br>> # image size is 1 GB<br>> # IT = itk.Image.UC3<br>> # img = IT.New(Regions=1000)<br>><br>> # image size is 1 GB<br>> IT = itk.Image.F3<br>> img = IT.New(Regions=[1000, 1000, 250])<br>><br>> img.Allocate()<br>> img.FillBuffer(0)<br>><br>> print img<br>><br>> # exercise buffer conversion from itk to numpy<br>> for i in range(1000):<br>> buf = itk.PyBuffer[IT].GetArrayFromImage(img)<br>> del buf<br>><br>> # exercise buffer conversion from numpy to itk<br>><br>> count = 0<br>><br>> def callback():<br>> global count<br>> sys.stderr.write(str(count)+"\t")<br>> if count%10 == 0:<br>> sys.stderr.write("\n")<br>> sys.stderr.flush()<br>> count += 1<br>> com = itk.PyCommand.New()<br>> com.SetCommandCallable( callback )<br>><br>> buf = itk.PyBuffer[IT].GetArrayFromImage(img)<br>><br>> for i in
range(1000):<br>> bi = itk.PyBuffer[IT].GetImageFromArray(buf)<br>> bi.AddObserver( itk.DeleteEvent(), com )<br>> del bi<br>><br>> # force garbage collection<br>> gc.collect()<br>><br>> sys.stderr.write(str(count)+"\n")<br>><br>> sys.exit(abs(1000-count))<br>><br>><br>><br>><br>> I'm now looking at wrapitk stable. I'll let you know what I'll found.<br>><br>> Ga?tan<br>><br>><br>> Le 22 mai 09 ? 06:16, Rick Giuly a ?crit :<br>><br>>> Hi Ga?tan,<br>>><br>>> Have you had a chance to look at this?<br>>><br>>> thanks<br>>><br>>> -rick<br>>><br>>> Ga?tan Lehmann wrote:<br>>>> Le 13 mai 09 ? 10:35, Rick Giuly a ?crit :<br>>>>><br>>>>> I've now tested invoking garbage collection with gc.collect() at <br>>>>> every iteration and that didn't change the problem. So, my best <br>>>>> guess would be that the image is not deleted when the python <br>>>>> object is destroyed. Maybe a bug?<br>>>> Maybe - can you file a bug on ITK's bug tracker and assign it
to me?<br>>>> I'll try to find a bit of time to investigate this in the next days.<br>>>>><br>>>>><br>>>>><br>>>>> Ga?tan Lehmann wrote:<br>>>>>> Hi Rick,<br>>>>>> GetImageFromArray() returns a smart pointer to an image, so the <br>>>>>> image should be deallocated once the python object is destroyed.<br>>>>>> Perhaps the problem is there: the garbage collection my not run <br>>>>>> fast enough.<br>>>>>> The right way to go may be to implement PyBuffer as a filter <br>>>>>> which reuse the output image, as all the filters in itk.<br>>>>>> For the Delete() method: you shouldn't use it in python (and I <br>>>>>> can't see any case for use it but the internal memory management <br>>>>>> in c++). In the latest version of wrapitk (the one hosted at <br>>>>>> googlecode), Delete() and the other methods related to smart <br>>>>>> pointers are hidden.<br>>>>>> Regards,<br>>>>>> Ga?tan<br>>>>>> Le 11 mai 09 ? 05:43, Rick Giuly a ?crit
:<br>>>>>>><br>>>>>>> Hello All,<br>>>>>>><br>>>>>>> It seems that converter.GetImageFromArray(inputNumpyVolume) <br>>>>>>> allocates memory in some way and never releases it. When I <br>>>>>>> tried using Delete() the program actually crashed silently <br>>>>>>> after one iteration.<br>>>>>>><br>>>>>>> Test code is below. (I'm running this on ubuntu, and the itk <br>>>>>>> package is from Paul Novo's site.)<br>>>>>>><br>>>>>>> Is there some way to release memory?<br>>>>>>><br>>>>>>><br>>>>>>><br>>>>>>> import itk<br>>>>>>> import numpy<br>>>>>>><br>>>>>>> for i in range(10000):<br>>>>>>><br>>>>>>> print i<br>>>>>>><br>>>>>>> ImageType = itk.Image[itk.F, 3]<br>>>>>>> converter = itk.PyBuffer[ImageType]<br>>>>>>><br>>>>>>> inputNumpyVolume = numpy.ones((100, 100, 200))<br>>>>>>> inputVolume = converter.GetImageFromArray(inputNumpyVolume)<br>>>>>>> #inputVolume.Delete()<br>>>>>>><br>>>>>>><br>>>>>>><br>>>>>>> ----------<br>>>>>>> Thanks,<br>>>>>>>
--Rick<br>>>>>>> _____________________________________<br>>>>>>> Powered by www.kitware.com<br>>>>>>><br>>>>>>> Visit other Kitware open-source projects at<br>>>>>>> <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>>>>>>><br>>>>>>> Please keep messages on-topic and check the ITK FAQ at: <a href="http://www.itk.org/Wiki/ITK_FAQ" target="_blank">http://www.itk.org/Wiki/ITK_FAQ</a><br>>>>>>><br>>>>>>> Follow this link to subscribe/unsubscribe:<br>>>>>>> <a href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>>>>><br>>><br>><br>> -- <br>> Ga?tan Lehmann<br>> Biologie du D?veloppement et de la Reproduction<br>> INRA de Jouy-en-Josas (France)<br>> tel: +33 1 34 65 29 66 fax: 01 34 65 29 09<br>> <a href="http://voxel.jouy.inra.fr" target="_blank">http://voxel.jouy.inra.fr</a> <a
href="http://www.mandriva.org" target="_blank">http://www.mandriva.org</a><br>> <a href="http://www.itk.org" target="_blank">http://www.itk.org</a> <a href="http://www.clavier-dvorak.org" target="_blank">http://www.clavier-dvorak.org</a><br>><br><br>-- <br>Ga?tan Lehmann<br>Biologie du D?veloppement et de la Reproduction<br>INRA de Jouy-en-Josas (France)<br>tel: +33 1 34 65 29 66 fax: 01 34 65 29 09<br><a href="http://voxel.jouy.inra.fr" target="_blank">http://voxel.jouy.inra.fr</a> <a href="http://www.mandriva.org" target="_blank">http://www.mandriva.org</a><br><a href="http://www.itk.org" target="_blank">http://www.itk.org</a> <a href="http://www.clavier-dvorak.org" target="_blank">http://www.clavier-dvorak.org</a><br><br>-------------- next part --------------<br>A non-text attachment was scrubbed...<br>Name: PGP.sig<br>Type: application/pgp-signature<br>Size: 203 bytes<br>Desc: Ceci est une signature ?lectronique PGP<br>URL: <<a
href="http://www.itk.org/pipermail/insight-users/attachments/20090522/24f46772/attachment-0001.pgp" target="_blank">http://www.itk.org/pipermail/insight-users/attachments/20090522/24f46772/attachment-0001.pgp</a>><br><br>------------------------------<br><br>Message: 2<br>Date: Fri, 22 May 2009 20:45:12 +0200<br>From: Ivan Macia <<a ymailto="mailto:imacia@vicomtech.org" href="/mc/compose?to=imacia@vicomtech.org">imacia@vicomtech.org</a>><br>Subject: [Insight-users] Processing of median filter in debug<br>To: Insight Users <<a ymailto="mailto:insight-users@itk.org" href="/mc/compose?to=insight-users@itk.org">insight-users@itk.org</a>><br>Message-ID:<br> <<a ymailto="mailto:a199a2980905221145s75446cd8x15d403ff6f669feb@mail.gmail.com" href="/mc/compose?to=a199a2980905221145s75446cd8x15d403ff6f669feb@mail.gmail.com">a199a2980905221145s75446cd8x15d403ff6f669feb@mail.gmail.com</a>><br>Content-Type: text/plain;
charset="iso-8859-1"<br><br>Hi,<br><br>I have been doing some 3D image processing with a Median filter. I added<br>some SimpleFilterWatcher to monitor progress. The input image was not too<br>large, about 250x40x175. I'm running an Intel Core 2 Quad Q6600 (4 cores) 3<br>Gb. RAM on WinXP SP3 and ITK 3.12 with VS2008.<br><br>The filter was running quite fast in release mode but I thought I had a<br>problem in debug since the progress did not update and it seemed to be<br>stuck. Now waiting a bit the progress started to grow at a very low pace.<br>The thing is that I changed the number of threads to a single thread and the<br>filter was running much faster in debug mode. In Release mode, as expected,<br>the it was more than twice faster. Just wondering, is it normal that the<br>cost of running four threads in debug mode makes it so slow? Is this related<br>to the IDE or OS?<br><br>Thanks in advance<br><br>Iv?n<br>-------------- next part
--------------<br>An HTML attachment was scrubbed...<br>URL: <<a href="http://www.itk.org/pipermail/insight-users/attachments/20090522/6d895d1f/attachment-0001.htm" target="_blank">http://www.itk.org/pipermail/insight-users/attachments/20090522/6d895d1f/attachment-0001.htm</a>><br><br>------------------------------<br><br>Message: 3<br>Date: Fri, 22 May 2009 14:55:15 -0400<br>From: John Drescher <<a ymailto="mailto:drescherjm@gmail.com" href="/mc/compose?to=drescherjm@gmail.com">drescherjm@gmail.com</a>><br>Subject: Re: [Insight-users] Processing of median filter in debug<br>To: Ivan Macia <<a ymailto="mailto:imacia@vicomtech.org" href="/mc/compose?to=imacia@vicomtech.org">imacia@vicomtech.org</a>><br>Cc: Insight Users <<a ymailto="mailto:insight-users@itk.org" href="/mc/compose?to=insight-users@itk.org">insight-users@itk.org</a>><br>Message-ID:<br> <<a ymailto="mailto:387ee2020905221155r45b71778uc140c771130dc57@mail.gmail.com"
href="/mc/compose?to=387ee2020905221155r45b71778uc140c771130dc57@mail.gmail.com">387ee2020905221155r45b71778uc140c771130dc57@mail.gmail.com</a>><br>Content-Type: text/plain; charset=ISO-8859-1<br><br>On Fri, May 22, 2009 at 2:45 PM, Ivan Macia <<a ymailto="mailto:imacia@vicomtech.org" href="/mc/compose?to=imacia@vicomtech.org">imacia@vicomtech.org</a>> wrote:<br>> Hi,<br>><br>> I have been doing some 3D image processing with a Median filter. I added<br>> some SimpleFilterWatcher to monitor progress. The input image was not too<br>> large, about 250x40x175. I'm running an Intel Core 2 Quad Q6600 (4 cores) 3<br>> Gb. RAM on WinXP SP3 and ITK 3.12 with VS2008.<br>><br>> The filter was running quite fast in release mode but I thought I had a<br>> problem in debug since the progress did not update and it seemed to be<br>> stuck. Now waiting a bit the progress started to grow at a very low pace.<br>> The thing is that I changed the number of threads to a
single thread and the<br>> filter was running much faster in debug mode. In Release mode, as expected,<br>> the it was more than twice faster. Just wondering, is it normal that the<br>> cost of running four threads in debug mode makes it so slow? Is this related<br>> to the IDE or OS?<br>><br>I have seen this myself and it forced me to debug in releasewithdeb<br>mode instead because instead of taking 30 seconds to process the<br>median filter on a 0.625 x 0.625 x 0.625 it ended up taking on the<br>order of 30 minutes.<br><br>John<br><br><br>------------------------------<br><br>Message: 4<br>Date: Fri, 22 May 2009 15:25:03 -0400<br>From: Bill Lorensen <<a ymailto="mailto:bill.lorensen@gmail.com" href="/mc/compose?to=bill.lorensen@gmail.com">bill.lorensen@gmail.com</a>><br>Subject: Re: [Insight-users] Processing of median filter in debug<br>To: John Drescher <<a ymailto="mailto:drescherjm@gmail.com"
href="/mc/compose?to=drescherjm@gmail.com">drescherjm@gmail.com</a>><br>Cc: Insight Users <<a ymailto="mailto:insight-users@itk.org" href="/mc/compose?to=insight-users@itk.org">insight-users@itk.org</a>><br>Message-ID:<br> <<a ymailto="mailto:4db4735c0905221225p2b51f54cy386b46289377c8bf@mail.gmail.com" href="/mc/compose?to=4db4735c0905221225p2b51f54cy386b46289377c8bf@mail.gmail.com">4db4735c0905221225p2b51f54cy386b46289377c8bf@mail.gmail.com</a>><br>Content-Type: text/plain; charset=ISO-8859-1<br><br>Yes, we have seen this with Debug mode. I didn't realize that the<br>number of threads affected it. I just thought it was slow. As John<br>mentioned, try RelWithDebinfo. That's how I normally debug.<br><br>Bill<br><br>On Fri, May 22, 2009 at 2:55 PM, John Drescher <<a ymailto="mailto:drescherjm@gmail.com" href="/mc/compose?to=drescherjm@gmail.com">drescherjm@gmail.com</a>> wrote:<br>> On Fri, May 22, 2009 at 2:45 PM, Ivan Macia <<a
ymailto="mailto:imacia@vicomtech.org" href="/mc/compose?to=imacia@vicomtech.org">imacia@vicomtech.org</a>> wrote:<br>>> Hi,<br>>><br>>> I have been doing some 3D image processing with a Median filter. I added<br>>> some SimpleFilterWatcher to monitor progress. The input image was not too<br>>> large, about 250x40x175. I'm running an Intel Core 2 Quad Q6600 (4 cores) 3<br>>> Gb. RAM on WinXP SP3 and ITK 3.12 with VS2008.<br>>><br>>> The filter was running quite fast in release mode but I thought I had a<br>>> problem in debug since the progress did not update and it seemed to be<br>>> stuck. Now waiting a bit the progress started to grow at a very low pace.<br>>> The thing is that I changed the number of threads to a single thread and the<br>>> filter was running much faster in debug mode. In Release mode, as expected,<br>>> the it was more than twice faster. Just wondering, is it normal that the<br>>> cost of running four threads in debug mode makes it
so slow? Is this related<br>>> to the IDE or OS?<br>>><br>> I have seen this myself and it forced me to debug in releasewithdeb<br>> mode instead because instead of taking 30 seconds to process the<br>> median filter on a 0.625 x 0.625 x 0.625 ?it ended up taking on the<br>> order of 30 minutes.<br>><br>> John<br>> _____________________________________<br>> Powered by www.kitware.com<br>><br>> Visit other Kitware open-source projects at<br>> <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>><br>> Please keep messages on-topic and check the ITK FAQ at: <a href="http://www.itk.org/Wiki/ITK_FAQ" target="_blank">http://www.itk.org/Wiki/ITK_FAQ</a><br>><br>> Follow this link to subscribe/unsubscribe:<br>> <a href="http://www.itk.org/mailman/listinfo/insight-users"
target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>><br><br><br>------------------------------<br><br>Message: 5<br>Date: Fri, 22 May 2009 15:46:14 -0700<br>From: Darren Weber <<a ymailto="mailto:darren.weber.lists@gmail.com" href="/mc/compose?to=darren.weber.lists@gmail.com">darren.weber.lists@gmail.com</a>><br>Subject: [Insight-users] dependency on imview<br>To: <a ymailto="mailto:insight-users@itk.org" href="/mc/compose?to=insight-users@itk.org">insight-users@itk.org</a><br>Message-ID:<br> <<a ymailto="mailto:b808b3510905221546n15c0d097jd12c59269ed60145@mail.gmail.com" href="/mc/compose?to=b808b3510905221546n15c0d097jd12c59269ed60145@mail.gmail.com">b808b3510905221546n15c0d097jd12c59269ed60145@mail.gmail.com</a>><br>Content-Type: text/plain; charset="utf-8"<br><br>How extensive is the dependency in ITK on imview?<br><br>For example, the tutorial here requires imview to display a 2D image:<br><a
href="http://farsight-toolkit.org/wiki/FARSIGHT_Tutorials/Quick_Start" target="_blank">http://farsight-toolkit.org/wiki/FARSIGHT_Tutorials/Quick_Start</a><br><br>Thanks, Darren<br>-------------- next part --------------<br>An HTML attachment was scrubbed...<br>URL: <<a href="http://www.itk.org/pipermail/insight-users/attachments/20090522/dd152e52/attachment-0001.htm" target="_blank">http://www.itk.org/pipermail/insight-users/attachments/20090522/dd152e52/attachment-0001.htm</a>><br><br>------------------------------<br><br>Message: 6<br>Date: Fri, 22 May 2009 18:15:41 -0400<br>From: Terry Yoo <<a ymailto="mailto:tyoo@mail.nih.gov" href="/mc/compose?to=tyoo@mail.nih.gov">tyoo@mail.nih.gov</a>><br>Subject: [Insight-users] Attending? RSVP please, ITK Code Review, May<br> 28-29, 2009 at NLM<br>To: insight-users <<a ymailto="mailto:insight-users@itk.org"
href="/mc/compose?to=insight-users@itk.org">insight-users@itk.org</a>><br>Message-ID: <<a ymailto="mailto:6C8A3626-B83C-4D86-B14A-DE99DCE649A6@mail.nih.gov" href="/mc/compose?to=6C8A3626-B83C-4D86-B14A-DE99DCE649A6@mail.nih.gov">6C8A3626-B83C-4D86-B14A-DE99DCE649A6@mail.nih.gov</a>><br>Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes<br><br><br>NLM is convening a meeting to collect input on the current status as <br>well as input on future directions for ITK on May 28-29, 2009. The <br>announcement for this meeting was made as a Special Notice posted as <br>FBO announcement number 09-104-CYC.<br><br>We are preparing to host this meeting. We are seeking a head count as <br>part of these preparations. If you are planning to attend the ITK <br>Code Review May 28-29, please RSVP by sending an e-mail to Terry Yoo a <a ymailto="mailto:tyoo@mail.nih.gov"
href="/mc/compose?to=tyoo@mail.nih.gov">tyoo@mail.nih.gov</a><br><br>Thank you.<br><br>Terry S. Yoo, PhD<br>Office of High Performance Computing and Communications<br>National Library of Medicine<br>National Institutes of Health<br><a ymailto="mailto:tyoo@mail.nih.gov" href="/mc/compose?to=tyoo@mail.nih.gov">tyoo@mail.nih.gov</a><br><br><br><br>On May 14, 2009, at 5:02 PM, Yoo, Terry (NIH/NLM/LHC) [E] wrote:<br>><br>> The Special Notice has been posted on FBO. The announcement number<br>> 09-104-CYC.<br>><br>> The National Library of Medicine, Office of High Performance<br>> Computing and Communications is seeking input regarding the<br>> current status of the Insight Toolkit (ITK) as well as input on<br>> future directions for this image-processing software library.<br>> We are holding a meeting to perform a code review, an<br>> informal audit of the state of ITK. We intend to<br>> explore the elements of the library that are most in need<br>> of
revision, the current stability of the library including<br>> a review of the policy for backward compatibility in ITK,<br>> the need for extending support in ITK for high performance<br>> computing environments, and the need for simplifying the<br>> use of ITK for entry-level programmers. The goal is to<br>> prioritize development efforts for ITK, focusing the<br>> programming community on a shared plan. This meeting will<br>> be held from 9AM, May 28, 2009, until Noon, May 29th, 2009,<br>> in the HPCC Collaboratory, National Library of Medicine, NIH<br>> Building 38A, Room B1N30E. For more information, see the<br>> following URL: <a href="http://visual.nlm.nih.gov/itk" target="_blank">http://visual.nlm.nih.gov/itk</a><br>><br>> <a href="https://www.fbo.gov/index?s=opportunity&mode=form&id=0812333190b08edde0c3bec549eb11db&tab=core&_cview=0"
target="_blank">https://www.fbo.gov/index?s=opportunity&mode=form&id=0812333190b08edde0c3bec549eb11db&tab=core&_cview=0</a><br>><br>><br>> Terry S. Yoo, PhD<br>> Office of High Performance Computing and Communications<br>> National Library of Medicine<br>> National Institutes of Health<br>> <a ymailto="mailto:tyoo@mail.nih.gov" href="/mc/compose?to=tyoo@mail.nih.gov">tyoo@mail.nih.gov</a><br><br><br><br>------------------------------<br><br>Message: 7<br>Date: Sat, 23 May 2009 10:51:29 +1000<br>From: Richard Beare <<a ymailto="mailto:richard.beare@gmail.com" href="/mc/compose?to=richard.beare@gmail.com">richard.beare@gmail.com</a>><br>Subject: Re: [Insight-users] dependency on imview<br>To: Darren Weber <<a ymailto="mailto:darren.weber.lists@gmail.com" href="/mc/compose?to=darren.weber.lists@gmail.com">darren.weber.lists@gmail.com</a>><br>Cc: <a ymailto="mailto:insight-users@itk.org"
href="/mc/compose?to=insight-users@itk.org">insight-users@itk.org</a><br>Message-ID:<br> <<a ymailto="mailto:779dabeb0905221751m27a8f11ftca986d05836d750f@mail.gmail.com" href="/mc/compose?to=779dabeb0905221751m27a8f11ftca986d05836d750f@mail.gmail.com">779dabeb0905221751m27a8f11ftca986d05836d750f@mail.gmail.com</a>><br>Content-Type: text/plain; charset=ISO-8859-1<br><br>Not at all.<br><br>Imview is callable from the python interface, and maybe people have<br>added it to other language bindings too. There is an Imview package<br>that uses some of the image server capabilities of Imview - check<br>Gaetan's darcs site for that. Alternative viewers can be called<br>instead, by defining environment variables used by show2d.<br><br>An example from Gaetan:<br><br>It is also possible to use a different viewer in the itk.show2D()<br>function by defining the WRAPITK_SHOW2D_COMMAND environment. For<br>example, for imagej, I have:<br><br> export
WRAPITK_SHOW2D_COMMAND="/usr/java/jdk1.6.0/bin/java -Xmx1024m<br>-jar /home/glehmann/ImageJ/ij.jar %s -run 'View 100%%' &"<br> export WRAPITK_SHOW2D_LABEL_COMMAND="/usr/java/jdk1.6.0/bin/java<br>-Xmx1024m -jar /home/glehmann/ImageJ/ij.jar %s -run 'View 100%%' -run<br>'3-3-2 RGB' &"<br> export WRAPITK_SHOW2D_COMPRESS=off<br><br><br>The imview server binding has some advantages in that it allows a<br>closer coupling of imview and the interpreter which lets you build<br>prototype interactive applications, and better performance because<br>there are no intermediate files - there are some examples in the<br>source package. It will also work with 3D images. The downside is that<br>colour images aren't supported yet.<br><br>On Sat, May 23, 2009 at 8:46 AM, Darren Weber<br><<a ymailto="mailto:darren.weber.lists@gmail.com" href="/mc/compose?to=darren.weber.lists@gmail.com">darren.weber.lists@gmail.com</a>> wrote:<br>><br>> How extensive is the
dependency in ITK on imview?<br>><br>> For example, the tutorial here requires imview to display a 2D image:<br>> <a href="http://farsight-toolkit.org/wiki/FARSIGHT_Tutorials/Quick_Start" target="_blank">http://farsight-toolkit.org/wiki/FARSIGHT_Tutorials/Quick_Start</a><br>><br>> Thanks, Darren<br>><br>><br>> _____________________________________<br>> Powered by www.kitware.com<br>><br>> Visit other Kitware open-source projects at<br>> <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>><br>> Please keep messages on-topic and check the ITK FAQ at:<br>> <a href="http://www.itk.org/Wiki/ITK_FAQ" target="_blank">http://www.itk.org/Wiki/ITK_FAQ</a><br>><br>> Follow this link to subscribe/unsubscribe:<br>> <a href="http://www.itk.org/mailman/listinfo/insight-users"
target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>><br>><br><br><br>------------------------------<br><br>_______________________________________________<br>Insight-users mailing list<br><a ymailto="mailto:Insight-users@itk.org" href="/mc/compose?to=Insight-users@itk.org">Insight-users@itk.org</a><br><a href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br><br><br>End of Insight-users Digest, Vol 61, Issue 92<br>*********************************************<br></div></blockquote></div></td></tr></table><br>