Ejemplo n.º 1
0
Archivo: bulk.py Proyecto: jboes/ase
    def parse(self, opts, args):
        OptimizeTask.parse(self, opts, args)

        if opts.srelax:
            if len(opts.srelax.split(',')) > 1:
                self.sfmax, self.soptimizer = opts.srelax.split(',')
            else:
                self.sfmax = opts.srelax
                self.soptimizer = 'BFGS'
            self.sfmax = float(self.sfmax)

        if opts.srelaxsteps is not None:
            self.ssteps = int(opts.srelaxsteps)
        else:
            # yes, the default number of ASE optimizer steps
            # ase/optimize/optimize.py
            self.ssteps = 100000000

        if opts.fit:
            points, strain = opts.fit.split(',')
            if float(strain) > 0:
                self.fit = (int(points), float(strain) * 0.01)
            else:
                self.fit = (int(points), float(strain))

        self.eos = opts.eos

        self.crystal_structure = opts.crystal_structure
        self.lattice_constant = opts.lattice_constant
        self.c_over_a = opts.c_over_a
        self.orthorhombic = opts.orthorhombic
        self.cubic = opts.cubic
        self.repeat = opts.repeat
Ejemplo n.º 2
0
    def parse(self, opts, args):
        OptimizeTask.parse(self, opts, args)

        if opts.srelax:
            if len(opts.srelax.split(',')) > 1:
                self.sfmax, self.soptimizer = opts.srelax.split(',')
            else:
                self.sfmax = opts.srelax
                self.soptimizer = 'BFGS'
            self.sfmax = float(self.sfmax)

        if opts.srelaxsteps is not None:
            self.ssteps = int(opts.srelaxsteps)
        else:
            # yes, the default number of ASE optimizer steps
            # ase/optimize/optimize.py
            self.ssteps = 100000000

        if opts.fit:
            points, strain = opts.fit.split(',')
            if float(strain) > 0:
                self.fit = (int(points), float(strain) * 0.01)
            else:
                self.fit = (int(points), float(strain))

        self.eos = opts.eos

        self.crystal_structure = opts.crystal_structure
        self.lattice_constant = opts.lattice_constant
        self.c_over_a = opts.c_over_a
        self.orthorhombic = opts.orthorhombic
        self.cubic = opts.cubic
        self.repeat = opts.repeat
Ejemplo n.º 3
0
Archivo: bulk.py Proyecto: lqcata/ase
    def parse(self, opts, args):
        OptimizeTask.parse(self, opts, args)

        if opts.fit:
            points, strain = opts.fit.split(',')
            self.fit = (int(points), float(strain) * 0.01)

        self.crystal_structure = opts.crystal_structure
        self.lattice_constant = opts.lattice_constant
        self.c_over_a = opts.c_over_a
        self.orthorhombic = opts.orthorhombic
        self.cubic = opts.cubic
        self.repeat = opts.repeat
Ejemplo n.º 4
0
    def parse(self, opts, args):
        OptimizeTask.parse(self, opts, args)

        if opts.fit:
            points, strain = opts.fit.split(',')
            self.fit = (int(points), float(strain) * 0.01)

        self.crystal_structure = opts.crystal_structure
        self.lattice_constant = opts.lattice_constant
        self.c_over_a = opts.c_over_a
        self.orthorhombic = opts.orthorhombic
        self.cubic = opts.cubic
        self.repeat = opts.repeat
Ejemplo n.º 5
0
    def parse(self, opts, args):
        OptimizeTask.parse(self, opts, args)

        self.vacuum = opts.vacuum
        self.bond_length = opts.bond_length
        self.atomize = opts.atomize

        if opts.fit:
            points, strain = opts.fit.split(',')
            self.fit = (int(points), float(strain) * 0.01)

        if opts.unit_cell:
            if ',' in opts.unit_cell:
                self.unit_cell = [float(x) for x in opts.unit_cell.split(',')]
            else:
                self.unit_cell = [float(opts.unit_cell)] * 3
Ejemplo n.º 6
0
    def parse(self, opts, args):
        OptimizeTask.parse(self, opts, args)

        self.vacuum = opts.vacuum
        self.bond_length = opts.bond_length
        self.atomize = opts.atomize

        if opts.fit:
            points, strain = opts.fit.split(',')
            self.fit = (int(points), float(strain) * 0.01)

        if opts.unit_cell:
            if ',' in opts.unit_cell:
                self.unit_cell = [float(x) for x in opts.unit_cell.split(',')]
            else:
                self.unit_cell = [float(opts.unit_cell)] * 3