Changeset fef38e8 in sasview for src/sas/qtgui/Plotting


Ignore:
Timestamp:
Sep 13, 2017 6:24:34 AM (7 years ago)
Author:
Piotr Rozyczko <rozyczko@…>
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:
3c8242c
Parents:
9909967
Message:

Startup time improvements - hiding expensive imports and such

Location:
src/sas/qtgui/Plotting
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/sas/qtgui/Plotting/Fittings.py

    • Property mode changed from 100755 to 100644
    rdc5ef15 rfef38e8  
    1414 
    1515""" 
    16 from scipy import optimize 
    17  
    18  
    1916class Parameter(object): 
    2017    """ 
     
    8481            sum += item * item 
    8582        return sum 
    86  
     83    # This import takes a long time, which is why it's here not in the top of file 
     84    from scipy.optimize import leastsq 
    8785    p = [param() for param in pars] 
     86    #out, cov_x, info, mesg, success = optimize.leastsq(f, p, full_output=1) 
    8887    out, cov_x, info, mesg, success = optimize.leastsq(f, p, full_output=1) 
    8988    # Calculate chi squared 
  • src/sas/qtgui/Plotting/Plotter.py

    rdc5ef15 rfef38e8  
    33import functools 
    44import copy 
    5  
    65import matplotlib.pyplot as plt 
    76from matplotlib.font_manager import FontProperties 
    8  
    97from sas.qtgui.Plotting.PlotterData import Data1D 
    10  
    118from sas.qtgui.Plotting.PlotterBase import PlotterBase 
    129from sas.qtgui.Plotting.AddText import AddText 
     
    390387        Deletes the selected plot from the chart 
    391388        """ 
    392         if id not in self.plot_dict: 
     389        if id not in self.plot_dict.keys(): 
    393390            return 
    394391 
Note: See TracChangeset for help on using the changeset viewer.