Visualization and Export

visualization.export_data(data, export_type='vtk', fileName='mesostructure.vti')[source]

The function exports data in the 3D array to the given export type (ex. vtk, npy, npz, csv, txt etc.).

Parameters
  • data (3D array of size NXNXN, type int) – Micro/Mesostructure/Inclusion in voxel format.

  • export_type (str.) – Export type (vtk/csv/txt/npy/npz)

  • fileName (str.) – File location and file name with proper extension (./…/fileName.csv for export_type=’csv’)

visualization.visualize_sections(matrix, slices=2)[source]

Visualize 2D sections of 3D matrix. Given number of sections (slices) are generated in each direction (xy,xz,yz)

visualization.vti_tail(f)[source]
visualization.write_vti_format(filename, phaseScalar)[source]

e.g write_vti_format(‘model101.vti’, mcrt)