Skip to main content

Group equivariant neural network library

Project description

GElib

GElib is a C++/CUDA library for building equivariant neural networks. The library can be used as a pure C++ library or as a C++ extension for PyTorch. GElib uses cnine as its backend. Documentation for the C++ API can be found in the 'doc' directory. Documentation for the PyTorch API is at https://risi-kondor.github.io/GElib/.

GElib is released under a combination of the Mozilla Public License v. 2.0. and a custom noncommercial license to be found in the file NONCOMMERCIAL.TXT. The latter also applies to the cnine component. Commercial use requires a licence from the author(s).

Default installation as a PyTorch C++ extension

GElib is distributed in source code format, therefore to install it as a C++ extension you must have a working C++ compiler supporting C++17 (or higher) on your system (GCC or clang recommended). You also need PyTorch. If these requirements are satified, in most cases GElib can be installed simply by running

   pip install gelib

or

   pip3 install gelib

Installation with CUDA support

Compiling GElib with CUDA enabled is more complicated because it also requires the CUDA development environment to be present on your system. Further, you must use the same CUDA version as the version that PyTorch was compiled against. If, for example, your PyTorch needs CUDA 12.6, which is installed at /usr/local/cuda-12.6, you need to point the installation script to it with

   export CUDA_HOME="/usr/local/cuda-12.6"

To compile with CUDA enabled you must also set

   export WITH_CUDA="TRUE"

before running pip install gelib command.

Fallback installation method as a C++ extension

The fallback installation method is to clone the library with

   git clone --recurse-submodules git@github.com:risi-kondor/GElib.git

and install it manually by running

   pip install -e . --no-build-isolation

in its root directory. The --recurse-submodules flag ensures that a copy of cnine is bundled inside the GElib directory structure. The --no-build-isolation flag forces GElib to be built using versions of PyTorch etc. already present in your environment rather than temporary versions downloaded during the build process. This can help avoid version conflicts. The CUDA component of the library is enabled the same way as in the default installation method.

Credits

Lead developer: Risi Kondor

Contributors: Erik Henning Thiede, Ryan Keane

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gelib-0.2.7.tar.gz (227.2 kB view details)

Uploaded Source

File details

Details for the file gelib-0.2.7.tar.gz.

File metadata

  • Download URL: gelib-0.2.7.tar.gz
  • Upload date:
  • Size: 227.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.6

File hashes

Hashes for gelib-0.2.7.tar.gz
Algorithm Hash digest
SHA256 0b460d5925804743fd522ef270ef4b3a1a8a6b66a14210c4a806daefe4d8c23d
MD5 3c9e1e004de494c788dd6b551cfea73a
BLAKE2b-256 ab4c58ee75ed278686893c63aaff66169a3911f5398f97d9ca8294282de21739

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page