Giter VIP home page Giter VIP logo

deepspeed-kernels's Introduction

License Apache 2.0 PyPI version

DeepSpeed Kernels

DeepSpeed-Kernels is a backend library that is used to power DeepSpeed-FastGen to achieve accelerated text-generation inference through DeepSpeed-MII. This library is not intended to be an independent user package, but is open-source to benefit the community and show how DeepSpeed is accelerating text-generation.

The resulting binaries that are compiled from this repo and included in the PyPI release are torch and python agnostic, this allows the core backend to be as portable as possible and leaves the task of compiling torch and python bindings to DeepSpeed itself using it's JIT op builder.

Installation

PyPI

If your environment supports it you can quickly install DeepSpeed-Kernels from PyPI (see below). We've tested the portability of the PyPI release on A100, A6000, and H100.

The release on PyPI should work with the following assumptions about your environment:

  • NVIDIA GPU(s) with compute capability of: 8.0, 8.6, 8.9, 9.0
  • CUDA 11.6+
  • Ubuntu 20+
pip install deepspeed-kernels

Source

If the PyPI release does not work for you we recommend installing from source which can take several minutes:

pip install -v .

Advanced

You can create a pre-compiled portable wheel that supports different CUDA architectures via the CUDA_ARCH_LIST environment variable. By default the kernels will be compiled using the native compute capability. If you want to compile for more than one you can set the CUDA_ARCH_LIST environment variable. We currently only support Ampere and above architectures (i.e., 8.0+). See example below to build for GPUs like A100 and A6000:

CUDA_ARCH_LIST="80;86;89;90" python setup.py bdist_wheel

deepspeed-kernels's People

Contributors

cmikeh2 avatar jeffra avatar loadams avatar mrwyattii avatar microsoft-github-operations[bot] avatar microsoft-github-policy-service[bot] avatar

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.