提交 a18fb6d6 编写于 作者: B Ben Hoff 提交者: Nikita Manovich

add robust JSON handeling for auto annotation runner (#758)

上级 a18e83ba
......@@ -70,7 +70,11 @@ def main():
return
with open(mapping_file) as json_file:
mapping = json.load(json_file)
try:
mapping = json.load(json_file)
except json.decoder.JSONDecodeError:
logging.critical('JSON file not able to be parsed! Check file')
return
try:
mapping = mapping['label_map']
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册