Below are the steps for the installation of AstroGeoFit for the AstroGeoFit Workshop. If possible, participants can make these installations before the start of the workshop.
Linux/unix install. Everything is in the documentation, and you can refer to it whenever you need additional information, but to make it more easy, we have described the essential steps below.
For a unix user, follow the following steps
1-Install Miniconda. This is the Python environment. In the Miniconda webpage for installation, use the Linux installer in terminal mode.
2-Download the AstroGeoFit Package from the AstroGeo.eu website Here. Unzip the package. You will see a astrogeofit-1.x folder. (1.0 in the example below, but now 1.1, so replace everywhere 1.0 by 1.1 below).
3- From now, you need to use the terminal tool of Linux. Open the terminal, go to the astrogeofit-1.0 folder.
4-The most simple way is to type “cd” (without the “) on the terminal. Use “cd [path]”, replace [path] with the path to the astrogeofit–1.0 folder. Then type “ls” to check what the folder contains. It should look like this

5. Next, create a virtual environment to avoid potential version compatibility issues.
In the terminal, write
conda create --name astrogeofit python=3.9
If conda command doesn’t work, load the Conda runtime environment in the current terminal session so that the conda command and environment-switching functionality become available, using “source [path to conda.sh]”:. For example:
source ~/miniconda3/etc/profile.d/conda.sh
source /opt/anaconda3/2022.05/etc/profile.d/conda.sh
(Change the [path to conda.sh] if needed.)
Once the environment is created, activate it by writing:
conda activate astrogeofit
6. Then register the “astrogeofit” environment as a Jupyter kernel by typing the following command in the terminal:
python -m ipykernel install --user --name astrogeofit --display-name "astrogeofit"
If errors are raised about “pip” or “ipykernel”, add two commands before the kernel registration command to fix them:
python -m pip install --upgrade pip
pip install ipykernel
python -m ipykernel install --user --name astrogeofit --display-name "astrogeofit"
Check if you have successfully registered the kernel by typing:
jupyter kernelspec list
7. Next, install the AstroGeoFit package inside the “astrogeofit” environment. Type this command in the terminal:
pip install astrogeofit-1.1-py3-none-any.whl
8. Run your first example. In order to limit the runtime that can be large on a full scale job, we will limit this first example to the genetic algorithm fitting part, and will not run the MCMC part. We use the configuration files stored in the “example” folder. The command is then
python ./AstroGeoFit_tool.py -fit -p ./examples/synthetic_data/configuration_file/configuration_synthetic_data.yml -r
The output should look like

(Note: For normal computers, it takes about 2 minutes. For computers with limited performance, it may take about 5 minutes.)
Congratulation, you have properly installed AstroGeoFit ! You have run your first AstroGeoFit job and are ready for the AstroGeoFit workshop !
Now you can go to the next step, that is the visualisation of the results : Here
