kkiningh / ee364a-project

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Stantord EE364b Project (Spring 2018)

Kevin Kiningham

Dependencies

These directions have only been tested on Ubuntu 16.04 with SDK version 18.0.

Download and install the Intel FPGA SDK For OpenCL.

Install Eigen

sudo apt install libeigen3-dev

Install OpenCL headers (note that you may have to install additional drivers depending on your GPU).

sudo apt install opencl-headers clinfo

Install CMake

sudo apt get install cmake

Install Pipenv

pip install pipenv --user

Install all python dependencies by running pipenv inside of the project directory

pipenv install

Building

This project is distributed as a C++ python extension which can be built using the provided setup.py.

pipenv run python setup.py build

Code examples

import numpy as np
from accel import accel

L = np.load('KKT_Factorized_L.npz')
D = np.load('KKT_Factorized_D.npz')
runner = accel.Kernelrunner()

# Run the solver with a random initial trajectory for 35 iterations
x, w = runner.run(L, D, 35)

About


Languages

Language:C++ 81.6%Language:Python 15.2%Language:CMake 2.8%Language:C 0.2%Language:Shell 0.1%Language:Makefile 0.0%Language:Objective-C 0.0%