Skip to content
Snippets Groups Projects
Commit 8a1ff38b authored by nina.marthe_ird.fr's avatar nina.marthe_ird.fr
Browse files

added a few progress bars

parent 22027111
No related branches found
No related tags found
No related merge requests found
from .Graph_gff import Segments, Features
from .Functions import *
from tqdm import tqdm
# outputs the gff line of the target genome for a feature occurence (a feature can be transfered at several positions)
......@@ -106,7 +107,7 @@ def transfer_on_target(segments_file, out_target_gff, out_var,out_aln,target_gen
reason_features_not_transfered=[0,0,0] # bad_size, absent_features, low_cov_id
diff_size_transfered_features=[0,0] # [count,sum], to get the average
for feat in list_feature_to_transfer:
for feat in tqdm(list_feature_to_transfer):
feature=Features[feat]
if feature.parent=="": # usually a gene
for match in feature.segments_list_target:
......@@ -149,7 +150,7 @@ def transfer_on_target(segments_file, out_target_gff, out_var,out_aln,target_gen
seg_seq=get_segments_sequence(segments_file,segments_list)
with open(out_var, 'w') as file_out_var:
for feat in list_feature_to_transfer:
for feat in tqdm(list_feature_to_transfer):
feature=Features[feat]
if feature.parent=="": # usually a gene
for match in feature.segments_list_target: # for all occurences of the gene
......@@ -163,7 +164,7 @@ def transfer_on_target(segments_file, out_target_gff, out_var,out_aln,target_gen
line="Sequence alignment generated from feature path comparison in pangenome graph. Made with GrAnnoT v1.\n\n"
file_out_aln.write(line)
for feat in list_feature_to_transfer:
for feat in tqdm(list_feature_to_transfer):
feature=Features[feat]
if feature.parent=="": # usually a gene
for match in feature.segments_list_target: # for all occurences of the gene
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment