to_paraview

to_paraview(im, filename, phase=2)[source]

Converts an array to a paraview state file.

Parameters
  • im (ndarray) – The image of the porous material.

  • filename (str) – Path to output file.

  • phase (str) – The desired phase of output image where phase = 0 represent the pore phase, phase = 1 represents the solid phase, and phase= 2 is the whole domain. The default value is 2.

Notes

Outputs an pvsm file that can opened in Paraview.