Changeset 1dc1d431 in sasview for src


Ignore:
Timestamp:
Dec 7, 2018 9:09:00 AM (6 years ago)
Author:
wojciech
Branches:
ESS_GUI, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_opencl, ESS_GUI_sync_sascalc
Children:
44a698c
Parents:
aea6bb7
Message:

Decoupling low and high q errors

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sas/qtgui/Perspectives/Invariant/InvariantPerspective.py

    raea6bb7 r1dc1d431  
    329329            surface = None 
    330330 
     331        if (calculation_failed): 
     332            logging.warning('Calculation failed: {}'.format(msg)) 
     333            return self.model 
     334 
     335        low_calculation_pass = True 
     336        high_calculation_pass = True 
    331337        if self._low_extrapolate: 
    332338            try: 
    333339                qstar_low, qstar_low_err = inv.get_qstar_low() 
    334340            except Exception as ex: 
    335                 calculation_failed = True 
     341                low_calculation_pass = False 
    336342                msg += str(ex) 
     343                logging.warning('Low-q calculation failed: {}'.format(msg)) 
    337344        if self._high_extrapolate: 
    338345            try: 
    339346                qstar_high, qstar_high_err = inv.get_qstar_high() 
    340347            except Exception as ex: 
    341                 calculation_failed = True 
     348                high_calculation_pass = False 
    342349                msg += str(ex) 
    343  
    344         if (calculation_failed): 
    345             logging.warning('Calculation failed: {}'.format(msg)) 
    346             return self.model 
    347  
    348         if self._low_extrapolate: 
     350                logging.warning('High-q calculation failed: {}'.format(msg)) 
     351 
     352 
     353        if self._low_extrapolate and low_calculation_pass: 
    349354            extrapolated_data = inv.get_extra_data_low(self._low_points) 
    350355            power_low = inv.get_extrapolation_power(range='low') 
     
    374379                                       title) 
    375380 
    376         if self._high_extrapolate: 
     381        if self._high_extrapolate and high_calculation_pass: 
    377382            # for presentation in InvariantDetails 
    378383            qmax_plot = Q_MAXIMUM_PLOT * max(temp_data.x) 
Note: See TracChangeset for help on using the changeset viewer.