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

Public Member Functions

int add_perturb (self)
 Add the perturbation voltage to the command. More...
 
int add_perturb_voltage (self, str name, numpy.ndarray[numpy.float32] perturb, int N)
 Add a new perturbation voltage buffer. More...
 
int clip_commands (self)
 Clip the commands between volt_min and volt_max (values set in the controller) More...
 
int command_delay (self)
 Delay the command. More...
 
int comp_voltage (self)
 Computes the final voltage to send to the DM. More...
 
int disable_perturb_voltage (self, str name)
 Disable a perturbation voltage buffer. More...
 
int enable_perturb_voltage (self, str name)
 Enable a perturbation voltage buffer. More...
 
int remove_perturb_voltage (self, str name)
 Remove a perturbation voltage buffer. More...
 
int reset_coms (self)
 Reset the commands circular buffer. More...
 
int reset_perturb_voltage (self)
 Remove all perturbation voltage buffers. More...
 
int set_com (self, numpy.ndarray[numpy.float32] com, int nElem)
 Set the command vector of the controller. More...
 
None set_comRange (self, float volt_min, float volt_max)
 Set the volt_min and volt_max value for command clipping. More...
 
int set_delay (self, float delay)
 Set the delay. More...
 
int set_gain (self, float gain)
 Set the gain. More...
 
int set_open_loop (self, int status, bool rst=True)
 Open (1) or close (0) the loop. More...
 
int set_perturb_voltage (self, str name, numpy.ndarray[numpy.float32] perturb, int N)
 Set an existing perturbation voltage buffer. More...
 
int set_val_max (self, float val_max)
 Set the val_max value for command conversion. More...
 
int set_volt_max (self, float volt_max)
 Set the volt_max value for command clipping. More...
 

Properties

 centro_idx = property
 Indices of the handled centroiders. More...
 
 comRange = property
 
type of : typing.Tuple[float, float] More...
 
 context = property
 GPU context. More...
 
 d_centroids = property
 Slopes vector. More...
 
 d_circularComs0 = property
 Oldest command vector in the circular buffer. More...
 
 d_circularComs1 = property
 Second oldest Command vector in the circular buffer. More...
 
 d_com = property
 Current command vector. More...
 
 d_com1 = property
 Command vector at iteration k-1. More...
 
 d_com_clipped = property
 Delayed commands. More...
 
 d_dmseen = property
 Vector of SutraDm commanded. More...
 
 d_perturb_map = property
 Perturbation voltage buffers. More...
 
 d_voltage = property
 Total voltage to apply on the DMs. More...
 
 delay = property
 Loop delay. More...
 
 device = property
 GPU device index. More...
 
 gain = property
 Controller gain. More...
 
 nactu = property
 Number of actuators to control. More...
 
 nslope = property
 Number of slopes. More...
 
 open_loop = property
 Open loop flag. More...
 
 type = property
 Controller type. More...
 
 val_max = property
 Maximum value for d_voltage (ADU). More...
 

Detailed Description

Definition at line 1528 of file sutraWrap.py.

Member Function Documentation

◆ add_perturb()

int sutraWrap.Controller_FF.add_perturb (   self)

Add the perturbation voltage to the command.

Definition at line 1532 of file sutraWrap.py.

◆ add_perturb_voltage()

int sutraWrap.Controller_FF.add_perturb_voltage (   self,
str  name,
numpy.ndarray[numpy.float32]  perturb,
int  N 
)

Add a new perturbation voltage buffer.

Parameters
name(str): name of the new buffer
perturb(np.array[ndim=2,dtype=np.float32]): perturbation voltage to set
N(int): Number of perturb voltage vectors in the buffer

Definition at line 1544 of file sutraWrap.py.

◆ clip_commands()

int sutraWrap.Controller_FF.clip_commands (   self)

Clip the commands between volt_min and volt_max (values set in the controller)

Definition at line 1548 of file sutraWrap.py.

◆ command_delay()

int sutraWrap.Controller_FF.command_delay (   self)

Delay the command.

Definition at line 1552 of file sutraWrap.py.

◆ comp_voltage()

int sutraWrap.Controller_FF.comp_voltage (   self)

Computes the final voltage to send to the DM.

Definition at line 1556 of file sutraWrap.py.

◆ disable_perturb_voltage()

int sutraWrap.Controller_FF.disable_perturb_voltage (   self,
str  name 
)

Disable a perturbation voltage buffer.

Parameters
name(str): name of the buffer to enable

Definition at line 1564 of file sutraWrap.py.

◆ enable_perturb_voltage()

int sutraWrap.Controller_FF.enable_perturb_voltage (   self,
str  name 
)

Enable a perturbation voltage buffer.

Parameters
name(str): name of the buffer to enable

Definition at line 1572 of file sutraWrap.py.

◆ remove_perturb_voltage()

int sutraWrap.Controller_FF.remove_perturb_voltage (   self,
str  name 
)

Remove a perturbation voltage buffer.

Parameters
name(str): name of the buffer to remove

Definition at line 1580 of file sutraWrap.py.

◆ reset_coms()

int sutraWrap.Controller_FF.reset_coms (   self)

Reset the commands circular buffer.

Definition at line 1584 of file sutraWrap.py.

◆ reset_perturb_voltage()

int sutraWrap.Controller_FF.reset_perturb_voltage (   self)

Remove all perturbation voltage buffers.

Definition at line 1589 of file sutraWrap.py.

◆ set_com()

int sutraWrap.Controller_FF.set_com (   self,
numpy.ndarray[numpy.float32]  com,
int  nElem 
)

Set the command vector of the controller.

Parameters
com(np.array[ndim=3, dtype=np.float32]) : command vector
nElem(int): Number of elements in com

Definition at line 1599 of file sutraWrap.py.

◆ set_comRange()

None sutraWrap.Controller_FF.set_comRange (   self,
float  volt_min,
float  volt_max 
)

Set the volt_min and volt_max value for command clipping.

Parameters
volt_min(float): volt_min value for clipping
volt_max(float): volt_max value for clipping

Definition at line 1609 of file sutraWrap.py.

◆ set_delay()

int sutraWrap.Controller_FF.set_delay (   self,
float  delay 
)

Set the delay.

Parameters
delay(float): loop delay in frames

Definition at line 1617 of file sutraWrap.py.

◆ set_gain()

int sutraWrap.Controller_FF.set_gain (   self,
float  gain 
)

Set the gain.

Parameters
gain(float): loop gain

Definition at line 1625 of file sutraWrap.py.

◆ set_open_loop()

int sutraWrap.Controller_FF.set_open_loop (   self,
int  status,
bool   rst = True 
)

Open (1) or close (0) the loop.

Parameters
status(int): open loop status
rst(bool): reset integrator if True

Definition at line 1635 of file sutraWrap.py.

◆ set_perturb_voltage()

int sutraWrap.Controller_FF.set_perturb_voltage (   self,
str  name,
numpy.ndarray[numpy.float32]  perturb,
int  N 
)

Set an existing perturbation voltage buffer.

Parameters
name(str): name of the buffer
perturb(np.array[ndim=2,dtype=np.float32]): perturbation voltage to set
N(int): Number of perturb voltage vectors in the buffer

Definition at line 1647 of file sutraWrap.py.

◆ set_val_max()

int sutraWrap.Controller_FF.set_val_max (   self,
float  val_max 
)

Set the val_max value for command conversion.

Parameters
val_max(float): val_max value for conversion

Definition at line 1655 of file sutraWrap.py.

◆ set_volt_max()

int sutraWrap.Controller_FF.set_volt_max (   self,
float  volt_max 
)

Set the volt_max value for command clipping.

Parameters
volt_max(float): volt_max value for clipping

Definition at line 1663 of file sutraWrap.py.

Property Documentation

◆ centro_idx

sutraWrap.Controller_FF.centro_idx = property
static

Indices of the handled centroiders.

   @n type of :  typing.List[int]

Definition at line 1670 of file sutraWrap.py.

◆ comRange

sutraWrap.Controller_FF.comRange = property
static


type of : typing.Tuple[float, float]

Definition at line 1677 of file sutraWrap.py.

◆ context

sutraWrap.Controller_FF.context = property
static

GPU context.

   @n type of :  carmaWrap.context

Definition at line 1686 of file sutraWrap.py.

◆ d_centroids

sutraWrap.Controller_FF.d_centroids = property
static

Slopes vector.

   @n type of :  carmaWrap.obj_float

Definition at line 1695 of file sutraWrap.py.

◆ d_circularComs0

sutraWrap.Controller_FF.d_circularComs0 = property
static

Oldest command vector in the circular buffer.

   @n type of :  carmaWrap.obj_float

Definition at line 1704 of file sutraWrap.py.

◆ d_circularComs1

sutraWrap.Controller_FF.d_circularComs1 = property
static

Second oldest Command vector in the circular buffer.

   @n type of :  carmaWrap.obj_float

Definition at line 1713 of file sutraWrap.py.

◆ d_com

sutraWrap.Controller_FF.d_com = property
static

Current command vector.

   @n type of :  carmaWrap.obj_float

Definition at line 1722 of file sutraWrap.py.

◆ d_com1

sutraWrap.Controller_FF.d_com1 = property
static

Command vector at iteration k-1.

   @n type of :  carmaWrap.obj_float

Definition at line 1731 of file sutraWrap.py.

◆ d_com_clipped

sutraWrap.Controller_FF.d_com_clipped = property
static

Delayed commands.

   @n type of :  carmaWrap.obj_float

Definition at line 1740 of file sutraWrap.py.

◆ d_dmseen

sutraWrap.Controller_FF.d_dmseen = property
static

Vector of SutraDm commanded.

   @n type of :  typing.List[Dm]

Definition at line 1749 of file sutraWrap.py.

◆ d_perturb_map

sutraWrap.Controller_FF.d_perturb_map = property
static

Perturbation voltage buffers.

   @n type of :  typing.Dict[str, typing.Tuple[carmaWrap.obj_float, int, bool]]

Definition at line 1758 of file sutraWrap.py.

◆ d_voltage

sutraWrap.Controller_FF.d_voltage = property
static

Total voltage to apply on the DMs.

   @n type of :  carmaWrap.obj_float

Definition at line 1767 of file sutraWrap.py.

◆ delay

sutraWrap.Controller_FF.delay = property
static

Loop delay.

   @n type of :  float

Definition at line 1776 of file sutraWrap.py.

◆ device

sutraWrap.Controller_FF.device = property
static

GPU device index.

   @n type of :  int

Definition at line 1785 of file sutraWrap.py.

◆ gain

sutraWrap.Controller_FF.gain = property
static

Controller gain.

   @n type of :  float

Definition at line 1794 of file sutraWrap.py.

◆ nactu

sutraWrap.Controller_FF.nactu = property
static

Number of actuators to control.

   @n type of :  int

Definition at line 1803 of file sutraWrap.py.

◆ nslope

sutraWrap.Controller_FF.nslope = property
static

Number of slopes.

   @n type of :  int

Definition at line 1812 of file sutraWrap.py.

◆ open_loop

sutraWrap.Controller_FF.open_loop = property
static

Open loop flag.

   @n type of :  int

Definition at line 1821 of file sutraWrap.py.

◆ type

sutraWrap.Controller_FF.type = property
static

Controller type.

   @n type of :  str

Definition at line 1830 of file sutraWrap.py.

◆ val_max

sutraWrap.Controller_FF.val_max = property
static

Maximum value for d_voltage (ADU).

Only used if output is expected in uint16

   @n type of :  float

Definition at line 1839 of file sutraWrap.py.


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