Changeset 3199
- Timestamp:
- Dec 21, 2017 9:54:27 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/imports/G2phase_CIF.py
r3198 r3199 123 123 sg = cf[blknm].get("_symmetry_space_group_name_H-M",'') 124 124 if not sg: sg = cf[blknm].get("_space_group_name_H-M_alt",'') 125 if not sg: sg = cf[blknm].get("_space_group_ssg_name",'') 126 if not sg: sg = cf[blknm].get("_space_group.magn_ssg_name_BNS",'') 127 if not sg: sg = cf[blknm].get("_space_group.magn_ssg_name",'') 125 128 #how about checking for super/magnetic ones as well? - reject 'X'? 126 129 sg = sg.replace('_','') … … 192 195 MSpGrp = blk.get("_space_group_magn.name_BNS",'') 193 196 if not MSpGrp: 194 msg = 'No magnetic BNSspace group name was found in the CIF.'197 msg = 'No recognizable space group name was found in the CIF.' 195 198 self.errors = msg 196 199 self.warnings += '\n'+msg … … 206 209 SpGrp = SpGrp.replace('_','') 207 210 self.Phase['General']['Type'] = 'nuclear' 211 if not SpGrp: 212 print (sspgrp) 213 self.warnings += 'No space group name was found in the CIF.' 214 return False 208 215 #process space group symbol 209 216 E,SGData = G2spc.SpcGroup(SpGrp) … … 214 221 # nope, try the space group "out of the Box" 215 222 if E: 216 if not SpGrp: 217 self.warnings += 'No space group name was found in the CIF.' 218 self.warnings += '\nThe space group has been set to "P 1". ' 219 self.warnings += "Change this in phase's General tab." 220 else: 221 self.warnings += 'ERROR in space group symbol '+SpGrp 222 self.warnings += '\nThe space group has been set to "P 1". ' 223 self.warnings += "Change this in phase's General tab." 224 self.warnings += '\nAre there spaces separating axial fields?\n\nError msg: ' 225 self.warnings += G2spc.SGErrors(E) 223 self.warnings += 'ERROR in space group symbol '+SpGrp 224 self.warnings += '\nThe space group has been set to "P 1". ' 225 self.warnings += "Change this in phase's General tab." 226 self.warnings += '\nAre there spaces separating axial fields?\n\nError msg: ' 227 self.warnings += G2spc.SGErrors(E) 226 228 SGData = G2obj.P1SGData # P 1 227 229 self.Phase['General']['SGData'] = SGData
Note: See TracChangeset
for help on using the changeset viewer.