def theory(prefix): """ construct the theory filesystem (1 layer) locators: 0 - [method, basis, orb_type] files: - energy - geometry - hessian - zmatrix - instability trajectory - instability reactant_graph :param prefix: sets the path where this filesystem will sit :type prefix: str """ leaf_ds = data_series.theory_leaf(prefix) geom_dfile = data_files.geometry(_FilePrefix.GEOM) ene_dfile = data_files.energy(_FilePrefix.GEOM) zmat_dfile = data_files.zmatrix(_FilePrefix.GEOM) hess_dfile = data_files.hessian(_FilePrefix.HESS) graph_dfile = data_files.graph(_FilePrefix.INSTAB) trans_dfile = data_files.transformation(_FilePrefix.INSTAB) leaf_ds.add_data_files({ _FileAttributeName.ENERGY: ene_dfile, _FileAttributeName.GEOM: geom_dfile, _FileAttributeName.HESS: hess_dfile, _FileAttributeName.ZMAT: zmat_dfile, _FileAttributeName.REACTANT_GRAPH: graph_dfile, _FileAttributeName.TRANS: trans_dfile }) return (leaf_ds, )
def transition_state(prefix): """ construct the ts filesystem (1 layer) locators: 0 - [] files: - energy - geometry - zmatrix :param prefix: sets the path where this filesystem will sit :type prefix: str """ trunk_ds = data_series.transition_state_trunk(prefix) geom_dfile = data_files.geometry(_FilePrefix.GEOM) ene_dfile = data_files.energy(_FilePrefix.GEOM) zmat_dfile = data_files.zmatrix(_FilePrefix.GEOM) vmat_dfile = data_files.vmatrix(_FilePrefix.GEOM) trunk_ds.add_data_files({ _FileAttributeName.ENERGY: ene_dfile, _FileAttributeName.GEOM: geom_dfile, _FileAttributeName.ZMAT: zmat_dfile, _FileAttributeName.VMATRIX: vmat_dfile }) return (trunk_ds, )
def zmatrix(prefix): """ Create a z-matrix file system manager for a given path. Layers: [0] The zmatrix "trunk" layer. Specifiers: [] (no files) Generated by :meth:`autofile.schema.data_series.zmatrix_trunk` [1] The zmatrix "leaf" layer. Specifiers: [Z-Matrix Number] Files: - Generated by :meth:`autofile.schema.data_series.zmatrix_leaf` :param prefix: Path to where the file system will be created :type prefix: str :returns: A tuple of DataSeries objects. Each item in this tuple manages a different layer in the file system, as described above. """ trunk_ds = data_series.zmatrix_trunk(prefix) leaf_ds = data_series.zmatrix_leaf(prefix, root_ds=trunk_ds) zmat_inf_dfile = data_files.information(_FilePrefix.ZMAT, function=info_objects.run) zmat_inp_dfile = data_files.input_file(_FilePrefix.ZMAT) inf_dfile = data_files.information(_FilePrefix.CONF, function=info_objects.conformer_trunk) zmat_dfile = data_files.zmatrix(_FilePrefix.ZMAT) vma_dfile = data_files.vmatrix(_FilePrefix.ZMAT) graph_dfile = data_files.graph(_FilePrefix.ZMAT) trans_dfile = data_files.transformation(_FilePrefix.ZMAT) leaf_ds.add_data_files({ _FileAttributeName.GEOM_INFO: zmat_inf_dfile, _FileAttributeName.TORS_INFO: inf_dfile, _FileAttributeName.GEOM_INPUT: zmat_inp_dfile, _FileAttributeName.ZMAT: zmat_dfile, _FileAttributeName.VMATRIX: vma_dfile, _FileAttributeName.REACTANT_GRAPH: graph_dfile, _FileAttributeName.TRANS: trans_dfile }) return (trunk_ds, leaf_ds)
def zmatrix(prefix): """ Create a z-matrix file system manager for a given path. Layers: [0] The zmatrix "trunk" layer. Specifiers: [] (no files) Generated by :meth:`autofile.schema.data_series.zmatrix_trunk` [1] The zmatrix "leaf" layer. Specifiers: [Z-Matrix Number] Files: - Generated by :meth:`autofile.schema.data_series.zmatrix_leaf` :param prefix: Path to where the file system will be created :type prefix: str :returns: A tuple of DataSeries objects. Each item in this tuple manages a different layer in the file system, as described above. """ trunk_ds = data_series.zmatrix_trunk(prefix) leaf_ds = data_series.zmatrix_leaf(prefix, root_ds=trunk_ds) instab_inf_dfile = data_files.instability(_FilePrefix.INSTAB) zmat_inf_dfile = data_files.information(_FilePrefix.ZMAT, function=info_objects.run) zmat_inp_dfile = data_files.input_file(_FilePrefix.ZMAT) tors_dfile = data_files.torsions(_FilePrefix.ZMAT) rtors_dfile = data_files.ring_torsions(_FilePrefix.ZMAT) zmat_dfile = data_files.zmatrix(_FilePrefix.ZMAT) reac_dfile = data_files.reaction(_FilePrefix.ZMAT) leaf_ds.add_data_files({ FileAttributeName.INSTAB: instab_inf_dfile, FileAttributeName.GEOM_INFO: zmat_inf_dfile, FileAttributeName.TORS: tors_dfile, FileAttributeName.RTORS: rtors_dfile, FileAttributeName.GEOM_INPUT: zmat_inp_dfile, FileAttributeName.ZMAT: zmat_dfile, FileAttributeName.REAC: reac_dfile }) return (trunk_ds, leaf_ds)
def run(prefix): """ construct the run filesystem (2 layers) locators: 0 - [] files: - info 1 - [job] files: - info - input - output - geometry - zmatrix :param prefix: sets the path where this filesystem will sit :type prefix: str """ trunk_ds = data_series.run_trunk(prefix) leaf_ds = data_series.run_leaf(prefix, root_ds=trunk_ds) inf_dfile = data_files.information(_FilePrefix.RUN, function=info_objects.run) inp_dfile = data_files.input_file(_FilePrefix.RUN) out_dfile = data_files.output_file(_FilePrefix.RUN) geom_dfile = data_files.geometry(_FilePrefix.GEOM) zmat_dfile = data_files.zmatrix(_FilePrefix.ZMAT) trunk_ds.add_data_files({_FileAttributeName.INFO: inf_dfile}) leaf_ds.add_data_files({ _FileAttributeName.INFO: inf_dfile, _FileAttributeName.INPUT: inp_dfile, _FileAttributeName.OUTPUT: out_dfile, _FileAttributeName.GEOM: geom_dfile, _FileAttributeName.ZMAT: zmat_dfile }) return (trunk_ds, leaf_ds)
def tau(prefix): """ construct the tau filesystem (2 layers) locators: 0 - [] files: - vmatrix - info - trajectory 0 - [tid] files: - geometry_info - gradient_info - hessian_info - geometry_input - gradient_input - hessian_input - energy - geometry - zmatrix - gradient - hessian - harmonic_frequencies :param prefix: sets the path where this filesystem will sit :type prefix: str """ trunk_ds = data_series.tau_trunk(prefix) leaf_ds = data_series.tau_leaf(prefix, root_ds=trunk_ds) vma_dfile = data_files.vmatrix(_FilePrefix.TAU) inf_dfile = data_files.information(_FilePrefix.TAU, function=info_objects.tau_trunk) traj_dfile = data_files.trajectory(_FilePrefix.TAU) trunk_ds.add_data_files({ _FileAttributeName.VMATRIX: vma_dfile, _FileAttributeName.INFO: inf_dfile, _FileAttributeName.TRAJ: traj_dfile }) geom_inf_dfile = data_files.information(_FilePrefix.GEOM, function=info_objects.run) grad_inf_dfile = data_files.information(_FilePrefix.GRAD, function=info_objects.run) hess_inf_dfile = data_files.information(_FilePrefix.HESS, function=info_objects.run) geom_inp_dfile = data_files.input_file(_FilePrefix.GEOM) grad_inp_dfile = data_files.input_file(_FilePrefix.GRAD) hess_inp_dfile = data_files.input_file(_FilePrefix.HESS) ene_dfile = data_files.energy(_FilePrefix.GEOM) geom_dfile = data_files.geometry(_FilePrefix.GEOM) zmat_dfile = data_files.zmatrix(_FilePrefix.GEOM) grad_dfile = data_files.gradient(_FilePrefix.GRAD) hess_dfile = data_files.hessian(_FilePrefix.HESS) hfreq_dfile = data_files.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 }) geom_inf_jobj = json_objects.information(_FilePrefix.GEOM, function=info_objects.run) grad_inf_jobj = json_objects.information(_FilePrefix.GRAD, function=info_objects.run) hess_inf_jobj = json_objects.information(_FilePrefix.HESS, function=info_objects.run) geom_inp_jobj = json_objects.input_file(_FilePrefix.GEOM) grad_inp_jobj = json_objects.input_file(_FilePrefix.GRAD) hess_inp_jobj = json_objects.input_file(_FilePrefix.HESS) ene_jobj = json_objects.energy(_FilePrefix.GEOM) geom_jobj = json_objects.geometry(_FilePrefix.GEOM) zmat_jobj = json_objects.zmatrix(_FilePrefix.GEOM) grad_jobj = json_objects.gradient(_FilePrefix.GRAD) hess_jobj = json_objects.hessian(_FilePrefix.HESS) hfreq_jobj = json_objects.harmonic_frequencies(_FilePrefix.HESS) leaf_ds.add_json_entries({ _JSONAttributeName.GEOM_INFO: geom_inf_jobj, _JSONAttributeName.GRAD_INFO: grad_inf_jobj, _JSONAttributeName.HESS_INFO: hess_inf_jobj, _JSONAttributeName.GEOM_INPUT: geom_inp_jobj, _JSONAttributeName.GRAD_INPUT: grad_inp_jobj, _JSONAttributeName.HESS_INPUT: hess_inp_jobj, _JSONAttributeName.ENERGY: ene_jobj, _JSONAttributeName.GEOM: geom_jobj, _JSONAttributeName.ZMAT: zmat_jobj, _JSONAttributeName.GRAD: grad_jobj, _JSONAttributeName.HESS: hess_jobj, _JSONAttributeName.HFREQ: hfreq_jobj }) return (trunk_ds, leaf_ds)
def cscan(prefix): """ Create a constrained scan (c-scan) file system manager for a given path. Layers: [0] The c-scan "trunk" layer. Specifiers: [] (no files) Generated by :meth:`autofile.schema.data_series.cscan_trunk` [1] The first c-scan "branch" layer. Specifiers: [Constraints] Files: - info - trajectory Generated by :meth:`autofile.schema.data_series.cscan_branch1` [2] The second c-scan "branch" layer. Specifiers: [Constraints, Scan Coordinate Names] (no files) Generated by :meth:`autofile.schema.data_series.cscan_branch2` [3] The c-scan "leaf" layer. Specifiers: [Constraints, Scan Coordinate Names, Scan Coordinate Values] Files: - geometry_info - gradient_info - hessian_info - geometry_input - gradient_input - hessian_input - energy - geometry - zmatrix - gradient - hessian - harmonic_frequencies Generated by :meth:`autofile.schema.data_series.cscan_leaf` :param prefix: Path to where the file system will be created :type prefix: str :returns: A tuple of DataSeries objects. Each item in this tuple manages a different layer in the file system, as described above. """ trunk_ds = data_series.cscan_trunk(prefix) branch1_ds = data_series.cscan_branch1(prefix, root_ds=trunk_ds) branch2_ds = data_series.cscan_branch2(prefix, root_ds=branch1_ds) leaf_ds = data_series.cscan_leaf(prefix, root_ds=branch2_ds) inf_dfile = data_files.information(_FilePrefix.SCAN, function=info_objects.scan_branch) traj_dfile = data_files.trajectory(_FilePrefix.SCAN) branch1_ds.add_data_files({ _FileAttributeName.INFO: inf_dfile, _FileAttributeName.TRAJ: traj_dfile }) geom_inf_dfile = data_files.information(_FilePrefix.GEOM, function=info_objects.run) grad_inf_dfile = data_files.information(_FilePrefix.GRAD, function=info_objects.run) hess_inf_dfile = data_files.information(_FilePrefix.HESS, function=info_objects.run) geom_inp_dfile = data_files.input_file(_FilePrefix.GEOM) grad_inp_dfile = data_files.input_file(_FilePrefix.GRAD) hess_inp_dfile = data_files.input_file(_FilePrefix.HESS) ene_dfile = data_files.energy(_FilePrefix.GEOM) geom_dfile = data_files.geometry(_FilePrefix.GEOM) zmat_dfile = data_files.zmatrix(_FilePrefix.GEOM) grad_dfile = data_files.gradient(_FilePrefix.GRAD) hess_dfile = data_files.hessian(_FilePrefix.HESS) hfreq_dfile = data_files.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 }) return (trunk_ds, branch1_ds, branch2_ds, leaf_ds)
def scan(prefix): """ construct the scan filesystem (3 layers) three layers with the following locators: 0 - [] files: - vmatrix 1 - [coo_names] files: - info - trajectory 2 - [coo_names, coo_vals] files: - geometry_info - gradient_info - hessian_info - irc_info - geometry_input - gradient_input - hessian_input - irc_input - energy - geometry - zmatrix - gradient - hessian - harmonic_frequencies :param prefix: sets the path where this filesystem will sit :type prefix: str """ trunk_ds = data_series.scan_trunk(prefix) branch_ds = data_series.scan_branch(prefix, root_ds=trunk_ds) leaf_ds = data_series.scan_leaf(prefix, root_ds=branch_ds) vma_dfile = data_files.vmatrix(_FilePrefix.SCAN) trunk_ds.add_data_files({_FileAttributeName.VMATRIX: vma_dfile}) inf_dfile = data_files.information(_FilePrefix.SCAN, function=info_objects.scan_branch) traj_dfile = data_files.trajectory(_FilePrefix.SCAN) branch_ds.add_data_files({ _FileAttributeName.INFO: inf_dfile, _FileAttributeName.TRAJ: traj_dfile }) # Need an irc file in the branch! # Need an run irc file in the forward and backward direction geom_inf_dfile = data_files.information(_FilePrefix.GEOM, function=info_objects.run) grad_inf_dfile = data_files.information(_FilePrefix.GRAD, function=info_objects.run) hess_inf_dfile = data_files.information(_FilePrefix.HESS, function=info_objects.run) irc_inf_dfile = data_files.information(_FilePrefix.IRC, function=info_objects.run) geom_inp_dfile = data_files.input_file(_FilePrefix.GEOM) grad_inp_dfile = data_files.input_file(_FilePrefix.GRAD) hess_inp_dfile = data_files.input_file(_FilePrefix.HESS) irc_inp_dfile = data_files.input_file(_FilePrefix.IRC) ene_dfile = data_files.energy(_FilePrefix.GEOM) geom_dfile = data_files.geometry(_FilePrefix.GEOM) zmat_dfile = data_files.zmatrix(_FilePrefix.GEOM) grad_dfile = data_files.gradient(_FilePrefix.GRAD) hess_dfile = data_files.hessian(_FilePrefix.HESS) hfreq_dfile = data_files.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.IRC_INFO: irc_inf_dfile, _FileAttributeName.GEOM_INPUT: geom_inp_dfile, _FileAttributeName.GRAD_INPUT: grad_inp_dfile, _FileAttributeName.HESS_INPUT: hess_inp_dfile, _FileAttributeName.IRC_INPUT: irc_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 }) return (trunk_ds, branch_ds, leaf_ds)