Read SGeMS Grid

Read SGeMS Grid file formats.

# sphinx_gallery_thumbnail_number = 2
from pyvista import examples
from PVGeo.gslib import SGeMSGridReader
# grid_url = 'http://www.trainingimages.org/uploads/3/4/7/0/34703305/a_wlreferencecat.zip'
filename, _ = examples.downloads._download_file('A_WLreferenceCAT.sgems')

grid = SGeMSGridReader().apply(filename)
print(grid)

Out:

UniformGrid (0x7f0ea79f1ee8)
  N Cells:      78000
  N Points:     157122
  X Bounds:     0.000e+00, 2.600e+02
  Y Bounds:     0.000e+00, 3.000e+02
  Z Bounds:     0.000e+00, 1.000e+00
  Dimensions:   261, 301, 2
  Spacing:      1.000e+00, 1.000e+00, 1.000e+00
  N Arrays:     1
warped = grid.cell_data_to_point_data().warp_by_scalar(scale_factor=5)
warped.plot()
../../_images/sphx_glr_read-sgems-grid_001.png
# grid_url = 'http://www.trainingimages.org/uploads/3/4/7/0/34703305/maules_creek_3d.zip'
filename, _ = examples.downloads._download_file('Maules_Creek_3D.SGEMS.zip')

grid = SGeMSGridReader().apply(filename)
grid.plot(categories=True)
../../_images/sphx_glr_read-sgems-grid_002.png
# grid_url = 'http://www.trainingimages.org/uploads/3/4/7/0/34703305/ti_horizons_continuous.zip'
filename, _ = examples.downloads._download_file('TI_horizons_continuous.SGEMS.zip')

grid = SGeMSGridReader().apply(filename)
grid.threshold([-4, 1.06]).plot(clim=grid.get_data_range())
../../_images/sphx_glr_read-sgems-grid_003.png
# grid_url = 'http://www.trainingimages.org/uploads/3/4/7/0/34703305/ti.zip'
filename, _ = examples.downloads._download_file('ti.sgems.zip')

grid = SGeMSGridReader().apply(filename)
grid.plot(scalars='photo', cpos='xy', cmap='bone')
../../_images/sphx_glr_read-sgems-grid_004.png
grid.plot(scalars='seismic', cpos='xy')
../../_images/sphx_glr_read-sgems-grid_005.png

Total running time of the script: ( 0 minutes 55.544 seconds)

Gallery generated by Sphinx-Gallery