Beispiel #1
0
 def __init__(self, filename=None, pickleddata=None):
     """Initialize."""
     self.poscar = poscar.POSCAR()
     self.grid = Grid3D()
     self.additional = []
     if filename:
         self.load_file(open_by_suffix(filename), pickleddata)
Beispiel #2
0
 def __init__(self, filename=None):
     """Initialize."""
     super(EIGENVAL, self).__init__()
     self.natom = 0
     #
     if filename:
         self.load_file(open_by_suffix(filename))
Beispiel #3
0
    def __init__(self, filename=None):
        """Initialize."""
        self.natom = 0
        self.nbands = 0
        self.dos_container = list()

        if filename:
            self.load_file(open_by_suffix(filename))
Beispiel #4
0
 def __init__(self, filename=None):
     """Initialize."""
     self.system_name = ""
     self.atoms = []
     #
     self.qpts = []
     self.freqs = []
     #
     if filename:
         self.load_file(open_by_suffix(filename))
Beispiel #5
0
 def __init__(self, filename=None):
     """Initialize."""
     self.natom = 0
     self.positions = []
     self.charges = []
     self.mindists = []
     self.vols = []
     self.vaccharge = 0
     self.vacvol = 0
     self.nelectron = 0
     if filename:
         self.parse(open_by_suffix(filename))
Beispiel #6
0
    def __init__(self, filename=None):
        """Initialize.

        Parameters
        ----------
        arg: str
            XDATCAR file name

        """
        super(XDATCAR, self).__init__()
        self.configurations = []
        if filename:
            self.load_file(open_by_suffix(filename))
Beispiel #7
0
    def __init__(self, arg=None):
        """Initialization.

        Parameters
        -----------
        arg: str
            POSCAR file name, or list of POSCAR text.

        """
        super(POSCAR, self).__init__()
        POSCAR_POS.__init__(self)
        if isinstance(arg, str):
            poscar = open_by_suffix(arg).readlines()
            self.load_array(poscar)
        if isinstance(arg, (list, tuple)):
            self.load_array(arg)
Beispiel #8
0
 def __init__(self, filename=None):
     """Initialize."""
     self.natom = 0
     self.atomtypes = []
     self.atomnums = []
     self.posforce = []
     self.posforce_title = []
     self.atom_names = []
     self.fermi = 0.0
     self.site_label = []
     self.numk = 0
     self.nkdim = 0
     self.nbands = 0
     self.magnetizations = []
     self.total_charges = []
     self.kvecs = []
     self.weights = []
     if filename:
         self.load_file(open_by_suffix(filename))
Beispiel #9
0
 def __init__(self, filename=None, pickleddata=None):
     """Initialize."""
     super(CHGCAR, self).__init__(None)
     self.spin = 1
     if filename:
         self.load_file(open_by_suffix(filename), pickleddata)
Beispiel #10
0
 def __init__(self, filename=None, phase_read=False):
     """Initialize."""
     super(PROCAR, self).__init__()
     if filename:
         self.load_file(open_by_suffix(filename), phase_read)