void _setOptions(po::options_description &desc,
			po::positional_options_description &p) {

		po::options_description usage("Usage: DistributedNucleatingAssembly <options> [[--contig-file contigs.fa] [[--input-file input.fq ...]\n\tNote: --contig-file and --input-file can be specified either as a positional argument or within the options");

		p.add("contig-file", 1);
		p.add("input-file", -1);

		desc.add(usage);

		po::options_description opts("DistributedNucleatingAssembly Options");
		opts.add_options()
					("max-iterations", po::value<int>()->default_value(maxIterations), "the maximum number of rounds to extend the set of contigs")

					("max-contigs-per-batch", po::value<int>()->default_value(maxContigsPerBatch), "the maximum number of assemblies (per mpi) to gather reads and execute per batch")

					("max-contig-length", po::value<int>()->default_value(maxContigLength), "the maximum size of a contig to continue extending");

		desc.add(opts);

		MatcherInterfaceOptions::_setOptions(desc,p);
		KmerMatchOptions::_setOptions(desc,p);
		KmerBaseOptions::_setOptions(desc,p);
		KmerSpectrumOptions::_setOptions(desc,p);
		VmatchOptions::_setOptions(desc,p);
		ContigExtenderBaseOptions::_setOptions(desc,p);
		NewblerOptions::_setOptions(desc, p);
		Cap3Options::_setOptions(desc,p);
		MPIOptions::_setOptions(desc,p);
		FilterKnownOdditiesOptions::_setOptions(desc,p);
		GeneralOptions::_setOptions(desc,p);

	};
Beispiel #2
0
    void InitOptions(po::options_description& opts, po::positional_options_description&) override {
        opts.add_options()
            ("home", po::value<std::string>()->required(), "home directory")
            ("proxy,p", po::value<std::string>()->default_value("localhost"), "proxy host")
            ;

        po::options_description indexerOpts("Lister options");

        indexerOpts.add_options()
            ("verbose,v", "use verbose mode")
            ("chunk-size", po::value<size_t>(), "custom chunk size")
            ;

        opts.add(indexerOpts);
    }
Beispiel #3
0
    void InitOptions(po::options_description& opts, po::positional_options_description&) override {
        opts.add_options()
            ("path,p", po::value<std::string>()->default_value("."), "path to a root directory")
            ("index,i", po::value<std::string>()->required(), "index path prefix")
            ;

        po::options_description listerOpts("Lister options");

        listerOpts.add_options()
            ("verbose,v", "use verbose mode")
            ("recursive,r", po::value<bool>()->default_value(true), "traverse recursively")
            ("hidden", "do not ignore hidden directories/files")
            ("max-depth", po::value<int>()->default_value(-1), "max recursion depth")
            ;

        opts.add(listerOpts);
    }
	void _setOptions(po::options_description &desc, po::positional_options_description &p) {
		// override the default output format!

		// set options specific to this program
		p.add("input-file", -1);

		po::options_description opts("Fastq to Fasta Options");
		opts.add_options()

				("split-pairs", po::value<bool>()->default_value(splitPairs), "if set, pairs will be directed into separate files")

				("split-size-mbase", po::value<int>()->default_value(splitSizeMbase), "maximum size of output fastas.  requires --output-file");

		desc.add(opts);

		GeneralOptions::getOptions()._setOptions(desc, p);
	}
	void _setOptions(po::options_description &desc, po::positional_options_description &p) {
		p.add("output-bam", 1);
		p.add("input-bams", -1);

		po::options_description opts("BamSort-P <options> output.bam input.bam [...]\n\nOptions");
		opts.add_options()
				("output-bam", po::value<std::string>())
				("input-bams", po::value<FileListType>())
				("unmapped-read-pairs", po::value<std::string>()->default_value(unmappedReadPairs), "gzipped file to place unmapped read Pairs Fastqs (can be same as --unmapped-reads)")
				("unmapped-reads", po::value<std::string>()->default_value(unmappedReads), "gzipped file to place unmapped reads Fastqs (can be same as --unmapped-read-pairs)")
				("keep-unmapped-paired-read", po::value<bool>()->default_value(keepUnmappedPairedRead), "if unmapped-read-pairs file is specified, keep an unmapped read in the bam if its pair is mapped")
				("num-partitions", po::value<int>()->default_value(numPartitions), "The number of alignment-index partitions to merge. Input bams expected to come ordered grouped by in batches of num-partitions where each group has the exact same read counts in the exact same order");
		desc.add(opts);

		GeneralOptions::_setOptions(desc, p);
		// Other *::_setOptions(desc,p);
	}
Beispiel #6
0
void RandomAccel2D::appendOptions(po::options_description &opts)
{
    // Accepts a config file and common opts
    PositionGenerator::appendOptions(opts);

    // Update CLI options
    po::options_description local_opts;
    local_opts.add_options()
        ("sigma-accel,a", po::value<double>(),
         "Standard deviation of normally-distributed random accelerations")
        ;
     
    opts.add(local_opts);

    // Return valid keys
    for (auto &o : local_opts.options())
        config_keys_.push_back(o->long_name());
}
Beispiel #7
0
po::variables_map LoadConfigurationSettings(int argNumber, char* argsString[], po::options_description& fileConfig)
{
    po::positional_options_description p;
    p.add("config-file", 1);
    po::options_description general = getGeneralConfigFileOptions();
    po::options_description cmdline= getCMDLineOptions();
    fileConfig.add(general).add(BlobTrackerAlgorithmParams::getTrackerOptions());

    po::variables_map vm;

    store(po::command_line_parser(argNumber, argsString).options(cmdline).positional(p).allow_unregistered().run(), vm);
    notify(vm);
    std::string configFileName = vm["config-file"].as<std::string>();
    std::string path = getPath(configFileName);
    LoadConfigFileinStore(fileConfig, vm, configFileName);
    LoadConfigFileinStore(fileConfig, vm, path + vm["filepath-filename"].as<std::string>());
    LoadConfigFileinStore(fileConfig, vm, path + vm["tracker-filename"].as<std::string>());

    return vm;
}
	void _setOptions(po::options_description &desc,
			po::positional_options_description &p) {
		p.add("kmer-size", 1);
		p.add("input-file", -1);

		po::options_description opts("EstimateSize Options");
		opts.add_options()

						("sample-partitions",po::value<long>()->default_value(samplePartitions),"The number of partitions to break up the file")

						("max-sample-fraction", po::value<double>()->default_value(maxSampleFraction), "The maximum amount of data to read")


						;
		desc.add(opts);
		KmerSpectrumOptions::_setOptions(desc, p);

		MPIOptions::_setOptions(desc, p);
		GeneralOptions::_setOptions(desc, p);
		KmerBaseOptions::_setOptions(desc, p);
		KmerSpectrumOptions::_setOptions(desc, p);
	}
Beispiel #9
0
 foreach(boost::shared_ptr<po::options_description> x, opts_desc){
     visible.add(*x);
 }
Beispiel #10
0
void Recorder::appendOptions(po::options_description &opts)
{
    // Common program options
    opts.add_options()
        ("frame-sources,s", po::value< std::vector<std::string> >()->multitoken(),
        "The names of the FRAME SOURCES that supply images to save to video.")
        ("position-sources,p", po::value< std::vector<std::string> >()->multitoken(),
        "The names of the POSITION SOURCES that supply object positions "
        "to be recorded.")
        ("config,c", po::value<std::vector<std::string> >()->multitoken(),
        "Configuration file/key pair.\n"
        "e.g. 'config.toml mykey'")
        ;

    // Update CLI options
    po::options_description local_opts;
    local_opts.add_options()
        ("filename,n", po::value<std::string>(),
        "The base file name. If not specified, defaults to the SOURCE "
        "name.")
        ("folder,f", po::value<std::string>(),
        "The path to the folder to which the video stream and position "
        "data will be saved. If not specified, defaults to the "
        "current directory.")
        ("date,d",
        "If specified, YYYY-MM-DD-hh-mm-ss_ will be prepended to the "
        "filename.")
        ("allow-overwrite,o",
        "If set and save path matches and existing file, the file will "
        "be overwritten instead of a incremental numerical index being "
        "appended to the file name.")
        ("fourcc,F", po::value<std::string>(),
         "Four character code (https://en.wikipedia.org/wiki/FourCC) used to "
         "specify the codec used for AVI video compression. Must be specified as "
         "a 4-character string (see http://www.fourcc.org/codecs.php for "
         "possible options). Not all valid FOURCC codes will work: it "
         "must be implemented by the low  level writer. Common values are "
         "'DIVX' or 'H264'. Defaults to 'None' indicating uncompressed "
         "video.")
        ("binary-file,b",
         "Position data will be written as numpy data file (version 1.0) "
         "instead of JSON. Each position data point occupies a single entry "
         "in a structured numpy array. Individual position characteristics "
         "are described in the arrays dtype.")
        ("concise-file,c",
         "If set and using JSON file format, indeterminate position data fields "
         "will not be written e.g. pos_xy will not be written even when "
         "pos_ok = false. This means that position objects will be of "
         "variable size depending on the validity of whether a position was "
         "detected or not, potentially complicating file parsing.")
        ("interactive", "Start recorder with interactive controls enabled.")
        ("rpc-endpoint", po::value<std::string>(),
         "Yield interactive control of the recorder to a remote ZMQ REQ "
         "socket using an interal REP socket with ZMQ style endpoint "
         "specifier: '<transport>://<host>:<port>'. For instance, "
         "'tcp://*:5555' to specify TCP communication on ports 5555.")
        ;

    opts.add(local_opts);

    // Return valid keys
    for (auto &o : local_opts.options())
        config_keys_.push_back(o->long_name());
}