Skip to main content

No project description provided

Project description

Redco: Distributed LLM training with a single line of code

Redco is a user-friendly toolkit for developing and scaling up Jax/Flax-based pipelines, where you can define your pipeline in a couple of functions, without concerning environmental issues, e.g., multi-host, parallelization for large dataset and large models, etc.

Features

  • Lightweight concepts: Redco only introduces three concepts: Deployer, Trainer, and Predictor. You can be an expert in a couple of minites!
  • Easy-to-use: Customize your pipeline with 4-5 functions, each with a handful of lines. Designing your pipeline is the only thing you need to take care with redco.
  • Automatic deployment: No need to take care of your multi-host or multi-device environment. Redco processes your environment automatically, as well as other pipeline-unrelated things, e.g., randomness, logging, etc.
  • Automatic model/data parallelism: No need to concern your large models and large datasets. Redco distributes your models and datasets to all your devices automatically.
  • Easy to migrate from PyTorch: No need to know complex Jax functions (e.g., pmap(), pjit(), etc.). Redco only needs a couple of numpy-like functions from you as your pipeline design.

Installation

Redco can be installed by

pip install redco

Make sure correct Jax version is installed according to your device.

Examples

Examples across a set of paradigms can be found in examples/, including

Exemplar large model settings

The table below shows runnable model LLM finetuning on different kinds of servers. Numbers inside the brackets are the maximum length in training. All the settings are with full precision (fp32) and Adam optimizer.

2 $\times$ 1080Ti
(2 $\times$ 10G)
4 $\times$ A100
(4 $\times$ 40G)
2 $\times$ TPU-v4
(2 hosts $\times$ 4 chips $\times$ 32G)
16 $\times$ TPU-v4
(16 hosts $\times$ 4 chips $\times$ 32G)
BART-Large (1024) LLaMA-7B (1024) T5-XL-11B (512) OPT-66B (512)
GPT2-Large (512) GPT-J-6B (1024) OPT-13B (1024)

Go to example/language_modeling and examples/text_to_text to try them out!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

redco-0.4.2.tar.gz (17.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

redco-0.4.2-py3-none-any.whl (26.2 kB view details)

Uploaded Python 3

File details

Details for the file redco-0.4.2.tar.gz.

File metadata

  • Download URL: redco-0.4.2.tar.gz
  • Upload date:
  • Size: 17.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.12

File hashes

Hashes for redco-0.4.2.tar.gz
Algorithm Hash digest
SHA256 5a9ff42dfb1535cc6e93d35203e0835f1436583ee41feba0e1b1f2f25dfce1eb
MD5 a9353e3c51d11505b1bfb72c983eb82c
BLAKE2b-256 cac1a00302dd942d24822f85f1e2e914a39388f3b7159be17345d8172000f80c

See more details on using hashes here.

File details

Details for the file redco-0.4.2-py3-none-any.whl.

File metadata

  • Download URL: redco-0.4.2-py3-none-any.whl
  • Upload date:
  • Size: 26.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.12

File hashes

Hashes for redco-0.4.2-py3-none-any.whl
Algorithm Hash digest
SHA256 fc66264106b73fc5717376418390040d9328e54c35b53812b1d5ebe40a858a04
MD5 3e6baba9c0d21cf6eca79adc6414434f
BLAKE2b-256 173cf65bfe91e3d1557efbda059d7e1a86bba4cf79cf2bf4e56a5e3f8b579195

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page