COMPASS  5.4.4
End-to-end AO simulation tool using GPU acceleration
shesha.init.lgs_init Namespace Reference

Initialization of a LGS in a Wfs object. More...

Functions

def make_lgs_prof1d (conf.Param_wfs p_wfs, conf.Param_tel p_tel, np.ndarray prof, np.ndarray h, float beam, center="")
 same as prep_lgs_prof but cpu only. More...
 
def prep_lgs_prof (conf.Param_wfs p_wfs, int nsensors, conf.Param_tel p_tel, Sensors sensors, center="", imat=0)
 The function returns an image array(double,n,n) of a laser beacon elongated by perpective effect. More...
 

Variables

 shesha_db = os.environ['SHESHA_DB_ROOT']
 
 shesha_savepath = shesha_db
 

Detailed Description

Initialization of a LGS in a Wfs object.

Author
COMPASS Team https://github.com/ANR-COMPASS
Version
5.4.4
Date
2022/01/24

This file is part of COMPASS https://anr-compass.github.io/compass/

Copyright (C) 2011-2023 COMPASS Team https://github.com/ANR-COMPASS All rights reserved. Distributed under GNU - LGPL

COMPASS is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version.

COMPASS: End-to-end AO simulation tool using GPU acceleration The COMPASS platform was designed to meet the need of high-performance for the simulation of AO systems.

The final product includes a software package for simulating all the critical subcomponents of AO, particularly in the context of the ELT and a real-time core based on several control approaches, with performances consistent with its integration into an instrument. Taking advantage of the specific hardware architecture of the GPU, the COMPASS tool allows to achieve adequate execution speeds to conduct large simulation campaigns called to the ELT.

The COMPASS platform can be used to carry a wide variety of simulations to both testspecific components of AO of the E-ELT (such as wavefront analysis device with a pyramid or elongated Laser star), and various systems configurations such as multi-conjugate AO.

COMPASS is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with COMPASS. If not, see https://www.gnu.org/licenses/lgpl-3.0.txt.

Function Documentation

◆ make_lgs_prof1d()

def shesha.init.lgs_init.make_lgs_prof1d ( conf.Param_wfs  p_wfs,
conf.Param_tel  p_tel,
np.ndarray  prof,
np.ndarray  h,
float  beam,
  center = "" 
)

same as prep_lgs_prof but cpu only.

original routine from rico

Parameters
p_tel(Param_tel) : telescope settings
prof(np.ndarray[dtype=np.float32]) : Na profile intensity, in arbitrary units
h(np.ndarray[dtype=np.float32]) : altitude, in meters. h MUST be an array with EQUALLY spaced elements.
beam(float) : size in arcsec of the laser beam
center(string) : either "image" or "fourier" depending on where the centre should be.

Definition at line 71 of file lgs_init.py.

Here is the caller graph for this function:

◆ prep_lgs_prof()

def shesha.init.lgs_init.prep_lgs_prof ( conf.Param_wfs  p_wfs,
int  nsensors,
conf.Param_tel  p_tel,
Sensors  sensors,
  center = "",
  imat = 0 
)

The function returns an image array(double,n,n) of a laser beacon elongated by perpective effect.

It is obtaind by convolution of a gaussian of width "lgsWidth" arcseconds, with the line of the sodium profile "prof". The altitude of the profile is the array "h".

Parameters
p_wfs(Param_wfs) : WFS settings
nsensors(int) : wfs index
p_tel(Param_tel) : telescope settings
Sensors(Sensors) : WFS object
center(string) : either "image" or "fourier" depending on where the centre should be.

Computation of LGS spot from the sodium profile: Everything is done here in 1D, because the Na profile is the result of the convolution of a function P(x,y) = profile(x) . dirac(y) by a gaussian function, for which variables x and y can be split : exp(-(x^2+y^2)/2.s^2) = exp(-x^2/2.s^2) * exp(-y^2/2.s^2) The convolution is (symbol $ denotes integral) C(X,Y) = $$ exp(-x^2/2.s^2) * exp(-y^2/2.s^2) * profile(x-X) * dirac(y-Y) dx dy First one performs the integration along y C(X,Y) = exp(-Y^2/2.s^2) $ exp(-x^2/2.s^2) * profile(x-X) dx which shows that the profile can be computed by

  • convolving the 1-D profile
  • multiplying it in the 2nd dimension by a gaussian function

If one has to undersample the inital profile, then some structures may be "lost". In this case, it's better to try to "save" those structures by re-sampling the integral of the profile, and then derivating it afterwards. Now, if the initial profile is a coarse one, and that one has to oversample it, then a simple re-sampling of the profile is adequate.

Definition at line 235 of file lgs_init.py.

Here is the call graph for this function:

Variable Documentation

◆ shesha_db

string shesha.init.lgs_init.shesha_db = os.environ['SHESHA_DB_ROOT']

Definition at line 40 of file lgs_init.py.

◆ shesha_savepath

shesha.init.lgs_init.shesha_savepath = shesha_db

Definition at line 46 of file lgs_init.py.