Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
panacota
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Amandine PERRIN
panacota
Commits
67dc4e05
Commit
67dc4e05
authored
4 years ago
by
Amandine PERRIN
Browse files
Options
Downloads
Patches
Plain Diff
cutN must be a positive number
parent
c681dc17
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
PanACoTA/subcommands/annotate.py
+1
-1
1 addition, 1 deletion
PanACoTA/subcommands/annotate.py
PanACoTA/subcommands/prepare.py
+1
-1
1 addition, 1 deletion
PanACoTA/subcommands/prepare.py
PanACoTA/utils_argparse.py
+12
-0
12 additions, 0 deletions
PanACoTA/utils_argparse.py
with
14 additions
and
2 deletions
PanACoTA/subcommands/annotate.py
+
1
−
1
View file @
67dc4e05
...
...
@@ -479,7 +479,7 @@ def build_parser(parser):
optional
.
add_argument
(
"
--nbcont
"
,
dest
=
"
nbcont
"
,
type
=
utils_argparse
.
cont_num
,
default
=
999
,
help
=
(
"
Maximum number of contigs allowed to keep a genome.
"
"
Default is 999.
"
))
optional
.
add_argument
(
"
--cutn
"
,
dest
=
"
cutn
"
,
type
=
int
,
default
=
5
,
optional
.
add_argument
(
"
--cutn
"
,
dest
=
"
cutn
"
,
type
=
utils_argparse
.
positive_
int
,
default
=
5
,
help
=
(
"
By default, each genome will be cut into new contigs when
"
"
at least 5
'
N
'
in a row are found in its sequence.
"
"
If you don
'
t want to
"
...
...
This diff is collapsed.
Click to expand it.
PanACoTA/subcommands/prepare.py
+
1
−
1
View file @
67dc4e05
...
...
@@ -312,7 +312,7 @@ def build_parser(parser):
"
By default, it will be saved in your
"
"
out_dir/tmp_files.
"
)
)
general
.
add_argument
(
"
--cutn
"
,
dest
=
"
cutn
"
,
type
=
int
,
default
=
5
,
general
.
add_argument
(
"
--cutn
"
,
dest
=
"
cutn
"
,
type
=
utils_argparse
.
positive_
int
,
default
=
5
,
help
=
(
"
By default, each genome will be cut into new contigs when
"
"
at least 5
'
N
'
in a row are found in its sequence.
"
"
If you don
'
t want to
"
...
...
This diff is collapsed.
Click to expand it.
PanACoTA/utils_argparse.py
+
12
−
0
View file @
67dc4e05
...
...
@@ -99,3 +99,15 @@ def thread_num(param):
elif
param
==
0
:
return
nb_cpu
return
param
def
positive_int
(
param
):
try
:
param
=
int
(
param
)
except
ValueError
:
msg
=
f
"
error: argument --cutn: invalid int value:
'
{
param
}
'"
raise
argparse
.
ArgumentTypeError
(
msg
)
if
param
<
0
:
msg
=
f
"
error: argument --cutn must be a positive integer: invalid int value:
'
{
param
}
'"
raise
argparse
.
ArgumentTypeError
(
msg
)
return
param
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment