Commit 3a945e0f authored by bliss administrator's avatar bliss administrator
Browse files

Bug corrections atfer testing pcotomo

parent d067a616
......@@ -1624,7 +1624,7 @@ class PcoTomo(FastTomo, TomoParameters):
f"Time to download film: {round((sizeofonescan * self.parameters.ntomo) / (transferrate / 1024), 2)} s ({round((sizeofonescan * self.parameters.ntomo) / (transferrate / 1024) / 60, 2)} min)\n"
)
elif mode == "multiple":
elif self.parameters.mode == "multiple":
print("\n\nWaiting Turns Between Each Scan")
print(f"You will collect a total of {self.parameters.nloop} scans\n")
print(f"You will wait {self.parameters.nwait} turns between each scan")
......@@ -1635,7 +1635,7 @@ class PcoTomo(FastTomo, TomoParameters):
f"Time to download film: {round((sizeofonescan * self.parameters.nloop) / (transferrate / 1024), 2)} s ({round((sizeofonescan * self.parameters.nloop) / (transferrate / 1024) / 60, 2)} min)\n"
)
elif mode == "endless":
elif self.parameters.mode == "endless":
print(
f"\n\nYou will wait {unlimitwaitingturns} turns between each scan, during this time, scan is downloaded"
)
......@@ -1720,7 +1720,8 @@ class PcoTomo(FastTomo, TomoParameters):
proj_scan_time = tomo_tools.continuous_scan_time(motor, start_pos)
proj_scan_time += round((self.in_pars["sizeofonescan"] * self.parameters.ntomo * self.parameters.nloop) / (self.in_pars["transferrate"] / 1024), 2)
if self.parameters.mode != 'endless':
proj_scan_time += round((self.in_pars["sizeofonescan"] * self.parameters.ntomo * self.parameters.nloop) / (self.in_pars["transferrate"] / 1024), 2)
return ref_scan_time + dark_scan_time + proj_scan_time
......@@ -1732,7 +1733,7 @@ class PcoTomo(FastTomo, TomoParameters):
self.tomo_scan.calculate_parameters(
self.tomo.parameters.start_pos,
self.tomo.parameters.end_pos - self.tomo.parameters.start_pos,
self.tomo.parameters.end_pos,
self.tomo.parameters.tomo_n,
self.tomo.parameters.exposure_time,
self.tomo.parameters.latency_time,
......@@ -1821,12 +1822,12 @@ class PcoTomo(FastTomo, TomoParameters):
proj_scan.add_preset(header_preset)
# add shutter preset
#shutter_preset = PcoTomoShutterPreset(
# self.tomo.shutter,
# self.tomo_musst,
# self.tomo.sequence_preset[0].mux,
#)
#proj_scan.add_preset(shutter_preset)
shutter_preset = PcoTomoShutterPreset(
self.tomo.shutter,
self.tomo_musst,
self.tomo.sequence_preset[0].mux,
)
proj_scan.add_preset(shutter_preset)
# add to scan sequence when requested
if scan_sequence != None:
......
......@@ -206,7 +206,7 @@ class PcoTomoTools(TomoTools):
disp = undershoot + undershoot_start_margin
scan_time = 0
disp += self.tomo.pcotomo.parameters.nloop*self.tomo.pcotomo.tomo_scan.in_pars['trange']
if self.tomo.pcotomo.parameters.nloop > 1:
......@@ -219,13 +219,13 @@ class PcoTomoTools(TomoTools):
if self.tomo.pcotomo.parameters.nwait < -1:
delta += abs(self.tomo.pcotomo.parameters.nwait) * 360
else:
delta += self.tomo.pcotomo.scan_info['unlimitwaitingturns'] * 360
delta += self.tomo.pcotomo.in_pars['unlimitwaitingturns'] * 360
else:
delta += self.tomo.pcotomo.parameters.nwait * 360
else:
delta = 0
disp += delta*self.tomo.pcotomo.parameters.nloop
disp += delta*self.tomo.pcotomo.parameters.nloop
scan_time += self.mot_disp_time(motor,disp,speed)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment