Skip to main content

General purpose OpenTURNS python wrapper tools

Project description

https://github.com/openturns/otwrapy/actions/workflows/build.yml/badge.svg?branch=master

otwrapy is a collection of tools that simplify the task of wrapping external codes in a Python environment as well as parallelizing it. It is built on top of OpenTURNS, with its users as the target audience. Documentation is available here. The module provides :

  • An integrated progress bar for unit evaluation of a sample without parallelization.

  • A Parallelizer class that converts any ot.Function into a parallel wrapper using either multiprocessing, ipyparallel, joblib, pathos or dask SSHCluster.

  • A set of useful tools that simply recurrent tasks when writing code wrappers:

    • TempWorkDir: Context manager that gracefully creates a temporary working directory. It handles errors and has the option to cleanup upon exit.

    • Debug: Decorator that protects the decorated function into a try/except structure so that errors are logged. It is specially useful when you launch your code in a non interactive environment.

    • load_array and dump_array: Used for efficiently create and load backups with the option to compress with gzip.

    • safemakedirs: Create a directory without raising an exception if it exits.

    • create_logger: Return a logger with a FileHandler at a given logging level.

otwrapy comes from the experience of wrapping a lot of different external codes at Phimeca engineering. We are a company specialized in uncertainty treatment and we assist our clients introducing the probabilistic dimension in their so far deterministic studies.

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

otwrapy-0.12.1-py3-none-any.whl (1.5 MB view hashes)

Uploaded Python 3

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