cuda-kernels

Build and benchmark CUDA kernels for NVIDIA GPUs in HuggingFace workflows.

Updated Apr 14, 2026
One-click install
npx skills add https://github.com/dotruru/claudemd --skill cuda-kernels-dotruru
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cuda-kernels
Source: https://github.com/dotruru/claudemd/tree/main/skills/cuda-kernels
Command: npx skills add https://github.com/dotruru/claudemd --skill cuda-kernels-dotruru

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires diffusers, transformers, accelerate, torch, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill provides patterns and guidance for developing optimized CUDA kernels for NVIDIA GPUs, enabling benchmarking, integration with HuggingFace Kernels Hub, and diffusers/transformers workflows.

Core Features & Use Cases

  • Patterns and templates for RMSNorm, RoPE, GEGLU, AdaLN, and other CUDA kernels aimed at accelerating diffusion models and large language models.
  • Benchmarking scripts and end-to-end usage demos to measure performance improvements against baselines.
  • Guides for integrating with HuggingFace Kernels Hub and with diffusers pipelines (Video/Image generation) and transformers models.
  • Includes example scripts, integration references, and build instructions to reproduce results locally.

Quick Start

Run the quick demo by executing scripts/benchmark_example.py to benchmark optimized versus baseline kernels.

Frequently Asked Questions about cuda-kernels

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build and optimize CUDA kernels for HuggingFace diffusers and transformers?

You build and optimize CUDA kernels for NVIDIA GPUs by applying provided patterns for RMSNorm, RoPE, and GEGLU, then integrating them directly into HuggingFace diffusers and transformers workflows using included scripts and references.

Can I benchmark custom CUDA kernels against baseline implementations for NVIDIA GPUs?

Yes, you can benchmark custom CUDA kernels against baselines by executing scripts such as benchmark_example.py, which measures performance improvements for optimized kernels targeting BF16, FP16, and FP32 workloads.

Does this CUDA kernel optimization skill support multi-arch GPU builds for H100, A100, and T4?

Yes, the CUDA kernel optimization requires multi-arch builds supporting NVIDIA H100, A100, and T4 GPUs, ensuring reproducible workflows across different hardware architectures via Nix or pip environments.

What CUDA kernel patterns are available for accelerating diffusion models and large language models?

Available CUDA kernel patterns include RMSNorm, RoPE, GEGLU, and AdaLN, specifically aimed at accelerating diffusion models and large language models within your HuggingFace transformers and diffusers pipelines.

How do I integrate optimized CUDA kernels with the HuggingFace Kernels Hub?

You integrate optimized CUDA kernels with the HuggingFace Kernels Hub by following included guides and integration references, enabling seamless deployment of your custom kernels into diffusers video and image generation pipelines.

What dependencies do I need to run optimized CUDA kernels with HuggingFace transformers?

You need diffusers, transformers, accelerate, and torch dependencies installed to run optimized CUDA kernels with HuggingFace transformers, ensuring proper BF16, FP16, and FP32 tensor operations across supported NVIDIA GPUs.