explaingit

oneflow-inc/oneflow

9,395C++Audience · researcherComplexity · 4/5LicenseSetup · hard

TLDR

OneFlow is a deep learning framework that trains AI models across multiple GPUs or machines automatically, with a PyTorch-compatible API and a Global Tensor abstraction that hides distributed complexity.

Mindmap

mindmap
  root((oneflow))
    What it does
      Distributed AI training
      PyTorch-compatible API
      Global Tensor abstraction
    Key features
      Multi-GPU multi-machine
      Graph Compiler for deploy
    Companion libs
      Libai for Transformers
      FlowVision for vision
    Setup
      pip install
      Docker images
      Source build on Linux
    Audience
      AI researchers
      ML engineers
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Train large AI models across multiple GPUs or machines using familiar PyTorch-style code with no manual distribution logic.

USE CASE 2

Speed up or prepare a trained model for production deployment using the built-in Graph Compiler.

USE CASE 3

Train large Transformer models like BERT or GPT in parallel using the companion Libai library.

USE CASE 4

Run computer vision experiments at scale using the FlowVision companion library.

Tech stack

C++PythonCUDADockerpip

Getting it running

Difficulty · hard Time to first run · 1h+

Requires Nvidia GPU with specific CUDA versions for GPU-accelerated training, CPU-only package available via pip.

Apache 2.0, use freely for any purpose including commercial projects, just keep the license notice.

In plain English

OneFlow is a deep learning framework built for training AI models at scale. It is designed to feel familiar to anyone who has used PyTorch, but adds built-in support for running training jobs across many machines or GPUs at once. The framework is developed by OneFlow Inc in collaboration with Zhejiang Lab, and is released under the Apache 2.0 license. The main feature that sets OneFlow apart from other deep learning frameworks is something called Global Tensor, which lets a developer write model code as if all the data fits on one device, while the framework handles spreading the work across multiple GPUs or machines automatically. There is also a Graph Compiler that can speed up or prepare a trained model for deployment, similar to how some other frameworks offer a static computation mode alongside their normal dynamic one. Installation is straightforward using pip. The simplest path is to run a single pip install command, and there are separate packages for CPU-only use and for systems with Nvidia GPU hardware. Docker images are also available with everything pre-configured. Building from source is possible but requires a Linux system, specific CUDA versions for GPU support, and a handful of system libraries. The README links to a companion library called Libai for training large Transformer-style models such as BERT and GPT in parallel, and to FlowVision for computer vision tasks. Both are separate repositories maintained by the same team. Documentation, an API reference, and a quickstart guide are available at docs.oneflow.org.

Copy-paste prompts

Prompt 1
I want to train a BERT model across 4 GPUs using OneFlow. Show me how to define the model using Global Tensor so the distribution is handled automatically.
Prompt 2
Convert a PyTorch training script to OneFlow, what API changes are needed and how do I enable multi-GPU training?
Prompt 3
Set up a OneFlow training environment with CUDA support using the official Docker image and run a simple MNIST example.
Prompt 4
Use OneFlow's Graph Compiler to export a trained model for faster inference, walk me through the steps from training to compiled deployment.
Prompt 5
Compare OneFlow's Global Tensor approach to PyTorch's DistributedDataParallel for a team choosing a distributed training framework.
Open on GitHub → Explain another repo

← oneflow-inc on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.