Skip to main content

No project description provided

Project description

DOI VTUinterface codecov DOI

VTUinterface

VTUinterface is a python package for easy accessing VTU/PVD files as outputed by Finite Element software like OpenGeoSys. It uses the VTK python wrapper and linear interpolation between time steps and grid points to access any points in space and time within the simulation domain.

VTUinterface together with ogs6py can be viewed in action here:

IMAGE ALT TEXT HERE

0. Installation

Note: VTUinterface requires the vtk wrapper for python. Alternatively, a version based on MESHIO is also under development. clone the repository and use pip to install the package

# pip install [--user] https://github.com/joergbuchwald/VTUinterface/archive/refs/heads/master.zip

1. Documentation for VTUinterface

You can find the documentation under https://joergbuchwald.github.io/VTUinterface-doc/

2. Quick start

CAUTION: naming style of methods has changed (2021-05-20)

Basic Usage (python)

Although, a python package, VTUinterface is tested to work through PyCall under julia as well:

Basic Usage (julia)

Unittests can be run via

# python tests/test_vtuinterface.py

from the project root directory.

3. FAQ/Troubleshooting

As the input data is triangulated with QHull for the linear interpolation it might fail at boundaries or if a wrong input dimension is given. Possible solutions:

  • In order for interpolation to work correctly providing the correct dimension (set via dim keyword) of the problem is crucial.
  • As the dim keyword specifies also the coordinates to use, VTUinterface assumes that dim=1 refers to the x coordinate and dim=2 implies that the problem lies in the xy-plane by default. This can be changed by specifying one_d_axis for one dimension or two_d_planenormal for two dimensions.
  • For some meshes it might help to adjust the number of points taken into account by the triangulation, which can be done using the nneighbors keyword. Default value is 20.
  • Especially along boundaries, linear interpolation with the QHULL method often fails, this can be resolved by using nearest neighbor interpolation.
  • Alternatively, you can change now the interpolation_backend from scipy to vtk and try out different interpolation kernels.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

VTUinterface-0.691-py2.py3-none-any.whl (9.5 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file VTUinterface-0.691-py2.py3-none-any.whl.

File metadata

  • Download URL: VTUinterface-0.691-py2.py3-none-any.whl
  • Upload date:
  • Size: 9.5 kB
  • Tags: Python 2, 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.9 tqdm/4.62.3 importlib-metadata/4.8.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.4

File hashes

Hashes for VTUinterface-0.691-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 d2613d5122c83610f32956f010b3ab3b2cc1d4abffaa26ea2c44153e78bb8d8c
MD5 48ce0e0854d77040da89a89a7b8a7a66
BLAKE2b-256 8623ae9c16facb359fab6e0e4ed8520b2e8aafff3e8eb50a006d4e2a74391e6c

See more details on using hashes here.

Provenance

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