# SAMModel output size different to the input

**URL:** <https://discuss.huggingface.co/t/sammodel-output-size-different-to-the-input/89340>\
**Category:** Intermediate\
**Created:** [May 30, 2024, 7:02am UTC](https://discuss.huggingface.co/t/sammodel-output-size-different-to-the-input/89340 "2024-05-30T07:02:18Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![nielsr](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/nielsr/32/39617_2.png) [@nielsr](https://discuss.huggingface.co/u/nielsr)\
**Post date:** [June 3, 2024, 1:23pm UTC](https://discuss.huggingface.co/t/sammodel-output-size-different-to-the-input/89340/2 "2024-06-03T13:23:03Z")

</div>

Hi,

You can interpolate the masks to the same size as your input, see my reply here: [SAM image size for fine-tuning - #2 by nielsr](https://discuss.huggingface.co/t/sam-image-size-for-fine-tuning/39666/2)

---

_[View the full topic](https://discuss.huggingface.co/t/sammodel-output-size-different-to-the-input/89340)._
