AIAny
AI Train2020
Icon for item

Tianshou

Deep reinforcement learning library on pure PyTorch and Gymnasium, with 30+ algorithms across on-policy, off-policy, and offline RL. Exposes both a one-call high-level interface and a procedural API, plus vectorized envs and reproducible MuJoCo benchmarks.

Introduction

Most reinforcement learning codebases force a trade-off: research frameworks expose every knob but bury you in boilerplate, while batteries-included libraries hide the algorithm so you can't actually modify it. The interesting move here is refusing that choice — the same 30+ algorithms are reachable through a one-call high-level interface or a fully procedural one where you wire up collector, buffer, and policy yourself.

What Sets It Apart
  • Two APIs, one engine: prototype with a high-level builder, then drop to the procedural layer when you need to control the training loop — without switching libraries.
  • Clean algorithm taxonomy: an explicit split between Algorithm and Policy, and between on-policy, off-policy, and offline families, makes it readable enough to fork rather than just consume.
  • Reproducibility as a feature: every algorithm ships with a full training test, and MuJoCo results are benchmarked to match published baselines — so a regression shows up in CI, not in your paper.
  • Built for real experiments: synchronous/asynchronous vectorized environments, EnvPool acceleration, multi-GPU training, RNN-style training for POMDPs, and multi-agent support.
Great Fit / Look Elsewhere

A great fit if you research or extend RL methods in pure PyTorch and want type-hinted, tested baselines you can read and modify — DQN variants, PPO/TRPO/SAC/TD3, and offline methods like CQL and BCQ are all in one place. Look elsewhere if you want single-file copy-paste implementations (CleanRL), large-scale distributed RL across a cluster (Ray RLlib), or JAX-level training throughput; Tianshou optimizes for clarity and breadth on a single machine, not horizontal scale.

Information

  • Websitegithub.com
  • OrganizationsTsinghua University, appliedAI Institute for Europe
  • Authorsthu-ml (Tsinghua University Machine Learning Group)
  • Published date2020/03/09

Categories

More Items

GitHub
AI Train2019

Train and experiment with multi-billion to trillion-parameter transformer models on large GPU clusters using GPU-optimized building blocks and reference training scripts; offers advanced parallelism and mixed-precision support for research teams and ML engineers.

GitHub
AI Train2026

Provides a one-command CLI to fine-tune and post-train LLMs, with layer streaming that lets an 8B model be fine-tuned on a 4 GB laptop GPU. Auto-configures quantization, LoRA adapters, batching and evaluation gates, and supports export and serving workflows.

GitHub
AI Train2025

A PyTorch DTensor-native SPMD library for training and fine-tuning LLMs, VLMs, diffusion and retrieval models. Integrates with Hugging Face for day-0 model support, provides YAML-driven recipes, DTensor/FSDP2 parallelism and NVIDIA-optimized kernels (Transformer Engine, DeepEP, FlexAttn).