Ejemplo n.º 1
0
def scan(prefix):
    """ construct the scan filesystem

    layers:
     - trunk (specifiers: [])
     - branch (specifiers: [coo_names])
     - leaf (specifiers: [coo_names, coo_vals])

    :param prefix: sets the path where this filesystem will sit
    :type prefix: str
    """
    trunk_ds = dir_.scan_trunk(prefix)
    branch_ds = dir_.scan_branch(prefix, root_ds=trunk_ds)
    leaf_ds = dir_.scan_leaf(prefix, root_ds=branch_ds)

    vma_dfile = file_.vmatrix(FilePrefix.SCAN)
    trunk_ds.add_data_files({FileAttributeName.VMATRIX: vma_dfile})

    inf_dfile = file_.information(FilePrefix.SCAN, function=info.scan_branch)
    traj_dfile = file_.trajectory(FilePrefix.SCAN)
    branch_ds.add_data_files({
        FileAttributeName.INFO: inf_dfile,
        FileAttributeName.TRAJ: traj_dfile
    })

    geom_inf_dfile = file_.information(FilePrefix.GEOM, function=info.run)
    grad_inf_dfile = file_.information(FilePrefix.GRAD, function=info.run)
    hess_inf_dfile = file_.information(FilePrefix.HESS, function=info.run)
    geom_inp_dfile = file_.input_file(FilePrefix.GEOM)
    grad_inp_dfile = file_.input_file(FilePrefix.GRAD)
    hess_inp_dfile = file_.input_file(FilePrefix.HESS)
    ene_dfile = file_.energy(FilePrefix.GEOM)
    geom_dfile = file_.geometry(FilePrefix.GEOM)
    zmat_dfile = file_.zmatrix(FilePrefix.GEOM)
    grad_dfile = file_.gradient(FilePrefix.GRAD)
    hess_dfile = file_.hessian(FilePrefix.HESS)
    hfreq_dfile = file_.harmonic_frequencies(FilePrefix.HESS)
    leaf_ds.add_data_files({
        FileAttributeName.GEOM_INFO: geom_inf_dfile,
        FileAttributeName.GRAD_INFO: grad_inf_dfile,
        FileAttributeName.HESS_INFO: hess_inf_dfile,
        FileAttributeName.GEOM_INPUT: geom_inp_dfile,
        FileAttributeName.GRAD_INPUT: grad_inp_dfile,
        FileAttributeName.HESS_INPUT: hess_inp_dfile,
        FileAttributeName.ENERGY: ene_dfile,
        FileAttributeName.GEOM: geom_dfile,
        FileAttributeName.ZMAT: zmat_dfile,
        FileAttributeName.GRAD: grad_dfile,
        FileAttributeName.HESS: hess_dfile,
        FileAttributeName.HFREQ: hfreq_dfile
    })

    dir_fs = model.FileSystem({
        SeriesAttributeName.TRUNK: trunk_ds,
        SeriesAttributeName.BRANCH: branch_ds,
        SeriesAttributeName.BRANCH1: branch_ds,
        SeriesAttributeName.LEAF: leaf_ds
    })
    return dir_fs
Ejemplo n.º 2
0
def theory(prefix):
    """ construct the theory filesystem [leaf]

    layers:
     - leaf (specifiers: [method, basis, orb_restricted])

    :param prefix: sets the path where this filesystem will sit
    :type prefix: str
    """
    leaf_ds = dir_.theory_leaf(prefix)

    geom_dfile = file_.geometry(FilePrefix.GEOM)
    ene_dfile = file_.energy(FilePrefix.GEOM)
    zmat_dfile = file_.zmatrix(FilePrefix.GEOM)
    hess_dfile = file_.hessian(FilePrefix.HESS)
    leaf_ds.add_data_files({
        FileAttributeName.ENERGY: ene_dfile,
        FileAttributeName.GEOM: geom_dfile,
        FileAttributeName.HESS: hess_dfile,
        FileAttributeName.ZMAT: zmat_dfile
    })

    dir_fs = model.FileSystem({SeriesAttributeName.LEAF: leaf_ds})
    return dir_fs
Ejemplo n.º 3
0
def conformer(prefix):
    """ construct the conformer filesystem [trunk/leaf]

    layers:
     - trunk (specifiers: [])
     - leaf (specifiers: [cid])

    :param prefix: sets the path where this filesystem will sit
    :type prefix: str
    """
    trunk_ds = dir_.conformer_trunk(prefix)
    leaf_ds = dir_.conformer_leaf(prefix, root_ds=trunk_ds)

    min_ene_dfile = file_.energy(FilePrefix.MIN)
    vma_dfile = file_.vmatrix(FilePrefix.CONF)
    inf_dfile = file_.information(FilePrefix.CONF,
                                  function=info.conformer_trunk)
    traj_dfile = file_.trajectory(FilePrefix.CONF)
    trunk_ds.add_data_files({
        FileAttributeName.VMATRIX: vma_dfile,
        FileAttributeName.INFO: inf_dfile,
        FileAttributeName.ENERGY: min_ene_dfile,
        FileAttributeName.TRAJ: traj_dfile
    })

    geom_inf_dfile = file_.information(FilePrefix.GEOM, function=info.run)
    grad_inf_dfile = file_.information(FilePrefix.GRAD, function=info.run)
    hess_inf_dfile = file_.information(FilePrefix.HESS, function=info.run)
    geom_inp_dfile = file_.input_file(FilePrefix.GEOM)
    grad_inp_dfile = file_.input_file(FilePrefix.GRAD)
    hess_inp_dfile = file_.input_file(FilePrefix.HESS)
    ene_dfile = file_.energy(FilePrefix.GEOM)
    geom_dfile = file_.geometry(FilePrefix.GEOM)
    zmat_dfile = file_.zmatrix(FilePrefix.GEOM)
    grad_dfile = file_.gradient(FilePrefix.GRAD)
    hess_dfile = file_.hessian(FilePrefix.HESS)
    hfreq_dfile = file_.harmonic_frequencies(FilePrefix.HESS)
    vpt2_inf_dfile = file_.information(FilePrefix.VPT2,
                                       function=info.vpt2_trunk)
    vpt2_inp_dfile = file_.input_file(FilePrefix.VPT2)
    anhfreq_dfile = file_.anharmonic_frequencies(FilePrefix.VPT2)
    anhzpve_dfile = file_.anharmonic_zpve(FilePrefix.VPT2)
    xmat_dfile = file_.anharmonicity_matrix(FilePrefix.VPT2)
    vibrot_mat_dfile = file_.vibro_rot_alpha_matrix(FilePrefix.VPT2)
    centrif_dist_dfile = file_.quartic_centrifugal_dist_consts(FilePrefix.VPT2)

    leaf_ds.add_data_files({
        FileAttributeName.GEOM_INFO: geom_inf_dfile,
        FileAttributeName.GRAD_INFO: grad_inf_dfile,
        FileAttributeName.HESS_INFO: hess_inf_dfile,
        FileAttributeName.GEOM_INPUT: geom_inp_dfile,
        FileAttributeName.GRAD_INPUT: grad_inp_dfile,
        FileAttributeName.HESS_INPUT: hess_inp_dfile,
        FileAttributeName.ENERGY: ene_dfile,
        FileAttributeName.GEOM: geom_dfile,
        FileAttributeName.ZMAT: zmat_dfile,
        FileAttributeName.GRAD: grad_dfile,
        FileAttributeName.HESS: hess_dfile,
        FileAttributeName.HFREQ: hfreq_dfile,
        FileAttributeName.VPT2_INFO: vpt2_inf_dfile,
        FileAttributeName.VPT2_INPUT: vpt2_inp_dfile,
        FileAttributeName.ANHFREQ: anhfreq_dfile,
        FileAttributeName.ANHZPVE: anhzpve_dfile,
        FileAttributeName.XMAT: xmat_dfile,
        FileAttributeName.VIBROT_MAX: vibrot_mat_dfile,
        FileAttributeName.CENTIF_DIST: centrif_dist_dfile
    })

    dir_fs = model.FileSystem({
        SeriesAttributeName.TRUNK: trunk_ds,
        SeriesAttributeName.LEAF: leaf_ds
    })
    return dir_fs