Changeset b3e8629 in sasview for src/sas/qtgui/Perspectives/Fitting/FitThread.py
- Timestamp:
- Nov 9, 2017 8:41:54 AM (7 years ago)
- Branches:
- ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc
- Children:
- cee5c78
- Parents:
- 749b715
- git-author:
- Piotr Rozyczko <rozyczko@…> (10/26/17 03:13:05)
- git-committer:
- Piotr Rozyczko <rozyczko@…> (11/09/17 08:41:54)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/qtgui/Perspectives/Fitting/FitThread.py
ree18d33 rb3e8629 14 14 15 15 def map_apply(arguments): 16 return a pply(arguments[0],arguments[1:])16 return arguments[0](*arguments[1:]) 17 17 18 18 class FitThread(CalcThread): … … 55 55 except KeyboardInterrupt: 56 56 msg = "Fitting: terminated by the user." 57 raise KeyboardInterrupt , msg57 raise KeyboardInterrupt(msg) 58 58 59 59 def compute(self): … … 71 71 list_q = [None]*fitter_size 72 72 73 inputs = zip(list_map_get_attr, self.fitter, list_fit_function,73 inputs = list(zip(list_map_get_attr, self.fitter, list_fit_function, 74 74 list_q, list_q, list_handler, list_curr_thread, 75 list_reset_flag) 76 result = map(map_apply, inputs)75 list_reset_flag)) 76 result = list(map(map_apply, inputs)) 77 77 results = (result, time.time()-self.starttime) 78 78 if self.handler: … … 81 81 return (results) 82 82 83 except KeyboardInterrupt ,msg:83 except KeyboardInterrupt as msg: 84 84 # Thread was interrupted, just proceed and re-raise. 85 85 # Real code should not print, but this is an example...
Note: See TracChangeset
for help on using the changeset viewer.