mirror of
https://github.com/PaddlePaddle/PaddleOCR.git
synced 2026-09-24 23:33:08 +08:00
dump model structure
This commit is contained in:
@@ -75,6 +75,8 @@ class AttrDict(dict):
|
||||
|
||||
global_config = AttrDict()
|
||||
|
||||
default_config = {'Global': {'debug': False, }}
|
||||
|
||||
|
||||
def load_config(file_path):
|
||||
"""
|
||||
@@ -85,6 +87,7 @@ def load_config(file_path):
|
||||
|
||||
Returns: global config
|
||||
"""
|
||||
merge_config(default_config)
|
||||
_, ext = os.path.splitext(file_path)
|
||||
assert ext in ['.yml', '.yaml'], "only support yaml files for now"
|
||||
merge_config(yaml.load(open(file_path), Loader=yaml.Loader))
|
||||
|
||||
Reference in New Issue
Block a user