Coder Social home page Coder Social logo

microcombustion / ctwrap Goto Github PK

View Code? Open in Web Editor NEW
6.0 1.0 5.0 2.88 MB

Python wrapper for batch simulations (e.g. Cantera)

Home Page: https://microcombustion.github.io/ctwrap/

License: MIT License

Python 81.56% Jupyter Notebook 18.44%
cantera batch-simulation-jobs yaml-configuration multiprocessing python-wrapper

ctwrap's Introduction

ci tag PyPI

ctwrap

Python wrapper for batch simulations (e.g. Cantera).

Documentation

Sphinx documentation includes:

Philosophy

The software was developed with the following objectives in mind. It should:

  • provide a low-level interface to essential cantera capabilities
  • create a flexible framework for generic simulations
  • provide a command line interface
  • be easily scriptable (using YAML configuration files)
  • enforce units (via pint)
  • enable parallel execution of (single-threaded) simulations (via multiprocessing)
  • enable simple re-import of simulation results into native Cantera objects

Although core functions of this software are continuously tested, there may be remaining bugs, non-working features, or other issues that could prevent a user from using this software to their specification. If you find problems, please report them in the issue tracker.

Installation

The simplest approach is to install ctwrap via pip, i.e.

$ pip install ctwrap

Note that ctwrap itself does not depend on a Cantera installation (only simulation modules do). It is recommended to install Cantera before ctwrap in a separate step.

Example

A parallel batch job for adiabatic flame calculations uses the freeflame module (modified from Cantera's adiabatic_flame.py example). Based on the YAML configuration given as a reference, a variation of 12 equivalence ratio values is run as:

$ ctwrap run freeflame freeflame.yaml --parallel --strategy sequence

Results are written to a single file freeflame.h5.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.