Changeset 3786
- Timestamp:
- Jan 17, 2019 2:31:32 PM (5 years ago)
- Location:
- trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/GSASIIElem.py
r3605 r3786 22 22 import atmdata 23 23 import GSASIImath as G2mth 24 import ElementTable as ET 25 24 26 25 27 getElSym = lambda sym: sym.split('+')[0].split('-')[0].capitalize() … … 163 165 164 166 ''' 165 import ElementTable as ET166 167 Elements = [] 167 168 for elem in ET.ElTable: … … 188 189 def GetAtomInfo(El,ifMag=False): 189 190 'reads element information from atmdata.py' 190 import ElementTable as ET191 191 Elem = ET.ElTable 192 192 if ifMag: -
trunk/GSASIIpwdGUI.py
r3783 r3786 3335 3335 SGData = G2spc.SpcGroup(SGData['SpGrp'])[1] 3336 3336 G2frame.dataWindow.RunSubGroups.Enable(True) 3337 ssopt.update({'Use':False,'ssSymb':'(abg)','ModVec':[0.1,0.1,0.1],'maxH':1}) 3337 3338 if 'SuperSg' in Phase['General'] or SGData.get('SGGray',False): 3338 3339 ssopt.update({'SGData':SGData,'ssSymb':Phase['General']['SuperSg'],'ModVec':Phase['General']['SuperVec'][0],'Use':True,'maxH':1}) … … 3347 3348 caption='Unusable super space group',style=wx.ICON_EXCLAMATION) 3348 3349 G2frame.dataWindow.RunSubGroups.Enable(False) 3349 ssopt.update({'Use':False,'ssSymb':'(abg)','ModVec':[0.1,0.1,0.1],'maxH':1})3350 3350 SpGrp = SGData['SpGrp'] 3351 3351 if 'mono' in SGData['SGSys']: -
trunk/imports/G2pwd_CIF.py
r3783 r3786 21 21 import CifFile as cif # PyCifRW from James Hester 22 22 import GSASIIpath 23 asind = lambda x: 180.*np.arcsin(x)/np.pi 23 24 GSASIIpath.SetVersionNumber("$Revision$") 24 25 … … 56 57 #'_pd_proc_energy_incident', 57 58 #'_pd_proc_energy_detection', 58 #'_pd_proc_recip_len_q',59 '_pd_proc_recip_len_q', 59 60 #'_pd_proc_wavelength', 60 61 ) … … 226 227 xi,yi,sui,modi = res 227 228 228 # now read in the values 229 # x-values 229 # now read in the values 230 # x-values 231 self.powderentry[0] = filename 232 #self.powderentry[1] = pos # bank offset (N/A here) 233 #self.powderentry[2] = 1 # xye file only has one bank 234 self.idstring = os.path.basename(filename) + ': ' + blk 235 if cf[blk].get('_diffrn_radiation_probe'): 236 if cf[blk]['_diffrn_radiation_probe'] == 'neutron': 237 self.instdict['type'] = 'PNC' 238 #if cf[blk].get('_pd_meas_time_of_flight'): self.instdict['type'] = 'PNT' # not supported yet 239 else: 240 self.instdict['type'] = 'PXC' 241 if cf[blk].get('_diffrn_radiation_wavelength'): 242 val = cf[blk]['_diffrn_radiation_wavelength'] 243 wl = [] 244 if type(val) is list: 245 for v in val: 246 w,e = cif.get_number_with_esd(v) 247 if w: wl.append(w) 248 else: 249 w,e = cif.get_number_with_esd(val) 250 if w: wl.append(w) 251 if wl: 252 if len(wl) > 1: 253 self.instdict['wave'] = wl 254 else: 255 self.instdict['wave'] = wl[0] 256 if cf[blk].get('_diffrn_ambient_temperature'): 257 val = cf[blk]['_diffrn_ambient_temperature'] 258 w,e = cif.get_number_with_esd(val) 259 if w: 260 self.Sample['Temperature'] = w 230 261 xcf = xch[xi] 231 262 if type(xcf) is tuple: … … 241 272 vl.append(v) 242 273 x = np.array(vl) 274 if 'recip_len_q' in xcf and 'wave' in self.instdict: 275 wl = self.instdict['wave'] 276 x = 2.*asind(wl*x/(4.*np.pi)) 243 277 # y-values 244 278 ycf = ych[yi] … … 315 349 np.zeros(N), # obs-calc profiles 316 350 ] 317 self.powderentry[0] = filename318 #self.powderentry[1] = pos # bank offset (N/A here)319 #self.powderentry[2] = 1 # xye file only has one bank320 self.idstring = os.path.basename(filename) + ': ' + blk321 if cf[blk].get('_diffrn_radiation_probe'):322 if cf[blk]['_diffrn_radiation_probe'] == 'neutron':323 self.instdict['type'] = 'PNC'324 #if cf[blk].get('_pd_meas_time_of_flight'): self.instdict['type'] = 'PNT' # not supported yet325 else:326 self.instdict['type'] = 'PXC'327 if cf[blk].get('_diffrn_radiation_wavelength'):328 val = cf[blk]['_diffrn_radiation_wavelength']329 wl = []330 if type(val) is list:331 for v in val:332 w,e = cif.get_number_with_esd(v)333 if w: wl.append(w)334 else:335 w,e = cif.get_number_with_esd(val)336 if w: wl.append(w)337 if wl:338 if len(wl) > 1:339 self.instdict['wave'] = wl340 else:341 self.instdict['wave'] = wl[0]342 if cf[blk].get('_diffrn_ambient_temperature'):343 val = cf[blk]['_diffrn_ambient_temperature']344 w,e = cif.get_number_with_esd(val)345 if w:346 self.Sample['Temperature'] = w347 351 return True
Note: See TracChangeset
for help on using the changeset viewer.