Skip to main content

3D visualization for the Open Mining Format (omf)

Project description

PyPI https://codecov.io/gh/OpenGeoVis/omfvista/branch/master/graph/badge.svg GitHub

A PyVista (and VTK) interface for the Open Mining Format package (omf) providing Python 3D visualization and useable mesh data structures for processing datasets in the OMF specification.

Documentation is hosted at https://opengeovis.github.io/omfvista/

Check out the Example Notebook on NBViewer! Or launch the Notebook on MyBinder to run the code yourself!

Integrated Scene

Installation

Installation is simply:

pip install omfvista

All necessary dependencies will be installed alongside omfvista. Please note that this package heavily leverages the PyVista package.

Questions & Support

For general questions about the project, its applications, or about software usage, please create an issue in the pyvista/pyvista-support repository where the PyVista community can collectively address your questions. You are also welcome to join us on join @OpenGeoVis on our Slack workspace under the #omfvista channel or send one of the developers an email. The project support team can be reached at info@opengeovis.org.

Example Use

https://mybinder.org/badge_logo.svg

Be sure to check out the Example Notebook that demos omfvista or our Example Gallery in the documentation! Here’s an example using the sample data hosted in the OMF repository.

import pyvista as pv
import omfvista

project = omfvista.load_project('test_file.omf')
project
Table Representation

Once the data is loaded as a pyvista.MultiBlock dataset from omfvista, then that object can be directly used for interactive 3D visualization from PyVista:

project.plot(multi_colors=True)

An interactive scene can be created and manipulated to create a compelling figure. First, grab the elements from the project:

# Grab a few elements of interest and plot em up!
vol = project['Block Model']
assay = project['wolfpass_WP_assay']
topo = project['Topography']
dacite = project['Dacite']

Then create a 3D scene with these spatial data and apply a filtering tool from PyVista to the volumetric data:

# Create a plotting window
p = pv.Plotter(notebook=False)
# Add our datasets
p.add_mesh(topo, cmap='gist_earth', opacity=0.5)
p.add_mesh(assay, color='blue', line_width=3)
p.add_mesh(dacite, color='yellow', opacity=0.6)
# Add the volumetric dataset with a thresholding tool
p.add_mesh_threshold(vol)
# Add the bounds axis
p.show_bounds()
# Redner the scene in a pop out window
p.show()
Interactive Rendering

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

omfvista-0.2.4.tar.gz (10.1 kB view details)

Uploaded Source

Built Distribution

omfvista-0.2.4-py3-none-any.whl (10.6 kB view details)

Uploaded Python 3

File details

Details for the file omfvista-0.2.4.tar.gz.

File metadata

  • Download URL: omfvista-0.2.4.tar.gz
  • Upload date:
  • Size: 10.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.0 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.8.12

File hashes

Hashes for omfvista-0.2.4.tar.gz
Algorithm Hash digest
SHA256 418133c92f8ea6b533ae05f632ecc0e9bea9ef06c364921bb4fb9cb393429918
MD5 0f26207b7155d31595708645ee4a2733
BLAKE2b-256 085f894e7e9bf7cda3f234ff480f28c99cf154d1dd87a33653e71a617e6b1d5f

See more details on using hashes here.

File details

Details for the file omfvista-0.2.4-py3-none-any.whl.

File metadata

  • Download URL: omfvista-0.2.4-py3-none-any.whl
  • Upload date:
  • Size: 10.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.0 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.8.12

File hashes

Hashes for omfvista-0.2.4-py3-none-any.whl
Algorithm Hash digest
SHA256 8b02dbc61f5a94cc2eaf8b5044ddb9f722b7001a37e92c15198a70e68bd187d5
MD5 2c7b195d43d6b0e0eba3c15d3e43ee1d
BLAKE2b-256 c7aeab7e656f24b42cb98eb2b56b645bd87f6c0874b002da2c74ddf5b88477b4

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page