Пример #1
0
 def OnOk(self, event):
     failed, hkl_interval, w_interval, tau_list, direction, temp, sphavg_bool, plotstats = self.Validate()
     
     if not failed:
         int_file = self.int_file_txtCtrl.GetValue()
         spin_file = self.spin_file_txtCtrl.GetValue()
         output_file = self.output_file_txtCtrl.GetValue()
         print 'yay'
         
         tau_list = np.array(tau_list)
         csection_calc.cs_driver(int_file, spin_file, hkl_interval, w_interval, tau_list, 
                                 direction, temp, output_file, sphavg_bool, plotstats)
Пример #2
0
def CrossSectionFunc(queue, args):
    pid = os.getpid()
#    cs_driver(*args)
#    csection_arrays = np.load('csection_calc_data.npz')
#    csection = csection_arrays['csection'][0]
#    queue.put((pid,printing.create_latex(csection, "Cross section")))  #(PID, answer)
#    args = args[:-2]+(False, True)
#    if args == None:
#        raise Exception("Nonetype")
    outpath, colorbar_bool, plot_min, plot_max  = cs_driver(*args)
    queue.put((pid, (outpath, colorbar_bool, plot_min, plot_max)))