Changeset cd89c6f in sasview for sanscalculator


Ignore:
Timestamp:
Jan 14, 2013 11:19:38 AM (12 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:
fad6056
Parents:
5c2932a
Message:

cleaned up a little

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sanscalculator/src/sans/calculator/sans_gen.py

    r5c2932a rcd89c6f  
    6464        self.params['Up_frac_out']    = 1.0 
    6565        self.params['Up_theta']  = 0.0 
    66         self.description='GenSAS' 
     66        self.description = 'GenSAS' 
    6767        ## Parameter details [units, min, max] 
    6868        self.details = {} 
     
    7474        self.details['Up_theta'] = ['[deg]', None, None] 
    7575        # fixed parameters 
    76         self.fixed=[] 
     76        self.fixed = [] 
    7777         
    7878    def set_pixel_volumes(self, volume):      
     
    146146        if x.__class__.__name__ == 'list': 
    147147            i_out = numpy.zeros_like(x[0]) 
    148             y_in = numpy.zero_like(x[0]) 
     148            y_in = numpy.zeros_like(x[0]) 
    149149            # 1D I is found at y =0 in the 2D pattern 
    150150            return self._gen(x[0], y_in, i_out ) 
     
    163163            i_out = numpy.zeros_like(x[0]) 
    164164            import time 
    165             s=time.time() 
     165            s = time.time() 
    166166            out = self._gen(x[0], x[1], i_out) 
    167             print "i_out_time",time.time()-s 
     167            print "i_out_time", time.time() - s 
    168168            return out 
    169169        else: 
     
    346346        :return: x, y, z, sld_n, sld_mx, sld_my, sld_mz 
    347347        """ 
    348         data_conv_m = None 
     348        #data_conv_m = None 
    349349        desc = "" 
    350350        mx = numpy.zeros(0) 
     
    454454                    output.zmax = float(zmax) * METER2ANG 
    455455                    output.valuemultiplier = valuemultiplier 
    456                     output.valuerangeminmag = mag2sld(float(valuerangeminmag),\ 
     456                    output.valuerangeminmag = mag2sld(float(valuerangeminmag), \ 
    457457                                                      valueunit) 
    458                     output.valuerangemaxmag = mag2sld(float(valuerangemaxmag),\ 
     458                    output.valuerangemaxmag = mag2sld(float(valuerangemaxmag), \ 
    459459                                                      valueunit) 
    460460            output.set_m(mx, my, mz) 
     
    10861086    x = numpy.arange(1000)/10000. + 1e-5 
    10871087    y = numpy.arange(1000)/10000. + 1e-5 
    1088     z = numpy.arange(1000)/10000. + 1e-5 
     1088    #z = numpy.arange(1000)/10000. + 1e-5 
    10891089    i = numpy.zeros(1000) 
    10901090    out = model.runXY([x,y,i]) 
Note: See TracChangeset for help on using the changeset viewer.