ApX logoApX logo
CalculatorCoursesPricing

Gemma 4 E2B

Open Source
Open Weights

Parameters

5.1B

Context Length

128K

Modality

Multimodal

Auxiliary Parameters

400M

Architecture

Dense

KV Cache Rate

35 KB/tok

License

Apache 2.0

Release Date

2 Apr 2026

Knowledge Cutoff

-

API Pricing (per 1M)

Self-hosted only

Hardware & System Requirements

Precision

Context

Workload Memory: 5.15 GB

vLLM

INT4 · 8K context · 1 user

Base Weights: 2.37 GB

KV Cache: 0.27 GB

Runtime & Graphs: 2.50 GB

Minimum Required Hardware

1x NVIDIA L4 24GB

vLLM

5.1 / 21.6 GB

1x RTX 3060 12GB

llama.cpp

5.1 / 11.2 GB

Apple M4 24GB

llama.cpp

5.1 / 18.0 GB

Determine requirements for concurrent users or multi-node clusters:

Runtime compatibility

Verified on hardware and checkpoint files.

Checkpoint format

FP16

CUDA

>= 11.8

PyTorch

>= 2.1

Transformers

>= 5.5.0.dev0

ArchitecturePrecisionAttention kernel

Blackwell, Hopper

Native FP16

FlashAttention-3

Ada Lovelace, Ampere

Native FP16

FlashAttention-2

Architecture Diagram

Input TokensToken EmbeddingPosition: RoPEHidden: 6.1k · Context: 128K · Vocab: 262.1kx 35 layersRMSNormPre-AttentionGrouped-Query Attention8Q / 1KV heads · SW: 512Head dim: 256+RMSNormPre-FFNFeed-Forward NetworkGELUIntermediate: 6.1k+Final RMSNormOutput Logits

Evaluation Benchmarks

Rank

#203

BenchmarkScoreRank

Professional Knowledge

MMLU Pro

0.6

#55

Graduate-Level QA

GPQA

0.434

#112

Intelligence Index

Artificial Analysis
auto

0.08

Standard

0.07

#281

#307

Coding Index

Archived
Artificial Analysis

0.07

#151

Rankings

Overall Rank

#203

Coding Rank

-

About Gemma 4 E2B

Gemma 4 E2B is an ultra-efficient model with 2.3B effective parameters (5.1B with Per-Layer Embeddings) designed for mobile and IoT devices. Supports text, image, and audio input with 128K context window, delivering frontier capabilities on edge devices with near-zero latency and offline operation. Features built-in reasoning mode and native function calling for agentic workflows.

Specifications

Attention

Attention Structure

Grouped-Query Attention

Attention Heads

8

Key-Value Heads

1

Attention Head Dimension

256

Position Embedding

ROPE

RoPE Theta

10,000

Sliding Window Attention

Yes

Sliding Window Size

512

Sliding Window Ratio

83.3%

Normalization

RMS Normalization

Activation Function

GELU

Dimensions

Base Precision

FP16

Auxiliary Parameters

400M

Hidden Dimension Size

6,144

Number of Layers

35

FFN Intermediate Size (Dense)

6,144

Tokenizer

Vocabulary Size

262,144

About Gemma 4

Gemma 4 is Google DeepMind's most advanced open model family, built from Gemini 3 research and technology. Featuring both Dense and Mixture-of-Experts (MoE) architectures, these multimodal models handle text, images, and audio (on smaller variants), with context windows up to 256K tokens. Designed for frontier-level performance across reasoning, coding, and agentic workflows, Gemma 4 delivers unprecedented intelligence-per-parameter from mobile devices to enterprise servers. Released under Apache 2.0 license.


Other Gemma 4 Models