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

Compilation error during adaptive_gridsampler installation #25

Open
Subarasheese opened this issue May 9, 2023 · 0 comments
Open

Compilation error during adaptive_gridsampler installation #25

Subarasheese opened this issue May 9, 2023 · 0 comments

Comments

@Subarasheese
Copy link

Hello,

I am trying to build and run the CAR-pytorch project on my Arch Linux machine, but I am encountering compilation errors during the installation of the adaptive_gridsampler.

Here are the steps I have followed:

  1. Cloned the repository and navigated to the CAR directory.
  2. Entered the adaptive_gridsampler directory and attempted to run python3 setup.py build_ext --inplace.

Initially, I encountered an error related to an incompatible version of PyTorch. The project requires PyTorch 1.3.1, but it is not available through pip or conda for Python 3.8. I tried installing PyTorch 1.4.0, but the error persisted. I then created a conda environment with Python 3.7 and installed PyTorch 1.3.1, but the compilation error still occurred.

Here is the error message I received:

/home/myuser/.conda/envs/car-env/lib/python3.7/site-packages/torch/include/pybind11/cast.h: In function ‘typename pybind11::detail::type_caster<typename pybind11::detail::intrinsic_type<T>::type>::cast_op_type<T> pybind11::detail::cast_op(make_caster<T>&)’:
/home/myuser/.conda/envs/car-env/lib/python3.7/site-packages/torch/include/pybind11/cast.h:914:120: error: expected template-name before ‘<’ token
  914 |     return caster.operator typename make_caster<T>::template cast_op_type<T>();
      |                                                                                                                        ^
/home/myuser/.conda/envs/car-env/lib/python3.7/site-packages/torch/include/pybind11/cast.h:914:120: error: expected identifier before ‘<’ token
/home/myuser/.conda/envs/car-env/lib/python3.7/site-packages/torch/include/pybind11/cast.h:914:123: error: expected primary-expression before ‘>’ token
  914 |     return caster.operator typename make_caster<T>::template cast_op_type<T>();
      |                                                                                                                           ^
/home/myuser/.conda/envs/car-env/lib/python3.7/site-packages/torch/include/pybind11/cast.h:914:126: error: expected primary-expression before ‘)’ token
  914 |     return caster.operator typename make_caster<T>::template cast_op_type<T>();
      |                                                                                                                              ^
error: command '/opt/cuda/bin/nvcc' failed with exit code 1

I would appreciate any guidance or assistance in resolving this issue. If there are any updates or additional steps required for compatibility with the latest versions of the dependencies, please let me know.

Thank you in advance for your help.

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

No branches or pull requests

1 participant