Installation

Nimble can be installed in a variety of ways and strives for flexibility during the install process. To avoid requiring packages that may never be used, Nimble only has only four required dependencies, Numpy, Scipy, packaging, and tomli. NumPy and Scipy enable a baseline portion of the data manipulation API. The packaging dependency is used to validate the installed versions of any optional packages. The tomli dependency is a fallback for certain dependency checks of the optional dependencies. All further functionality is accessed by installing third-party Optional Packages.

For convenience, installing optional packages can also be triggered while installing Nimble. We recommend the Nimble Install Quickstart to make almost all of Nimble’s functionality available with a single command.

Install Methods

Nimble Install Quickstart

To install a curated selection of Optional Packages while installing Nimble, both pip and conda installs offer a quickstart option. Quickstart installs all Operational Support packages and SciKit-Learn from the Machine-Learning Interfaces. These packages were chosen because they are reliably installable through pip and conda and provide access to the majority of Nimble’s functionality.

With pip:

Nimble uses extras to provide the quickstart shortcut

pip install nimble[quickstart]

Note

The brackets may need to be escaped in some shells. For example, on a mac, which uses z shell as default, the command would be

pip install nimble\[quickstart\]

With conda:

The nimble-data channel available through this website provides a package with expanded dependencies, nimble-quickstart. Once installed, import still occurs with import nimble, the name nimble-quickstart only serves to install nimble and the other desired packages.

conda install nimble-quickstart -c https://www.nimbledata.org/nimble-data

Install with Specific Packages

Optional Packages can always be installed separately with pip or conda, for example: pip install pandas or conda install pandas. However, both package managers offer ways to install optional packages in the same step as installing nimble.

Warning

Installs will fail if any package fails to install.

With pip:

pip supports the use of extras included in brackets after the package name. Nimble provides each optional package as an extra and extras that are shortcuts to installing multiple packages. The [quickstart] shortcut was outlined in Nimble Install Quickstart, but there are other defined in Optional Packages below.

# single extra
pip install nimble[dateutil]
  or
# multiple extras
pip install nimble[requests,matplotlib,sklearn]
  or
# shortcut (for ML packages)
pip install nimble[interfaces]

Note

  • The names of the extras match the names displayed in the “Package” columns in Optional Packages.

  • The brackets may need to be escaped in some shells.

With conda:

For conda, Optional Packages must be installed manually. However, conda allows for multiple packages to be installed at the same time so they can be listed alongside nimble, provided they are available in the known channels.

conda install nimble matplotlib scikit-learn -c https://www.nimbledata.org/nimble-data

Note

  • The package names used for the installation do not always match the python importable names displayed in the “Package” columns in Optional Packages, for example, “scikit-learn” is used to install the sklearn package and “python-dateutil” is used to install the dateutil package.

Basic Installation

This will install Nimble and its NumPy dependency only. Accessing much of Nimble’s functionality will require manually installing the Optional Packages. Nimble will raise its PackageException for operations requiring an optional package that is not installed.

With pip:

pip install nimble

With conda:

conda install nimble -c https://www.nimbledata.org/nimble-data

Optional Packages

Many components of Nimble rely on the following third-party packages. Most packages are pip and conda installable, but install recommendations vary and some offer further optimizations. Reading the linked installation instructions for each package is highly recommended.

Operational Support

Package

Supports

pip

conda

scipy

Nimble’s Sparse object and various scientific calculations.

pandas

Nimble’s DataFrame object.

matplotlib

Plotting.

requests

Retrieving data from the web.

cloudpickle

Saving Nimble data objects.

dateutil

Parsing strings to datetime objects.

h5py

Loading hdf5 files.

hyperopt

Bayesian method for hyperparameter tuning.

storm_tuner

StochasticRandomMutator for hyperparameter tuning.

Machine-Learning Interfaces

Package

Provides

pip

conda

sklearn

Machine Learning.

tensorflow/ keras

Neural Networks. See install note below.

autoimpute

Imputation. Machine Learning with missing data.

Note

Tensorflow recommends building from source, but some third parties provide prebuilt tensorflow binaries available for various architectures.