keras-team/keras

Deep Learning for humans

What it solves

Keras 3 solves the problem of framework lock-in by allowing developers to build and train deep learning models that are not tied to a single underlying engine. It enables you to write code once and run it on top of JAX, TensorFlow, or PyTorch, letting you choose the backend that provides the best performance or ecosystem for your specific project.

How it works

Keras 3 acts as a high-level interface that sits on top of different deep learning backends. You configure your preferred backend (JAX, TensorFlow, PyTorch, or OpenVINO for inference) via an environment variable or a configuration file before importing the library. Because it is designed to be backend-agnostic, you can use your existing data pipelines—whether they are TensorFlow tf.data.Dataset or PyTorch DataLoaders—and even integrate Keras models directly into native PyTorch or JAX workflows.

Who it’s for

It is designed for developers and researchers who want to build deep learning solutions—such as computer vision, natural language processing, or forecasting models—without being restricted to one framework. It is ideal for those who want to switch between the performance of JAX, the production ecosystem of TensorFlow, or the debugging experience of PyTorch without rewriting their model code.

Highlights

  • Multi-backend support: Run the same code on JAX, TensorFlow, PyTorch, or OpenVINO.
  • High-performance: Achieve significant speedups by selecting the optimal backend for your specific architecture.
  • Scalable: Train models seamlessly on everything from a local laptop to large clusters of GPUs or TPUs.
  • Future-proof: Avoid framework lock-in by keeping your model definitions independent of the underlying engine.
  • Backwards compatible: Works as a drop-in replacement for existing tf.keras code.

Related

  • Project
  • Dispatch
  • Project
  • Project
  • Project