def test_run_dscf_aoforce_sym(self, structure):
        dp = get_define_template("dscf")
        dp["desy"] = True

        assert run_itest(["dscf", "aoforce"], dp, structure,
                         "dscf_aoforce_{}_sym".format(structure),
                         [ScfOutput, AoforceOutput])
    def test_run_ridft_aoforce_nosym(self, structure):
        dp = get_define_template("ridft")
        dp["desy"] = False

        assert run_itest(["ridft", "aoforce"], dp, structure,
                         "ridft_aoforce_{}_nosym".format(structure),
                         [ScfOutput, AoforceOutput])
示例#3
0
    def test_run_ridft_escf(self, structure):
        dp = get_define_template("ridft_escf")
        dp["desy"] = True
        dp["ex_all_states"] = 12

        assert run_itest(["ridft", "escf"], dp,
                         structure, "ridft_escf_{}_std".format(structure), [ScfOutput, EscfOutput])
示例#4
0
    def test_run_dscf_egrad_relax(self, structure):
        dp = get_define_template("dscf_escf")
        dp["desy"] = False
        dp["ired"] = False

        assert run_itest(["dscf", "egrad", "relax"], dp, structure,
                         "dscf_escf_relax_{}_nosym".format(structure),
                         [ScfOutput, EgradOutput, RelaxOutput])
示例#5
0
    def test_run_ridft_f12x(self, structure):

        define_opt = get_define_template("ridft_rimp2")
        define_opt["use_f12"] = False
        define_opt["use_f12*"] = True

        assert run_itest(["ridft", "rimp2"], define_opt, structure,
                         "ridft_rimp2_{}_f12*".format(structure), {})
示例#6
0
    def test_run_dscf_escf(self, structure):
        dp = get_define_template("dscf_escf")
        dp["desy"] = False
        dp["ex_all_states"] = None
        dp["ex_irrep_states"] = {"a": 8}

        assert run_itest(["dscf", "escf"], dp,
                         structure, "dscf_escf_{}_std".format(structure), [ScfOutput, EscfOutput])
示例#7
0
    def test_run_dscf_escf_triplet(self, structure):
        dp = get_define_template("dscf_escf")
        dp["desy"] = True
        dp["ex_all_states"] = 10
        dp["ex_multi"] = "triplet"

        assert run_itest(["dscf", "escf"], dp,
                         structure, "dscf_escf_{}_triplet".format(structure), [ScfOutput, EscfOutput])
示例#8
0
    def test_run_dscf_grad_statpt(self, structure):
        dp = get_define_template("dscf")
        dp["desy"] = True
        dp["ired"] = True

        assert run_itest(["dscf", "grad", "statpt"], dp, structure,
                         "dscf_grad_statpt_{}_sym".format(structure),
                         [ScfOutput, GradOutput, StatptOutput])
示例#9
0
    def test_run_ridft_rdgrad_relax(self, structure):
        dp = get_define_template("ridft")
        dp["desy"] = True
        dp["ired"] = True

        assert run_itest(["ridft", "rdgrad", "relax"], dp, structure,
                         "ridft_rdgrad_relax_{}_sym".format(structure),
                         [ScfOutput, GradOutput, StatptOutput])
示例#10
0
    def test_run_ridft_fermi(self, structure):
        define_opt = get_define_template("ridft")
        define_opt["ri"] = False
        define_opt["rijk"] = True
        datagroups_options = {"fermi": "tmstrt=500 tmend=50 tmfac=0.9 hlcrt=0.2"}

        assert run_itest("ridft", define_opt, structure, "ridft_{}_fermi".format(structure), ScfOutput,
                         datagroups_options=datagroups_options)
示例#11
0
    def test_run_dscf_escf_charged(self, structure):
        dp = get_define_template("dscf_escf")
        dp["desy"] = True
        dp["ex_all_states"] = 10
        dp["charge"] = 1

        assert run_itest(["dscf", "escf"], dp,
                         structure, "dscf_escf_{}_charged".format(structure), [ScfOutput, EscfOutput])
示例#12
0
    def test_run_ridft_adc2(self):

        define_opt = get_define_template("ridft_rimp2")
        define_opt["method"] = "adc(2)"
        define_opt["ex_mp2"] = {"a1": [1, 10], "a2": [3, 10]}
        define_opt["maxiter"] = 100
        define_opt["maxcor"] = 400

        assert run_itest(["ridft", "rimp2"], define_opt, "nh3", "ridft_rimp2_nh3_adc2", [ScfOutput, None])
示例#13
0
    def test_run_ridft_egrad_statpt_ex_irrep(self, structure):
        dp = get_define_template("ridft_escf")
        dp["desy"] = True
        dp["ired"] = True
        dp["ex_all_states"] = None
        dp["ex_irrep_states"] = {"a1": 1}

        assert run_itest(["ridft", "egrad", "statpt"], dp, structure,
                         "ridft_egrad_statpt_{}_ex_irrep".format(structure),
                         [ScfOutput, EgradOutput, RelaxOutput])
示例#14
0
    def test_run_jobex_dscf(self, structure):
        dp = get_define_template("dscf")
        dp["desy"] = True
        dp["ired"] = True

        assert run_itest("jobex",
                         dp,
                         structure,
                         "jobex_dscf_{}_sym".format(structure),
                         JobexOutput,
                         arguments="-c 2")
示例#15
0
    def test_run_dscf_copymo(self):
        """
        Tests the copy functionalities with mos file
        """

        define_opt = get_define_template("dscf")

        define_opt["basis"] = "def2-SV(P)"
        define_opt["copymo"] = os.path.join(get_tfp(), "mo", "mos_nh3")

        assert run_itest("dscf", define_opt, "nh3", "dscf_nh3_copymo_mos",
                         ScfOutput)
示例#16
0
    def test_run_dscf_hf(self, structure):

        define_opt = get_define_template("dscf")
        define_opt["method"] = "hf"
        define_opt["desy"] = False
        define_opt["sym"] = "c1"
        define_opt["sym_eps"] = 0.001
        define_opt["scfiterlimit"] = 300
        define_opt["scfconv"] = 6
        define_opt["title"] = None

        assert run_itest("dscf", define_opt, structure,
                         "dscf_{}_hf".format(structure), ScfOutput)
示例#17
0
    def test_run_dscf_copymo_alpha_unpaired(self):
        """
        Tests the copy functionalities with mos file
        """

        define_opt = get_define_template("dscf")

        define_opt["basis"] = "def2-SV(P)"
        define_opt["charge"] = 1
        define_opt["unpaired_electrons"] = 1
        define_opt["copymo"] = os.path.join(get_tfp(), "mo", "alpha_beta_nh3")

        assert run_itest("dscf", define_opt, "nh3",
                         "dscf_nh3_copymo_alpha_unpaired", ScfOutput)
示例#18
0
    def test_run_dscf_cosmo(self, structure):

        define_opt = get_define_template("dscf")
        define_opt["use_cosmo"] = True
        define_opt.update({
            "epsilon": 60.0,
            "nppa": 92,
            "nspa": None,
            "disex": 0,
            "rsolv": 1.3,
            "routf": None,
            "cavity": "open"
        })
        assert run_itest("dscf", define_opt, structure,
                         "dscf_{}_cosmo".format(structure), ScfOutput)
示例#19
0
    def test_run_dscf_escf_set_dict(self):
        """
        Tests some properties that are set with a dictionary. So it is structure specific.
        It also sets some specific parameters to add coverage.
        The structure is nh3_wrong_internal, which is the same as nh3, but with internal coordinates
        not matching with the cartesian, to check that the code will handle that as well.
        """

        define_opt = get_define_template("dscf_escf")
        define_opt["metric"] = 2
        define_opt["sym"] = None
        define_opt["desy"] = True
        define_opt["desy_eps"] = 1e-5
        define_opt["basis"] = None
        define_opt["basis_atom"] = {"n": "def2-SV(P)", "h": "def2-SV(P)"}
        define_opt["ex_all_states"] = None
        define_opt["ex_irrep_states"] = {"a1": 10, "a2": 8}

        assert run_itest(["dscf", "escf"], define_opt, "nh3_wrong_internal",
                              "dscf_escf_nh3_set_dict", ScfOutput)
示例#20
0
    def test_run_dscf(self, structure):

        assert run_itest("dscf", get_define_template("dscf"), structure,
                         "dscf_{}_std".format(structure), ScfOutput)
示例#21
0
    def test_run_ridft(self, structure):

        assert run_itest("ridft", get_define_template("ridft"), structure, "ridft_{}_std".format(structure), ScfOutput)
示例#22
0
    def test_run_ridft_rimp2(self, structure):

        assert run_itest(["ridft", "rimp2"], get_define_template("ridft_rimp2"),
                          structure, "ridft_rimp2_{}_std".format(structure), [ScfOutput, None])
示例#23
0
    def test_run_ridft_marij(self, structure):
        define_opt = get_define_template("ridft")
        define_opt["ri"] = True
        define_opt["marij"] = True

        assert run_itest("ridft", define_opt, structure, "ridft_{}_marij".format(structure), ScfOutput)
示例#24
0
    def test_run_dscf_ired(self, structure):
        define_opt = get_define_template("dscf")
        define_opt["ired"] = True

        assert run_itest("dscf", define_opt, structure,
                         "dscf_{}_ired".format(structure), ScfOutput)
示例#25
0
    def test_run_dscf_disp(self, disp):

        define_opt = get_define_template("dscf")
        define_opt["disp"] = disp
        disp_fn = "dscf_nh3_disp_{}".format("_".join(disp.split()))
        assert run_itest("dscf", define_opt, "nh3", disp_fn, ScfOutput)