sniklaus / 3d-ken-burns

an implementation of 3D Ken Burns Effect from a Single Image using PyTorch
Other
1.52k stars 225 forks source link

IndexError: index 0 is out of bounds for dimension 0 with size 0 #55

Closed sp8va100 closed 3 years ago

sp8va100 commented 3 years ago

Hi, thanks for you incredible work.

autozoom.py works well for me in most of images. However, I met the below question by inputting this image

Traceback (most recent call last):
  File "autozoom.py", line 76, in <module>
    process_load(npyImage, {})
  File "<string>", line 10, in process_load
  File "<string>", line 64, in disparity_adjustment
IndexError: index 0 is out of bounds for dimension 0 with size 0

Python version

Python 3.8.10

The package list I have installed


Package                Version
---------------------- ---------
certifi                2021.10.8
charset-normalizer     2.0.7
click                  8.0.3
cupy                   9.5.0
decorator              4.4.2
fastrlock              0.8
Flask                  2.0.2
gevent                 21.8.0
greenlet               1.1.2
h5py                   3.5.0
idna                   3.3
imageio                2.9.0
imageio-ffmpeg         0.4.5
itsdangerous           2.0.1
Jinja2                 3.0.2
MarkupSafe             2.0.1
moviepy                1.0.3
numpy                  1.21.3
opencv-python-headless 4.5.4.58
Pillow                 8.4.0
pip                    21.2.4
proglog                0.1.9
requests               2.26.0
scipy                  1.7.1
setuptools             58.1.0
torch                  1.10.0
torchvision            0.11.1
tqdm                   4.62.3
typing-extensions      3.10.0.2
urllib3                1.26.7
Werkzeug               2.0.2
wheel                  0.37.0
zope.event             4.5.0
zope.interface         5.4.0
sniklaus commented 3 years ago

Thanks for reporting this and for making it easy for me to replicate this error! Fixed with the newest commit. :+1:

https://user-images.githubusercontent.com/1238034/139136315-61051669-c6c7-4b77-8647-deae8933ca9f.mp4