Skip to main content

Predictive and probabilistic simulation tools.

Project description

Description

PSimPy (Predictive and probabilistic simulation with Python) implements a Gaussian process emulation-based framework that enables systematic and efficient investigation of uncertainties associated with physics-based models (i.e. simulators).

Prerequisites

Before installing and using PSimPy, please ensure that you have the following prerequisites:
(Please note that we will cover number 1 to 3 in our recommended installation method: Installation in a Conda Environment.)

  1. Python 3.9 or later:
    Make sure you have Python installed on your system. You can download the latest version of Python from the official website: Python Downloads
  2. R Installed and Added to the PATH Environment Variable:
    • Install R from the official R Project website.
    • Add R to your system's PATH environment variable. This step is crucial for enabling communication between Python and R.
  3. (Optional) RobustGaSP - R package:
    The emulator module, robustgasp.py, relies on the R package RobustGaSP. This has also been initegrated with other PSimPy modules, such as active_learning.py. In order to utilize these modules, make sure to install the R package RobustGaSP first.
  4. (Optional) r.avaflow - Mass Flow Simulation Tool:
    PSimPy includes a simulator module, ravaflow3G.py, that interfaces with the open source software r.avaflow 3G. If you intend to use this module, please refer to the official documentation of r.avaflow 3G to for installation guide.

Installation

PSimPy can be installed using pip.

$ pip install psimpy

This command will install the package along with its dependencies.

Installation in a Conda Environment (Recommended)

We recommond you to install PSimPy in a virtual environment such as a conda environment. In this section, we will ceate a conda environment with prerequisites (number 1 to 3), and install PSimPy in this environment. You may want to first install Anaconda or Miniconda if you haven't. The steps afterwards are as follows:

  1. Create a conda environment with Python, R, and RobustGaSP, and activate the environment:

    conda create --name your_env_name python r-base conda-forge::r-robustgasp
    conda activate your_env_name
    
  2. Install PSimPy using pip in your conda environment:

    pip install psimpy
    

Now you should have PSimPy and its dependencies successfully installed in your conda environment. You can use it in the Python terminal or in your Python IDE.

Quick Note on R_HOME in Conda Environments:

If you're running PSimPy in a conda environment without a predefined R_HOME variable, we automatically set it to the default R installation path of the active conda environment. This ensures PSimPy works smoothly with R without needing manual setup. If you prefer setting R_HOME yourself, please define it before starting PSimPy to use a custom R environment.

Documentation

Detailed documentation of PSimPy is hosted at https://mbd.pages.rwth-aachen.de/psimpy/, including the API and theory (or reference) of each module.

Usage

Usage examples are provided by the Example Gallery.

License

PSimPy was created by Hu Zhao at the Chair of Methods for Model-based Development in Computational Engineering (RWTH Aachen University, Germany). It is licensed under the terms of the MIT license.

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

psimpy-0.2.1.tar.gz (29.6 kB view details)

Uploaded Source

Built Distribution

psimpy-0.2.1-py3-none-any.whl (39.2 kB view details)

Uploaded Python 3

File details

Details for the file psimpy-0.2.1.tar.gz.

File metadata

  • Download URL: psimpy-0.2.1.tar.gz
  • Upload date:
  • Size: 29.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.7.1 CPython/3.12.0 Windows/11

File hashes

Hashes for psimpy-0.2.1.tar.gz
Algorithm Hash digest
SHA256 3a633a9354fff21ea0f61b2a8d4bc5a2dd41e5b74438fe08af1c3edd77d3b30c
MD5 e792ba9eb55cf40aea285a0c070a2795
BLAKE2b-256 11917580ac3acc760ec7dc53ca5a6e3337ca832fb2d9e1f1b4474e928ea353a4

See more details on using hashes here.

File details

Details for the file psimpy-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: psimpy-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 39.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.7.1 CPython/3.12.0 Windows/11

File hashes

Hashes for psimpy-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 269c372eb7b4579e048b35ea32a3e42740070e77ef334c09cdf90f19b4d5a898
MD5 6d61f608510434284c30b5bcea1037f3
BLAKE2b-256 db07b76bb430333cd568a9b15813f15a781f8ab1c81e35c11f03cb4299878d26

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