Skip to main content

Python package to install BOUT++ and its dependencies

Project description

Build Status codecov pypi package Python PEP8 License

bout_install

Python package to install BOUT++ and its dependencies.

NOTE: This package is meant as a "last resort" to install BOUT++, for example when you are not a root user, and you are trying to install on a "tricky" system. Otherwise BOUT++ can easily be installed using docker or installed as explained in the BOUT ++ documentation .

Getting Started

bout_install is a lightweight package, and requires only python3, requests and an internet connection to run.

Building BOUT++ and dependencies can be done by executing

from bout_install import install_bout
install_bout(config_path=None, add_to_bashrc=False)

or from command-line

bout_install --help

which returns

usage: bout_install [-h] [-c CONFIG] [-a]

Install BOUT++ with dependencies

optional arguments:
  -h, --help            show this help message and exit
  -c CONFIG, --config CONFIG
                        Path to the configuration file. Default is
                        /path/to/bout_install/bout_install/config.ini
  -a, --add_to_bashrc   If set, paths to binaries and libraries of
                        dependencies will be added to .bashrc. Default is
                        false

This will build BOUT++ and its dependencies according to the content of config.ini:

[bout_options]
# Let these be empty for default behavior
# Read docstring of InstallerUsingGit.InstallerUsingGit.__init__ for details
# NOTE: Commit 8567b2d5bb5f4b70face0b8d0849fc1bbafbbdb0 is known to work
git_dir =
checkout =
enable_checks = no
enable_optimize = 3

[install_options]
# If packages not residing in local should be used
use_preinstalled = false
# Let these be empty for default behavior
# Read docstring of Installer.Installer.setup_install_dirs for details
main_dir =
install_dir =
local_dir =
examples_dir =

[required]
fftw = true
hdf5 = true
mpi = true
netcdf = true

[optional]
cmake = false
ffmpeg = false
gcc = false
slepc = true
sundials = true
# NOTE: PETSc is installed if slepc is true
petsc = false

[versions]
cmake = 3.7.2
ffmpeg = 3.1.4
fftw = 3.3.6-pl2
gcc = 6.1.0
hdf5 = 1.10.1
mpi = 3.2
nasm = 2.13.03
netcdf = 4.4.1.1
netcdf_cxx = 4.3.0
# NOTE: Only certain PETSc versions are supported by BOUT++
petsc = 3.10.0
# NOTE: Sundials 2.7.0 have given openmp problems
sundials = 2.6.2
# NOTE: Must correspond to the PETSc version
slepc = 3.10.0
yasm = 1.3.0
x264 = x264-snapshot-20180709-2245-stable

Installing from pip

The package can be installed from pip:

pip install bout-install

Installing from source

Alternatively it can be installed from source

python setup.py install

Running the tests

The test suite can be executed through pytest or through codecov pytest-cov. Installation through

pip install pytest

or

pip install codecov pytest-cov

and run with

pytest

or

pytest --cov=./

respectively

NOTE: Due to time constraints of automatic testing with Travis, the unittests have been "blinded" by adding a "." in front of the name. In this way pytest will ignore those test. "Un-blind" them by removing the leading " ." in order to run them.

License

This project is licensed under the GNU Lesser General Public License - see the LICENSE file for details

Acknowledgments

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

bout_install-0.1.2.tar.gz (19.3 kB view details)

Uploaded Source

Built Distribution

bout_install-0.1.2-py3-none-any.whl (33.5 kB view details)

Uploaded Python 3

File details

Details for the file bout_install-0.1.2.tar.gz.

File metadata

  • Download URL: bout_install-0.1.2.tar.gz
  • Upload date:
  • Size: 19.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.6.2 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.6

File hashes

Hashes for bout_install-0.1.2.tar.gz
Algorithm Hash digest
SHA256 4d8d81164fc0a55a5e8072ec7220073a79ff193319660bba0d2fed7d5e3e94e5
MD5 a4f8b2e58f038c0cc705a3148c10d2b6
BLAKE2b-256 9a4b2c92665d30476d5268695594fd702be3118b7ffc5419f674301e4e7dfc80

See more details on using hashes here.

File details

Details for the file bout_install-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: bout_install-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 33.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.6.2 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.6

File hashes

Hashes for bout_install-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 8ea8040d8ed98fdd7acb6427c967cecbfcaad57dfa420557144f822b25c58c46
MD5 8341cb85a68bcce527874b6721cddc55
BLAKE2b-256 2f66dec885f8a741e379de37d7f6e2e67e18dc57cde682c8703be8761ab6fa79

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