Mercurial > repos > iuc > data_manager_build_kraken2_database
changeset 4:0eebe086fd58 draft
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/data_managers/data_manager_build_kraken2_database/ commit fed92935f1f0b52173d2fddbdd2bbf44e802b51e"
author | iuc |
---|---|
date | Mon, 23 Nov 2020 20:49:52 +0000 |
parents | 19b6a2f0dbe2 |
children | 2f27f3b86827 |
files | data_manager/kraken2_build_database.py data_manager/kraken2_build_database.xml |
diffstat | 2 files changed, 18 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/data_manager/kraken2_build_database.py Sun Nov 22 12:45:56 2020 +0000 +++ b/data_manager/kraken2_build_database.py Mon Nov 23 20:49:52 2020 +0000 @@ -59,6 +59,7 @@ "kmer-len", str(kraken2_args["kmer_len"]), "minimizer-len", str(kraken2_args["minimizer_len"]), "minimizer-spaces", str(kraken2_args["minimizer_spaces"]), + "load-factor", str(kraken2_args["load_factor"]), ]) database_name = " ".join([ @@ -68,6 +69,7 @@ "kmer-len=" + str(kraken2_args["kmer_len"]) + ",", "minimizer-len=" + str(kraken2_args["minimizer_len"]) + ",", "minimizer-spaces=" + str(kraken2_args["minimizer_spaces"]) + ")", + "load-factor", str(kraken2_args["load_factor"]), ]) database_path = database_value @@ -78,6 +80,7 @@ '--kmer-len', str(kraken2_args["kmer_len"]), '--minimizer-len', str(kraken2_args["minimizer_len"]), '--minimizer-spaces', str(kraken2_args["minimizer_spaces"]), + '--load-factor', str(kraken2_args["load_factor"]), '--db', database_path ] @@ -172,6 +175,7 @@ "kmer-len", str(kraken2_args["kmer_len"]), "minimizer-len", str(kraken2_args["minimizer_len"]), "minimizer-spaces", str(kraken2_args["minimizer_spaces"]), + "load-factor", str(kraken2_args["load_factor"]), ]) database_name = " ".join([ @@ -181,6 +185,7 @@ "kmer-len=" + str(kraken2_args["kmer_len"]) + ",", "minimizer-len=" + str(kraken2_args["minimizer_len"]) + ",", "minimizer-spaces=" + str(kraken2_args["minimizer_spaces"]) + ")", + "load-factor=" + str(kraken2_args["load_factor"]) + ")", ]) database_path = database_value @@ -191,6 +196,7 @@ '--kmer-len', str(kraken2_args["kmer_len"]), '--minimizer-len', str(kraken2_args["minimizer_len"]), '--minimizer-spaces', str(kraken2_args["minimizer_spaces"]), + '--load-factor', str(kraken2_args["load_factor"]), '--db', database_path ] @@ -247,6 +253,7 @@ '--kmer-len', str(kraken2_args["kmer_len"]), '--minimizer-len', str(kraken2_args["minimizer_len"]), '--minimizer-spaces', str(kraken2_args["minimizer_spaces"]), + '--load-factor', str(kraken2_args["load_factor"]), '--db', custom_database_name ] @@ -282,6 +289,7 @@ parser.add_argument('--kmer-len', dest='kmer_len', type=int, default=35, help='kmer length') parser.add_argument('--minimizer-len', dest='minimizer_len', type=int, default=31, help='minimizer length') parser.add_argument('--minimizer-spaces', dest='minimizer_spaces', default=6, help='minimizer spaces') + parser.add_argument('--load-factor', dest='load_factor', type=float, default=0.7, help='load factor') parser.add_argument('--threads', dest='threads', default=1, help='threads') parser.add_argument('--database-type', dest='database_type', type=KrakenDatabaseTypes, choices=list(KrakenDatabaseTypes), required=True, help='type of kraken database to build') parser.add_argument('--minikraken2-version', dest='minikraken2_version', type=Minikraken2Versions, choices=list(Minikraken2Versions), help='MiniKraken2 version (only applies to --database-type minikraken)') @@ -312,6 +320,7 @@ "kmer_len": args.kmer_len, "minimizer_len": args.minimizer_len, "minimizer_spaces": args.minimizer_spaces, + "load_factor": args.load_factor, "threads": args.threads, "clean": args.clean, } @@ -330,6 +339,7 @@ "kmer_len": args.kmer_len, "minimizer_len": args.minimizer_len, "minimizer_spaces": args.minimizer_spaces, + "load_factor": args.load_factor, "threads": args.threads, "clean": args.clean, } @@ -344,6 +354,7 @@ "kmer_len": args.kmer_len, "minimizer_len": args.minimizer_len, "minimizer_spaces": args.minimizer_spaces, + "load_factor": args.load_factor, "threads": args.threads, "clean": args.clean, }
--- a/data_manager/kraken2_build_database.xml Sun Nov 22 12:45:56 2020 +0000 +++ b/data_manager/kraken2_build_database.xml Mon Nov 23 20:49:52 2020 +0000 @@ -1,16 +1,18 @@ <?xml version="1.0"?> -<tool id="kraken2_build_database" name="Kraken2" tool_type="manage_data" version="2.0.8_beta+galaxy2" profile="18.09"> +<tool id="kraken2_build_database" name="Kraken2" tool_type="manage_data" version="@TOOL_VERSION@" profile="18.09"> <macros> + <token name="@TOOL_VERSION@">2.1.1</token> <xml name="common_params"> <param name="kmer_len" type="integer" value="35" label="K-mer length in BP" /> <param name="minimizer_len" type="integer" value="31" label="Minimizer length" /> <param name="minimizer_spaces" type="integer" value="6" label="Minimizer spaces" /> + <param name="load_factor" type="float" value="0.7" min="0" max="1" label="Load factor" help="Proportion of the hash table to be populated" /> <param name="clean" type="boolean" truevalue="--clean" falsevalue="" checked="true" label="Clean up extra files" /> </xml> </macros> <description>database builder</description> <requirements> - <requirement type="package" version="2.0.8_beta">kraken2</requirement> + <requirement type="package" version="@TOOL_VERSION@">kraken2</requirement> <requirement type="package" version="3.7">python</requirement> </requirements> <version_command>kraken2 -version | head -n 1 | awk '{print $NF}'</version_command> @@ -26,6 +28,7 @@ --kmer-len ${database_type.kmer_len} --minimizer-len ${database_type.minimizer_len} --minimizer-spaces ${database_type.minimizer_spaces} + --load-factor ${database_type.load_factor} ${database_type.clean} #else if $database_type.database_type == "special" --threads \${GALAXY_SLOTS:-1} @@ -33,6 +36,7 @@ --kmer-len ${database_type.kmer_len} --minimizer-len ${database_type.minimizer_len} --minimizer-spaces ${database_type.minimizer_spaces} + --load-factor ${database_type.load_factor} ${database_type.clean} #else if $database_type.database_type == "custom" --threads \${GALAXY_SLOTS:-1} @@ -42,6 +46,7 @@ --kmer-len ${database_type.kmer_len} --minimizer-len ${database_type.minimizer_len} --minimizer-spaces ${database_type.minimizer_spaces} + --load-factor ${database_type.load_factor} ${database_type.clean} #end if ]]>