Ignore:
Timestamp:
Jan 31, 2011 10:03:56 AM (14 years ago)
Author:
Jae Cho <jhjcho@…>
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:
213892bc
Parents:
d603001
Message:

Fixed the Npts_fit bug in 1D calculation

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sansview/perspectives/fitting/basepage.py

    r4ce74917 r3f6508f  
    20392039 
    20402040        # q value from qx and qy 
    2041         radius= numpy.sqrt( self.data.qx_data*self.data.qx_data + self.data.qy_data*self.data.qy_data ) 
     2041        radius= numpy.sqrt( self.data.qx_data * self.data.qx_data +  
     2042                            self.data.qy_data * self.data.qy_data ) 
    20422043        #get unmasked index 
    2043         index_data = (float(self.qmin.GetValue()) <= radius)&(radius<= float(self.qmax.GetValue())) 
    2044         index_data = (index_data)&(self.data.mask)  
    2045         index_data = (index_data)&(numpy.isfinite(self.data.data)) 
     2044        index_data = (float(self.qmin.GetValue()) <= radius) & \ 
     2045                        (radius <= float(self.qmax.GetValue())) 
     2046        index_data = (index_data) & (self.data.mask)  
     2047        index_data = (index_data) & (numpy.isfinite(self.data.data)) 
    20462048 
    20472049        if len(index_data[index_data]) < 10: 
     
    24052407 
    24062408        self.qmin    = self.ModelTextCtrl(self, -1,size=(_BOX_WIDTH,20),style=wx.TE_PROCESS_ENTER, 
    2407                                             text_enter_callback = self._onparamEnter) 
     2409                                            text_enter_callback = self._onQrangeEnter) 
    24082410        self.qmin.SetValue(str(self.qmin_x)) 
    24092411        self.qmin.SetToolTipString("Minimun value of Q in linear scale.") 
    24102412      
    24112413        self.qmax    = self.ModelTextCtrl(self, -1,size=(_BOX_WIDTH,20),style=wx.TE_PROCESS_ENTER, 
    2412                                             text_enter_callback = self._onparamEnter) 
     2414                                            text_enter_callback = self._onQrangeEnter) 
    24132415        self.qmax.SetValue(str(self.qmax_x)) 
    24142416        self.qmax.SetToolTipString("Maximum value of Q in linear scale.") 
Note: See TracChangeset for help on using the changeset viewer.