cfm_predict_batch: Batch CFM prediction using a Linux cluster with a SLURM...

Description Usage Arguments Value

View source: R/cfm-predict.R

Description

Batch CFM prediction using a Linux cluster with a SLURM scheduler

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
cfm_predict_batch(
  id,
  out_dir,
  input_smiles_or_inchi,
  prob_thresh_for_prune = 0.001,
  include_annotations = 1,
  apply_post_processing = 1,
  param_filename,
  config_filename,
  slurm_options,
  cpus_per_node,
  nodes
)

Arguments

id

A molecule identifier. Used for the filename of the cfm-predict output file.

out_dir

A directory to write the cfm-predict results.

input_smiles_or_inchi

The smiles or inchi string of the structure whose spectra you want to predict.

prob_thresh_for_prune

The probability below which to prune unlikely fragmentations (default 0.001)

include_annotations

Whether to include fragment information in the output spectra (0 = NO (default), 1 = YES ). Note: ignored for msp/mgf output.

apply_post_processing

Whether or not to post-process predicted spectra to take the top 80 (whichever comes first) (0 = OFF, 1 = ON (default) ).

param_filename

The filename where the parameters of a trained cfm model can be found (if not given, assumes param_output.log in current directory)

config_filename

The filename where the configuration parameters of the cfm model can be found (if not given, assumes param_config.txt in current directory)

slurm_options

A named list of options recognized by sbatch; see Details below for more information.

cpus_per_node

The number of CPUs per node on the cluster; determines how many processes are run in parallel per node.

nodes

The (maximum) number of cluster nodes to spread the calculation over. slurm_apply automatically divides params in chunks of approximately equal size to send to each node. Less nodes are allocated if the parameter set is too small to use all CPUs on the requested nodes.

Value

A slurm_job object containing the jobname and the number of nodes effectively used.


gjgetzinger/cfmR documentation built on May 11, 2020, 1 p.m.