COMPASS  5.4.4
End-to-end AO simulation tool using GPU acceleration
sutraWrap.Dm Class Reference
Collaboration diagram for sutraWrap.Dm:

Public Member Functions

str __str__ (self)
 
int comp_oneactu (self, int nactu, float ampli)
 Push the specified actuator and computes the corresponding DM shape. More...
 
int comp_shape (self)
 Compute the DM shape according to commands d_com. More...
 
int comp_shape (self, numpy.ndarray[numpy.float32] com)
 
int comp_shape (self, numpy.ndarray[numpy.uint16] com)
 
int compute_KLbasis (self, numpy.ndarray[numpy.float32] xpos, numpy.ndarray[numpy.float32] ypos, numpy.ndarray[numpy.int32] indx_pup, int dim, float norm, float ampli)
 Computes the KL to volt matrix by double diagonalisation (cf. More...
 
int kl_loadarrays (self, numpy.ndarray[numpy.float32] rabas, numpy.ndarray[numpy.float32] azbas, numpy.ndarray[numpy.int32] ords, numpy.ndarray[numpy.float32] cr, numpy.ndarray[numpy.float32] cp)
 Load all the arrays computed during the initialization for a kl DM in a SutraDm object. More...
 
int pzt_loadarrays (self, numpy.ndarray[numpy.float32] influ, numpy.ndarray[numpy.int32] influpos, numpy.ndarray[numpy.int32] npoints, numpy.ndarray[numpy.int32] istart, numpy.ndarray[numpy.int32] xoff, numpy.ndarray[numpy.int32] yoff)
 Load all the arrays computed during the initialization for a pzt DM in a SutraDm object. More...
 
int reset_shape (self)
 Reset the DM shape to zeros (flat) More...
 
None set_com (self, numpy.ndarray[numpy.float32] com, bool shape_dm=True)
 Set the command vector of a SutraDm, and computes the DM shape. More...
 
int set_registration (self, float dx, float dy, float theta, float G)
 Set the registration parameters : dx, dy, theta and G. More...
 
int tt_loadarrays (self, numpy.ndarray[numpy.float32] influ)
 Load all the arrays computed during the initialization for a tt DM in a SutraDm object. More...
 

Properties

 G = property
 Magnification factor registration in pixels. More...
 
 altitude = property
 DM conjugaison altitude. More...
 
 d_KLbasis = property
 KL to volts matrix. More...
 
 d_com = property
 Current commands of the DM. More...
 
 d_influ = property
 Cube of influence functions. More...
 
 d_influpos = property
 Influence functions positions in the pupil. More...
 
 d_istart = property
 TODO docstring. More...
 
 d_kl = property
 SutraKL DM. More...
 
 d_npoints = property
 Number of IF that impact each pixel of the pupil. More...
 
 d_shape = property
 DM shape. More...
 
 d_xoff = property
 TODO docstring. More...
 
 d_yoff = property
 TODO docstring. More...
 
 device = property
 Device index. More...
 
 dim = property
 DM support size. More...
 
 dx = property
 X registration in pixels. More...
 
 dy = property
 Y registration in pixels. More...
 
 influsize = property
 Influence function support size. More...
 
 nactus = property
 Number of actuators. More...
 
 push4imat = property
 Voltage to apply for imat computation. More...
 
 thetaML = property
 thetaML registration in radians More...
 
 type = property
 DM type. More...
 

Detailed Description

Definition at line 4724 of file sutraWrap.py.

Member Function Documentation

◆ __str__()

str sutraWrap.Dm.__str__ (   self)

Definition at line 4725 of file sutraWrap.py.

◆ comp_oneactu()

int sutraWrap.Dm.comp_oneactu (   self,
int  nactu,
float  ampli 
)

Push the specified actuator and computes the corresponding DM shape.

Parameters
nactu(int): Actuator index
ampli(float): Volt to apply to this actuator

Definition at line 4735 of file sutraWrap.py.

◆ comp_shape() [1/3]

int sutraWrap.Dm.comp_shape (   self)

Compute the DM shape according to commands d_com.

    Compute the DM shape according to given commands
Parameters
com(np.ndarray[ndim=1,dtype=np.float32_t]): commands to apply
    Compute the DM shape according to given commands
Parameters
com(np.ndarray[ndim=1,dtype=np.uint16_t]): commands to apply

Definition at line 4757 of file sutraWrap.py.

Here is the caller graph for this function:

◆ comp_shape() [2/3]

int sutraWrap.Dm.comp_shape (   self,
numpy.ndarray[numpy.float32]  com 
)

Definition at line 4759 of file sutraWrap.py.

Here is the call graph for this function:

◆ comp_shape() [3/3]

int sutraWrap.Dm.comp_shape (   self,
numpy.ndarray[numpy.uint16]  com 
)

Definition at line 4761 of file sutraWrap.py.

Here is the call graph for this function:

◆ compute_KLbasis()

int sutraWrap.Dm.compute_KLbasis (   self,
numpy.ndarray[numpy.float32]  xpos,
numpy.ndarray[numpy.float32]  ypos,
numpy.ndarray[numpy.int32]  indx_pup,
int  dim,
float  norm,
float  ampli 
)

Computes the KL to volt matrix by double diagonalisation (cf.

Gendron thesis)

  • compute the phase covariance matrix on the actuators using Kolmogorov
  • compute the geometric covariance matrix
  • double diagonalisation to obtain KL basis
Parameters
xpos(np.ndarray[ndim=1,dtype=np.float32_t]) : x-position of actuators
ypos(np.ndarray[ndim=1,dtype=np.float32_t]) : y-position of actuators
indx_pup(np.ndarray[ndim=1,dtype=np.int32_t]) : indices of pupil points
dim(long) : number of points in the pupil
norm(float) : normalization factor
ampli(float) : amplitude

Definition at line 4782 of file sutraWrap.py.

◆ kl_loadarrays()

int sutraWrap.Dm.kl_loadarrays (   self,
numpy.ndarray[numpy.float32]  rabas,
numpy.ndarray[numpy.float32]  azbas,
numpy.ndarray[numpy.int32]  ords,
numpy.ndarray[numpy.float32]  cr,
numpy.ndarray[numpy.float32]  cp 
)

Load all the arrays computed during the initialization for a kl DM in a SutraDm object.

Parameters
rabas(np.ndarray[ndim=1,dtype=np.float32_t]): TODO docstring
azbas(np.ndarray[ndim=1,dtype=np.float32_t]):
ords(np.ndarray[ndim=1,dtype=np.int32_t]):
cr(np.ndarray[ndim=1,dtype=np.float32_t]):
cp(np.ndarray[ndim=1,dtype=np.float32_t]):

Definition at line 4798 of file sutraWrap.py.

◆ pzt_loadarrays()

int sutraWrap.Dm.pzt_loadarrays (   self,
numpy.ndarray[numpy.float32]  influ,
numpy.ndarray[numpy.int32]  influpos,
numpy.ndarray[numpy.int32]  npoints,
numpy.ndarray[numpy.int32]  istart,
numpy.ndarray[numpy.int32]  xoff,
numpy.ndarray[numpy.int32]  yoff 
)

Load all the arrays computed during the initialization for a pzt DM in a SutraDm object.

Parameters
influ(np.ndarray[ndim=3,dtype=np.float32_t]) : influence functions cube
       influ2:

       influ3:
influpos(np.ndarray[ndim=1,dtype=np.int32_t]) : positions of the IF in the pupil
       influpos2:
npoints(np.ndarray[ndim=1,dtype=np.int32_t]) : for each pixel on the DM screen, the number of IF which impact on this pixel
istart(np.ndarray[ndim=1,dtype=np.int32_t]) :
xoff(np.ndarray[ndim=1,dtype=np.int32_t]) : x-offset for shape computation
yoff(np.ndarray[ndim=1,dtype=np.int32_t]) : y-offset or shape computation

Definition at line 4822 of file sutraWrap.py.

◆ reset_shape()

int sutraWrap.Dm.reset_shape (   self)

Reset the DM shape to zeros (flat)

Definition at line 4826 of file sutraWrap.py.

◆ set_com()

None sutraWrap.Dm.set_com (   self,
numpy.ndarray[numpy.float32]  com,
bool   shape_dm = True 
)

Set the command vector of a SutraDm, and computes the DM shape.

Parameters
com(np.array(ndim=1, dtype=np.float32)): Command vector
shape_dm(bool): (optionnal, default=True) Computes the DM shape

Definition at line 4836 of file sutraWrap.py.

◆ set_registration()

int sutraWrap.Dm.set_registration (   self,
float  dx,
float  dy,
float  theta,
float  G 
)

Set the registration parameters : dx, dy, theta and G.

Parameters
dx(float): X axis misregistration [pixels]
dy(float): Y axis misregistration [pixels]
theta(float): Rotation angle misregistration [radians]
G(float): Magnification factor

Definition at line 4850 of file sutraWrap.py.

◆ tt_loadarrays()

int sutraWrap.Dm.tt_loadarrays (   self,
numpy.ndarray[numpy.float32]  influ 
)

Load all the arrays computed during the initialization for a tt DM in a SutraDm object.

Parameters
influ(np.ndarray[ndim=3,dtype=np.float32_t]) : influence functions cube

Definition at line 4858 of file sutraWrap.py.

Property Documentation

◆ altitude

sutraWrap.Dm.altitude = property
static

DM conjugaison altitude.

   @n type of :  float

Definition at line 4874 of file sutraWrap.py.

◆ d_com

sutraWrap.Dm.d_com = property
static

Current commands of the DM.

   @n type of :  carmaWrap.obj_float

Definition at line 4892 of file sutraWrap.py.

◆ d_influ

sutraWrap.Dm.d_influ = property
static

Cube of influence functions.

   @n type of :  carmaWrap.obj_float

Definition at line 4901 of file sutraWrap.py.

◆ d_influpos

sutraWrap.Dm.d_influpos = property
static

Influence functions positions in the pupil.

   @n type of :  carmaWrap.obj_int

Definition at line 4910 of file sutraWrap.py.

◆ d_istart

sutraWrap.Dm.d_istart = property
static

TODO docstring.

   @n type of :  carmaWrap.obj_int

Definition at line 4919 of file sutraWrap.py.

◆ d_kl

sutraWrap.Dm.d_kl = property
static

SutraKL DM.

   @n type of :  SutraKL

Definition at line 4928 of file sutraWrap.py.

◆ d_KLbasis

sutraWrap.Dm.d_KLbasis = property
static

KL to volts matrix.

   @n type of :  carmaWrap.obj_float

Definition at line 4883 of file sutraWrap.py.

◆ d_npoints

sutraWrap.Dm.d_npoints = property
static

Number of IF that impact each pixel of the pupil.

   @n type of :  carmaWrap.obj_int

Definition at line 4937 of file sutraWrap.py.

◆ d_shape

sutraWrap.Dm.d_shape = property
static

DM shape.

   @n type of :  carmaWrap.obj_float

Definition at line 4946 of file sutraWrap.py.

◆ d_xoff

sutraWrap.Dm.d_xoff = property
static

TODO docstring.

   @n type of :  carmaWrap.obj_int

Definition at line 4955 of file sutraWrap.py.

◆ d_yoff

sutraWrap.Dm.d_yoff = property
static

TODO docstring.

   @n type of :  carmaWrap.obj_int

Definition at line 4964 of file sutraWrap.py.

◆ device

sutraWrap.Dm.device = property
static

Device index.

   @n type of :  int

Definition at line 4973 of file sutraWrap.py.

◆ dim

sutraWrap.Dm.dim = property
static

DM support size.

   @n type of :  int

Definition at line 4982 of file sutraWrap.py.

◆ dx

sutraWrap.Dm.dx = property
static

X registration in pixels.

   @n type of :  float

Definition at line 4991 of file sutraWrap.py.

◆ dy

sutraWrap.Dm.dy = property
static

Y registration in pixels.

   @n type of :  float

Definition at line 5000 of file sutraWrap.py.

◆ G

sutraWrap.Dm.G = property
static

Magnification factor registration in pixels.

   @n type of :  float

Definition at line 4865 of file sutraWrap.py.

◆ influsize

sutraWrap.Dm.influsize = property
static

Influence function support size.

   @n type of :  int

Definition at line 5009 of file sutraWrap.py.

◆ nactus

sutraWrap.Dm.nactus = property
static

Number of actuators.

   @n type of :  int

Definition at line 5018 of file sutraWrap.py.

◆ push4imat

sutraWrap.Dm.push4imat = property
static

Voltage to apply for imat computation.

   @n type of :  float

Definition at line 5027 of file sutraWrap.py.

◆ thetaML

sutraWrap.Dm.thetaML = property
static

thetaML registration in radians

   @n type of :  float

Definition at line 5036 of file sutraWrap.py.

◆ type

sutraWrap.Dm.type = property
static

DM type.

   @n type of :  str

Definition at line 5045 of file sutraWrap.py.


The documentation for this class was generated from the following file: