Giter Site home page Giter Site logo

snake's Introduction

Snake

A collection of Python modules to post-process the numerical solution of simulations run with one of the following software:

Installation

Dependencies (last tested)

  • Python-2.7 or Python-3.5
  • Numpy-1.11.1
  • Scipy-0.17.1
  • Matplotlib-1.5.3
  • Pandas-0.19.2

To install the specific version of these packages we recommend using either conda.

To create a new environment for using snake with Python-3.5 with conda you can do the following:

> conda create -n snakepy35 python=3.5 numpy scipy matplotlib pandas
> source activate snakepy35

or with Python-2.7:

> conda create -n snakepy27 python=2.7 numpy scipy matplotlib pandas
> source activate snakepy27

Optional

  • PETSc-3.7.4 (for PetIBM post-processing; only the Python scripts are needed)
  • VisIt-2.12.1 (IBAMR post-processing)
  • OpenFOAM-2.3.1 and ThirdParty-2.3.1 (for OpenFOAM post-processing)

Install snake using git

> git clone https://github.com/mesnardo/snake.git
> cd snake
> python setup.py install
> export SNAKE=$PWD

Install snake using a specific release

> VERSION="X.X.X"
> wget https://github.com/mesnardo/snake/archive/v${VERSION}.tar.gz
> mkdir snake-${VERSION}
> tar -xzf v${VERSION}.tar.gz -C snake-${VERSION} --strip-components=1
> rm -f v${VERSION}.tar.gz
> cd snake-${VERSION}
> python setup.py install
> export SNAKE=$PWD

where X.X.X defines the version number to use.

Notes

Some of the modules call the environment variable $SNAKE defined as the local directory of the snake repository. The variable can be set by adding the following line to your .bashrc or .bash_profile file:

> export SNAKE="/path/to/snake/directory"

The module for PetIBM calls the environment variable $PETSC_DIR defined as the local directory of PETSc. The variable can be set by adding the following line to your .bashrc or .bash_profile file:

> export PETSC_DIR="/path/to/petsc/directory"

Some examples to post-process the numerical solution from the four codes are provided in the examples folder.

Suggestions and bug-fix are welcome. Contact: [email protected]

snake's People

Contributors

mesnardo avatar

Stargazers

 avatar  avatar

Watchers

 avatar

snake's Issues

[Python 3] New API change to the use of color_cycler

In Python 3, it seems matplotlib has removed the old usage of color_cycler like what is at line 118 in logSummaryReader.py.

According to the suggested new API usage, line 118 in logSummaryReader.py should be modified to

color_cycle = ax._get_lines.prop_cycler

And line 126 in the same file should be modified correspondingly to:

... color=next(color_cycle)['color'], ...

Also, line 20 in mesnardo.mplstyle is deprecated in Python 3, though it has not been deleted yet. The new usage is:

axes.prop_cycle : cycler('color', 
    ['348ABD', '7A68A6', 'A60628', '467821', 'CF4457', '188487', 'E24A33'])

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.