Usage#

Managing libraries and conda environments#

Note

For the standard version only, i.e. not supported for the portable version.

As an alternative to the Anaconda Navigator, the HyperSpy bundle includes gator to manage libraries and conda environments.

Managing environments and libraries using gator

Managing environments and libraries using gator.#

The packages can also be managed from the command line using conda or mamba. For example, the distribution can be updated easily using

$ conda update --all

or

$ mamba update --all

Note

conda is usually slow, when the distribution contains many libraries, as is the case for the hyperspy-bundle. Mamba is a fast drop-in replacement for conda.

Context Menu Shortcuts#

The context menu shortcuts are created when the corresponding option has been selected during installation using the start_jupyter_cm tool. Using these shortcuts, the jupyter QtConsole / Lab / Notebook will start from the current folder.

Launching the interactive HyperSpy-bundle prompt console

Jupyter context menu entries.#

Installation alongside other Python Distribution#

The hyperspy-bundle will install a python distribution alongside existing python distribution. The easiest way to use the python distribution installed by the hyperspy-bundle is to use the shortcuts defined above (constext_menu and menu shortcut).

Alternatively, it is possible to:

Note

To check which python distribution you are using, you can import a library and find its location using the __file__ attribute, for example:

import hyperspy
print("Location of the hyperspy library:", hyperspy.__file__)

The path of the file will contain the path of the python distribution which should help you to identify which python distribution is being used.

Note

conda/mamba uses a configuration file (.condarc) to allow users to save conda settings. The hyperspy-bundle includes such a configuration file in the distribution but user-defined .condarc file saved in other location (for example, the home folder) can overwrite the default settings defined in the hyperspy-bundle. See the conda documentation for more information on conda uses .condarc files.