COMPASS  5.0.0
End-to-end AO simulation tool using GPU acceleration
open_loop Namespace Reference

Functions

def loop (n)
 

Variables

string error = 'command line should be:"python -i test.py parameters_filename"\n with "parameters_filename" the path to the parameters file'
 
 param_file = sys.argv[1]
 
 filename = param_file.split('/')[-1]
 
 param_path = param_file.split(filename)[0]
 
string simul_name = ""
 
int clean = 1
 
dictionary matricesToLoad = {}
 
 c = ch.carmaWrap_context(devices=config.p_loop.devices)
 
 wfs
 
 tel
 
 atm
 
 dms = ao.dm_init(config.p_dms, config.p_wfss, wfs, config.p_geom, config.p_tel)
 
int mimg = 0.
 

Function Documentation

◆ loop()

def open_loop.loop (   n)

Definition at line 91 of file open_loop.py.

91 def loop(n):
92  print("----------------------------------------------------")
93  print("iter# | S.E. SR | L.E. SR | Est. Rem. | framerate")
94  print("----------------------------------------------------")
95  t0 = time.time()
96  for i in range(n):
97  atm.move_atmos()
98 
99  for w in range(len(config.p_wfss)):
100  wfs.sensors_trace(w, b"all", tel, atm, dms)
101 
102  t1 = time.time()
103  print(" loop execution time:", t1 - t0, " (", n, "iterations), ", (t1 - t0) / n,
104  "(mean) ", n / (t1 - t0), "Hz")
105 
106 
107 # loop(config.p_loop.niter)

Variable Documentation

◆ atm

open_loop.atm
Initial value:
1 = ao.atmos_init(c, config.p_atmos, config.p_tel, config.p_geom, config.p_loop,
2  config.p_wfss, wfs, None, clean=clean, load=matricesToLoad)

Definition at line 66 of file open_loop.py.

◆ c

open_loop.c = ch.carmaWrap_context(devices=config.p_loop.devices)

Definition at line 57 of file open_loop.py.

◆ clean

int open_loop.clean = 1

Definition at line 46 of file open_loop.py.

◆ dms

open_loop.dms = ao.dm_init(config.p_dms, config.p_wfss, wfs, config.p_geom, config.p_tel)

Definition at line 71 of file open_loop.py.

◆ error

string open_loop.error = 'command line should be:"python -i test.py parameters_filename"\n with "parameters_filename" the path to the parameters file'

Definition at line 16 of file open_loop.py.

◆ filename

open_loop.filename = param_file.split('/')[-1]

Definition at line 22 of file open_loop.py.

◆ matricesToLoad

dictionary open_loop.matricesToLoad = {}

Definition at line 47 of file open_loop.py.

◆ mimg

int open_loop.mimg = 0.

Definition at line 88 of file open_loop.py.

◆ param_file

open_loop.param_file = sys.argv[1]

Definition at line 20 of file open_loop.py.

◆ param_path

open_loop.param_path = param_file.split(filename)[0]

Definition at line 23 of file open_loop.py.

◆ simul_name

string open_loop.simul_name = ""

Definition at line 39 of file open_loop.py.

◆ tel

open_loop.tel

Definition at line 61 of file open_loop.py.

◆ wfs

open_loop.wfs

Definition at line 61 of file open_loop.py.