I downloaded ultrlytics (master branch) and modified line 35
modules.add_module('BatchNorm2d', nn.BatchNorm2d(filters, momentum=0.1))
to
modules.add_module('batchnorm%d' % i, nn.BatchNorm2d(filters))
I used the unpruned weights provided and the cfg and ran
python3.7 prune.py
I get following error:
ayer: 121 convolutional
layer: 122 convolutional
layer: 123 convolutional
layer: 124 convolutional
layer: 125 yolo
Traceback (most recent call last):
File "prune.py", line 389, in
opt.perlayer_ratio,
File "prune.py", line 270, in test
pruned_model = Darknet(output_cfg_path, img_size).to(device)
File "/src/slimyolov3/ktian/yolov3/models.py", line 199, in init
self.module_defs = parse_model_cfg(cfg)
File "/src/slimyolov3/ktian/yolov3/utils/parse_config.py", line 22, in parse_model_cfg
mdefs[-1][key] = np.array([float(x) for x in val.split(',')]).reshape((-1, 2)) # np anchors
File "/src/slimyolov3/ktian/yolov3/utils/parse_config.py", line 22, in
mdefs[-1][key] = np.array([float(x) for x in val.split(',')]).reshape((-1, 2)) # np anchors
ValueError: could not convert string to float: ' [[ 10 13]'
I have no name!@6558fd4db45e:/src/slimyolov3/ktian/yolov3$ ValueError: could not convert string to float:
bash: ValueError:: command not found
I downloaded ultrlytics (master branch) and modified line 35 modules.add_module('BatchNorm2d', nn.BatchNorm2d(filters, momentum=0.1)) to modules.add_module('batchnorm%d' % i, nn.BatchNorm2d(filters))
I used the unpruned weights provided and the cfg and ran python3.7 prune.py
I get following error:
ayer: 121 convolutional layer: 122 convolutional layer: 123 convolutional layer: 124 convolutional layer: 125 yolo Traceback (most recent call last): File "prune.py", line 389, in
opt.perlayer_ratio,
File "prune.py", line 270, in test
pruned_model = Darknet(output_cfg_path, img_size).to(device)
File "/src/slimyolov3/ktian/yolov3/models.py", line 199, in init
self.module_defs = parse_model_cfg(cfg)
File "/src/slimyolov3/ktian/yolov3/utils/parse_config.py", line 22, in parse_model_cfg
mdefs[-1][key] = np.array([float(x) for x in val.split(',')]).reshape((-1, 2)) # np anchors
File "/src/slimyolov3/ktian/yolov3/utils/parse_config.py", line 22, in
mdefs[-1][key] = np.array([float(x) for x in val.split(',')]).reshape((-1, 2)) # np anchors
ValueError: could not convert string to float: ' [[ 10 13]'
I have no name!@6558fd4db45e:/src/slimyolov3/ktian/yolov3$ ValueError: could not convert string to float:
bash: ValueError:: command not found