update parse_model_cfg() (#350)
Removing the two lines for adding batch_normalize key to convolutional layers causes the parsing of the model to break when parsing it in models.py
This commit is contained in:
parent
c1bb037cbe
commit
b202baa31c
|
@ -9,6 +9,8 @@ def parse_model_cfg(path):
|
||||||
if line.startswith('['): # This marks the start of a new block
|
if line.startswith('['): # This marks the start of a new block
|
||||||
module_defs.append({})
|
module_defs.append({})
|
||||||
module_defs[-1]['type'] = line[1:-1].rstrip()
|
module_defs[-1]['type'] = line[1:-1].rstrip()
|
||||||
|
if module_defs[-1]['type'] == 'convolutional':
|
||||||
|
module_defs[-1]['batch_normalize'] = 0
|
||||||
else:
|
else:
|
||||||
key, value = line.split("=")
|
key, value = line.split("=")
|
||||||
value = value.strip()
|
value = value.strip()
|
||||||
|
|
Loading…
Reference in New Issue