Changeset 2347


Ignore:
Timestamp:
Jun 27, 2016 9:48:51 AM (7 years ago)
Author:
vondreele
Message:

implement Steven Weigand's fixes for Pilatus 'I' for 'L'
do a 'fix' for powderCif files with value(esd) for powder profile points
add a couple of comments for tutorial stuff

Location:
trunk
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASIIctrls.py

    r2295 r2347  
    41134113                wx.EndBusyCursor()
    41144114                raise Exception
    4115         if not GSASIIpath.svnInstallDir(baseURL+"/MT",fullpath):
     4115        if not GSASIIpath.svnInstallDir(baseURL+"/MT",fullpath):    #this could load specific requested tutorial directory
    41164116            wx.EndBusyCursor()
    41174117            print("Problem transferring empty directory from web")
     
    41514151        if not os.path.exists(pth):
    41524152            try:
    4153                 os.makedirs(pth)
     4153                os.makedirs(pth)    #failing for no obvious reason
    41544154            except OSError:
    41554155                msg = 'The selected directory is not valid.\n\t'
  • trunk/GSASIIpath.py

    r2337 r2347  
    444444    print("Loading files from "+URL)
    445445    s = subprocess.Popen(cmd,stdout=subprocess.PIPE,stderr=subprocess.PIPE)
    446     out,err = s.communicate()
     446    out,err = s.communicate()   #this fails too easily
    447447    if err:
    448448        print(60*"=")
  • trunk/ReadMarCCDFrame.py

    r1299 r2347  
    284284        self.TIFFresolutionUnit = IFD[296][2][0] # 3 = centimeter
    285285        self.byteDepth = self.TIFFbitDepth/8
    286         self.arrayTypeCode = ['','B','H','L'][self.byteDepth]
     286        self.arrayTypeCode = ['','B','H','I','I'][self.byteDepth]
    287287        # MarCCD specific header info
    288288        File.seek(IFD[34710][2][0])
  • trunk/imports/G2img_1TIF.py

    r2299 r2347  
    164164# extract resonable distance from header
    165165        distance = (marFrame.startXtalToDetector+marFrame.endXtalToDetector)*5e-4
    166         distance = (distance <= 0) and marFrame.xtalToDetector*1e-3 or distance
     166        distance = (distance <= marFrame.startXtalToDetector*5e-4) and marFrame.xtalToDetector*1e-3 or distance
    167167        distance = (distance <= 0) and None or distance
    168168# extract resonable center from header
     
    197197            File.seek(4096)
    198198            print 'Read Pilatus tiff file: ',filename
    199             image = ar.array('L',File.read(4*Npix))
     199            image = ar.array('I',File.read(4*Npix))
    200200            image = np.array(np.asarray(image),dtype=np.int32)
    201201        else:
     
    211211                File.seek(8)
    212212                print 'Read CHESS-detector tiff file: ',filename
    213                 image = np.array(ar.array('L',File.read(4*Npix)),dtype=np.int32)
     213                image = np.array(ar.array('I',File.read(4*Npix)),dtype=np.int32)
    214214    elif 270 in IFD:
    215215        File.seek(IFD[270][2][0])
  • trunk/imports/G2pwd_CIF.py

    r2342 r2347  
    261261            ycf = ych[yi]
    262262            vl = []
     263            v2 = []
    263264            for val in cf[blk].get(ycf,'?'):
    264265                v,e = cif.get_number_with_esd(val)
    265266                if v is None: # not parsed
    266267                    vl.append(np.NaN)
     268                    v2.append(np.NaN)
    267269                else:
    268270                    vl.append(v)
     271                    v2.append(max(e,1.0))
    269272            y = np.array(vl)
     273            w = 1./np.array(v2)**2
    270274            # weights
    271275            if sui == -1:
     
    300304                        else:
    301305                            vl.append(1./(e*e))
    302             w = np.array(vl)
     306#            w = np.array(vl)
    303307            # intensity modification factor
    304308            if modi >= 1:
Note: See TracChangeset for help on using the changeset viewer.