# largestpossibile region is bigger than request region and m\_buffered region

**URL:** <https://discourse.itk.org/t/largestpossibile-region-is-bigger-than-request-region-and-m-buffered-region/5222>\
**Category:** Uncategorized\
**Created:** [July 28, 2022, 8:15am UTC](https://discourse.itk.org/t/largestpossibile-region-is-bigger-than-request-region-and-m-buffered-region/5222 "2022-07-28T08:15:18Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Bugmaker](https://discourse.itk.org/user_avatar/discourse.itk.org/bugmaker/32/2500_2.png) [@Bugmaker](https://discourse.itk.org/u/Bugmaker)\
**Post date:** [July 28, 2022, 8:15am UTC](https://discourse.itk.org/t/largestpossibile-region-is-bigger-than-request-region-and-m-buffered-region/5222/1 "2022-07-28T08:15:18Z")

</div>

hi  
I load a nii.gz file using ITK, and I find this file`s largest possible region(531,531,604) is bigger than request and m\_buffer region (both of them are 512,512,604). I know this can be fixed by setrequest() or setmybuffer(), but why does this happen? what should I notice?

---

<div class="post-metadata">

**Author:** ![dzenanz](https://discourse.itk.org/user_avatar/discourse.itk.org/dzenanz/32/1093_2.png) [@dzenanz](https://discourse.itk.org/u/dzenanz)\
**Post date:** [July 28, 2022, 12:17pm UTC](https://discourse.itk.org/t/largestpossibile-region-is-bigger-than-request-region-and-m-buffered-region/5222/2 "2022-07-28T12:17:36Z")

</div>

That sounds wrong. Can you share minimal code to reproduce and the offending image?

---

<div class="post-metadata">

**Author:** ![blowekamp](https://discourse.itk.org/user_avatar/discourse.itk.org/blowekamp/32/79_2.png) [@blowekamp](https://discourse.itk.org/u/blowekamp)\
**Post date:** [July 28, 2022, 12:33pm UTC](https://discourse.itk.org/t/largestpossibile-region-is-bigger-than-request-region-and-m-buffered-region/5222/3 "2022-07-28T12:33:53Z")

</div>

Are you reusing the `ImageFileReader` class to read multiple files? Try using `UpdateLargestPossibleRegion()` instead of just `Update()`.

---

<div class="post-metadata">

**Author:** ![Bugmaker](https://discourse.itk.org/user_avatar/discourse.itk.org/bugmaker/32/2500_2.png) [@Bugmaker](https://discourse.itk.org/u/Bugmaker)\
**Post date:** [July 29, 2022, 1:23am UTC](https://discourse.itk.org/t/largestpossibile-region-is-bigger-than-request-region-and-m-buffered-region/5222/4 "2022-07-29T01:23:23Z")

</div>

@blowekamp  
Thanks, that work.
