# Create a cvb.Image object from a numpy array

**URL:** <https://forum.commonvisionblox.com/t/create-a-cvb-image-object-from-a-numpy-array/1733>\
**Category:** Python API\
**Created:** [June 29, 2022, 10:43am UTC](https://forum.commonvisionblox.com/t/create-a-cvb-image-object-from-a-numpy-array/1733 "2022-06-29T10:43:10Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![JRo85](https://avatars.discourse-cdn.com/v4/letter/j/7993a0/32.png) [@JRo85](https://forum.commonvisionblox.com/u/JRo85)\
**Post date:** [June 29, 2022, 10:43am UTC](https://forum.commonvisionblox.com/t/create-a-cvb-image-object-from-a-numpy-array/1733/1 "2022-06-29T10:43:10Z")

</div>

Hello,

is it possible to convert a numpy array to a cvb.Image object? I didn’t find any function to do this. Just found this https://ftp.commonvisionblox.com/webdavs/forum/documents/CVBInterop%201.1.0.pdf, which is unfortunately not helping for the python case.

Thanks for your help!

---

<div class="post-metadata">

**Author:** ![s-woe](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.commonvisionblox.com/s-woe/32/572_2.png) [@s-woe](https://forum.commonvisionblox.com/u/s-woe)\
**Post date:** [June 29, 2022, 11:22am UTC](https://forum.commonvisionblox.com/t/create-a-cvb-image-object-from-a-numpy-array/1733/2 "2022-06-29T11:22:43Z")

</div>

Hi @JRo85 !  
Yes it is! Just try the following:

```auto
import numpy as np
import cvb
any_array = np.ones([2,2]) # 2x2 image of ones
cvb_image = cvb.WrappedImage.from_buffer(any_array)
# continue with cvb_image

```

Hope this helps. For fruther guidance you could look at [Getting-Started-With-CVBpy](https://forum.commonvisionblox.com/t/getting-started-with-cvbpy/241)
