diff --git a/user/sumlab_auto.py b/user/sumlab_auto.py index 37f590bc7eef4c96a3b0e452732f2476fcc377aa..760cab06be3cfeb3376743f9183f8c4924fdc0b6 100644 --- a/user/sumlab_auto.py +++ b/user/sumlab_auto.py @@ -70,9 +70,12 @@ print("=======================================\033[0m") # Loop thorough SORTED files in alphabetical order! files_to_fit = sorted(files_to_fit, key=lambda x: x[0]) for i, (file, path) in enumerate(files_to_fit): - print("Fitting: \033[95m{:s}\033[0m".format(file)) V = float(file.split('deg')[1].split('V')[0].replace('_', '.')) - f_tau_hmt = f_tau(V, V_bd_hmt, V_0_hmt) + if 'ns' in file: + t_gate = float(file.split('V')[1].split('ns')[0].replace('_', '.')) + print(f"Fitting: \033[95m{file}\033[0m (t_gate = {t_gate} ns)") + + #f_tau_hmt = f_tau(V, V_bd_hmt, V_0_hmt) # Load files. data = np.loadtxt(path, skiprows=0) @@ -83,7 +86,7 @@ for i, (file, path) in enumerate(files_to_fit): tau=tau, # SLOW PULSE COMPONENT TIME CONSTANT (ns) t_gate=t_gate, # GATE LENGTH (ns) t_0=t_0, # INTEGRATION TIME BEFORE GATE (ns) - tau_R=f_tau_hmt*tau, + tau_R=0.65*tau, #WAS: tau_R=f_tau_hmt*tau, bin_0=bin_0, truncate_nsigma0_up=truncate_nsigma0_up, truncate_nsigma0_do=truncate_nsigma0_do,