def parser(self, ): s = System() s.options = self.options s.methods = self.methods for i in self.redundant: s.redundant.append(i.strip().split()) s.connect = self.connect s.spin = self.spin s.charge = self.charge s.name = self.title.strip() for i in self.atoms: a = Atom() a.name = i[0] a.x[0] = float(i[1]) a.x[1] = float(i[2]) a.x[2] = float(i[3]) s.atoms.append(a) return s
def parser(self,): s = System() s.options = self.options s.methods = self.methods for i in self.redundant: s.redundant.append(i.strip().split()) s.connect = self.connect s.spin = self.spin s.charge = self.charge s.name = self.title.strip() for i in self.atoms: a = Atom() a.name = i[0] a.x[0] = float(i[1]) a.x[1] = float(i[2]) a.x[2] = float(i[3]) s.atoms.append(a) return s