Ejemplo n.º 1
0
        def get_atome_energy():

            need_all = True
            print_children = False
            get_children = True

            # -#-#-#-#- #
            # l _ e l e #
            # -#-#-#-#- #

            arguments["--run_id"] = [arguments["--run_atom"]]

            # Usefull object contain all related stuff to l_ele
            a = ListEle(l_ele, get_children, print_children)

            # Only get the children
            a.l_ele = a.l_ele_children
            a.l_ele_to_get = a.l_ele_children

            # -#-#-#-#-#- #
            # F i l t e r #
            # -#-#-#-#-#- #

            _, cmd_where = get_cmd(arguments, a, need_all)

            # -#-#-#-#-#-#-#-#-#- #
            # P r o c e s s i n g #
            # -#-#-#-#-#-#-#-#-#- #
            e_cal_atom, _, _ = get_ecal_runinfo_finfo(cmd_where, "var")

            # -#-#-#-#-#- #
            # R e t u r n #
            # -#-#-#-#-#- #
            return e_cal_atom[int(arguments["--run_atom"])]
Ejemplo n.º 2
0
        def get_atome_energy():

            need_all = True
            print_children = False
            get_children = True

            # -#-#-#-#- #
            # l _ e l e #
            # -#-#-#-#- #

            arguments["--run_id"] = [arguments["--run_atom"]]

            # Usefull object contain all related stuff to l_ele
            a = ListEle(l_ele, get_children, print_children)

            # Only get the children
            a.l_ele = a.l_ele_children
            a.l_ele_to_get = a.l_ele_children

            # -#-#-#-#-#- #
            # F i l t e r #
            # -#-#-#-#-#- #

            _, cmd_where = get_cmd(arguments, a, need_all)

            # -#-#-#-#-#-#-#-#-#- #
            # P r o c e s s i n g #
            # -#-#-#-#-#-#-#-#-#- #
            e_cal_atom, _, _ = get_ecal_runinfo_finfo(cmd_where, "var")

            # -#-#-#-#-#- #
            # R e t u r n #
            # -#-#-#-#-#- #
            return e_cal_atom[int(arguments["--run_atom"])]
Ejemplo n.º 3
0
        def get_ae():
            """Returnb dict [mol] = ae"""

            # User give the ae
            if arguments["--ae_ref"]:

                # -#-#-#-#-#-#-#-#-#- #
                # P r o c e s s i n g #
                # -#-#-#-#-#-#-#-#-#- #

                ae_nr = dict()
                for mol, ae in zip(l_ele, arguments["--ae_ref"]):
                    ae_nr[mol] = float(ae)

            # User wana use the nr ae
            elif arguments["--ae_nr"]:
                need_all = True
                print_children = True
                get_children = True

                # -#-#-#-#- #
                # l _ e l e #
                # -#-#-#-#- #

                a = ListEle(l_ele, get_children, print_children)
                cond_filter_ele, cmd_where = get_cmd(arguments, a, need_all)

                # -#-#-#-#-#-#-#-#-#- #
                # P r o c e s s i n g #
                # -#-#-#-#-#-#-#-#-#- #

                from src.data_util import get_enr, get_ae_nr

                _, _, f_info = get_ecal_runinfo_finfo(cmd_where, "var")
                e_nr = get_enr(cond_filter_ele)
                ae_nr = get_ae_nr(f_info, e_nr)

            # -#-#-#-#-#- #
            # R e t u r n #
            # -#-#-#-#-#- #

            return ae_nr
Ejemplo n.º 4
0
        def get_ae():
            """Returnb dict [mol] = ae"""

            # User give the ae
            if arguments["--ae_ref"]:

                # -#-#-#-#-#-#-#-#-#- #
                # P r o c e s s i n g #
                # -#-#-#-#-#-#-#-#-#- #

                ae_nr = dict()
                for mol, ae in zip(l_ele, arguments["--ae_ref"]):
                    ae_nr[mol] = float(ae)

            # User wana use the nr ae
            elif arguments["--ae_nr"]:
                need_all = True
                print_children = True
                get_children = True

                # -#-#-#-#- #
                # l _ e l e #
                # -#-#-#-#- #

                a = ListEle(l_ele, get_children, print_children)
                cond_filter_ele, cmd_where = get_cmd(arguments, a, need_all)

                # -#-#-#-#-#-#-#-#-#- #
                # P r o c e s s i n g #
                # -#-#-#-#-#-#-#-#-#- #

                from src.data_util import get_enr, get_ae_nr

                _, _, f_info = get_ecal_runinfo_finfo(cmd_where, "var")
                e_nr = get_enr(cond_filter_ele)
                ae_nr = get_ae_nr(f_info, e_nr)

            # -#-#-#-#-#- #
            # R e t u r n #
            # -#-#-#-#-#- #

            return ae_nr
Ejemplo n.º 5
0
    # We get and calcul all the info
    # aka : e_cal, run_info, f_info, mad, ...

    from src.data_util import get_ecal_runinfo_finfo
    from src.data_util import get_zpe_aeexp
    from src.data_util import get_enr, complete_e_nr, get_ediff
    from src.data_util import get_ae_cal, get_ae_nr, get_ae_diff
    from src.data_util import convert, get_header_unit, get_values

    # -#-#-#- #
    # E c a l #
    # -#-#-#- #

    energy_opt = "var" if arguments["--without_pt2"] else "var+pt2"

    e_cal, run_info, f_info = get_ecal_runinfo_finfo(cmd_where, energy_opt)

    # -#-#- #
    # Z P E #
    # -#-#- #
    if arguments["--ae"] or arguments["--no_relativist"]:
        zpe_exp, ae_exp = get_zpe_aeexp(cond_filter_ele)
        convert("zpe_exp", zpe_exp)

    # -#-#-#-#-#-#-#-#-#-#-#-#- #
    # N o _ r e l a t i v i s t #
    # -#-#-#-#-#-#-#-#-#-#-#-#- #
    if arguments["--no_relativist"] or arguments["--ae"]:
        e_nr = get_enr(cond_filter_ele)
        complete_e_nr(e_nr, f_info, ae_exp, zpe_exp)