What problem does it solve? Writing raw PyTorch training loops requires repetitive boilerplate for device management, distributed synchronization, checkpointing, and logging, which introduces bugs and slows down experimentation. ## Core Features & Use Cases - Structured Training Loops: Organize model code into LightningModule with training_step, validation_step, and configure_optimizers while the Trainer handles epochs, devices, and logging. - Distributed Training: Switch between single GPU, multi-GPU DDP, FSDP, and DeepSpeed ZeRO with a single strategy parameter, including multi-node and SLURM cluster support. - Callbacks and Tuning: Use ModelCheckpoint, EarlyStopping, and LearningRateMonitor callbacks, plus integrations with Ray Tune, Optuna, and WandB sweeps for hyperparameter search. - Use Case: Convert an existing PyTorch image classifier into a LightningModule, then scale it from one GPU to eight GPUs with DDP and automatic checkpointing by changing only the Trainer configuration. ## Quick Start Convert my PyTorch training script into a PyTorch Lightning module and train it on two GPUs with validation and early stopping.