I encountered a problem while installing pip install pytorch-nlp.
The error is as follows:
ERROR: Could not install packages due to an OSError: [Errno 2] No such file or directory: 'c:\users\pcpcpc\anaconda3\envs\pytorch\lib\site-packages\numpy-1.21`.2.dist-info\METADATA'
So I tried to reinstall numpy by running:
pip install --force-reinstall --no-deps numpy==1.21.2
But I get the error:
ERROR: Cannot uninstall numpy 1.21.2, RECORD file not found. You might be able to recover from this via: 'pip install --force-reinstall --no-deps numpy==1.21.2'.
ERROR: Could not install packages due to an OSError: [Errno 2] No such file or directorywhere I had to enable Windows Long Path Support. After enabling the long path support, I removed every numpy file and directory inside thesite-packagesof the virtual environment and reinstalled numpy, which then worked. I'm not 100% sure the problems are related, but they might be. Maybe also numpy was installed for a previous python version which I didn't want to use for the virtual env.