Changeset 6da860a in sasview for src/sas/qtgui/Perspectives/Inversion/InversionPerspective.py
- Timestamp:
- May 1, 2018 11:51:06 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:
- 72ecbdf2
- Parents:
- 6bd0d81
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/qtgui/Perspectives/Inversion/InversionPerspective.py
rd79bb7e r6da860a 31 31 MAX_DIST = 140.0 32 32 DICT_KEYS = ["Calculator", "PrPlot", "DataPlot"] 33 34 logger = logging.getLogger(__name__) 33 35 34 36 … … 354 356 msg = "Unable to update P{r}. The connection between the main GUI " 355 357 msg += "and P(r) was severed. Attempting to restart P(r)." 356 logg ing.warning(msg)358 logger.warning(msg) 357 359 self.setClosable(True) 358 360 self.close() … … 395 397 """ 396 398 from .DMaxExplorerWidget import DmaxWindow 397 self.dmaxWindow = DmaxWindow(self._calculator, self.getNFunc(), self) 399 self.dmaxWindow = DmaxWindow(pr_state=self._calculator, 400 nfunc=self.getNFunc(), 401 parent=self) 398 402 self.dmaxWindow.show() 399 403 … … 459 463 nfunc = int(self.noOfTermsInput.text()) 460 464 except ValueError: 461 logg ing.error("Incorrect number of terms specified: %s"465 logger.error("Incorrect number of terms specified: %s" 462 466 %self.noOfTermsInput.text()) 463 467 self.noOfTermsInput.setText(str(NUMBER_OF_TERMS)) … … 581 585 self.dataList.setCurrentIndex(index) 582 586 self.isBatch = True 587 # Add the index before calculating in case calculation fails 588 self.batchComplete.append(index) 583 589 break 584 590 if self.isBatch: … … 599 605 # Set data before running the calculations 600 606 self.updateCalculator() 607 # Disable calculation buttons to prevent thread interference 608 self.calculateAllButton.setEnabled(False) 609 self.calculateThisButton.setEnabled(False) 601 610 602 611 # If a thread is already started, stop it … … 672 681 """ 673 682 alpha, message, elapsed = output_tuple 683 self._calculator.alpha = alpha 684 self._calculator.elapsed += self._calculator.elapsed 674 685 if message: 675 logg ing.info(message)686 logger.info(message) 676 687 self.performEstimateNT() 677 688 … … 690 701 """ 691 702 nterms, alpha, message, elapsed = output_tuple 692 self._calculator.elapsed = elapsed703 self._calculator.elapsed += elapsed 693 704 self._calculator.suggested_alpha = alpha 694 705 self.nTermsSuggested = nterms … … 696 707 self.updateGuiValues() 697 708 if message: 698 logg ing.info(message)709 logger.info(message) 699 710 if self.isBatch: 700 711 self.acceptAlpha() … … 742 753 Call-back method for calculation errors 743 754 """ 744 logg ing.warning(error)755 logger.error(error)
Note: See TracChangeset
for help on using the changeset viewer.