Skip to content
An algorithm that approximates an orthogonal matrix with few-factor Givens factorization.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
CMakeLists.txt
LICENSE
README.md
coordinate_descent.py
example.py
givens.py
givens_gpu.cpp
givens_gpu.cu
pip_requirements.txt
test_givens_gpu.py
util.cu
util.h
util.py

README.md

Approximating Orthogonal Matrices with Effective Givens Factorization

This is an implementation of the algorithms analyzed in our ICML 2019 paper:

Approximating Orthogonal Matrices with Effective Givens Factorization (Thomas Frerix, Joan Bruna; ICML 2019)

The core algorithm is written in C++/CUDA and interfaces with python through pybind11.

Installation

  1. Make sure you have a running Python 3 (tested with Python 3.7) ecosytem, e.g. through conda, and an Nvidia GPU (tested with CUDA 9.0 on a Titan X).
  2. Install the python dependencies via pip install -r pip_requirements.txt.
  3. Install CUB (tested with 1.8.0) and Eigen3 (tested with 3.2).
  4. Specify the environment variables CUB_INCLUDE_DIR to the CUB library and PYBIND_INDLUDE_DIR to the python library path of your installation that includes pybind11 (installed as a python package).
  5. Run cmake . and make to compile the code.
  6. Run the end-to-end tests by calling pytest test_givens_gpu.py -v -s.

Example

The file example.py contains an example of factorizing an orthogonal matrix with various algorithms, which are explained and discussed in the paper.

You can’t perform that action at this time.