Installation & Updating
Installation
First, obtain Python3 (tested on versions≥3.8). If you haven’t used python before, we recomend installing it through anaconda3.
mineralML can be installed using pip in one line. If you are using a terminal, enter:
pip install mineralML
If you are using Jupyter Notebooks (on Google Colab or Binder) or Jupyter Lab, you can also install it by entering the following code into a notebook cell (note the !):
!pip install mineralML
You then need to import mineralML into the script you are running code in. In all the examples, we import mineralML as mm:
import mineralML as mm
This means any time you want to call a function from mineralML, you use mm.function_name. If you are uncertain about how the function works, you can check the arguments required with help(mm.function_name).
Updating
To upgrade to the most recent version of mineralML, type the following into terminal:
pip install mineralML --upgrade
Or in your Jupyter environment:
!pip install mineralML --upgrade
For maximum reproducability, you should state which version of mineralML you are using. If you have imported mineralML as mm, you can find this using:
mm.__version__