Skip to content
Snippets Groups Projects
Commit e5ba3540 authored by Yohan Jarosz's avatar Yohan Jarosz
Browse files

check input data

parent 03475da6
No related branches found
No related tags found
No related merge requests found
......@@ -53,7 +53,9 @@ if __name__ == '__main__':
mt_data = [Path(p).abspath() for p in args['-t']]
# check paths
for pth in mg_data + mt_data:
print(pth)
if not pth.exists():
print("'%s' does not exist" % pth)
exit(1)
common_path = Path(os.path.commonprefix(mg_data + mt_data)).dirname()
# update data paths
mg_data = [p.partition(common_path)[-1][1:] for p in mg_data]
......
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