Skip to content

Installation and first setup¤

Note

If you have any problems at any stage or need a consultation, feel free to contact the author at

zdenek.vostrel(at)cern.ch
I am always happy to help!

Python installation¤

The framework is written in Python 3.9, and thus it is required to download it first.

There are multiple ways of getting Python, one of the simplest options is to use the conda installer, which is an open source package management system for Python.

Follow the installation instructions for your OS:

  1. Windows
  2. MacOS
  3. Linux

ASTRA installation¤

This framework uses the ASTRA tracking code to perform the simulations. You need to download the ASTRA executables from here.

See Usage for more information of how to use the ASTRA executables.

Framework installation¤

The framework can be downloaded from CERN Gitlab as a .zip file. See the image bellow.

Code download

After the download and unzipping, you need to install the python packages required by the framework.

Warning

Make sure you have Python 3.9 installed and running at this point. Please refer to the relevant section.

Downloading these packages is very simple. To do so, open the terminal (on Windows, click on the Windows logo and type terminal). After the terminal window is opened, you need to navigate to the directory with the unzipped downloaded code. To do so, type the following line to the terminal (replace pathToCode by the actual full path1)

cd pathToCode

Now, the required packages can be downloaded simply by typing

pip install -r requirements.txt

If this command fails, either you are not in the directory with the downloaded code or there is a problem with you Python distribution.

After the command is finished, the framework is ready to be used.

Next steps¤

See the example scripts, which serve as a basis or template. Adjust them to match your needs.

The full process of how to start a simulation with this framework is described in the Usage tab and the subpages there.


  1. Full path can be copied from the file browser. On Windows, it starts with a letter representing the disk, for example C:\..., on MacOS and Window, the path start with /...


Last update: October 31, 2023
Created: October 31, 2023