import pyvista
import omfvista
pyvista. set_plot_theme( 'document' )
project = omfvista. load_project( 'data/test_file.omf' )
project
Information Blocks
MultiBlock Values
N Blocks 9
X Bounds 443941.105, 447059.611
Y Bounds 491941.536, 495059.859
Z Bounds 2330.000, 3555.942
Index Name Type
0 collar PolyData
1 wolfpass_WP_assay PolyData
2 Topography UnstructuredGrid
3 Basement UnstructuredGrid
4 Early Diorite UnstructuredGrid
5 Intermineral diorite UnstructuredGrid
6 Dacite UnstructuredGrid
7 Cover UnstructuredGrid
8 Block Model RectilinearGrid
project. plot( multi_colors= True )
vol = project[ 'Block Model' ]
assay = project[ 'wolfpass_WP_assay' ]
topo = project[ 'Topography' ]
dacite = project[ 'Dacite' ]
vol. slice_orthogonal( ) . plot( )
threshed = vol. threshold_percent( [ 0.25 , 0.75 ] )
threshed. plot( clim= vol. get_data_range( ) )
p = pyvista. Plotter( )
p. add_mesh( topo, cmap= 'gist_earth' , opacity= 0.5 )
p. add_mesh( threshed, opacity= 0.5 )
p. add_mesh( assay, color= 'red' , line_width= 3 )
p. add_mesh( dacite, color= 'yellow' , opacity= 0.6 )
p. show_bounds( )
p. show( )
Reference
PVGeo-Examples