GithubHelp home page GithubHelp logo

huifu1018 / accelerator-k8s Goto Github PK

View Code? Open in Web Editor NEW

This project forked from kaist-ncl/accelerator-k8s

0.0 0.0 0.0 3.76 MB

Kubernetes device plugin supporting FPGA and other accelerators

License: BSD 3-Clause "New" or "Revised" License

Makefile 4.68% Go 92.15% Dockerfile 3.17%

accelerator-k8s's Introduction

Accelerator-K8S

Accelerator-K8S is a device plugin works with Accelerator-Docker

Getting Started

Dependencies

Installation

  • Deploy as a daemonset (Recommended)
kubectl create -f https://raw.githubusercontent.com/KAIST-NCL/Accelerator-K8S/master/acc-k8s.yml

OR

  • Install manually by cloning and building
$ git clone https://github.com/KAIST-NCL/Accelerator-K8S.git
$ cd Accelerator-K8S
$ make
$ sudo make install

$ out/acc-k8s

for every node

How to Use

Prerequisites

First, you need to make sure that you installed Accelerator-Docker properly.

  • default-runtime of docker daemon should be set to acc-runtime. Check /etc/docker/daemon.json
  • In Accelerator-Docker setting(/etc/accelerator-docker/device.pbtxt), accelerator type should be named following kubernetes resourece naming rule. Refer to this.

Enabling Accelerators in Containers

You can require your accelerators as a resource like below:

apiVersion: v1
kind: Pod
metadata:
  name: demo-pod
spec:
  containers:
    - name: demo-container
      image: ubuntu:16.04
      resources:
        limits:
          {ACCELERATOR_TYPE}: 1

'Accelerator type' is configured in Accelerator-Docker configuration file and you can check it by using acc-manager list command

  • Example)
$ acc-manager list
+------------+--------------+------------------------+----------------+----------------+----------+
|     ID     |     Name     |          Type          |    PCI-Slot    |     Status     |  Holder  |
+------------+--------------+------------------------+----------------+----------------+----------+
| 234750     | QuadroM2000  | nvidia.com/gpu         | 0000:02:00.0   | Available      | 0        |
| 1121730    | KCU-1500     | xilinx.fpga/kcu-1500   | 0000:01:00.0   | Available      | 0        |
+------------+--------------+------------------------+----------------+----------------+----------+

If you want to use KCU-1500 for your pod, you can set container limit as follows.

  containers:
    - name: demo-container
      image: ubuntu:16.04
      resources:
        limits:
          xilinx.fpga/kcu-1500: 1

Authors

KAIST NCL

License

This project is released under the BSD-3-Clause, see LICENSE for more information.

Acknowledgement

This work was supported by 'The Cross-Ministry Giga KOREA Project' grant funded by the Korea government (MSIT) (No.GK19P0400, Development of Mobile Edge Computing Platform Technology for URLLC Services)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.