rem stringlengths 0 322k | add stringlengths 0 2.05M | context stringlengths 8 228k |
|---|---|---|
self.aoresults[spin][i] = Numeric.divide(tempcoeffs, scale) | tempvec = tempcoeffs/scale self.aoresults[spin][i] = Numeric.divide(tempcoeffs, scale).astype("f") | def calculate(self, indices=None, fupdate=0.05): """Perform a C^2 population analysis given the results of a parser""" if not self.parser.parsed: self.parser.parse() |
self.logger.info("Creating attribute HOMO[]") | self.logger.info("Creating attribute homos[]") | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.logger.info("Creating attribute evalue[[]]") self.evalue = [[]] | self.logger.info("Creating attribute moenergies[[]]") self.moenergies = [[]] | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
HOMO = len(self.evalue[0])-1 | HOMO = len(self.moenergies[0])-1 | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.evalue[0].append(self.float(x)*27.2114) | self.moenergies[0].append(self.float(x)*27.2114) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.evalue.append([]) | self.moenergies.append([]) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
HOMO = len(self.evalue[1])-1 | HOMO = len(self.moenergies[1])-1 | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.evalue[1].append(self.float(x)*27.2114) | self.moenergies[1].append(self.float(x)*27.2114) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.vibfreq = [] | self.vibfreqs = [] | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.vibfreq.extend(map(self.float,line[15:].split())) | self.vibfreqs.extend(map(self.float,line[15:].split())) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
if not hasattr(self,"raman"): | if not hasattr(self,"vibramans"): | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.logger.info("Creating attribute raman[]") | self.logger.info("Creating attribute vibramans[]") | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.etenergy = [] self.etwavelen = [] self.etosc = [] self.etsym = [] self.etcis = [] self.logger.info("Creating attributes etenergy[], etwavelen[], etosc[], etsym[], etcis[]") | self.etenergies = [] self.etoscs = [] self.etsyms = [] self.etsecs = [] self.logger.info("Creating attributes etenergies[], etoscs[], etsyms[], etsecs[]") | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.logger.debug(parts) self.etenergy.append(convertor(self.float(parts[0]),"eV","cm-1")) self.etwavelen.append(self.float(parts[2])) self.etosc.append(self.float(parts[4].split("=")[1])) self.etsym.append(line[21:36].split()) | self.etenergies.append(convertor(self.float(parts[0]),"eV","cm-1")) self.etoscs.append(self.float(parts[4].split("=")[1])) self.etsyms.append(line[21:36].split()) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.etcis.append(CIScontrib) | self.etsecs.append(CIScontrib) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.rotatory = [] self.logger.info("Creating attribute rotatory[]") | self.etrotats = [] self.logger.info("Creating attribute etrotats[]") | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.rotatory.append(R) | self.etrotats.append(R) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
NBasis = int(line.split('=')[1].split()[0]) | nbasis = int(line.split('=')[1].split()[0]) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
if hasattr(self,"NBasis"): assert NBasis==self.NBasis else: self.NBasis = NBasis self.logger.info("Creating attribute NBasis: %d" % self.NBasis) | if hasattr(self,"nbasis"): assert nbasis==self.nbasis else: self.nbasis= nbasis self.logger.info("Creating attribute nbasis: %d" % self.nbasis) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
NBsUse = int(line.split('=')[1].split()[0]) if hasattr(self,"NBsUse"): assert NBsUse==self.NBsUse else: self.NBsUse = NBsUse self.logger.info("Creating attribute NBsUse: %d" % self.NBsUse) | nindep = int(line.split('=')[1].split()[0]) if hasattr(self,"nindep"): assert nindep==self.nindep else: self.nindep = nindep self.logger.info("Creating attribute nindep: %d" % self.nindep) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
NBasis = int(line.split()[0]) if hasattr(self,"NBasis"): assert NBasis==self.NBasis | nbasis = int(line.split()[0]) if hasattr(self,"nbasis"): assert nbasis==self.nbasis | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.NBasis = NBasis self.logger.info("Creating attribute NBasis: %d" % self.NBasis) | self.nbasis = nbasis self.logger.info("Creating attribute nbasis: %d" % self.nbasis) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.logger.info("Creating attribute overlap[x,y]") | self.logger.info("Creating attribute aooverlaps[x,y]") | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.overlap = Numeric.zeros( (self.NBasis,self.NBasis), "float") | self.aooverlaps = Numeric.zeros( (self.nbasis,self.nbasis), "float") | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
while base<self.NBasis: for i in range(self.NBasis-base): | while base<self.nbasis: for i in range(self.nbasis-base): | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.overlap[base+j,i+base] = k self.overlap[i+base,base+j] = k | self.aooverlaps[base+j,i+base] = k self.aooverlaps[i+base,base+j] = k | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.mocoeff = Numeric.resize(self.mocoeff,(2,NBsUse,NBasis)) | self.mocoeffs = Numeric.resize(self.mocoeffs,(2,nindep,nbasis)) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.logger.info("Creating attributes orbitals[], mocoeff[][]") self.orbitals = [] self.mocoeff = Numeric.zeros((NBsUse,NBasis),"float") | self.logger.info("Creating attributes aonames[], mocoeffs[][]") self.aonames = [] self.mocoeffs = Numeric.zeros((nindep,nbasis),"float") | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
for base in range(0,NBsUse,5): | for base in range(0,nindep,5): | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
for i in range(NBasis): | for i in range(nbasis): | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.orbitals.append("%s_%s" % (atomname,orbital)) | self.aonames.append("%s_%s" % (atomname,orbital)) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.mocoeff[1,base:base+len(part)/10,i] = temp | self.mocoeffs[1,base:base+len(part)/10,i] = temp | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.mocoeff[base:base+len(part)/10,i] = temp | self.mocoeffs[base:base+len(part)/10,i] = temp | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") for line in inputfile: if line[1:8]=="NAtoms=": |
self.scftargets = Numeric.array([5E-5,5E-6],"f") if not geoopt: values = [[],[]] else: values = [[]] | self.scftargets = [[5E-5,5E-6]] values = [] | def parse(self,fupdate=0.05,cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename,"r") if self.progress: inputfile.seek(0,2) #go to end of file nstep=inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep=0 |
values[0].append(denergy) values[1].append(ddensity) | values.append([denergy,ddensity]) | def parse(self,fupdate=0.05,cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename,"r") if self.progress: inputfile.seek(0,2) #go to end of file nstep=inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep=0 |
values[0].append(ddensity) | values.append([ddensity]) | def parse(self,fupdate=0.05,cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename,"r") if self.progress: inputfile.seek(0,2) #go to end of file nstep=inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep=0 |
if not geoopt and line[2:24]=="start of program geopt": geoopt = True if hasattr(self,"scfvalues"): | if line[2:24]=="start of program geopt": if not geoopt: | def parse(self,fupdate=0.05,cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename,"r") if self.progress: inputfile.seek(0,2) #go to end of file nstep=inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep=0 |
self.scfvalues[0] = [self.scfvalues[0][1]] self.scftargets = self.scftargets[0] | self.scftargets = [[self.scftargets[0][0]]] if hasattr(self,"scfvalues"): self.scfvalues[0] = [[x[0]] for x in self.scfvalues[0]] geoopt = True else: self.scftargets.append([5E-5]) | def parse(self,fupdate=0.05,cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename,"r") if self.progress: inputfile.seek(0,2) #go to end of file nstep=inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep=0 |
elif hasattr(self.parser,"foonames"): | elif hasattr(self.parser,"fonames"): | def partition(self,indices=None): |
data[i, j, k] = bfs[bs].amp(x[i], y[j], z[k]) | data[i, j, k] = bfs[bs].amp(x[i], y[j], z[k])**2 | def electrondensity(coords, mocoeffs, gbasis, volume): """Calculate the magnitude of the electron density at every point in a volume. Attributes: coords -- the coordinates of the atoms mocoeffs -- mocoeffs for all of the occupied eigenvalues gbasis -- gbasis from a parser object volume -- a template Volume object (wil... |
self.etsyms.append(line[21:36].split()) | self.etsyms.append(line[21:36].strip()) | def parse(self,fupdate=0.05,cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename,"r") if self.progress: inputfile.seek(0,2) #go to end of file nstep=inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep=0 optfinished = False # Flag that indicates whether it ... |
density = electrondensity(b.atomcoords[0], b.mocoeffs[0,0:b.homos[0]]*2, a.gbasis, vol) | density = electrondensity(b.atomcoords[0], b.mocoeffs[0,0:b.homos[0]], a.gbasis, vol) | def electrondensity(coords, mocoeffs, gbasis, volume): """Calculate the magnitude of the electron density at every point in a volume. Attributes: coords -- the coordinates of the atoms mocoeffs -- mocoeffs for all of the occupied eigenvalues gbasis -- gbasis from a parser object volume -- a template Volume object (wil... |
multiple = {'E':2, 'T':3} | multiple = {'E':2, 'T':3, 'P':3, 'D':5} | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
sym += ":%i"%(repeat+1) | sym = self.normalisedegenerates(info[0],repeat) | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
elif line.find("Gaussian") >= 0: | elif line.find("Gaussian System") >= 0: | def ccopen(filename,progress=None,loglevel=logging.INFO,logname="Log"): """Guess the identity of a particular log file and return an instance of it. Returns: one of ADF, GAMESS, GAMESS UK, Gaussian, Jaguar, or None (if it cannot figure it out). """ filetype = None inputfile = open(filename, "r") for line in inputfile:... |
' 100 C 2 S ' ] | ' 100 C 2 S ', ' 1 SI 1 S ' ] | def normalise_aonames(self,listoflines): """Normalise the aonames attribute to agree with the other parsers. |
['C1_1S', 'C1_2S', 'C1_3S', 'C1_4XXXX', 'C2_1S'] | ['C1_S', 'C1_S', 'C1_S', 'C1_XXXX', 'C2_S', 'Si1_S'] | def normalise_aonames(self,listoflines): """Normalise the aonames attribute to agree with the other parsers. |
p = re.compile("(\d+)\s*([A-Z][a-z]?)\s*(\d+)\s*([A-Z]+)") | p = re.compile("(\d+)\s*([A-Z][A-Z]?)\s*(\d+)\s*([A-Z]+)") | def normalise_aonames(self,listoflines): """Normalise the aonames attribute to agree with the other parsers. |
i = 0 oldatom = "0" | oldatom = "0" | def normalise_aonames(self,listoflines): """Normalise the aonames attribute to agree with the other parsers. |
if g[3] in ['S','X','XX','XXX','XXXX']: i += 1 if g[2]!=oldatom: i = 1 aoname = "%s%s_%d%s" % (g[1],g[2],i,g[3]) | aoname = "%s%s_%s" % (g[1].capitalize(),g[2],g[3]) | def normalise_aonames(self,listoflines): """Normalise the aonames attribute to agree with the other parsers. |
atomnos.append(self.table.number[temp[0]]) | atomnos.append(int(round(float(temp[1])))) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") if self.progress: inputfile.seek(0,2) #go to end of file nstep=inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep=0 |
if line2.find("Create") < 0: | else: line2 = None if line2 and line2.find("Create") < 0: | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
if line[1:37] == 'Orbital Energies, per Irrep and Spin' and not hasattr(self, "mosyms") and nosymflag and not unrestrictedflag: | if line.find('Orbital Energies, per Irrep and Spin') > 0 and not hasattr(self, "mosyms") and nosymflag and not unrestrictedflag: | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
while len(line) > 3: | while len(line) > 10: | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
homoa = None | homoa = 0 | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
if info[3] == '0.00' and not homoa: homoa = len(self.moenergies[0]) - 2 | if info[3] != '0.00': homoa = len(self.moenergies[0]) - 1 | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
if info[3] == '0.00' and not homob: homob = len(self.moenergies[0]) - 2 | if info[3] != '0.00': homob = len(self.moenergies[1]) - 1 | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
self.logger.error("MO info up to else: self.logger.info("Creating attribute mosyms[[]]") self.mosyms = [[]] self.logger.info("Creating attribute moenergies[[]]") self.moenergies = [[]] homoA = None while len(line) > 10: info = line.split() self.mosyms[0].append('A') self.moenergies[0].append(utils.convertor(float(i... | self.logger.warning("MO info up to while int(info[0]) != len(self.moenergies[0]): self.moenergies[0].append(99999) self.mosyms[0].append('A') homoA = None while len(line) > 10: info = line.split() self.mosyms[0].append('A') self.moenergies[0].append(utils.convertor(float(info[2]), 'hartree', 'eV')) if info[1] == '0... | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
title = inputfile.next() title = inputfile.next() equals = inputfile.next() | line = inputfile.next() while line != equals: line = inputfile.next() | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 |
blank = inputfile.next() blank = inputfile.next() evalues = inputfile.next() | line = inputfile.next() while line==blank: line = inputfile.next() evalues = line | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 |
if line[2:12] == "m.o. irrep": | if line[7:12] == "irrep": | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 |
title = inputfile.next() | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 | |
while line != equals: | if not line.strip(): line = inputfile.next() while line.strip() and line != equals: | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 |
moenergies.append(float(temp[3])) | moenergies.append(utils.convertor(float(temp[2]), "hartree", "eV")) | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 |
if coeff**2 < 1.0: | sum = coeff**2 while sum < 1.0: | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
if line[42] == ' ': | if line[42] == ' ' and len(info) > 4: | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
else: | sum += coeff**2 if sum == coeff**2: | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
def __init__(self,*args): | def __init__(self,parser,progress=None, \ loglevel=logging.INFO,logname="Log"): | def __init__(self,*args): |
super(Population, self).__init__(logname="Population",*args) | super(Population, self).__init__(parser,progress,loglevel,logname) | def __init__(self,*args): |
atomcoords.append(map(float, line.split()[5:])) | atomcoords.append(map(float, line.split()[5:8])) | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
break | continue | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 optfinished = False # Flag that indicates whe... |
aolist = symlist[sym][spin] | if nosymflag: aolist = range(len(self.moenergies[spin])) else: aolist = symlist[sym][spin] | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
symlist = {} | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... | |
for repeat in range(multiple.get(info[0][0], 1)): | count = multiple.get(info[0][0],1) for repeat in range(count): | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
for repeat in range(multiple.get(info[0][0], 1)): | for repeat in range(count): | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
sym = inputfile.next() | line = inputfile.next() sym = line.split()[1] | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
for i in range(8): line = inputfile.next() | for i in range(4): inputfile.next() line = inputfile.next() sym = line.split()[1] for i in range(3): inputfile.next() | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
if len(info) > 1: | if info[0] == "occup:": | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
self.mocoeffs[spin, i + symoffset + base, row + symoffset] = float(cols[i + 1]) | self.mocoeffs[spin, aolist[i+base], row + symoffset] = float(cols[i + 1]) | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
self.homos = [len(self.moenergies[0]) - 2] | self.homos = [len(self.moenergies[0]) - (count + 1)] | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
homoa = len(self.moenergies[0]) - 2 | homoa = len(self.moenergies[0]) - (count + 1) | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
homob = len(self.moenergies[1]) - 2 | homob = len(self.moenergies[1]) - (count + 1) | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
glob(os.path.join(data, "Gaussian", "Gaussian98", "*.bz2")), | glob(os.path.join(data, "Gaussian", "Gaussian98", "*.bz2")) + glob(os.path.join(data, "Gaussian", "Gaussian98", "*.gz")), | def testADF_ADF2004_01_Fe_ox3_final_out_gz(logfile): """ Make sure HOMOS are correct """ assert logfile.homos[0]==59 and logfile.homos[1]==54 |
print "got inside" | def parse(self,fupdate=0.05,cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename,"r") if self.progress: inputfile.seek(0,2) #go to end of file nstep=inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep=0 # Used to avoid extracting the final geometry twice i... | |
self.scfenergies.append(temp[temp.index("IS")+1]) | self.scfenergies.append(float(temp[temp.index("IS")+1])) | def parse(self): """Extract information from the logfile.""" inputfile = open(self.filename,"r") if self.progress: inputfile.seek(0,2) #go to end of file nstep=inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep=0 |
assert type in ['rhf', 'uhf'] | assert type in ['rhf', 'uhf'], "%s not one of 'rhf', 'uhf'" % type | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 |
temp = line.split() scfvalues.append([float(temp[5])]) | if line[2:6]!="****": scfvalues.append([float(line[tester-5:tester+6])]) | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 |
self.vibcarts.append(p[0:len(broken)/3]) | self.vibcarts.extend(p[0:len(broken)/3]) | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = utils.openlogfile(self.filename) if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 optfinished = False # Flag that indic... |
sym = temp[1][1:] assert sym in ['s', 'p', 'd', 'f', 'sp'] | sym = basisregexp.match(temp[1]).groups()[0] assert sym in ['s', 'p', 'd', 'f', 'sp'], "'%s' not a recognized symmetry" % sym | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 |
if line.find("Input orientation") > -1: | if line.find("Input orientation") > -1 or line.find("Z-Matrix orientation") > -1: | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 optfinished = False # Flag that indicates whe... |
if len(self.moenergies) == 0: | if len(self.moenergies) == 1: | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = utils.openlogfile(self.filename) if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final ... |
while len(line) == 77: | while line.strip(): | def parse(self, fupdate=0.05, cupdate=0.002): """Extract information from the logfile.""" inputfile = open(self.filename, "r") if self.progress: inputfile.seek(0, 2) #go to end of file nstep = inputfile.tell() inputfile.seek(0) self.progress.initialize(nstep) oldstep = 0 # Used to avoid extracting the final geometry... |
index = self.indexPage() self.putChild('', index) self.putChild('index.html', index) self.putChild('moduleIndex.html', nevowhtml.ModuleIndexPage(self.system)) self.putChild('classIndex.html', nevowhtml.ClassIndexPage(self.system)) self.putChild('nameIndex.html', nevowhtml.NameIndexPage(self.system)) | self.index = WrapperPage(self.indexPage()) self.putChild('', self.index) self.putChild('index.html', self.index) self.putChild('moduleIndex.html', WrapperPage(nevowhtml.ModuleIndexPage(self.system))) self.putChild('classIndex.html', WrapperPage(nevowhtml.ClassIndexPage(self.system))) self.putChild('nameIndex.html', Wra... | def __init__(self, system): self.system = system self.putChild('apidocs.css', File(nevowhtml.sibpath(__file__, 'templates/apidocs.css'))) self.putChild('sorttable.js', File(nevowhtml.sibpath(__file__, 'templates/sorttable.js'))) index = self.indexPage() self.putChild('', index) self.putChild('index.html', index) self.p... |
return self.pageClassForObject(obj)(obj) | return WrapperPage(self.pageClassForObject(obj)(obj)) | def childFactory(self, ctx, name): if not name.endswith('.html'): return None name = name[0:-5] if name not in self.system.allobjects: return None obj = self.system.allobjects[name] return self.pageClassForObject(obj)(obj) |
return nevowhtml.IndexPage(self.system).renderHTTP(ctx) | return self.index.renderHTTP(ctx) | def renderHTTP(self, ctx): return nevowhtml.IndexPage(self.system).renderHTTP(ctx) |
def render_recentChanges(self, context, data): return context.tag | @page.renderer def recentChanges(self, request, tag): return tag | def render_recentChanges(self, context, data): return context.tag |
def __init__(self, root): | def __init__(self, root, url): | def __init__(self, root): self.root = root |
def render_changes(self, context, data): item = context.tag.patternGenerator('item') tag = context.tag | self.url = url @page.renderer def changes(self, request, tag): item = tag.patternGenerator('item') | def __init__(self, root): self.root = root |
tag[item(data=d)] | tag[nevowhtml.fillSlots(item, diff=self.diff(d), hist=self.hist(d), object=self.object(d), time=self.time(d), user=self.user(d))] | def render_changes(self, context, data): item = context.tag.patternGenerator('item') tag = context.tag for d in reversed(self.root.edits): tag[item(data=d)] return tag |
def render_diff(self, context, data): return tags.a(href=url.URL.fromContext(context).sibling( | def diff(self, data): return tags.a(href=self.url.sibling( | def render_diff(self, context, data): return tags.a(href=url.URL.fromContext(context).sibling( 'diff').add( 'ob', data.obj.fullName()).add( 'revA', data.rev-1).add( 'revB', data.rev))["(diff)"] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.