Adaptive Optics Group, INAF - Osservatorio Astrofisico di Arcetri
OptiCalib is a python package which first goal is to make easy deformable mirror's calibration in the laboratory (and not only).
It was born as a general extrapolation of the software built for the control and calibration of the ELT @ M4 adaptive mirror and it's calibration tower, OTT (Optical Test Tower).
Note: to cite this package check CITATION.bib
The OPTICALIB package serves two main purposes:
-
Making connection to the hardware (interferometers, DMs, ...) easy;
-
Providing routines for Deformable Mirrors calibrations.
The latests, stable, version can be installed from pypi:
pip install opticalibThe in-development version can be installed directly from this repository:
pip install git+"https://github.com/ArcetriAdaptiveOptics/opticalib.git"But do expect some bugs!
Upon installation, the software will create an entry point script called calpy, which is usefull to set up a specific experiment's environment. Let's say we have an optical bench composed of an interferometer 4D PhaseCam6110 and an Alpao Deformable mirror, say DM820. We can create the experiment's environment just like:
calpy -f ~/alpao_experiment --createThis will create, in the ~/alpao_experiment folder, the package's data folder tree, together with a configuration file in the SysConfig folder. The configuration file, documented in configuration documentation, is where all devices must be specified.
Once done with the configuration, we can then start using out instruments:
calpy -f ~/alpao_experiment# The `calpy` function will automatically import opticalib (with `opt`
# as alias), as well as the `opticalib.dmutils` as dmutils
interf = opt.PhaseCam(6110) # set in the configuration file
dm = opt.AlpaoDm(820) # set in the configuration file
# Having the bench set up and the configuration file set, we can acquire
# an Influence Function by just doing
tn = dmutils.iff_module.iffDataAcquisition(dm, interf) # Optional paramenters
# are `modesList, modesAmplitude, template`, which if not specified are
# read from the configuration fileFor the API references, check Opticalib API PDF (work in progress...), while for configuration details check configuration documentation.
Simulator data is no longer shipped inside the repository or Python package. All files used by the simulator are fetched on demand and cached locally.
You can pre-download all known simulator files:
from opticalib.simulator import prefetch_simdata
prefetch_simdata()This avoids runtime downloads when simulators are instantiated.
The repository intentionally does not include the opticalib/simulator/_API/SimData
payload anymore.