<div dir="ltr"><div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small">Hi Matias,</div><div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small">can you check that all images in that series have size 512x512? A possible cause is if one of the images has size 484x484.</div><div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small">Orientation and region are not connected too much, I doubt that a funky orientation would cause problems for region.</div><div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small"><div dir="ltr"><div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small">Regards,</div><div class="gmail_default"><font face="verdana, sans-serif">Dženan Zukić, PhD, Senior R&D Engineer, Kitware (Carrboro, N.C.)</font></div></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Aug 7, 2017 at 3:57 PM, matimont <span dir="ltr"><<a href="mailto:matimontg@gmail.com" target="_blank">matimontg@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
I'm reading a serie from a directory and I get this:<br>
<br>
itk::<wbr>InvalidRequestedRegionError (0000001D4B9AEDD8)<br>
Location: "unknown"<br>
File: c:\itk-4.12.0\modules\io\<wbr>imagebase\include\<wbr>itkImageFileReader.hxx<br>
Line: 350<br>
Description: ImageIO returns IO region that does not fully contain the<br>
requested regionRequested region: ImageRegion (0000001D4B9AEDA0)<br>
  Dimension: 3<br>
  Index: [0, 0, 0]<br>
  Size: [512, 512, 1]<br>
StreamableRegion region: ImageRegion (0000001D4B9AEE00)<br>
  Dimension: 3<br>
  Index: [0, 0, 0]<br>
  Size: [484, 484, 1]<br>
<br>
I noticed the images I read have ImageOrientationPatient as:<br>
(0020,0037)     ImageOrientationPatient<br>
-0.4181660095794\0.<wbr>90837062283655\0\0\0\-1<br>
<br>
This only patient has failed, all others work<br>
<br>
Would this cause the reader to fail?<br>
<br>
This is part of the code I use to read the series:<br>
<br>
ImageIOType::Pointer gdcmIO = ImageIOType::New();<br>
  InputNamesGeneratorType::<wbr>Pointer inputNames =<br>
InputNamesGeneratorType::New()<wbr>;<br>
  inputNames->SetInputDirectory( argv[1] );<br>
<br>
  const ReaderType::FileNamesContainer & filenames =<br>
                            inputNames->GetInputFileNames(<wbr>);<br>
<br>
  ReaderType::Pointer reader = ReaderType::New();<br>
<br>
  reader->SetImageIO( gdcmIO );<br>
  reader->SetFileNames( filenames );<br>
  try<br>
    {<br>
                reader->Update();<br>
    }<br>
  catch (itk::ExceptionObject &excp)<br>
    {<br>
    std::cerr << "Exception thrown while reading the series" << std::endl;<br>
    std::cerr << excp << std::endl;<br>
    return EXIT_FAILURE;<br>
    }<br>
<br>
Thanks,<br>
<br>
Matias.<br>
<br>
<br>
<br>
--<br>
View this message in context: <a href="http://itk-insight-users.2283740.n2.nabble.com/Reader-InvalidRequestedRegionError-tp7590161.html" rel="noreferrer" target="_blank">http://itk-insight-users.<wbr>2283740.n2.nabble.com/Reader-<wbr>InvalidRequestedRegionError-<wbr>tp7590161.html</a><br>
Sent from the ITK Insight Users mailing list archive at Nabble.com.<br>
______________________________<wbr>_______<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at<br>
<a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/<wbr>opensource/opensource.html</a><br>
<br>
Kitware offers ITK Training Courses, for more information visit:<br>
<a href="http://www.kitware.com/products/protraining.php" rel="noreferrer" target="_blank">http://www.kitware.com/<wbr>products/protraining.php</a><br>
<br>
Please keep messages on-topic and check the ITK FAQ at:<br>
<a href="http://www.itk.org/Wiki/ITK_FAQ" rel="noreferrer" target="_blank">http://www.itk.org/Wiki/ITK_<wbr>FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/insight-users" rel="noreferrer" target="_blank">http://public.kitware.com/<wbr>mailman/listinfo/insight-users</a><br>
</blockquote></div><br></div>