On-Device AI on Android: What an NPU Actually Does

19 mins.21k

A spec sheet says 40 TOPS. Your OCR model still takes 400 ms and warms the back of the tablet.

Both numbers are true. The gap between them is the whole story of on-device AI — and it is not a marketing problem, it is an engineering one.

Where on-device AI runs: the NPU inside a modern Android SoC

This article explains what the silicon can do, what the software layer actually lets you use, and which workloads waste the hardware. If you are specifying an Android handheld, tablet or kiosk for computer vision or speech, this is the part that decides whether the project ships on time.

TIP

New global site. Our online tools are currently in Chinese while we finish the English build — it’s landing in the next few weeks. In the meantime, tell us what you need and we’ll set up a fast, tailored version for you: sales@happylab.me.

What “on-device AI” actually means

On-device AI means the model runs on the same processor that drives the screen. No round trip to a server. That single architectural choice changes five things that matter in the field:

Property Cloud inference On-device inference
Latency 100 ms – 2 s, varies with signal 50 – 300 ms, stable
Offline operation Stops working Keeps working
Data exposure Images and text leave the device Nothing leaves the device
Cost Per call, grows with volume Fixed at purchase
Reliability Depends on a network and a backend you maintain Depends on one device

For a phone that summarises messages, these are conveniences. For a production line that inspects 2,000 labels an hour, they are the difference between a working system and a support ticket.

Four compute units, four jobs

Every modern Android SoC contains the same four kinds of silicon. Vendors bundle them under names like “AI Engine” or “AI performance”, which is why the marketing reads the same across very different chips.

Unit Good at Weak at, for AI Analogy
CPU Branching, control flow, small irregular work Parallel throughput; matrix maths is wasteful A specialist with only two hands
GPU Wide parallel floating point Power draw; poor at staying resident A large crowd — fast, loud, thirsty
DSP Fixed-point signal work: audio, image, sensors Narrow programming model A dedicated assembly line for a few steps
NPU Matrix multiply, convolution, quantised fixed point Anything irregular; unsupported operators A machine tool — fast when the die fits

The important consequence is not which unit is “fastest”. It is that a real model is a mixture, and the runtime decides which unit executes which part.

When the NPU cannot execute an operator, it hands that subgraph back to the CPU. This is called fallback. It does not raise an error, it does not log a warning by default, and the app keeps working — just slowly. Measure the assignment per layer before you believe any speed claim, including your own.

Why TOPS does not compare

TOPS means trillions of operations per second. Three things make the number incomparable across vendors.

1. Precision changes the number by multiples. The same NPU might quote 40 TOPS at INT8, 10 TOPS at FP16, and refuse FP32 entirely. “100 TOPS” without a precision is not a specification.

2. Quantisation legally buys multipliers. Current flagship NPUs support INT4, INT2 and even 1.58-bit formats. Fewer bits per operation means more operations per second from the same circuit. That is real acceleration, not a trick — but it means two vendors can quote very different TOPS for hardware of similar size.

3. Most models never reach peak. Peak throughput needs large, contiguous matrices. Real models are full of transposes, reshapes, normalisation and non-maximum suppression. Those either run on the CPU or leave the NPU waiting on memory.

A detail worth noticing

At its September 2025 summit, Qualcomm announced the Snapdragon 8 Elite Gen 5 and did not publish an absolute TOPS figure for the phone chip. It published relative numbers instead: the Hexagon NPU is 37% faster than the previous generation with 16% better performance per watt.

In the same keynote, the laptop chip — Snapdragon X2 Elite — was given a clean 80 TOPS.

That is a deliberate choice, and it tells you something useful: when absolute numbers stop flattering, vendors switch to percentages. For anyone specifying hardware, the practical rule is simple. Ignore the headline. Measure milliseconds and milliwatts on your own model.

What the current silicon looks like

Qualcomm: from Hexagon 690 to fused AI

The Hexagon line has been the AI block in Snapdragon for years. Hexagon 690, for example, shipped in the Snapdragon 855 generation around 2019 and was quoted at roughly 7 TOPS. Successive generations raised that by an order of magnitude, and the 8-series moved to a fused architecture where scalar, vector and tensor work share one pipeline.

The current flagship generation is worth reading closely, because the architecture tells you what it was designed for:

Element Snapdragon 8 Elite Gen 5 (public specs)
NPU structure 12 scalar + 8 vector + 1 tensor accelerator
Precision support INT2 / INT4 / INT8 / INT16 / FP8 / FP16, mixed
Generation gain +37% throughput, +16% perf per watt
Process TSMC N3P (3 nm)
Absolute TOPS Not published

The INT2 support is the tell. Two-bit quantisation is how you fit a usable language model into phone memory without draining the battery. An NPU that supports INT2 is designed to run local LLMs, not only to sharpen photographs.

The industrial line matters more than the phone line

Phone chips get the headlines, but the silicon in a warehouse handheld is a different product family. Qualcomm’s Dragonwing line targets exactly that, and the Q-6690 is the most interesting part to appear in years:

Q-6690
CPU 8-core Kryo 7, up to 2.9 GHz
Process 4 nm
NPU Hexagon, 6 TOPS
Connectivity Wi-Fi 7, Bluetooth 6.0, 5G + 5G dual SIM dual active, UWB
Integration First enterprise mobile processor with UHF RFID reader built in
Longevity 8 years of Android upgrades
Commercial model Four software feature packs, upgradeable over the air

Two things here are more consequential than the TOPS figure.

RFID moved into the SoC. That removes a separate module from the bill of materials, shrinks the board and removes a failure point.

Compute became a software tier. Four feature packs let one board ship as three products at three price points, with compute, multimedia and camera capability unlocked by licence rather than by redesign. Hardware is designed once; capability is sold in layers.

Six TOPS sounds small next to a flagship phone. For a rugged handheld it is not: 6 TOPS of INT8 is comfortable headroom for a 6 MB OCR model, a wake-word model and a defect classifier running on the same device. Industrial buyers are not shopping for peak throughput — they are shopping for eight years of supply and a device that does not throttle at hour three.

MediaTek: efficiency as the design goal

MediaTek’s Dimensity 9500 (September 2025) takes a different route. Its ninth-generation NPU 990 with Generative AI Engine 2.0 is quoted against the previous generation:

Metric Claimed improvement
NPU compute Integer and floating point doubled
3B-parameter LLM output 2x faster
Context length 128K tokens
Image generation First 4K on-device image generation
Peak power -56%
Model loading 4-channel UFS 4.1, 40% faster
Low-bit support BitNet 1.58-bit models, up to 33% less power

The architecture detail worth knowing is compute-in-memory. In a conventional design, weights move between memory and the compute array, and that movement often costs more energy than the arithmetic. Doing multiply-accumulate inside the memory array removes the trip.

The goal is not a better benchmark. It is a model that can stay loaded and running without the user noticing the battery. That distinction decides whether always-on wake words and continuous vision are practical.

In January 2026 MediaTek added the Dimensity 9500s and 8500, pushing this class of NPU into mid-range price bands. Industrial handhelds, tablets and kiosks are usually the first devices to benefit, because they buy mature silicon one tier below flagship.

The software stack decides more than the chip

This is the part most teams underestimate. A capable NPU with an outdated runtime is a slow CPU with extra steps.

NNAPI has been deprecated

For years the standard advice for Android was one line: add the NNAPI delegate and the hardware takes over. That path is now closed.

Google’s own documentation states that the Neural Networks API (NNAPI) is deprecated. The reasoning is straightforward: after NNAPI shipped in Android 8.1, on-device machine learning moved to transformers and diffusion models, and a system API that only changes with Android releases could not keep up. Google also warns that on many future devices NNAPI is expected to resolve to a CPU backend — meaning the “NPU enabled” flag would compile, run, and accelerate nothing.

The recommended paths are now:

  1. LiteRT — the renamed TensorFlow Lite, shipped as an independently updatable runtime.
  2. AICore with Gemini Nano — a foundation model already present on the device.
  3. ML Kit GenAI APIs — turnkey generative features for apps.

If you are starting a project in 2026, NNAPI is a fallback, not a strategy.

LiteRT is the unified NPU entry point

LiteRT exposes one interface across NPU vendors, so you do not integrate a different compiler for each chip family:

Vendor Support
Google Tensor AOT compilation; no on-device JIT yet
Qualcomm AOT and on-device compilation
MediaTek AOT and on-device compilation
Samsung Exynos AOT and on-device compilation
Intel AOT and on-device compilation

Two compilation modes, and the choice visibly affects the user’s first launch:

Mode When it compiles Advantage Cost
AOT (ahead of time) On your build machine, per target SoC Fast first launch, lower memory One build per SoC family
On-device (JIT) On the user’s device at first run One package for all devices Slow first run

Large models — LLMs, segmentation networks — should be compiled ahead of time. Small models, including most OCR and classifier graphs, are usually fine on device.

Deployment is handled by AI Packs: compiled artifacts are packaged and delivered through Google Play’s per-device delivery, so a user only downloads the build for their own SoC. NPU acceleration requires API level 31 or higher.

Gemini Nano: the model you do not have to train

The most underrated route is to use the model the platform already ships.

Gemini Nano runs on more than 140 million devices. On Tensor G5 (Pixel 10 series, TSMC 3 nm) the TPU delivers up to 60% more compute, and the latest Nano runs 2.6x faster and 2x more efficiently in features such as screenshot search and recorder transcription. On a Pixel 10 Pro, the current model processes text at roughly 940 tokens per second with image encoding around 0.6 s.

The next generation, Gemini Nano 4, is built on the Gemma 4 family and splits into Fast and Full variants; the Fast variant is quoted as up to 4x faster with 60% less battery on the TPU.

You reach it through ML Kit GenAI APIs — summarisation, proofreading, rewriting, image description — without converting a model, without checking operator support, and without shipping weights in your APK.

Android 17: from operating system to “intelligence system”

Android 17 (June 2026) reframes the platform. The mechanism most relevant to device builders is AppFunctions with Android MCP: an app exposes its capabilities as callable tools, and on-device agents can discover and execute them, with direct access to the app’s local state.

The compute implication is direct. An agent that runs locally is the only way to get low latency and keep data on the device. That turns “always-on, low-power inference” from a nice extra into a baseline requirement.

Android 17 also introduces a hybrid inference API for routing between local and cloud models, and A2UI for agents that render interface elements. The split is consistent: frequent, private, small work stays on the device; long-context and heavy reasoning goes to a server.

What you can actually run

OCR: the most mature workload, with one specific trap

OCR suits on-device inference unusually well. The input is one image, the output is a few dozen characters, the model is small, it is called constantly, and the content is often sensitive — serial numbers, batch codes, documents.

It also has a structural problem on NPUs:

Sub-model Input shape NPU friendliness
Text detection Dynamic, 32² – 4000² Poor — NPUs generally require static shapes
Text recognition Fixed 3×48×320 Excellent — a natural fit

This is why teams enable NPU acceleration and see no gain. Detection falls back to the CPU because the input size varies; recognition is accelerated but its compute is small enough that data movement eats the benefit.

The reliable pattern is hybrid inference:

1
2
3
4
frame capture
└─► detection (CPU, fixed size) → text boxes
└─► per-box crop → recognition (NPU, 3×48×320 static) → text
└─► regex field extraction → output

TIP

Field numbers, for scale. Our OCR v6 tiny model is about 6 MB in total (1.7 MB detection, 4.3 MB recognition). On a mid-range Android device, a full-frame CPU pass takes 200–500 ms; a single region takes about 37 ms.

At this model size the NPU win is not “5x faster”. It is “500 consecutive scans without the device getting hot”. Whether that matters depends entirely on your duty cycle.

Vision: beyond reading, to deciding

In industrial settings the value is rarely recognition — it is judgement, and judgement has a deadline.

Task What runs on device Why it must be local
Label and print defect detection Segmentation plus template comparison Line cycle 100–300 ms; a round trip does not fit
Barcode quality grading ISO/IEC metric computation The verdict must be traceable and unaltered
Assembly verification Object detection plus keypoints Site is offline, or images may not leave it
AR work instructions Real-time pose estimation (ORB/AKAZE) Under 50 ms or the overlay swims
Multi-camera inspection 2–4 streams on one SoC Cloud bandwidth cost is prohibitive

There is also a hardware trend worth tracking: ISPs are being designed with AI in the loop. Tensor G5 introduced a new ISP, and MediaTek’s Imagiq 1190 does RAW-domain pre-processing. Low light, glare and motion blur — historically the hardest part of any vision project — are being partly absorbed by silicon.

Speech: the workload with the highest frequency

Speech is more demanding than OCR because it is continuous.

Capability Model size Why on-device
Wake word Tens to hundreds of KB Must be resident and draw almost nothing
Speech recognition 40–300 MB Offline operation, no per-minute billing, privacy
Noise suppression, echo cancellation 1–10 MB Decides usability on a noisy floor
Speech synthesis 10–100 MB No network latency for prompts
Understanding and summarisation Gemini Nano class Dictation into structured records

In an intercom, the split that works is: noise suppression, wake word and voice activity detection on the device; the cloud only forwards and synthesises what is necessary. That combination is how you get both low latency and low running cost.

Three integration routes

1
2
3
4
5
6
7
8
9
10
// LiteRT CompiledModel with NPU acceleration (API 31+)
// Refer to the official docs for the current API surface
val options = CompiledModel.Options(Accelerator.NPU)
val model = CompiledModel.create(
context.assets,
"ocr_rec.tflite",
options,
env
)
// Reuse input and output buffers across calls

Multi-vendor, officially supported, with AOT compilation and per-device delivery through Play. The cost is that models must be converted to .tflite, and custom operators need implementing.

B. ONNX Runtime — the shortest path from PyTorch

1
2
3
4
5
6
7
// Qualcomm: QNN execution provider, direct to Hexagon
val qnn = OrtSession.SessionOptions()
qnn.addQnn(mapOf("backend_path" to "libQnnHtp.so"))

// Other devices: NNAPI as a transitional fallback only (deprecated)
val nnapi = OrtSession.SessionOptions()
nnapi.addNnapi()

No framework change if your models are already ONNX. The cost is that QNN bundles vendor .so files, so the APK grows, and the NNAPI route is on its way out.

C. Vendor SDK — the performance ceiling

Qualcomm QNN/QAIRT, MediaTek NeuroPilot, Samsung ENN. This extracts the most from the hardware at the cost of lock-in and one build pipeline per vendor.

WARNING

You do not need a system signature. LiteRT, ONNX Runtime, QNN and NeuroPilot all work for ordinary third-party apps — no root, no platform key.

The NPU driver ships in the vendor partition, already signed by the manufacturer. Your app submits a request through a public interface; everything behind that door is the system’s responsibility. QNN does involve signing, but the signature is applied by the vendor to the libraries that execute inside the DSP, not to your app.

Where it breaks

Five limits account for most failed pilots.

Limit What you observe What to do
Dynamic shapes Detection models are rejected outright Fix the input size, or split work between CPU and NPU
Unsupported operators Silent fallback; no error, no speed Inspect per-layer backend assignment; replace or implement the operator
Quantisation loss Small, low-contrast characters degrade at INT8 Quantisation-aware training; keep an FP16 path for critical reads
Device fragmentation The same model is 2–3x slower on another vendor Maintain a real-device matrix and test on all of it
Sustained performance Peak is fine for five minutes, then it throttles Measure steady state, not peak; control concurrency and thermals

The fifth one is the one that kills industrial deployments. A production line does not forgive a device that benchmarks well and then slows down after half an hour.

WARNING

Quantise before you reach for the NPU. INT8 quantisation alone typically delivers 2–4x, and every device benefits — including ones without a usable NPU. NPU acceleration is the second step, not the first.

A sequence that holds up in practice: FP32 baseline, then INT8, then NPU, then vendor-specific tuning. Change one variable at a time and measure after each.

Why industrial devices get there first

Consumer on-device AI sells convenience: photo editing, summaries, translation. Industrial deployments pay for different reasons.

Requirement Cloud On-device
Cycle time 100 ms – 2 s, variable 50–300 ms, repeatable
Uptime in a dead zone Stops Continues
Data governance Images and text leave the site Nothing leaves the device
Cost at volume Rises with usage Fixed at purchase
Service life Backend must be maintained indefinitely Self-contained for the device’s life

Add chips like the Q-6690 — eight years of Android upgrades, compute unlockable by software tier — and the product logic changes. A board can ship today as a basic barcode terminal and be upgraded later to run OCR, defect detection and voice commands. The device is no longer fixed at the factory.

This is also why we build on standard ONNX and standard inference runtimes. A model that runs on today’s CPU and accelerates on tomorrow’s NPU, without a rewrite, is worth more than a model that is 20% faster on one vendor’s silicon and locked to it.

Two bets worth making

1. Hybrid routing becomes a platform API. Android already ships the routing primitives. Developers will stop hand-writing the “local or cloud” decision.

2. Low-bit quantisation brings LLMs to mid-range silicon. MediaTek supports BitNet 1.58-bit in hardware; Qualcomm supports INT2. Model compression and hardware formats are converging, and a 3B-parameter model on a mid-range chip will stop being news.

The quieter consequence: once assistants listen and watch continuously, the metric that matters shifts from peak TOPS to milliwatts while resident. Compute-in-memory, low-power NPUs and event-driven pipelines will matter more than another round of benchmark gains.

One page

Question Answer
What is an NPU? Fixed-point matrix and convolution acceleration; fast on regular graphs, poor on irregular ops
Can I compare TOPS? No — precision, sparsity and model shape all change the number
What to use in 2026 LiteRT as the default; ONNX Runtime with QNN for Qualcomm; vendor SDKs for the last 20%
Is NNAPI still viable? It runs, but it is deprecated and may resolve to CPU on future devices
Do I need a signed system image? No — ordinary apps can use the NPU
How do I optimise? INT8 quantisation first, then NPU, then vendor tuning
Biggest OCR obstacle Dynamic shapes in detection; run detection on CPU and recognition on the NPU
Where is the real gain? Power, heat, offline operation and privacy — not a 5x headline
Who benefits most Handhelds, line-side vision, offline speech, anything that cannot export data

💬 Questions or a custom requirement?

This global site is brand new, and our online tools are currently in Chinese. Tell us what you need and we’ll set up a fast, tailored solution for you — an English version is coming in the next few weeks.

📧 sales@happylab.me · 🌐 global.happylab.me


Specifications and platform behaviour reflect public information as of October 2026 and change with firmware, drivers and OS versions. Validate on your own hardware before committing to production.

Previous

  • Solutions

      Fixed-Mount OCR on an Android Tablet: No PC Required

      There is a computer standing next to most fixed-mount reading stations. It is th...

    • Next

    • Solutions

        Label Print Inspection: Let AI Spot the Difference

        A printed label reads BC: 8.7 — except the colon is missing its lower dot. A def...

      • avatar

        HappyLab

        HAPPY LAB · Tools · Solutions · Lookup

        • 22

          Articles

        • 7

          Categories

        • 125

          Tags

        • Home
        • Friend Links
        • Tools
        • Pricing
        • Order
        • About
        • Contact
        • Chinese Site