def identify_many(scenes):
"""
return metadata handlers of all valid scenes in a list, similar to function identify
prints a progressbar
:param scenes: a list of file names
:return: a list of pyroSAR metadata handlers
"""
idlist = []
pbar = pb.ProgressBar(maxval=len(scenes)).start()
for i, scene in enumerate(scenes):
if isinstance(scene, ID):
idlist.append(scene)
else:
try:
id = identify(scene)
idlist.append(id)
except IOError:
continue
pbar.update(i + 1)
pbar.finish()
return idlist
评论列表
文章目录