Skip to main content

VifPara

CAE Post-Processing Toolkit

OS Languages Version License

VifPara is a Python library that automates ParaView to produce high‑quality visuals from CAE simulation results from different CAE (computer-aided engineering) frameworks. It helps you automate the generation of reproducible 2D/3D plots, animations, comparative layouts, and batch visualizations. VifPara is not here to replace manual GUI-based post-processing workflows, but to enable intuitive automation of commonly needed visualization procedures.

Key Features

  • Cross-platform compatibility - Works on Linux and Windows
  • Multiple file formats - Supports OpenFOAM and Ensight
  • Flexible configuration - JSON-based configuration system
  • Comprehensive visualization - 2D slices, 3D views, animations, and more
  • Visualization Automation - Generate many different visualizations and animations with a single script
  • Various Frameworks - Developed with OpenFoam & MESHFREE. Other frameworks can be implemented upon request

Example Code

The following code takes a finished OpenFoam simulation testcase and outputs an image of a slice of the case through the center with a view along the y-axis.

To make this code work, you need to install ParaView and download VifPara into a compatible Python environment (see below).

from vifpara import *

if __name__ == "__main__":
    # Read config and load case
    config = Config(custom_config = {"case_path": "tutorials/incompressible/simpleFoam/motorBike/case.foam",
                                     "dir_plots": "plots/motorBike",
                                     "dir_logs": "logs/motorBike"})
    logger.set_log_path(config.get_log_path())
    case = Case(config=config, case_type=CaseType.RECONSTRUCTED)

    # Define single view layout
    layout = Layout([1])

    # Create color map
    cmap = ColorMap(field="U")

    # Create slice object
    slice_obj = Slice(
        case=case,
        color_map=cmap,
        normal=Vector3(0.0, 1.0, 0.0))

    # Render slice in single view layout
    slice_obj.render(layout)
    layout.set_height(800)
    exporter = Exporter(config=config, layout=layout)

    # Save screenshot of slice
    exporter.save_snapshot(filename="minimal_example")

Example output: Example Result

Info To test the example, you need to download the OpenFoam motorbike testcase and run it with OpenFoam. Afterwards, you point the case_path in the config to the case.foam of the testcase. If it does not exist, just create an empty file with this name in the cases root directory. Afterwards, do not run the script with python, python3, etc. but with vifpara, which is a dedicated runner installed together with the package.

Software Concept & Supported ParaView Versions

VifPara is a library which adds itself on top of your installed ParaView Python environment (pvpython) via an external Python environment. Therefore, it is crucial, that the Python version you install and use VifPara in, is the same your ParaView installation uses internally.

Please make sure your installed ParaView version is between 5.11 and 5.13. ParaView version 6 is currently not supported.

Tested and working configurations are:

  • ParaView 5.11 - Python 3.12
  • ParaView 5.12 - Python 3.10
  • ParaView 5.13 - Python 3.10

VifPara Architecture

Installation & Use

For information of how to install and use VifPara consult the user documentation and API reference:

User Documentation

Python Package

In the examples directory, you can find several example scripts of how to use VifPara, which can be used as templates to start from. The result of most example scripts can be found in the reference_exports directory in the examples directory.

Contact

Virtual Vehicle Research GmbH: https://www.v2c2.at

Team

Acknowledgments

Virtual Vehicle Research GmbH has received funding within COMET Competence Centers for Excellent Technologies from the Austrian Federal Ministry for Climate Action, the Austrian Federal Ministry for Labour and Economy, the Province of Styria (Dept. 12) and the Styrian Business Promotion Agency (SFG). The Austrian Research Promotion Agency (FFG) has been authorised for the programme management.

Release files for vifpara 1.3.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for vifpara 1.3.4
File Size Uploaded
vifpara-1.3.4.tar.gz 46.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for vifpara 1.3.4
File Interpreter ABI Platform
vifpara-1.3.4-py3-none-any.whl Python 3 none any Details

Total release size: 102.7 kB

Release files / vifpara-1.3.4.tar.gz

Download URL vifpara-1.3.4.tar.gz
Size 46.7 kB
Tags Source
SHA-256 checksum
How to use checksums
549467a259b7464e0fa47d4557183ed5ffcff06318dc625cb21f6c978f1b0914
BLAKE2b-256 checksum
How to use checksums
1a6750fd57e36f4f0c50ba1358f2e60e1d23c6f6b31144c6d6f2afb580f4f81d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.3

Release files / vifpara-1.3.4-py3-none-any.whl

Download URL vifpara-1.3.4-py3-none-any.whl
Size 56.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
39f2cabb67b8c413ff465bb2016dcb0e659c636dfe1409e4635c48ff6715efe0
BLAKE2b-256 checksum
How to use checksums
9447bbd4a84b284a7c349d13cd03aea7b769def35e6f519554363b5f15ce853b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.3

Release history Release notifications | RSS feed

This release

1.3.4 This release

2 release files

1.3.3

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page