Commit 15dcf72a490d845a04c9ed4a369993eb878a1f2b

Authored by pyros_astroguita
2 parents 9db75bf8 d4c2451c
Exists in dev

Merge branch 'dev' of https://gitlab.irap.omp.eu/pyros-irap/pyros into dev

config/pyros_observatory/general/devices/device_FLI_KITS_generic.yml
@@ -5,17 +5,17 @@ schema: schema_device-2.0.yml @@ -5,17 +5,17 @@ schema: schema_device-2.0.yml
5 DEVICE: 5 DEVICE:
6 6
7 inventory_label: Undefined 7 inventory_label: Undefined
8 - manufacturer: FLI  
9 - model: Kepler Image Time Stamp  
10 - description: "GPS FLI Kepler" # opt str 8 + manufacturer: GARMIN
  9 + model: Kepler Image Time Stamp (FITS)
  10 + description: "GPS 19x HVSM/N M1A1GN00" # opt str
11 sn: Undefined 11 sn: Undefined
12 power: 12 power:
13 - voltage: 12  
14 - intensity: 1 13 + voltage: 7.33
  14 + intensity: 0.1
15 socket: "MiniDIN 8 pins" 15 socket: "MiniDIN 8 pins"
16 16
17 connector: 17 connector:
18 - input: "GPS radio waves" 18 + input: "GLONASS radio waves"
19 output: "Meta data" 19 output: "Meta data"
20 20
21 comm: 21 comm:
src/core/pyros_django/scheduling/A_Scheduler.py
@@ -238,6 +238,10 @@ class A_Scheduler(Agent): @@ -238,6 +238,10 @@ class A_Scheduler(Agent):
238 """ 238 """
239 t0 = time.time() 239 t0 = time.time()
240 self.DPRINT = True 240 self.DPRINT = True
  241 +
  242 + # ===================
  243 + # --- Initializations
  244 + # ===================
241 # --- Get the incoming directory of the night 245 # --- Get the incoming directory of the night
242 info = self.get_infos() 246 info = self.get_infos()
243 rootdir = info['rootdir'] 247 rootdir = info['rootdir']
@@ -265,7 +269,10 @@ class A_Scheduler(Agent): @@ -265,7 +269,10 @@ class A_Scheduler(Agent):
265 schedule_order = np.zeros(self.BINS_NIGHT, dtype=int) -1 269 schedule_order = np.zeros(self.BINS_NIGHT, dtype=int) -1
266 schedule_jd = np.zeros(self.BINS_NIGHT, dtype=float) 270 schedule_jd = np.zeros(self.BINS_NIGHT, dtype=float)
267 schedule_scientific_programm_id = np.zeros(self.BINS_NIGHT, dtype=int) -1 271 schedule_scientific_programm_id = np.zeros(self.BINS_NIGHT, dtype=int) -1
  272 +
  273 + # ===========================================================================================================
268 # --- Initialize the predictive schedule by the effective schedule from start of the current instant (=index) 274 # --- Initialize the predictive schedule by the effective schedule from start of the current instant (=index)
  275 + # ===========================================================================================================
269 try: 276 try:
270 last_schedule = EffectiveSchedule.objects.last() 277 last_schedule = EffectiveSchedule.objects.last()
271 except EffectiveSchedule.DoesNotExist: 278 except EffectiveSchedule.DoesNotExist:
@@ -287,7 +294,7 @@ class A_Scheduler(Agent): @@ -287,7 +294,7 @@ class A_Scheduler(Agent):
287 schedule_jd[0:index] = schedule_eff_jd[0:index] 294 schedule_jd[0:index] = schedule_eff_jd[0:index]
288 schedule_scientific_programm_id[0:index] = schedule_eff_scientific_programm_id[0:index] 295 schedule_scientific_programm_id[0:index] = schedule_eff_scientific_programm_id[0:index]
289 else: 296 else:
290 - # --- Case when there is not ever effective schedule for this night 297 + # --- Case when there is no effective schedule for this night
291 print(f"No effective schedule for this night {night}") 298 print(f"No effective schedule for this night {night}")
292 else: 299 else:
293 # --- Case of invalid entry in the database 300 # --- Case of invalid entry in the database
@@ -316,9 +323,9 @@ class A_Scheduler(Agent): @@ -316,9 +323,9 @@ class A_Scheduler(Agent):
316 if os.path.exists(ephfile): 323 if os.path.exists(ephfile):
317 self.dprint(f"Read file {seqfile}") 324 self.dprint(f"Read file {seqfile}")
318 # --- seq_info = sequence dictionary 325 # --- seq_info = sequence dictionary
319 - # --- eph_info = ephemeris dictionary  
320 seq_info = pickle.load(open(seqfile,"rb")) 326 seq_info = pickle.load(open(seqfile,"rb"))
321 #print("="*20 + "\n" + f"{seq_info=}") 327 #print("="*20 + "\n" + f"{seq_info=}")
  328 + # --- eph_info = ephemeris dictionary
322 eph_info = pickle.load(open(ephfile,"rb")) 329 eph_info = pickle.load(open(ephfile,"rb"))
323 #print("="*20 + "\n" + f"{eph_info=}") 330 #print("="*20 + "\n" + f"{eph_info=}")
324 # --- 331 # ---