FlashAttention is a high-performance deep learning optimization library that reimplements the attention mechanism used in transformer models to be significantly faster and more memory-efficient than standard implementations. It achieves this by using IO-aware algorithms that minimize memory reads and writes, reducing the quadratic memory overhead typically associated with attention operations. The project provides implementations of FlashAttention, FlashAttention-2, and newer iterations optimized for modern GPU architectures such as NVIDIA Hopper and AMD accelerators. By improving both forward and backward pass efficiency, it enables training and inference of large language models with longer sequence lengths and higher throughput. The library integrates with PyTorch and supports various attention configurations, including causal masking, multi-query attention, and rotary embeddings.

Features

  • Memory-efficient attention with linear scaling instead of quadratic overhead
  • High-performance GPU kernels optimized for CUDA and ROCm
  • Support for FlashAttention-2 and newer optimized implementations
  • Integration with PyTorch and modern transformer architectures
  • Support for causal masking, rotary embeddings, and advanced attention types
  • Enables faster training and inference for large-scale AI models

Project Samples

Project Activity

See All Activity >

Categories

Machine Learning

License

BSD License

Follow FlashAttention

FlashAttention Web Site

Other Useful Business Software
Already Paying for an RMM? Get 50% Off Splashtop AEM Icon
Already Paying for an RMM? Get 50% Off Splashtop AEM

Switch to Splashtop AEM and save up to 50% in your first year

Automated OS and third-party patching for Windows and macOS, CVE prioritization with AI patch summaries, and built-in remote control that also supports Linux. Qualifying organizations switching from another RMM get up to 50% off year one.
Get Started
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of FlashAttention!

Additional Project Details

Operating Systems

Linux, Mac, Windows

Programming Language

Python

Related Categories

Python Machine Learning Software

Registered

2026-03-18