Skip to content

Windows installation / Kaolin Issue #2

Open

Description

@atonalfreerider

Thank you for such a wonderful research contribution in the area of Human Motion Reconstruction.

I am attempting a Windows installation of MultiPly and am documenting my installation progress here. I have encountered an issue with Kaolin. MultiPly requires Kaolin 0.13.0.

I'm following these instructions:
https://kaolin.readthedocs.io/en/latest/notes/installation.html

Installing with:

pip install kaolin==0.13.0 -f https://nvidia-kaolin.s3.us-east-2.amazonaws.com/torch-1.12.1_cu113.html

results in a "successful" install, but a failed compilation. This error results after running multiply/code python train.py

    from kaolin import _C
ImportError: DLL load failed: The specified module could not be found.

Installing Kaolin from source with

python setup.py develop

fails because CUDA cannot be found. I have CUDA 11.8 per the requirements. The same ImportError: DLL load failed occurs when I run train.py. I tried conda install -c nvidia cuda-python==11.8.0 but this has issues finding Visual Studio build tools, and am not sure if I'm running down a rabbit hole there.

This is an old issue ticket for the import _C dll issue:
NVIDIAGameWorks/kaolin#140

Other preparations/modifications I had to implement:
-Visual Studio with Python, C++ tools, Windows 10 SDK
-MSVC v141 VS 2017 C++ x64/x86 build tools (v14.16) for Kaolin
-must install pytorch with cuda support:
conda install pytorch torchvision torchaudio pytorch-cuda=11.8 -c pytorch -c nvidia
-Cython incompatibility. Had to enforce:
cython==0.29.20
-had to install pytorch3d while in multiply env
-had to uninstall marshmallow and reinstall
-had to install chardet
pip install chardet

Running on Windows 10, with CUDA 11.8 SDK, and a NVIDIA GeForce RTX 2080 Ti

Thank you for your help

Activity

  1. jzr99 commented on Jun 21, 2024

    @jzr99
    Collaborator

    Hi,

    What if you try to install a compatible version of pytorch and kaolin with CUDA 11.8 to avoid installing from source.

    For example, install

    # For CUDA 11.8
    conda install pytorch==2.0.1 torchvision==0.15.2 torchaudio==2.0.2 pytorch-cuda=11.8 -c pytorch -c nvidia
    pip install kaolin==0.15.0 -f https://nvidia-kaolin.s3.us-east-2.amazonaws.com/torch-2.0.1_cu118.html
    

    Although we do not test our code with CUDA 11.8 and pytorch 2.0.1, but I assume the results should be similar.

  2. atonalfreerider commented on Jun 21, 2024

    @atonalfreerider
    Author

    Thank you, there are other incompatibilities with python 3.7 in these cases:

    Could not solve for environment specs
    The following packages are incompatible
    ├─ pin-1 is installable and it requires
    │  └─ python 3.7.* , which can be installed;
    └─ torchvision 0.15.2  is not installable because there are no viable options
       ├─ torchvision 0.15.2 would require
       │  └─ python >=3.10,<3.11.0a0 , which conflicts with any installable versions previously reported;
       ├─ torchvision 0.15.2 would require
       │  └─ python >=3.11,<3.12.0a0 , which conflicts with any installable versions previously reported;
       ├─ torchvision 0.15.2 would require
       │  └─ python >=3.8,<3.9.0a0 , which conflicts with any installable versions previously reported;
       └─ torchvision 0.15.2 would require
          └─ python >=3.9,<3.10.0a0 , which conflicts with any installable versions previously reported.
    
    Pins seem to be involved in the conflict. Currently pinned specs:
     - python 3.7.* (labeled as 'pin-1')
    

    EDIT:
    Installing with Python 3.10 is proceeding. I'm working on getting Pytorch3D reinstalled

    multiply/
    conda install pytorch==2.0.1 torchvision==0.15.2 torchaudio==2.0.2 pytorch-cuda=11.8 -c pytorch -c nvidia
    pip install kaolin==0.15.0 -f https://nvidia-kaolin.s3.us-east-2.amazonaws.com/torch-2.0.1_cu118.html
    
    pip install -r requirements.txt
    
    conda install -c fvcore -c iopath -c conda-forge fvcore iopath
    conda install -c bottler nvidiacub
    
    pytorch3d/ pip install -e .
    

    I encountered this error, and installed CUB_HOME even though this is deprecated:
    https://stackoverflow.com/questions/62304087/installing-pytorch3d-fails-with-anaconda-and-pip-on-windows-10

    Currently having an issue compiling pytorch3d, even though this wasn't a problem before.

  3. jzr99 commented on Jun 22, 2024

    @jzr99
    Collaborator

    Hi,

    I'll be on vacation till July 1st. If it is possible, we highly recommend you trying to install those dependencies and run our code on a Linux-like system. We currently do not have a Windows PC to test the compatibility of the dependencies.

  4. assigned and unassigned on Jun 22, 2024
  5. atonalfreerider commented on Jun 26, 2024

    @atonalfreerider
    Author

    I was able to get everything running on Ubuntu 24. I made upgrades for CUDA 11.8 and Python 3.10. Please see my fork here:
    https://github.com/atonalfreerider/MultiPly/tree/cuda-11.8

    I had to use GCC v 10 (not v 11) to get the Kaolin and Pytorch3d binaries to compile. I might see if I can get this to work for Windows as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions