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
09f9e758
Commit
09f9e758
authored
5 years ago
by
Amandine PERRIN
Browse files
Options
Downloads
Patches
Plain Diff
Complete docstring on parameter types
parent
7595475f
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
PanACoTA/utils.py
+5
-4
5 additions, 4 deletions
PanACoTA/utils.py
with
5 additions
and
4 deletions
PanACoTA/utils.py
+
5
−
4
View file @
09f9e758
...
@@ -1084,9 +1084,9 @@ def get_genome_contigs_and_rename(gembase_name, gpath, outfile):
...
@@ -1084,9 +1084,9 @@ def get_genome_contigs_and_rename(gembase_name, gpath, outfile):
Returns
Returns
-------
-------
tuple
tuple
- List of all contigs with their original and new name:
- List of all contigs with their original and new name:
(list of str)
[
"
contig1
'
\t
'
orig_name1
"
,
"
contig2
'
\t
'
orig_name2
"
...]
[
"
contig1
'
\t
'
orig_name1
"
,
"
contig2
'
\t
'
orig_name2
"
...]
- List of all contigs with their size:
- List of all contigs with their size:
(list of str)
[
"
contig1
'
\t
'
size1
"
,
"
contig2
'
\t
'
size2
"
...]
[
"
contig1
'
\t
'
size1
"
,
"
contig2
'
\t
'
size2
"
...]
"""
"""
# Initialize variables
# Initialize variables
...
@@ -1095,9 +1095,9 @@ def get_genome_contigs_and_rename(gembase_name, gpath, outfile):
...
@@ -1095,9 +1095,9 @@ def get_genome_contigs_and_rename(gembase_name, gpath, outfile):
contig_num
=
1
contig_num
=
1
# contig size
# contig size
cont_size
=
0
cont_size
=
0
# List of contigs [<name>\t<orig_name>]
# List of contigs
(str)
[<name>\t<orig_name>]
contigs
=
[]
contigs
=
[]
# List of contigs with their sizes [<name>\t<size>]
# List of contigs
(str)
with their sizes [<name>\t<size>]
sizes
=
[]
sizes
=
[]
# Name of previous contig (to put to contigs, as we need to wait for the next
# Name of previous contig (to put to contigs, as we need to wait for the next
# contig to know the size of the previous one)
# contig to know the size of the previous one)
...
@@ -1124,6 +1124,7 @@ def get_genome_contigs_and_rename(gembase_name, gpath, outfile):
...
@@ -1124,6 +1124,7 @@ def get_genome_contigs_and_rename(gembase_name, gpath, outfile):
contigs
.
append
(
cor
)
contigs
.
append
(
cor
)
grf
.
write
(
cont
)
grf
.
write
(
cont
)
grf
.
write
(
seq
)
grf
.
write
(
seq
)
prev_cont
=
"
>
"
+
gembase_name
+
"
.
"
+
str
(
contig_num
).
zfill
(
4
)
prev_cont
=
"
>
"
+
gembase_name
+
"
.
"
+
str
(
contig_num
).
zfill
(
4
)
prev_orig_name
=
line
prev_orig_name
=
line
contig_num
+=
1
contig_num
+=
1
...
...
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