#! /usr/bin/perl # The top level script that runs a rmark benchmark. # # Usage: # ./rmark-master.pl # # : Directory for finding executables to be benchmarked. This # is passed on to the without modification. # # : Directory for finding scripts used by the benchmark, namely # rmark-idpositives.pl. # # : Directory for finding model files for the benchmark. This # is passed on to the without modification. # Some programs don't require model files (e.g. BLAST), but they're # benchmark scripts will still take a argument. # # : A directory for holding all temporary files # created by the benchmark. This name should be short and unique; # it will also be used to construct job names on the cluster, as # . # # : File with options for the search program. # For example, a non-filtered cmsearch 1.0 run would have a single # line in this file: # '--fil-no-hmm --fil-no-qdb" # # : The script will look for files .tbl, # .msa, .fa, and .pos, defining a RMARK # benchmark set. If -P option is used, a positive-only benchmark is # being conducted, .pfa and .ppos will be used # instead of .fa and .pos. # # : This script is executed for each process, # on an appropriately constructed subset of the benchmark queries. # # It must take the following arguments: # # # See definition of $options_usage string for description of options. # # Example of rmark benchmark: # ./rmark-master.pl -C models/rmark3.cm -F ../src/ rmark models r3-test cmsearch-df.opts rmark3 rmark/x-cmsearch use Getopt::Std; getopts('DPWB:N:T:FAM:O:C:X:ZYH:I:'); $do_posonly = 0; $do_poswindowonly = 0; $do_nopos = 0; $do_debug = 0; $do_onejob_only = 0; $do_build_models = 0; $do_indi = 0; $onejob = 0; $ncpu_set = 0; $ncpu = 0; $tbl_set = 0; $tbl_file = ""; $do_force = 0; $do_add = 0; $x_opt_to_pass = ""; $z_opt_to_pass = ""; $h_opt_to_pass = ""; $mpi_nprocs = 8; #default, we'll only use it if --mpi exists in if (defined $opt_D) { $do_debug = 1; } if (defined $opt_P) { $do_posonly = 1; } if (defined $opt_W) { $do_poswindowonly = 1; } if (defined $opt_Y) { $do_nopos = 1; } if (defined $opt_B) { $do_build_models = 1; $build_optsfile = $opt_B; } if (defined $opt_N) { $ncpu_set = 1; $ncpu = $opt_N; } if (defined $opt_T) { $tbl_set = 1; $tbl_file = $opt_T; } if (defined $opt_F) { $do_force = 1; } if (defined $opt_A) { $do_add = 1; } if (defined $opt_O) { $do_onejob_only = 1; $onejob = $opt_O; } if (defined $opt_C) { $do_fetch_models = 1; $master_model = $opt_C; if($do_build_models) { die "-B and -C are incompatible"; } } if (defined $opt_X) { $x_opt_to_pass = "-X $opt_X"; } if (defined $opt_Z) { $z_opt_to_pass = "-Z"; } if (defined $opt_H) { $h_opt_to_pass = "-H $opt_H"; } if (defined $opt_I) { $do_indi = 1; $nindi = $opt_I; } if (defined $opt_M) { $mpi_nprocs = $opt_M; if($mpi_nprocs < 2 || $mpi_nprocs > 8) { die "ERROR, with -M , must be between 2 and 8"; } } $usage = "Usage: perl rmark-master.pl\n\t\n\t