sbpy has the following requirements that will be automatically taken care of with installation using pip:

  • Python 3.8 or later

  • astropy 4.3 or later.

  • numpy 1.18 or later.

Optional dependencies

  • ads 0.12 or later, to fetch citation details for bibliography tracking. Recommended

  • astroquery 0.4.5 or later, for retrieval of online data, e.g., ephemerides and orbits. Recommended

  • Python extensions for oorb: For orbit transformations (oo_transform) and propagations (oo_propagate), as well as ephemerides calculations (from_oo).

  • pyradex: For non-LTE production rate calculations related to cometary activity (NonLTE).

  • scipy: 1.3 or later, for numerical integrations in sbpy.activity.gas and sbpy.photometry, among others. Recommended

  • synphot 1.1.1 or later, for calibration with respect to the Sun and Vega, filtering spectra through bandpasses. Recommended

  • ginga : To interactively enhance images of comets with the CometaryEnhancement Ginga plugin.

  • photutils: For centroiding within the Cometary Enhancements Ginga plugin.

Using pip

The latest stable version of sbpy can be installed with:

$ pip install sbpy

Recommended dependencies may be installed via:

$ pip install sbpy[recommended]

Most optional dependencies may be installed via:

$ pip install sbpy[all]

oorb and pyradex are left for the user to install manually.

The latest development version of sbpy can be easily installed using:

$ pip install git+

Using conda

The latest stable version of sbpy can be installed with Anaconda via the conda-forge channel:

$ conda install sbpy --channel=conda-forge

If you do not have the conda-forge channel available, add it and re-run the installation command:

$ conda config --add channels conda-forge
$ conda install sbpy --channel=conda-forge

Using Git+Pip

This way of installing sbpy is recommended if you plan to contribute to the module. The current development version of sbpy can be obtained from GitHub using:

$ git clone

This will create a new directory (sbpy/). In this directory, run:

$ pip install .

As above, to install optional dependencies, instead use pip install .[all].

If you plan to work on the code and always want to use the latest version of your code, we recommend installing in “editable” mode with the optional dependences and the testing dependencies:

$ pip install -e .[all,test]