Process object has no attribute '_popen'

ShellCollector發表於2019-03-06

 

object has no attribute '_popen'

 

Traceback (most recent call last):
  File "E:/project/CV_client_new190222/py_client/algorithm/detect_process.py", line 154, in <module>
    frcnn_process.start()
  File "D:\ProgramData\Miniconda3\envs\python3.6\lib\multiprocessing\process.py", line 99, in start
    assert self._popen is None, 'cannot start a process twice'
AttributeError: 'Detect_process' object has no attribute '_popen'

Process finished with exit code 1

 

原因:少了程式碼:super().__init__()

加上即可。

class Detect_process(Process):
    def __init__(self, q_in,q_out,process_mode = 0,gpu_perc = 0.1):
        super().__init__()

相關文章