Set Up a Launch Script for TipTop and Display Results
π Run a TipTop simulation and display PSFsβ
Simplest wayβ
As explained in the Quickstart section, to run a simulation with TipTop, you need:
β‘οΈ a launch script which:
-
Loads the simulation parameters from a .ini file (e.g., minimalPar.ini)
-
Initializes the necessary modules
-
Starts the simulation using the overallSimulation function
The simplest file to launch a simulation looks like this (TIPTOP-EXAMPLE.py,
available in the examples/ folder of our GitHub repository):
from tiptop.tiptop import *
overallSimulation("./", "minimalPar", './', 'test')
where:
- The first and second arguments of
overallSimulationare the path to the folder containing the input.inifile and the name of that file (without the extension). - The third and fourth arguments specify where to save the output results (in
.fitsformat) and the name of the resulting.fitsfile.
A detailed documentation on the overallSimulation function is available below.
More complete launch scriptβ
Below is an example of a more advanced launch script (suitable for a single science source).
It runs a simulation for the ERIS instrument and
extracts key outputs, including PSFs and performance metrics (e.g., Strehl Ratio (SR),
Full Width at Half Maximum (FWHM)) from the output FITS file (see Simulation Output below).
It also generates log-scaled intensity plots of the AO PSF, diffraction limited PSF, and seeing limited PSF, as well as a log-scaled radial profile plot.
β
You can adapt this script by changing the input/output paths and filenames to match your configuration.
The full example script is available for download
here