io¶
  | 
Load an image.  | 
  | 
Load a vtk polydata to a supported format file.  | 
  | 
Save a 2d or 3d image.  | 
  | 
Save a vtk polydata to a supported format file.  | 
  | 
Set Generic input function which takes into account VTK 5 or 6.  | 
load_image¶
load_polydata¶
save_image¶
- 
fury.io.save_image(arr, file_name, compression_quality=100, compression_type='deflation')[source]¶ Save a 2d or 3d image.
- Parameters
 - arr: ndarray
 array to save
- file_name: string
 should be png, bmp, jpeg or jpg files
- compression_quality: int
 compression_quality for jpeg data. 0 = Low quality, 100 = High quality
- compression_type: str
 compression type for tiff file select between: None, lzw, deflation (default)
save_polydata¶
- 
fury.io.save_polydata(polydata, file_name, binary=False, color_array_name=None, is_mni_obj=False)[source]¶ Save a vtk polydata to a supported format file.
Save formats can be VTK, FIB, PLY, STL and XML.
- Parameters
 - polydatavtkPolyData
 - file_namestring
 - binarybool
 - color_array_name: ndarray
 - is_mni_objbool
 
set_input¶
- 
fury.io.set_input(vtk_object, inp)[source]¶ Set Generic input function which takes into account VTK 5 or 6.
- Parameters
 - vtk_object: vtk object
 - inp: vtkPolyData or vtkImageData or vtkAlgorithmOutput
 
- Returns
 - vtk_object
 
Notes
- This can be used in the following way::
 from fury.utils import set_input poly_mapper = set_input(vtk.vtkPolyDataMapper(), poly_data)