xinntao / Real-ESRGAN

Real-ESRGAN aims at developing Practical Algorithms for General Image/Video Restoration.
BSD 3-Clause "New" or "Revised" License
27.95k stars 3.51k forks source link

raise ValueError("Number of processes must be at least 1") #340

Open kongzhh1101 opened 2 years ago

kongzhh1101 commented 2 years ago

Can anyone help me, why is this?

┌─[Michael@code-me] - [~/Real-ESRGAN] - [Thu May 26, 00:40] └─[$]> python3 inference_realesrgan_video.py -i /Users/Michael/Downloads/aa.mp4 -n realesr-animevideov3 -s 2 --suffix outx2 Traceback (most recent call last): File "/Users/Michael/Real-ESRGAN/inference_realesrgan_video.py", line 362, in main()

File "/Users/Michael/Real-ESRGAN/inference_realesrgan_video.py", line 354, in main run(args)

File "/Users/Michael/Real-ESRGAN/inference_realesrgan_video.py", line 272, in run pool = ctx.Pool(num_process)

File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/context.py", line 119, in Pool return Pool(processes, initializer, initargs, maxtasksperchild,

File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/pool.py", line 205, in init raise ValueError("Number of processes must be at least 1")

ValueError: Number of processes must be at least 1`

pranathlcp commented 2 years ago

Did you find a solution for this issue?

zcaceres commented 2 years ago

Pretty sure this is caused when you run on a system with 0 gpus. The CUDA gpu count is 0 and is multiplied by the num_processes_for_gpu arg (1)... equal to 0.

Milor123 commented 2 years ago

What is the solution on windows?