facebookresearch / nougat

Implementation of Nougat Neural Optical Understanding for Academic Documents
https://facebookresearch.github.io/nougat/
MIT License
8.81k stars 561 forks source link

Could not load library libcudnn_cnn_infer.so.8. #115

Closed KangWooLee closed 1 year ago

KangWooLee commented 1 year ago

Hi, I am using WSL2 with Python 3.11, and I am facing the error when I run nougat FILE -o OUTFOLDER.


/home/USERNAME/miniconda3/envs/ENVNAME/lib/python3.11/site-packages/torch/functional.py:504: UserWarning: torch.meshgrid: in an upcoming release, it will be required to pass the indexing argument. (Triggered internally at ../aten/src/ATen/native/TensorShape.cpp:3483.) return _VF.meshgrid(tensors, **kwargs) # type: ignore[attr-defined] 0%| | 0/1 [00:00<?, ?it/s]Could not load library libcudnn_cnn_infer.so.8. Error: libcuda.so: cannot open shared object file: No such file or directory Aborted

What should I do to resolve this issue?

Also, when I tried to run Nougat in Python 3.7 or 3.8, I faced different types of issues. What is the lowest Python version is available? Our server has very old Python version with many apps already, so I wish I can stick to older version of Python if possible.

lukas-blecher commented 1 year ago

Duplicate of #105 python 3.9 is officially supported but I don't know how far down you can go. The newer the better I guess 3.8 should work as well, I think but haven't tested it

KangWooLee commented 1 year ago

I had to create a link to /usr/lib/wsl/lib/libcuda.so.1 in .local/lib/pythonx.xx/site-packages/nvidia/cudnn/lib/ directory, where libcudnn_cnn_infer.so.8 was found to make it work. -> Could you help me to clarify what this means? I see libcuda.so.1 in that folder and I see nvidia/cudnn/lib directory too. Thank you.