Skip to content
Last Dictionary

Triton

proper noun/TRY-tun/Also: OpenAI Triton, Triton language, Triton kernel

In plain wordsA free language from OpenAI for writing the fast inner routines of AI programs in Python-style code; its compiler handles hardware details that Nvidia's own tools leave to experts.

  1. 1

    Programming language

    An open-source, Python-embedded language and compiler for writing GPU kernelskernel, n.: A word with several AI meanings: a similarity measure used by some learning methods; a small grid of numbers that scans an image inside a neural network; or a small program that runs on a GPU. at the level of blocks (tiles) of data rather than individual threads. The programmer writes a kernel as operations on whole tiles (loads, matrix multipliesmatrix multiplication, n.: The rule for combining two grids of numbers into a new grid by repeatedly multiplying rows by columns. It is the single calculation AI chips spend most of their time doing., reductions) and leaves the low-level decisions, such as when to use tensor corestensor core, n.: A small, specialized part of an AI chip that does one job — multiplying small blocks of numbers together — far faster than ordinary circuits can., how work is scheduled, how threads share on-chip memory and how global-memory accesses are combined, to the compiler, which generates code for Nvidia, AMD and other accelerators through the MLIR and LLVM compiler frameworks. Fused, high-performance kernels for attention, normalization or quantizedquantization, n.: Storing an AI model's numbers with fewer digits, like rounding prices to the nearest dollar, so the model takes less memory and runs faster, usually with only a small loss of accuracy. matrix multiplication can thus be written in tens of lines rather than hundreds of lines of CUDACUDA, prop. n.: Nvidia's software system for programming its graphics chips to do general calculations. Most AI software is built on it, which is a big reason Nvidia chips dominate AI.. Triton is the default code generator of PyTorchPyTorch, prop. n.: The most widely used free software toolkit for building and training neural networks, especially in research; programmers write ordinary Python and it handles the calculus and the graphics chips.'s TorchInductor compiler (PyTorch 2.0, 2023) and is widely used for research kernels, making it a key route to hardware portability.

    We wrote the fused attention kernel in Triton, and it ran within 10% of the hand-tuned CUDA version.

  2. 2

    Inference serving

    Short for Nvidia's Triton Inference Server, an open-source system for serving models from many frameworks with dynamic batching and multi-GPU support, since rebranded as NVIDIA Dynamo-Triton. It is unrelated to the language despite the shared name.

Origin

Created by Philippe Tillet as a Harvard graduate student and described with H. T. Kung and David Cox at the MAPL workshop in 2019. OpenAI, which hired Tillet, released Triton 1.0 on 28 July 2021, claiming FP16 matrix-multiply kernels that matched cuBLAS in under 25 lines of code.

Related

See also
  • CUDACUDA, prop. n.: Nvidia's software system for programming its graphics chips to do general calculations. Most AI software is built on it, which is a big reason Nvidia chips dominate AI.
  • AI compilerAI compiler, n.: Software that translates an AI model into efficient instructions for a specific chip, rearranging and combining its calculations so the hardware is used as fully as possible.
  • kernel fusionkernel fusion, n.: Merging several small calculation steps into one, so a chip finishes them in a single pass instead of saving and reloading data in between, like cooking at the counter without returning ingredients to the fridge after each step.
  • FlashAttentionFlashAttention, prop. n.: A faster way for AI chips to compute attention, the step in which a language model relates every word to every other. It gets exactly the same answer while moving far less data around the chip.
  • PyTorchPyTorch, prop. n.: The most widely used free software toolkit for building and training neural networks, especially in research; programmers write ordinary Python and it handles the calculus and the graphics chips.
  • ROCmROCm, prop. n.: AMD's free, open-source software for programming its graphics and AI chips — its answer to Nvidia's CUDA, letting AI software run on AMD hardware.

Sources

  1. Tillet, P., Kung, H. T. & Cox, D. (2019). Triton: An Intermediate Language and Compiler for Tiled Neural Network Computations. Proceedings of MAPL 2019.
  2. Tillet, P. (2021). Introducing Triton: Open-source GPU programming for neural networks. OpenAI blog. openai.com/index/triton

Mentioned in

CUDACUDA, prop. n.: Nvidia's software system for programming its graphics chips to do general calculations. Most AI software is built on it, which is a big reason Nvidia chips dominate AI., kernelkernel, n.: A word with several AI meanings: a similarity measure used by some learning methods; a small grid of numbers that scans an image inside a neural network; or a small program that runs on a GPU., model servingmodel serving, n.: Running a trained AI model as a live service, so that apps and people can send it requests and get answers back quickly, reliably and at a sensible cost., PyTorchPyTorch, prop. n.: The most widely used free software toolkit for building and training neural networks, especially in research; programmers write ordinary Python and it handles the calculus and the graphics chips., AI compilerAI compiler, n.: Software that translates an AI model into efficient instructions for a specific chip, rearranging and combining its calculations so the hardware is used as fully as possible., kernel fusionkernel fusion, n.: Merging several small calculation steps into one, so a chip finishes them in a single pass instead of saving and reloading data in between, like cooking at the counter without returning ingredients to the fridge after each step., ROCmROCm, prop. n.: AMD's free, open-source software for programming its graphics and AI chips — its answer to Nvidia's CUDA, letting AI software run on AMD hardware., XLAXLA, abbr.: A compiler from Google that turns AI programs into fast code for chips such as TPUs and GPUs, mainly by merging many small steps into fewer, bigger ones.