We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eec406c commit 1c46cfbCopy full SHA for 1c46cfb
SimpleITK/utilities/vtk.py
@@ -77,7 +77,7 @@ def sitk2vtk(image: sitk.Image) -> vtk.vtkImageData:
77
vtk_image.SetDirectionMatrix(direction)
78
79
# Set pixel data
80
- depth_array = vtknp.numpy_to_vtk(sitk.GetArrayViewFromImage(image).ravel())
+ depth_array = vtknp.numpy_to_vtk(sitk.GetArrayFromImage(image).ravel())
81
depth_array.SetNumberOfComponents(ncomp)
82
vtk_image.GetPointData().SetScalars(depth_array)
83
0 commit comments