Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to install dependencies #10

Open
piyush-bagad opened this issue Jun 20, 2020 · 8 comments · May be fixed by #33
Open

Unable to install dependencies #10

piyush-bagad opened this issue Jun 20, 2020 · 8 comments · May be fixed by #33

Comments

@piyush-bagad
Copy link

On running conda env create -f environment.yml, I am getting the following error:

Collecting package metadata: done
Solving environment: failed

ResolvePackageNotFound:
  - pytorch3d=0.2.0

I tried with pip but that throws up error on this line from pytorch3d import _C.

@ranahanocka
Copy link
Owner

Hi @piyush-bagad ,

It seems you need update the conda package manager (which is a good idea in general).

I think if you run this
conda update -c defaults conda

it will solve your problem. In general, you can check the version with conda -V. I am using conda 4.8.3.

@piyush-bagad
Copy link
Author

Thanks @ranahanocka for the response. I updated to version 4.8.3

However, the problem still is not solved.

Collecting package metadata (repodata.json): done
Solving environment: failed

ResolvePackageNotFound:
  - pytorch3d=0.2.0

=>  point2mesh (master) $ conda -V
conda 4.8.3

@piyush-bagad
Copy link
Author

I tried using pip but get this error:

(sample) =>  point2mesh (master) $ python
Python 3.7.7 (default, Mar 10 2020, 15:43:03)
[Clang 11.0.0 (clang-1100.0.33.17)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import pytorch3d
>>> from pytorch3d import _C
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: dlopen(/Users/piyushbagad/virtual_environments/sample/lib/python3.7/site-packages/pytorch3d/_C.cpython-37m-darwin.so, 2): Library not loaded: @rpath/libc10.dylib
  Referenced from: /Users/piyushbagad/virtual_environments/sample/lib/python3.7/site-packages/pytorch3d/_C.cpython-37m-darwin.so
  Reason: image not found
>>> import torch
>>> from pytorch3d import _C
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: dlopen(/Users/piyushbagad/virtual_environments/sample/lib/python3.7/site-packages/pytorch3d/_C.cpython-37m-darwin.so, 2): Library not loaded: @rpath/libtorch_cpu.dylib
  Referenced from: /Users/piyushbagad/virtual_environments/sample/lib/python3.7/site-packages/pytorch3d/_C.cpython-37m-darwin.so
  Reason: image not found
>>>

@piyush-bagad
Copy link
Author

I think there is some problem with pytorch3d==0.2.0. I am getting the same issue with conda environment

(pytorch3d) =>  point2mesh (master) $ python
Python 3.8.3 (default, May 19 2020, 13:54:14)
[Clang 10.0.0 ] :: Anaconda, Inc. on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import pytorch3d
>>> from pytorch3d import _C
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: dlopen(/usr/local/anaconda3/envs/pytorch3d/lib/python3.8/site-packages/pytorch3d/_C.cpython-38-darwin.so, 2): Library not loaded: @rpath/libc10.dylib
  Referenced from: /usr/local/anaconda3/envs/pytorch3d/lib/python3.8/site-packages/pytorch3d/_C.cpython-38-darwin.so
  Reason: image not found
>>>

@ranahanocka
Copy link
Owner

Hi @piyush-bagad ,

So it seems you are using a mac, which according to the pytorch3d installation instructions should be done with pip.

Unfortunately, I don't have a mac so I can't reproduce your issue. But there is a mention of this issue in PyTorch 3D with some potential work arounds. If the issue persists, maybe you can open an issue in PyTorch3D.

@pocaha
Copy link

pocaha commented Jul 1, 2020

Dear @ranahanocka,

first and foremost, thank you very much for the code and congrats for the interesting work.
I am using windows and have the same problems as @piyush-bagad. I updated conda many times. I think it is a problem with PyTorch3D as you said...

@ranahanocka
Copy link
Owner

Hi @pocaha (and @piyush-bagad ),

I think it may be an issue with pytorch e.g.,. Maybe you can try installing the nightly version .

With conda : conda install -c pytorch pytorch-nightly

with pip (for macos, without cuda support):
pip install --pre torch torchvision -f https://download.pytorch.org/whl/nightly/cpu/torch_nightly.html

(reference)

@jrmh96
Copy link

jrmh96 commented Jul 3, 2021

For anyone still struggling w. this on MacOS, I am on Big Sur and got it to work by using python venv and using following versions:
torch 1.5.0
torchvision 0.5.0
pytorch3d 0.2.0

@smokhov smokhov linked a pull request Mar 27, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants