ChenyangLEI / deep-video-prior

[NeurIPS 2020] Blind Video Temporal Consistency via Deep Video Prior
323 stars 39 forks source link

attempt to get argmax of an empty sequence #19

Open semel1 opened 2 years ago

semel1 commented 2 years ago

Upon running "main_IRT.py", got an error:

Exception has occurred: ValueError
attempt to get argmax of an empty sequence
  File "D:\colorization\deep-video-prior-master-pytorch\main_IRT.py", line 49, in <module>
    for x in subprocess.Popen("nvidia-smi -q -d Memory | grep -A4 GPU | grep Free", shell=True, stdout=subprocess.PIPE).stdout.readlines()]))

Happened in both Windows 10 and WSL2 Nvidia RTX 3090

Jdavidmn commented 8 months ago

I fixed this issue by changing the first grep command, resulting in this:

"nvidia-smi -q -d Memory | grep -A5 GPU | grep Free"

Edit: Apparently in my case the nvidia-smi command gives one more row of information so the 'Free' row is left out

This is the output when using this command nvidia-smi -q -d Memory | grep -A5 GPU:

Attached GPUs                             : 1
GPU 00000000:02:00.0
    FB Memory Usage
        Total                             : 20480 MiB
        Reserved                          : 1812 MiB
        Used                              : 0 MiB
        Free                              : 18667 MiB