Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Amandine PERRIN
pipeline_annotation
Commits
647a117b
Commit
647a117b
authored
Oct 05, 2021
by
Amandine PERRIN
Browse files
gff headers with 1 space instead of 2
parent
2c04051c
Pipeline
#66649
passed with stages
in 5 minutes and 38 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
PanACoTA/annotate_module/format_prodigal.py
View file @
647a117b
...
@@ -358,7 +358,7 @@ def create_gff(gpath, gff_file, res_gff_file, res_lst_file, contigs, sizes):
...
@@ -358,7 +358,7 @@ def create_gff(gpath, gff_file, res_gff_file, res_lst_file, contigs, sizes):
# open lst file to read all information saved from prodigal results
# open lst file to read all information saved from prodigal results
with
open
(
gff_file
,
'r'
)
as
gf
,
open
(
res_gff_file
,
"w"
)
as
rgf
,
open
(
res_lst_file
,
"r"
)
as
rlf
:
with
open
(
gff_file
,
'r'
)
as
gf
,
open
(
res_gff_file
,
"w"
)
as
rgf
,
open
(
res_lst_file
,
"r"
)
as
rlf
:
# Write headers of gff3 file
# Write headers of gff3 file
rgf
.
write
(
"##gff-version
3
\n
"
)
rgf
.
write
(
"##gff-version 3
\n
"
)
for
ori_name
,
new_name
in
contigs
.
items
():
for
ori_name
,
new_name
in
contigs
.
items
():
# Write the list of contigs, with their size
# Write the list of contigs, with their size
end
=
sizes
[
new_name
]
end
=
sizes
[
new_name
]
...
...
PanACoTA/annotate_module/format_prokka.py
View file @
647a117b
...
@@ -411,7 +411,7 @@ def generate_gff(gpath, prokka_gff_file, res_gff_file, res_lst_file, sizes, cont
...
@@ -411,7 +411,7 @@ def generate_gff(gpath, prokka_gff_file, res_gff_file, res_lst_file, sizes, cont
with
open
(
prokka_gff_file
,
"r"
)
as
prokf
,
open
(
res_lst_file
,
"r"
)
as
lstf
,
\
with
open
(
prokka_gff_file
,
"r"
)
as
prokf
,
open
(
res_lst_file
,
"r"
)
as
lstf
,
\
open
(
res_gff_file
,
"w"
)
as
gfff
:
open
(
res_gff_file
,
"w"
)
as
gfff
:
# Write headers of gff3 file
# Write headers of gff3 file
gfff
.
write
(
"##gff-version
3
\n
"
)
gfff
.
write
(
"##gff-version 3
\n
"
)
# Write all sequences with their size. Order by name in gembase format
# Write all sequences with their size. Order by name in gembase format
for
old
,
new
in
sorted
(
contigs
.
items
(),
key
=
lambda
items
:
items
[
1
]):
for
old
,
new
in
sorted
(
contigs
.
items
(),
key
=
lambda
items
:
items
[
1
]):
end
=
sizes
[
new
]
end
=
sizes
[
new
]
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment