YOLOv3-model-pruning
YOLOv3-model-pruning copied to clipboard
test_prune.py进行剪枝时出错,求助
RuntimeError: An attempt has been made to start a new process before the current process has finished its bootstrapping phase.
This probably means that you are not using fork to start your
child processes and you have forgotten to use the proper idiom
in the main module:
if __name__ == '__main__':
freeze_support()
...
The "freeze_support()" line can be omitted if the program
is not going to be frozen to produce an executable.
Detecting objects: 0%| | 0/37 [00:04<?, ?it/s] Detecting objects: 0%| | 0/37 [00:00<?, ?it/s]
没找到该在哪里修改
添加一个if name == 'main':就可以了 官方文档
一样的问题,请问解决了吗
一样的问题,请问解决了吗
把test_prune.py里面除了import的代码全放在def main():里,然后在最下面添加 if name == 'main': main()
一样的问题,请问解决了吗
把test_prune.py里面除了import的代码全放在def main():里,然后在最下面添加 if name == 'main': main()
非常感谢,解决了