Changeset 87e2f81 in sasview


Ignore:
Timestamp:
Oct 3, 2011 5:33:58 PM (13 years ago)
Author:
Gervaise Alina <gervyh@…>
Branches:
master, 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, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
Children:
9149431
Parents:
18a6556
Message:

make sure residuals are proprely stored after the fit

File:
1 edited

Legend:

Unmodified
Added
Removed
  • fittingview/src/sans/perspectives/fitting/fitting.py

    rf64a4b7 r87e2f81  
    10441044                    cell.label = null_value 
    10451045                    cell.value = null_value 
     1046                    cell.object = [None] 
    10461047                    batch_outputs["Chi2"].append(cell) 
    10471048                    for index  in range(len(pars)): 
     
    10981099        fitproblem = self.page_finder[pid][fid] 
    10991100        index = self.page_finder[pid].nbr_residuals_computed - 1 
    1100         print "index", index 
    11011101        residuals =  fitproblem.get_residuals() 
    11021102        theory_data = fitproblem.get_theory_data() 
     
    11111111        cell.value = index 
    11121112        theory_data.id = wx.NewId() 
     1113        theory_data.name = data.name + "[%s]" % str(model.__class__.__name__) 
    11131114        cell.object = [data, theory_data] 
    11141115         
     
    11241125            batch_inputs[param].append(data.sample.temperature) 
    11251126        # associate residuals plot 
     1127         
    11261128        batch_outputs["Chi2"][index].object = [residuals] 
    11271129        
     
    17671769        flag = False 
    17681770        batch_inputs, batch_outputs = self.page_finder[page_id].get_result() 
    1769        
     1771          
    17701772        if self.page_finder[page_id].nbr_residuals_computed == -1: 
    17711773            flag = False 
    17721774        else: 
    1773             if m == n - 1: 
     1775            if m == n -1: 
    17741776                flag = True 
    17751777            else: 
    17761778                flag = False 
    1777                 self.page_finder[page_id].nbr_residuals_computed += 1 
     1779            self.page_finder[page_id].nbr_residuals_computed += 1 
    17781780             
    17791781            self.on_set_batch_result(page_id=page_id, 
Note: See TracChangeset for help on using the changeset viewer.