Commit 9752ff84 by Celine Mercier

embl parser: information display about progress when parsing multiple

parent d99702f5
......@@ -169,9 +169,12 @@ def emblIterator_dir(dir_path,
path = dir_path
read = 0
for filename in glob.glob(os.path.join(path, b'*.dat*')):
read_files = 0
files = [filename for filename in glob.glob(os.path.join(path, b'*.dat*'))]
for filename in files:
if read==only:
print("Parsing file %s (%d/%d)" % (tostr(filename), read_files, len(files)))
f = uopen(filename)
if only is not None:
only_f = only-read
......@@ -180,6 +183,7 @@ def emblIterator_dir(dir_path,
for seq in emblIterator_file(f, skip=skip, only=only_f, buffersize=buffersize):
yield seq
def emblIterator(obj,
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment