Giter Site home page Giter Site logo

baberabb / cookbook Goto Github PK

View Code? Open in Web Editor NEW

This project forked from eleutherai/cookbook

0.0 0.0 0.0 261 KB

Deep learning for dummies. All the practical details and useful utilities that go into working with real models.

License: Apache License 2.0

Python 74.12% HTML 13.93% Makefile 0.03% C++ 10.21% C 0.69% Cuda 0.90% Jupyter Notebook 0.11% Shell 0.01%

cookbook's Introduction

The Cookbook

Deep learning for dummies, by Quentin Anthony, Jacob Hatef, Hailey Schoelkopf, and Stella Biderman

All the practical details and utilities that go into working with real models! If you're just getting started, we recommend jumping ahead to Basics for some introductory resources on transformers.

Table of Contents

Utilities

Calculations

For training/inference calculations (e.g. FLOPs, memory overhead, and parameter count)

Useful external calculators include

Cerebras Model Lab. User-friendly tool to apply Chinchilla scaling laws.

Transformer Training and Inference VRAM Estimator by Alexander Smirnov. A user-friendly tool to estimate VRAM overhead.

Benchmarks

Communication benchmarks

Transformer sizing and GEMM benchmarks

Reading List

Basics

LLM Visualizations. Clear LLM visualizations and animations for basic transformer understanding.

Annotated PyTorch Paper Implementations

Jay Alammar's blog contains many blog posts pitched to be accessible to a wide range of backgrounds. We recommend his posts the Illustrated Transformer, and the Illustrated GPT-2 in particular.

The Annotated Transformer by Sasha Rush, Austin Huang, Suraj Subramanian, Jonathan Sum, Khalid Almubarak, and Stella Biderman. A walk through of the seminal paper "Attention is All You Need" along with in-line implementations in PyTorch.

How to do LLM Calculations

Transformers Math 101. A blog post from EleutherAI on training/inference memory estimations, parallelism, FLOP calculations, and deep learning datatypes.

Transformer Inference Arithmetic. A breakdown on the memory overhead, FLOPs, and latency of transformer inference

LLM Finetuning Memory Requirements by Alex Birch. A practical guide on the memory overhead of finetuning models.

Distributed Deep Learning

Everything about Distributed Training and Efficient Finetuning by Sumanth R Hegde. High-level descriptions and links on parallelism and efficient finetuning.

Efficient Training on Multiple GPUs by Hugging Face. Contains a detailed walk-through of model, tensor, and data parallelism along with the ZeRO optimizer.

Papers

Best Practices

ML-Engineering Repository. Containing community notes and practical details of everything deep learning training led by Stas Bekman

Common HParam Settings by Stella Biderman. Records common settings for model training hyperparameters and her current recommendations for training new models.

Data and Model Directories

Directory of LLMs by Stella Biderman. Records details of trained LLMs including license, architecture type, and dataset.

Data Provenance Explorer A tool for tracing and filtering on data provenance for the most popular open source finetuning data collections.

Minimal Repositories for Educational Purposes

Large language models are frequently trained using very complex codebases due to the need to optimize things to work at scale and support a wide variety of configurable options. This can make them less useful pedagogical tools, so some people have developed striped-down so-called "Minimal Implementations" that are sufficient for smaller scale work and more pedagogically useful.

GPT Inference

GPT Training

Architecture-Specific Examples

RWKV

Contributing

If you found a bug, typo, or would like to propose an improvement please don't hesitate to open an Issue or contribute a PR.

Cite As

If you found this repository helpful, please consider citing it using

@misc{anthony2024cookbook,
    title = {{The EleutherAI Model Training Cookbook}},
    author = {Anthony, Quentin and Hatef, Jacob and Schoelkopf, Hailey and Biderman, Stella},
    howpublished = {GitHub Repo},
    url = {https://github.com/EleutherAI/cookbook},
    year = {2024}
}

cookbook's People

Contributors

haileyschoelkopf avatar jahatef avatar quentin-anthony avatar stas00 avatar stellaathena avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.