Skip to content

Installation and Setup 🛠️

Installation 📥

Pyro-NN works with PyTorch and TensorFlow. This guide focuses on PyTorch.

Requirements:

  • Microsoft Visual Studio (for self-build) 💻
  • Microsoft Visual C++ 14.0+
  • Python packagebuild🐍
  • CUDA >10.2 🚀

Once all of these requirements are fulfilled, follow these steps::

  • Clone the repo and switch to the develop branch if not done yet:

    git checkout develop
    

  • Modify TOML file if needed; please make sure the torch version in TOML file is the same as your environment, or DLL errors will occur:

     requires = ["setuptools==69.5.1",
               "ninja",
               "tensorflow[and-cuda]==2.11.1",
               "--extra-index-url https://download.pytorch.org/whl/cu118",
               "torch==2.3.0+cu118",
       ]
    

  • Run the command:

    python -m build . 
    

  • Switch to the newly created sub-directory dist

    cd dist/ 
    

  • Build the wheel file using the following command:

    pip install pyronn-(*version_number*).whl
    

Note

    If necessary, you can modify the `pyproject.toml` file to specify a 
    particular torch version. However, be cautious and only make changes 
    if you are confident in what you are doing!

If you encounter a problem during installation, have a look at our wiki: https://github.com/csyben/PYRO-NN/wiki