GithubHelp home page GithubHelp logo

ludoguer / shyft Goto Github PK

View Code? Open in Web Editor NEW

This project forked from felixmatt/shyft

0.0 1.0 0.0 1.82 MB

Statkraft’s Hydrologic Forecasting Toolbox

License: GNU Lesser General Public License v3.0

CMake 1.05% C++ 65.99% C 4.00% Batchfile 0.21% Shell 0.24% Python 28.50%

shyft's Introduction

README

Branch Status
master Build Status

SHyFT is an OpenSource hydrological toolbox developed by Statkraft.

It is optimized for highly efficient modeling of hydrologic processes following the paradigm of distributed, lumped parameter models -- though recent developments have introduced more physically based / process-level methods.

The code is based on an early initiative for distributed hydrological simulation, called ENKI developed at Sintef by Sjur Kolberg with contributions from Kolbjorn Engeland and Oddbjorn Bruland.

Wiki for SHyFT includes details for how to get prebuilt binaries, how to build and contribute.

REQUIREMENTS

For compiling and running SHyFT, you will need:

  • A C++11 compiler
  • The BLAS and LAPACK libraries (development packages)
  • A Python3 (3.4 or higher) interpreter
  • The NumPy package (>= 1.8.0)
  • The netCDF4 package (>= 1.2.1)
  • The CMake building tool (2.8.7 or higher)

In addition, a series of Python packages are needed mainly for running the tests. These can be easily installed via:

$ pip install -r requeriments.txt

or, if you are using conda:

$ cat requirements.txt | xargs conda install

COMPILING

NOTE: the compiling instructions below have been mainly tested on Linux platforms. SHyFT can also be compiled (and it is actively maintained) for Windows, but the building instructions are not covered here (yet).

You can compile SHyFT by using the typical procedure for Python packages:

$ python setup.py build

from the root directory.

Although SHyFT tests are meant to be run from the sources directory (e.g. it expects the shyft-data repo to be cloned locally next to the shyft repo sources), you can also install it with:

$ python setup.py install

Although you won't be able to run the tests except in a very restricted scenario (i.e. shyft-data should be a sibling of the current working directory), this won't prevent you to use SHyFT on top of your own datasets.

COMPILING MANUALLY VIA CMAKE

Although (at least on Linux) the setup.py method above uses the CMake building tool behind the scenes, you can also compile it manually (in fact, this is recommended because you will be able to run the integrated C++ tests). The steps are the usual ones:

$ export SHYFT_SOURCES=shyft_root_directory  # absolute path required!
$ cd $SHYFT_SOURCES
$ mkdir build
$ cd build
$ export SHYFT_DEPENDENCIES_DIR=directory_to_keep_dependencies  # absolute path
$ cmake ..      # configuration step; or "ccmake .." for curses interface
$ make -j 4     # do the actual compilation of C++ sources (using 4 processes)
$ make install  # copy Python extensions somewhere in $SHYFT_SOURCES

We have the beast compiled by now. For testing:

$ export LD_LIBRARY_PATH=$SHYFT_DEPENDENCIES_DIR/local/lib
$ make test     # run the C++ tests
$ export PYTHONPATH=$SHYFT_SOURCES
$ nosetests ..  # run the Python tests

If all the tests pass, then you have an instance of SHyFT that is fully functional. In case this directory is going to act as a long-term installation it is recommended to persist your $LD_LIBRARY_PATH and $PYTHONPATH environment variables (in ~/.bashrc or similar).

TESTING

The way to test SHyFT is by running:

$ nosetests

from the root directory.

The test suite is not very comprehensive yet, but at least would provide indications that your installation is sane.

INSTALLING

Once you tested you SHyFT package you can install it in your system via::

$ python setup.py install

AUTHORS

SHyFT is developed by Statkraft, and the two main initial authors to the C++ core were Sigbjørn Helset [email protected] and Ola Skavhaug [email protected].

Orchestration and the Python wrappers were originally developed by John F. Burkhart [email protected]

Several of the methods implemented are rewrites of corresponding code in ENKI

THANKS

Contributors and current project participants include:

COPYING / LICENSE

SHyFT is released under LGPL V.3 See LICENCE

shyft's People

Contributors

sigbjorn avatar skavhaug avatar francescalted avatar jfburkhart avatar johneih avatar

Watchers

James Cloos avatar

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.