# OBB script error

**URL:** <https://discourse.slicer.org/t/obb-script-error/21533>\
**Category:** Support\
**Created:** [January 19, 2022, 10:43pm UTC](https://discourse.slicer.org/t/obb-script-error/21533 "2022-01-19T22:43:21Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![matsuba8](https://avatars.discourse-cdn.com/v4/letter/m/59ef9b/32.png) [@matsuba8](https://discourse.slicer.org/u/matsuba8)\
**Post date:** [January 19, 2022, 10:43pm UTC](https://discourse.slicer.org/t/obb-script-error/21533/1 "2022-01-19T22:43:21Z")

</div>

Hello,

I’ve been trying to get the oriented bounding boxes (OBBs) for my segmentations, and have been trying to use the script found on this page ([Script repository — 3D Slicer documentation](https://slicer.readthedocs.io/en/latest/developer_guide/script_repository.html)) under “Markups ROI” of “Get size, position, and orientation of each segment.”

It always works smoothly until the very last line of code, where I get an attribution error as seen in the picture below.

 ![Screen Shot 2022-01-15 at 1.59.55 PM](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/9/b/9b99db545e1d0a53fe12852d4c8937200f5deffc.png)

Why is this happening and how can I fix it?  
Thank you in advance for your help.

Michele
