Open avidale opened 1 year ago
@gwenzek Hi, thank you for reporting the issue. I tried to reproduce this, but I couldn't. Can you also confirm this?
Hi @hirofumi0810, please re-run this notebook, it does reproduce the issue. https://colab.research.google.com/drive/1erS7TRgZDzk1u8LTMdoBIvbqU2BOdo-c?usp=sharing
@avidale Thank you for sharing the notebook with me. But I was able to run the notebook without any error...
@avidale @hirofumi0810 I can confirm this error pops out. If anyone encounters it, it can be solved by adding fairseq to python path, like following:
import sys
sys.path.append("/usr/local/lib/python3.7/dist-packages/fairseq") # or where fairseq repository is kept
Note that the path where fairseq repository is kept may differ if you use different ways to download/install and different python version,etc.
So there was time I did not have to append the path. But now this appending becomes a must to me.
I realized that if instead of installing fairseq
from the git repository, you do pip install fairseq
, it runs without any errors
🐛 Bug
When importing anything from the main branch of Fairseq, an error occurs.
To Reproduce
Install fresh Fairseq
then try importing from it
Result:
Expected behavior
The import succeeds.
Environment
main
pip
, source):pip install 'git+https://github.com/facebookresearch/fairseq.git'
Additional context
NA