io#

The io module contain a function that writes a 2D image array to a VTK format file.


img2vtk()#

pore2chip.io.img2vtk(image, vtk_fl_name, dims, **kwargs)#

Converts 2D image array to 3D vtk model

Parameters:
  • image (2D array) – 2D image array

  • vtk_fl_name (str) – Filename/filepath

  • dims (array) – Size 3 Array-like for x, y, and z dimentions respectively

  • **kwargs – Extra arguements to write to VTK file. Examples: Permeability = perm_matrix … where perm_matrix is an array defining permeability values for each pixel

  • generated_network (dict) – The OpenPNM network containing pore and throat information.

  • throat_random (int) – Multiplier that decides how random the throat shape will be. Default is 1. A value of 0 makes the throats straight.

Returns:

None

Note

This project is under active development.

On this page