An on-device dataset is the corpus of raw or preprocessed data—such as sensor data streams, user activity logs, or environmental readings—persistently stored in the local memory of a resource-constrained device like a microcontroller. This dataset is the foundational input for on-device training and inference, enabling Federated Edge Learning where models learn directly from decentralized data. Its creation involves on-device preprocessing to transform raw signals into features suitable for a TinyML model, all while adhering to strict memory footprint and energy budget constraints.
Glossary
On-Device Dataset

What is an On-Device Dataset?
An on-device dataset is the collection of sensor readings, user interactions, or other locally generated data stored on an edge device, which is used for local model training or personalization in federated and on-device learning paradigms without being transmitted to a central server.
In Federated Learning for TinyML, the on-device dataset is never centralized; only model updates derived from it are shared. This architecture directly addresses the cold-start problem by allowing personalization and tackles the challenges of heterogeneous clients with non-IID data distributions. The dataset's size and statistical properties are primary factors in client selection strategies and dictate the feasibility of local training within an availability window, making its efficient management a core systems challenge for embedded engineers.
Key Characteristics of On-Device Datasets
On-device datasets are the localized, private collections of data used for training and personalization in federated and edge learning systems. Their defining properties are shaped by the severe constraints and unique environment of the embedded devices that host them.
Data Sovereignty & Privacy
The most defining characteristic of an on-device dataset is that the raw data never leaves the physical device. This is the core privacy guarantee of federated learning. The data is generated, stored, and processed locally, with only encrypted mathematical updates (like gradients or weight deltas) being shared. This is critical for applications involving personal user interactions, proprietary industrial sensor readings, or regulated health data where centralization poses legal and ethical risks.
Statistical Heterogeneity (Non-IID)
On-device data is almost never Independent and Identically Distributed (IID). Each device's dataset reflects its unique environment and user. For example:
- A fitness tracker in Sweden will have different temperature and activity data than one in Singapore.
- A keyboard on a programmer's phone will have a different word distribution than one on a journalist's phone. This non-IID data distribution is the primary challenge in federated learning, as it can cause model divergence and slow convergence, requiring specialized optimization algorithms like Federated Averaging (FedAvg) with client weighting.
Extreme Resource Constraints
On TinyML devices, datasets are bounded by severe hardware limits:
- Memory (RAM/Flash): The entire dataset must fit in the device's limited volatile and non-volatile memory, often measured in kilobytes to a few megabytes. This prohibits storing large historical archives.
- Compute: Processing the dataset for local training is constrained by the MCU's clock speed and lack of a dedicated GPU, limiting model and batch sizes.
- Energy: Reading from memory and performing computations directly drains the energy budget. Data collection and training must be scheduled to balance utility with battery life.
Dynamic & Streaming Nature
On-device datasets are not static; they are built from continuous sensor data streams or user interactions. This creates a temporal dimension where data distribution can drift over time (e.g., a sensor's environment changes with seasons). It enables online or continual learning paradigms where the model adapts to new patterns. However, it also introduces challenges like managing dataset size (e.g., FIFO buffers) and handling the cold-start problem where a new device has insufficient initial data for effective training.
Unlabeled & Weakly Labeled Data
A significant portion of on-device data is unlabeled. Manually labeling sensor streams (e.g., identifying specific sounds or motion patterns) is infeasible at scale. This drives the use of:
- Self-supervised learning techniques that generate labels from the data's structure.
- Weak supervision using heuristic rules or other sensor modalities as proxy labels.
- Federated learning with scarce labels, where only a small subset of clients may have labeled data, requiring algorithms that can leverage both labeled and unlabeled datasets across the network.
Task-Specific & Multi-Modal Composition
The dataset's composition is dictated by the device's sensors and its specific inference task, often combining multiple data types:
- A wake-word detection device collects audio time-series.
- An industrial predictive maintenance sensor collects vibration, temperature, and current readings.
- A smartphone may use typing patterns, accelerometer data, and app usage logs for personalization. This multi-modal nature requires on-device preprocessing pipelines to align and fuse different data streams into a format usable by the model, all within the device's resource envelope.
On-Device Dataset
The on-device dataset is the foundational, private data asset that enables decentralized machine learning on edge hardware.
An on-device dataset is the collection of sensor readings, user interactions, or other locally generated data stored on an edge device, which is used for local model training or personalization without the raw data being transmitted to a central server. In Federated Edge Learning, this dataset is the source for computing model updates (e.g., gradients), which are then aggregated to improve a global model while preserving data privacy and reducing bandwidth. Its characteristics—size, distribution, and quality—directly influence model performance and training efficiency.
For TinyML deployments on resource-constrained devices, managing the on-device dataset involves significant engineering trade-offs. Storage is limited, often requiring on-device preprocessing to extract features and discard raw streams. The data is typically non-IID (non-identically distributed) across devices, posing challenges for federated optimization. Furthermore, the dataset is dynamic, growing from continuous sensor data streams, which enables on-device training for continual learning but must operate within strict energy budget and compute constraints to avoid excessive battery drain.
Common Examples & Data Types
An on-device dataset is the local, private collection of data used for training or personalization directly on an edge device. Its characteristics are defined by the device's sensors, user interactions, and operational constraints.
Sensor Telemetry Streams
The most common on-device dataset type, consisting of continuous, time-series readings from embedded sensors. These are raw, unlabeled, and generated in real-time.
Examples include:
- Inertial Measurement Unit (IMU) Data: Accelerometer, gyroscope, and magnetometer readings for activity recognition (e.g., step counting, fall detection).
- Environmental Sensors: Temperature, humidity, air quality (VOC), and barometric pressure logs.
- Acoustic Data: Raw audio waveforms or Mel-frequency cepstral coefficients (MFCCs) for keyword spotting or anomaly detection.
Key Constraint: Data volume is bounded by the device's limited non-volatile storage (Flash memory), often requiring circular buffers or aggressive compression.
User Interaction Logs
Datasets composed of implicit and explicit feedback from a device's primary user, enabling highly personalized model adaptation.
Examples include:
- Touchscreen Gestures & Typing Patterns: For adaptive keyboards or UI personalization.
- App Usage Statistics & Feature Preferences: Sequences of actions within a mobile or embedded application.
- Voice Command History: Successful and failed interactions with a local voice assistant.
Privacy Imperative: This data is highly sensitive and must never leave the device raw. Federated learning protocols like Secure Aggregation are designed to learn from these logs without central collection.
Operational & Diagnostic Logs
Data generated by the device's own systems, capturing its health, performance, and failure modes. This dataset is critical for predictive maintenance and self-healing applications.
Examples include:
- Power State Transitions: Records of sleep/wake cycles and battery voltage levels.
- Thermal Profiles: Processor temperature logs correlated with compute load.
- Wireless Link Quality: Histograms of signal strength (RSSI) and packet loss rates.
- System Exception Dumps: Context around crashes or faults.
This data is inherently non-IID (Non-Independently and Identically Distributed) across a device fleet, as each unit experiences unique environmental and usage stresses.
Synthetic & Augmented Data
Artificially generated or transformed data created on-device to overcome local data scarcity. This is a key technique for on-device continual learning.
Methods include:
- Data Augmentation: Applying real-time transformations (e.g., time-warping, adding noise, scaling) to existing sensor samples to create new training examples.
- Generative Model Inference: Using a tiny, pre-loaded generative adversarial network (GAN) or diffusion model to create plausible synthetic samples that respect the local data distribution.
- Simulation via Digital Twin: If the device has a physics-based model of its environment, it can generate simulated sensor readings for rare edge cases.
This approach directly addresses the cold-start problem in federated edge learning.
Federated Learning Artifacts
The specialized data types exchanged during the federated learning process, which are derived from—but do not contain—the raw on-device dataset.
Core Artifacts:
- Model Updates (ΔW): The difference between the model parameters before and after local training. This is a mathematical summary of learning from the local dataset.
- Training Metadata: Scalars like the number of local training steps (E) and the size of the local dataset (n_k), used for weighted averaging in algorithms like Federated Averaging (FedAvg).
- Sparse Gradients: For communication efficiency, clients may send only the top-k% of gradient values by magnitude, creating a sparse update.
These artifacts are the only information about the local dataset that is transmitted to the coordinating server.
Ephemeral vs. Persistent Storage
A fundamental distinction in how on-device datasets are managed, dictated by memory constraints and data relevance.
Ephemeral (In-Memory) Datasets:
- Storage: Volatile RAM only.
- Use Case: Streaming learning where the model trains on a continuous, real-time sensor feed. Data is processed in small batches and then discarded.
- Challenge: Requires extremely efficient algorithms to learn from a data window before it vanishes.
Persistent (Flash) Datasets:
- Storage: Non-volatile Flash memory.
- Use Case: Learning from rare events (e.g., a machine fault) or user habits that develop over days/weeks. Data is stored in a managed buffer.
- Challenge: Flash memory has limited write cycles (endurance), making frequent saves unsustainable. Techniques like wear leveling are essential.
On-Device Dataset vs. Centralized Dataset
A comparison of data storage and processing paradigms for machine learning, highlighting the core distinctions between federated edge learning and traditional cloud-centric approaches.
| Feature / Metric | On-Device Dataset | Centralized Dataset |
|---|---|---|
Data Location & Sovereignty | Resides on the edge device (MCU, sensor, phone). | Stored on remote cloud or enterprise servers. |
Data Privacy Posture | Raw data never leaves the device; only model updates may be shared. | Raw data is transmitted and stored centrally, creating a single point of exposure. |
Primary Use Case | Federated Learning, On-Device Training, TinyML, Personalization. | Traditional Centralized Training, Big Data Analytics. |
Data Transmission Volume | Minimal (sparse model updates only). Typically < 1 MB per round. | Massive (entire raw datasets). Often GBs to TBs. |
Latency for Model Updates | Low (computation is local). Bounded by device compute speed. | High (dominated by data upload bandwidth and cloud queueing). |
Operational Resilience | High. Functions offline; model improves with local data without connectivity. | Low. Dependent on stable, high-bandwidth cloud connectivity. |
Compliance Suitability | Inherently aligns with GDPR, HIPAA, and data localization laws. | Requires complex legal agreements, encryption, and access controls. |
Scalability Challenge | Managing heterogeneity and partial participation across 1000s of devices. | Scaling storage and GPU clusters for exponentially growing data. |
Primary Cost Driver | Edge device hardware & embedded software development. | Cloud storage fees, egress charges, and compute instance costs. |
Data Preprocessing | On-device preprocessing (filtering, FFT) to reduce dimensionality. | Centralized ETL/ELT pipelines on powerful servers. |
Data Distribution | Typically Non-IID (Non-Independent and Identically Distributed). Statistically heterogeneous across devices. | Assumed to be IID (or can be shuffled into such). Statistically homogeneous. |
Security Attack Surface | Distributed. Requires defenses against adversarial clients & model poisoning. | Centralized. High-value target for database breaches and exfiltration. |
Frequently Asked Questions
An on-device dataset is the collection of sensor readings, user interactions, or other locally generated data stored on an edge device, which is used for local model training or personalization in federated and on-device learning paradigms without being transmitted to a central server.
An on-device dataset is the collection of raw sensor data, user interactions, or system logs that is generated, stored, and processed locally on a resource-constrained device like a microcontroller or smartphone. It is the fundamental fuel for on-device training and personalized federated learning, where the data never leaves the physical device, ensuring privacy and reducing bandwidth. Unlike centralized datasets, it is typically small, highly personalized, and reflects the unique statistical distribution of its local environment.
Key characteristics include:
- Local Storage: Resides in the device's limited Flash memory or RAM.
- Continuous Generation: Often built from a live sensor data stream.
- Non-IID Nature: Data distribution is specific to the device's user and environment, a core challenge in federated learning.
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Related Terms
An on-device dataset is the local data used for training within a federated learning system. These related concepts define the hardware, software, and algorithmic constraints that shape how such datasets are created, processed, and utilized on the edge.
On-Device Training
The process of updating a machine learning model's parameters directly on an edge device using its local dataset. This enables continual learning and personalization without transmitting raw data. For TinyML, this requires algorithms designed for severe memory and compute constraints.
Resource-Constrained Device
An embedded system, such as a microcontroller-based sensor, with severe limitations that define the TinyML challenge space. Key constraints include:
- Memory Footprint: Limited RAM and Flash for models and data.
- Compute Constraint: Low operations-per-second (OPS) for training.
- Energy Budget: Finite battery life for sustained operation.
- Thermal Throttling: Heat limits that can throttle processor speed during intensive tasks.
Sparse Update
A client model update in federated learning where only a small, critical subset of parameters have non-zero values. This is a core technique for communication-efficient federated learning, drastically reducing the bandwidth required to transmit updates from edge devices to the aggregating server. It often pairs with model sparsification techniques.
Embedded FL Runtime
A lightweight software library deployed on a microcontroller that manages the local federated learning client protocol. It handles:
- Downloading the global model.
- Executing on-device training using the local dataset.
- Applying compression (e.g., sparsification, quantization) to the update.
- Securely communicating the update. It must integrate tightly with the device's firmware.
Sensor Data Stream
The continuous, real-time sequence of measurements (e.g., acceleration, temperature, audio) generated by an embedded sensor. This raw stream is the primary source for building an on-device dataset. It typically undergoes on-device preprocessing (filtering, FFT) to extract features before being used for model training or inference.
Heterogeneous Clients
The variation across edge devices participating in federated learning. This heterogeneity directly impacts how on-device datasets are used and includes:
- Hardware: Differences in CPU, memory, and sensors.
- Data Distribution: Non-IID data across devices.
- Availability: Devices have different availability windows for training.
- Connectivity: Varied network bandwidth and reliability. Algorithms must account for this to avoid the straggler problem.

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us