# KernelBook

- **ID:** 105
- **Kind:** dataset
- **URL:** https://huggingface.co/datasets/GPUMODE/KernelBook
- **Authors:** GPUMODE
- **Venue:** GPUMODE
- **Published:** 2025
- **Source:** huggingface
- **Language:** en
- **Access:** free
- **License:** other
- **License family:** Other (auto-classified)
- **Added:** 2026-07-17
- **Verified:** 2026-07-17
- **Research status:** done
- **Page:** https://papers.projxon.ai/entries/105

## Summary

`dataset_permissive{.json/.parquet}` is a curated collection of pairs of pytorch programs and equivalent triton code (generated by torch inductor) which can be used to train models to translate pytorch code to triton code.

## Attributes

- **Scale:** 10K<n<100K
- **Time period:** created 2025-03-14; updated 2026-06-09
- **Author type:** unknown

## From the source (fetched 2026-10-03)

- **Repository:** GPUMODE/KernelBook (Hugging Face)
- **Created:** Mar 14, 2025 (Hugging Face)
- **Last updated:** Jun 9, 2026 (Hugging Face)
- **Downloads (last month):** 242 (Hugging Face)
- **Likes:** 57 (Hugging Face)
- **Size:** 10K to 100K rows (Hugging Face)
- **Modalities:** text (Hugging Face)
- **Formats:** parquet (Hugging Face)

## Dataset profile

- **Scale:** Hub datasets-server: 18,162 train rows / 12 columns; size_categories 10K<n<100K. Parquet download_size 87,425,771 bytes (~87.4 MB); uncompressed dataset_size 400,578,833 (~400.6 MB). JSON twin dataset_permissive.json 416.4 MB. Hub usedStorage 604,388,003 bytes (~604.4 MB). Hub 829 downloads / 57 likes at check.
- **Format:** parquet (dataset_permissive.parquet) and JSON (dataset_permissive.json). Columns: entry_point, original_triton_code, python_code, triton_code, repo_name, module_name, synthetic, uuid, licenses, stars, sha, repo_link.
- **Type:** Paired code corpus / PyTorch→Triton kernel translation
- **License:** June 9 Researcher Reciprocity License v1.0 (card license:other). Broad reuse with attribution; Training Use of covered AI models requires reciprocal generation access ("If you train on it, you let us generate."). Upstream per-repo licenses in `licenses` still apply. Not a standard OSI license.
- **Cost:** Free
- **Languages:** English 100% (card language:en) plus Python/Triton source. Comments inherit GitHub-repo language mix; not quantified. No LID table.
- **Modality:** Text-only (Python + Triton source). No PTX/cubin binaries in the schema.
- **Domain:** GPU kernels; PyTorch nn.Module to Triton translation; compiler-generated kernels; KernelBench-style code
- **Time period:** HF createdAt 2025-03-14; lastModified 2026-06-09 (Researcher Reciprocity license v1.0 dated 2026-06-09). Citation month May 2025. Triton generated with PyTorch 2.5.0 inductor. Source repos/hashes from The Stack v1 GitHub snapshot, not a live crawl.
- **Purpose:** Train models to translate PyTorch modules into equivalent Triton kernels
- **Used for:** GPU Mode / popcorn-kernels research and KernelBench-format kernel generation. Hub 829 downloads / 57 likes at check. Discord posted the HF URL. Sibling GPUMODE/pytorch_scrape_inductor_data is gated=manual — skipped; this is the public permissive slice.
- **Authors:** Public GitHub authors on permissively licensed PyTorch repos (MIT/Apache-2.0/BSD/MPL/Unlicense/zlib listed). Curated by Sahan Paliskara and Mark Saroufim (GPU Mode). Triton is TorchInductor output, not human-written kernels. `synthetic` bool column marks some rows.
- **Bias:** Stack v1 GitHub PyTorch modules that compiled and unit-tested, not general CUDA/Triton. Permissive-license subset only. Popular/starred repos overweighted (`stars` column). Inductor/PyTorch 2.5.0 kernel style, not hand-tuned kernels. KernelBench format transform. Parent bigcode/the-stack remains gated — this derived slice is public.
- **Text quality:** Extracted torch.nn modules with generated unit tests; modules that could not be tested were dropped. Triton from torch.compile then rewritten toward KernelBench format. Residual compiler boilerplate and version-locked kernels (card: use PyTorch 2.5.0 to run). Not independently re-executed here.
- **Sample size:** Single default train 18,162. No official val/test or language configs. JSON and parquet are the same permissive set. Gated siblings (pytorch_scrape_inductor_data, synthetic_data) are not this file.
- **Long context:** No (single-module Python/Triton pairs; not full-repo context).
- **Intermediate steps:** Yes (Stack v1 repo+hash collection; nn.Module extraction; unit-test generation; torch.compile Triton; KernelBench-style rewrite; license/star/SHA metadata). Scripts: github.com/pytorch-labs/popcorn-kernels/tree/main/github_pytorch_index.
- **Idea quality:** High
- **Novelty:** High (public paired PyTorch/Triton kernel dump in KernelBench format)
- **Text conversion:** Ready parquet; load_dataset('GPUMODE/KernelBook') or pandas.read_parquet. ~87.4 MB parquet / ~416 MB JSON.
- **Collection method:** Download
- **Static:** Unknown (HF lastModified 2026-06-09 is a license refresh; code snapshot is one-shot Stack v1 / PyTorch 2.5.0)
- **Processed:** Unknown

## Links

- Dataset: https://huggingface.co/datasets/GPUMODE/KernelBook
- Related: https://huggingface.co/datasets/GPUMODE/KernelBook
- Related: https://github.com/pytorch-labs/popcorn-kernels
- Related: https://github.com/ScalingIntelligence/KernelBench
- Related: https://huggingface.co/datasets/bigcode/the-stack

## Research notes

- downloads=378; likes=56
- Discord posted this HF pointer (message 1428356240630747206). gated=false; public; CuratorBote listed dataset_permissive.parquet and .json. Parent bigcode/the-stack remains gated and was skipped; this permissive inductor slice is the public dump. Do not catalog gated GPUMODE/pytorch_scrape_inductor_data. Cite Paliskara and Saroufim 2025 KernelBook. Not in papers_local.csv.

## Related entries

- Related: [The Stack](https://papers.projxon.ai/entries/92) (dataset, #92)
- Related: [GPUMODE/KernelBook](https://papers.projxon.ai/entries/1173) (dataset, #1173)

## Similar entries

- [High-Coder-Reasoning-Multi-Turn](https://papers.projxon.ai/entries/324) (dataset, #324)
- [One Search, Two Layers: Compiler Controls Inside PyTorch Helion Using NVIDIA CompileIQ](https://papers.projxon.ai/entries/1419) (post, #1419)
- [CUDA-Agent-Ops-6K](https://papers.projxon.ai/entries/239) (dataset, #239)
- [RLVR_Coding_Problems](https://papers.projxon.ai/entries/207) (dataset, #207)
