GetArrayFromImage
makes a deep copy, but GetArrayViewFromImage
is a read only buffer in numpy. With the view you must maintain a ssitk::Image
copy and if you modify the image it could effect the bumpy buffer. There is also SimpleITK’s lazy copying and reference accounting which can affect which image the buffer points to.
1 Like