I missed the first part of the thread, but thought I would comment on Daniels assertion regarding the windows machines.  VS 8 has implemented assertions into the stl libraries only for DEBUG mode in an attempt to remove memory management errors.  These are real errors, that are never caught and rarely cause problems on non-Windows systems during run time.  A quick check might be to compile and run your code and ITK as Release (RelWithDebInfo may also work, try it first).  One of three things will happen. 1)  If the assertion is not thrown by the VS 8 debug libraries, but is thrown by something else, your code will behave the same.  2) If the assertion is being thrown by the VS 8 debug libraries, but the error does not cause immediate problems, your code will run, or 3) Your code will crash and you can get an idea of where (you will need many print statements to do this in Release, RelWithDebInfo should get you within a few lines in the debugger.)
<br><br>- Wes Turner<br><br><div><span class="gmail_quote">On 1/11/07, <b class="gmail_sendername">Ashish Singh</b> &lt;<a href="mailto:mrasingh@gmail.com">mrasingh@gmail.com</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Thanks Dan. I tried this one also, still doesn&#39;t work. If I comment the
writer1-&gt;Update() line, it goes through the for loop(the code works then, but I want to be able to write the files).Or even if I
read the same image again and again in the loop, it works.<div><span class="e" id="q_1101378f6d9356b8_1"><br><br><div><span class="gmail_quote">On 1/11/07, <b class="gmail_sendername">Daniel Mace</b> &lt;<a href="mailto:dlm19@duke.edu" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
dlm19@duke.edu</a>&gt; wrote:</span>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Ashish,<br><br>The assertion errors tend to pop up (only/more often) with windows<br>machines for some reason, so they are odd bugs to track down.&nbsp;&nbsp;I could
<br>be wrong, but I&#39;m not entirely sure that your image file has set its<br>region settings correctly.&nbsp;&nbsp;Just to make sure, after the line<br>-----------------<br>InputImageType::Pointer image = reader-&gt;GetOutput();
<br>-----------------<br><br>add in a<br>-----------------<br>image-&gt;Update()<br>----------------<br><br>Just to make sure that the image-&gt;GetRequestedRegion() actually returns<br>a valid region.&nbsp;&nbsp;I&#39;m pretty sure that assigning it to an image doesn&#39;t
<br>actually create the image regions until it is forced to update.&nbsp;&nbsp;Had<br>this code been in a ImageToImageFilter the Update() would be propagated<br>down the line before the Regions and iterators were called in the<br>
GenerateData() method.&nbsp;&nbsp;I don&#39;t think that is happening here.
<br><br>Cheers,<br>Dan<br><br>Ashish Singh wrote:<br>&gt; Hi Dan,<br>&gt;<br>&gt; I tried it with the &#39;for&#39; loop that you suggested. I even tried it<br>&gt; with different set of images. It behaves the same each time, 
i.e. the<br>&gt; first run in the for loop goes fine, the second time, it crashes. So<br>&gt; what I did was to comment each line below the reader-&gt;Update() one by<br>&gt; one to find out if anything else is causing the error. And I found out
<br>&gt; that if I comment the writer1-&gt;Update() line down below in the for<br>&gt; loop, it doesn&#39;t crash at reader-&gt;Update anymore and goes through the<br>&gt; entire for loop. But then I don&#39;t want to comment the
<br>&gt; writer1-&gt;Update() line, because then I can&#39;t write the files.<br>&gt; Do you know how to fix it? Has anyone else faced this problem?<br>&gt;<br>&gt; Thanks,<br>&gt; Ashish<br>&gt;<br>&gt; On 1/11/07, *Daniel Mace* &lt; 
<a href="mailto:dlm19@duke.edu" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">dlm19@duke.edu</a> &lt;mailto:<a href="mailto:dlm19@duke.edu" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
dlm19@duke.edu</a>&gt;&gt;<br>&gt; wrote:<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Ashish,<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; It could be an issue with the reader reading in that particular file.
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Tracking down the particular location of the vector assertion<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; error can<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; be a bit painful as everything is caught by the ITK exception<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; libraries<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; and repropagated.&nbsp;&nbsp;See what happens if you start you loop off with
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; the<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; second image.&nbsp;&nbsp;Replace your for loop with the following and see if it<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; gets through the first iteration.<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; ---------------------------<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; for(fni = 1; fni&lt;numberOfFilenames; fni++)
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; ---------------------------<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; If it still dies on the second loop, then we can at least<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; contribute it<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; to the code you wrote and not an error with the reader reading in a
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; particular tag/etc. for that particular image.<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Cheers,<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Dan<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Ashish Singh wrote:<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; Dan here&#39;s my complete code.It is crashing inside the loop
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; second time<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; at the reader-&gt;Update().Can you or anyone please help me figure out<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; what&#39;s wrong&nbsp;&nbsp;here?<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; Thanks,<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; Ashish<br>

&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; ------------<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; #include &quot; itkImageFileReader.h&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; #include &quot;itkImageFileWriter.h&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; #include &quot;itkRescaleIntensityImageFilter.h&quot;<br>
&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; #include &quot;
itkGDCMImageIO.h&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; #include &quot;itkImageRegionConstIterator.h&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; #include &quot;itkImageRegionIterator.h&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; #include &quot;itkRegionOfInterestImageFilter.h&quot;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; #include &quot;itkGDCMSeriesFileNames.h&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; #include &lt;list&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; #include &lt;fstream&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; #include &lt;vector&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; #include &lt;itksys/SystemTools.hxx&gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; using namespace std;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;int main( int argc, char* argv[] )<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;{<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; typedef signed short InputPixelType;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; const unsigned int&nbsp;&nbsp; InputDimension = 2;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; typedef itk::Image&lt; InputPixelType, InputDimension &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; InputImageType;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; typedef itk::ImageFileReader&lt; InputImageType &gt; ReaderType;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; typedef itk::GDCMImageIO&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ImageIOType;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; ImageIOType::Pointer gdcmImageIO = ImageIOType::New();<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; ReaderType::Pointer reader = ReaderType::New();
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; typedef itk::GDCMSeriesFileNames NamesGeneratorType;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; NamesGeneratorType::Pointer nameGenerator =<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; NamesGeneratorType::New();<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; nameGenerator-&gt;SetInputDirectory( &quot;D:\\testimages\\SRS00001&quot;&nbsp;&nbsp;);
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; typedef std::vector&lt;std::string&gt; FileNamesContainer;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; FileNamesContainer fileNames = nameGenerator-&gt;GetInputFileNames();<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; unsigned int numberOfFilenames =&nbsp;&nbsp;
fileNames.size();<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; std::cout &lt;&lt; numberOfFilenames &lt;&lt; std::endl;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; unsigned int fni;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; for(fni = 0; fni&lt;numberOfFilenames; fni++)<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; {<br>
&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp; std::cout &lt;&lt; &quot;filename # &quot; &lt;&lt; fni &lt;&lt; &quot; = &quot;;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp; std::cout &lt;&lt; fileNames[fni] &lt;&lt; std::endl;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; }<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;typedef itk::Image&lt;InputPixelType, InputDimension&gt; InputImageType;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;typedef itk::ImageRegionConstIterator&lt; InputImageType &gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; ConstIteratorType;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;typedef itk::ImageRegionIterator&lt; InputImageType &gt; IteratorType;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;InputImageType::Pointer image2 = InputImageType::New();<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;typedef itk::ImageFileWriter&lt; InputImageType &gt;&nbsp;&nbsp;Writer1Type;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;Writer1Type::Pointer writer1 = Writer1Type::New();<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; for(fni = 0; fni&lt;numberOfFilenames; fni++)<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; {<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; cout&lt;&lt;&quot;inside for loop&quot;&lt;&lt;&quot; &quot;&lt;&lt;&quot;loop # &quot;&lt;&lt;fni&lt;&lt;endl;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; reader-&gt;SetFileName( fileNames[fni] );<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; reader-&gt;SetImageIO( gdcmImageIO );<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; try<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; reader-&gt;Update();
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; catch (itk::ExceptionObject &amp; e)<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::cerr &lt;&lt; &quot;exception in file reader &quot; &lt;&lt; std::endl;
<br>
&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::cerr &lt;&lt; e &lt;&lt; std::endl;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return EXIT_FAILURE;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;InputImageType::Pointer image = reader-&gt;GetOutput();
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;image2-&gt;SetRegions(image-&gt;GetRequestedRegion());<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;image2-&gt;CopyInformation(image);<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;image2-&gt;Allocate();<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;ConstIteratorType in1( image, image-&gt;GetRequestedRegion() );
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;IteratorType out( image2, image-&gt;GetRequestedRegion() );<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for (in1.GoToBegin(),out.GoToBegin<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; ();!in1.IsAtEnd();++in1,++out)<br>
&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; //copy original image to new image
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; out.Set(in1.Get());<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if(fni==0)<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; writer1-&gt;SetFileName(&quot;D:\\testimages\\SRS\\IM1.dcm&quot; );
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if(fni==1)<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; writer1-&gt;SetFileName(&quot;D:\\testimages\\SRS\\IM2.dcm&quot; );<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; writer1-&gt;SetInput( image2 );<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; writer1-&gt;SetImageIO(gdcmImageIO);
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; try<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; writer1-&gt;Update();<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; catch (itk::ExceptionObject &amp; e)<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::cerr &lt;&lt; &quot;exception in file writer &quot; &lt;&lt; std::endl;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::cerr &lt;&lt; e &lt;&lt; std::endl;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return EXIT_FAILURE;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; }//for loop end<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp; return EXIT_SUCCESS;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;}<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; --------------<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br></blockquote></div><br>

</span></div><br>_______________________________________________<br>Insight-users mailing list<br><a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:Insight-users@itk.org">Insight-users@itk.org</a><br>
<a onclick="return top.js.OpenExtLink(window,event,this)" href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br><br><br></blockquote></div><br><br clear="all">
<br>-- <br>Wesley D. Turner, Ph.D.<br>R&amp;D Engineer<br>28 Corporate Drive<br>Clifton Park, NY 12065-8662<br>Phone: 518-371-3971 x120