Part I: Foundations of Sensory AI
Chapter 1: What Is Sensory AI?

Book map: measure, clean, represent, infer, fuse, deploy

"They gave me six verbs and swore the whole book was hiding inside them. It was annoying how completely correct that turned out to be."

A Well-Read AI Agent

The Big Picture

A book with fourteen Parts and seventy-two chapters is easy to get lost in, and a linear reading front to back is the wrong plan for almost everyone who will open it. This closing section of Chapter 1 hands you a navigation instrument instead of a summary. The instrument has one moving part: six verbs, measure, clean, represent, infer, fuse, deploy, that name the six things every sensory-AI system does to turn a physical signal into a reliable action. Every Part of this book advances one or more of those verbs. Once you can see which verb a chapter serves, you can find your own route through the volume, skip what your role does not need, and always know where the current idea sits in the larger arc. This is a mental table of contents, not a recap.

Virtually every sensory-AI system ever shipped runs on the same six-word sentence, whether a two-dollar fall detector or a full self-driving stack. The rest of this book is the dictionary for it. Section 1.5 walked one signal through that sentence at the scale of a single sensing chain, from raw transduction to a decision. This section zooms all the way out and applies the same idea at the scale of the whole volume. The prerequisite is light: you need only the shared vocabulary built earlier in this chapter, the four quantities from Section 1.3 (a signal \(x(t)\) or \(x[n]\), a hidden state \(s\), an event \(e\), an action \(a\)), the measurement model \(x = h(s) + \eta\), and a learned representation \(z\). Those symbols are the alphabet; the six verbs are the grammar that arranges them into a working system. The full symbol table lives in Appendix J, Notation and Glossary, and the concrete route-planning advice lives in Front Matter F4, How to Use This Book; this section is the bridge between them.

The six-verb arc as the spine of the book

When a self-driving car brakes for a phantom obstacle or a wrist wearable misses a real arrhythmia, the hardest question on the team is often not how to fix the bug but where the error entered in the first place. The six-verb arc exists to answer exactly that, and to answer it before you write a single line of debugging code. What the arc is: an ordered sentence that every sensory-AI system speaks. You measure to obtain \(x\) from the world through an imperfect sensor \(h(\cdot)\). You clean to suppress the noise \(\eta\) and produce a conditioned observation \(y\). You represent to compress \(y\) into a feature or embedding \(z\) (a learned vector that places inputs with similar structure near each other) that exposes the structure a decision needs. You infer to estimate the hidden state \(\hat{s}\), or an event \(e\), from \(z\). You fuse to combine several sensors or several times into one coherent estimate. You deploy to run all of it reliably under the power, latency, and privacy budgets of Section 1.6. Why six and not one end-to-end box: even a model trained end-to-end still performs these functions internally, and naming them separately is what lets you reason about where an error entered, which stage to fix, and which chapter teaches the fix.

Checkpoint

So far: the six verbs (measure, clean, represent, infer, fuse, deploy) form one ordered sentence that turns a physical signal into a reliable action, and naming each stage separately is what lets you locate where an error entered.

How the arc maps onto the fourteen Parts is the actual map, drawn in Figure 1. The mapping is many-to-many on purpose: infer is the widest verb because most of the book is inference under a different sensor, while clean is narrow because classical signal conditioning concentrates in one Part. When to consult it: any time you feel lost, ask which verb the current chapter serves, and the arc tells you what came before it and what it feeds. In short: name the verb a chapter serves and you instantly know what feeds it, what it feeds, and where to look when the output is wrong.

Common Misconception

A frequent belief is that a modern end-to-end network, which learns a mapping straight from raw signal to output, makes the six verbs obsolete because it "skips the stages." It does not: the network still measures, cleans, represents, infers, and fuses internally; those operations are folded into learned weights rather than removed, so the verbs remain a diagnostic vocabulary for locating where an error entered, even when no stage appears as a separate module in your code.

measure clean represent infer fuse deploy Parts I, IX Part II Parts II, IV, V Parts III, IV, V, VI, VII, VIII, IX Parts X, XI Parts VIII, XI, XII, XIII Part XIV Capstone Ch 72: all six verbs reunited
Figure 1. The six-verb arc and its Part mapping. The signal flows left to right through the verbs; the dashed lines show that the capstone in Part XIV reunites all six into one end-to-end system.

Key Insight

The verbs are a coordinate system, not a schedule. You are not meant to read Part I, master measure, and only then be allowed to think about infer. A robotics engineer lives mostly in fuse and deploy and dips back into measure when a sensor misbehaves. The value of the arc is that it gives every chapter a fixed address, so no matter where you jump in, you can always say which verb you are practicing and which verbs the current one depends on.

Real-World Application: autonomous driving

Autoware, the open-source self-driving stack, maps cleanly onto this six-verb arc: sensor drivers pull lidar (a laser range-finder that sweeps the scene and returns a 3D point cloud), camera, and radar frames (measure), point-cloud croppers and ground-removal filters condition them (clean), voxel (a small 3D volume cell, the spatial analog of a 2D pixel) and image encoders build features (represent), 3D detectors estimate object states (infer), a dedicated sensor-fusion node reconciles the three modalities into one track list (fuse), and a real-time Robot Operating System 2 (ROS 2) runtime holds it all inside a latency budget on the vehicle (deploy). An engineer who sees a mislabeled object can ask which verb's node introduced it and open exactly that module, which is the diagnostic payoff the arc promises.

Mental Model

Think of the six verbs like the basic techniques of a kitchen: chop, season, sear, simmer, plate. Every dish uses all of them, but no cook masters all chopping before ever touching heat, and no recipe walks the techniques in a fixed textbook order; a stir-fry sears late and chops early, a stew simmers for hours and plates in seconds. You practice whichever technique the dish in front of you demands, and the technique names are still what let you say where a dish went wrong (under-seasoned, over-seared). In the same way you enter the book at whatever verb your project needs, and the verb names let you name the stage without reading the volume front to back.

Reading only your level: the [F], [C], [A], [R] tags

The verbs place a chapter on the arc, but they say nothing about how deep it dives, and that second dimension is exactly what the level tags supply. Three audiences share this one book, and the level tags are how they avoid reading each other's chapters. What the tags mean: [F] foundational, the shared floor everyone needs; [C] core, the working methods a practitioner uses daily; [A] advanced, the harder machinery for specialists; [R] research frontier, the 2023 to 2026 techniques that are still moving. Every chapter carries a tag in its header, and many carry two (Chapter 5 is [F][C], Chapter 16 is [A][R]) to signal that they straddle a boundary. Why this matters: an advanced undergraduate can read every [F] and most [C] chapters and come away with a complete, honest picture, while safely skimming the [R] material. A practicing engineer can go straight to the [C] and [A] chapters for their modality and treat the [F] chapters as a reference to dip into. How to use them with the verbs: pick your verbs (your job), then pick your level (your depth), and the intersection is your reading path.

Those paths are named explicitly in Front Matter F4: an undergraduate track that stays in the [F] and [C] spine, a graduate track that adds the [A] and [R] chapters, and role tracks for edge, robotics, health, and industrial readers that select the Parts matching a deployment domain. The edge track, for instance, threads from deploy in Chapter 59, Edge AI Fundamentals and Model Optimization back through whichever infer chapter serves its modality, rather than reading the volume in Part order.

In Practice: A Cardiology Team Plots Its Route

A medical-device startup building a wrist wearable that flags atrial fibrillation from a photoplethysmography (PPG) signal does not read this book front to back. Its firmware engineer follows the health and edge tracks: measure and clean from Parts I and II to understand the PPG waveform and its motion artifacts, infer from Chapter 30, PPG and Wearable Cardiovascular Sensing, then deploy from Part XII for the on-wrist runtime. The clinical lead follows a shorter route: the [F] chapters for shared vocabulary, then Chapter 34 for validation, regulation, and biometric privacy. Two people, one book, two paths that never fully overlap, and neither wastes a week reading the other's chapters. The map is what made that division of labor obvious on day one.

Five running threads that recur all the way to the capstone

Verbs and levels together pin down where a chapter sits and how deep it goes, yet a third kind of structure runs sideways through every one of them. Some ideas are too important to confine to one chapter, so the book weaves them as recurring threads. What the five threads are: leakage-safe evaluation (never let information from the test window inform training), uncertainty and calibration (a \(\hat{s}\) without a trustworthy confidence is half an answer), sensor failure modes (drift, saturation, dropout, and spoofing are the rule, not the exception), biometric and privacy ethics (a heartbeat or a gait is an identity), and the classical-versus-foundation-model tradeoff (when a Kalman filter (the classical recursive state estimator) beats a transformer, and when it does not). Why thread them rather than chapter them: each one applies to every verb, so pinning it to a single location would falsely imply it is done once and forgotten. How they resurface: a leakage-safe split appears the moment any model is trained, in Part IV as much as in Part VIII; calibration appears wherever a decision rides on a probability. When they converge: all five reunite in Chapter 72, Frontier Research and the End-to-End Capstone, where you build one system that measures, cleans, represents, infers, fuses, and deploys, and every thread is graded at once.

The most easily botched of the five is leakage-safe evaluation, because the mistake is invisible: a model that peeked at the future reports a beautiful score and then fails in the field. The discipline is developed in full in Chapter 5, Sensor Data Engineering and Leakage-Safe Datasets, and the single most common fix, grouping by subject or session so no person straddles the train and test sets, is a one-liner with the right tool.

Precisely, leakage is any path by which information tied to a test sample reaches the model during training. Leakage-safe evaluation is a splitting rule that closes those paths, so the reported score estimates true unseen-data performance. It matters because leakage silently inflates accuracy: the model memorizes a shortcut (this subject's resting heart rate, this session's sensor bias) instead of the target relationship, and the inflated number collapses in deployment. The fix defines a grouping key, such as subject, session, or a time boundary, and forces every correlated sample onto one side of the split so no shared information crosses it. Use grouped or time-based splitting whenever samples within a group are correlated, which is nearly always true for sensor windows. A plain random split is defensible only when every sample is genuinely independent, which for streaming physical signals it almost never is.

Right Tool

A hand-rolled leakage-safe split means collecting every window's subject ID, partitioning subjects into folds, masking rows, and asserting no subject appears twice, which is a few dozen lines that are easy to get subtly wrong. The grouped cross-validator does it directly:

from sklearn.model_selection import GroupKFold

# groups[i] = subject id for window i; no subject spans train and test
gkf = GroupKFold(n_splits=5)
for train_idx, test_idx in gkf.split(X, y, groups=subject_ids):
    fit(X[train_idx], y[train_idx])
    score(X[test_idx], y[test_idx])
Subject-grouped 5-fold cross-validation with GroupKFold: passing groups=subject_ids forces every window from one subject into a single fold, so no subject spans train and test and identity leakage cannot occur.

Four lines replace roughly forty of manual partitioning and assertion code. The library guarantees that each subject lands in exactly one fold, which is the property that stops identity leakage, and it balances fold sizes for you. The reasoning behind why subject grouping (not random splitting) is the correct choice for sensor data is the subject of Chapter 5.

Step-Through: grouped versus random splitting

Trace the leakage thread with a tiny dataset of six windows from three subjects, two windows each: subject_ids = [A, A, B, B, C, C] for windows w0..w5. We compare a plain 3-fold random split against GroupKFold(n_splits=3). Figure 1.8.1 illustrates grouped versus random cross-validation and subject leakage.

Grouped versus random cross-validation and subject leakage
Figure 1.8.1: A random split lets one subject's windows fall into both train and test (identity leakage, inflating accuracy to 0.95), while a grouped split keeps every subject in a single fold, yielding the honest 0.82 that predicts field performance.

Random 3-fold. Shuffle indices, say to [w4, w1, w3, w0, w5, w2], then cut into three folds of two: test folds become {w4, w1}, {w3, w0}, {w5, w2}. Look at fold 1: its test set holds w1 (subject A) and w4 (subject C), while its training set holds w0 (subject A) and w5 (subject C). Subject A now sits on both sides, so the model can memorize A's resting-heart-rate bias from w0 and reuse it to score w1. Suppose the reported mean accuracy is 0.95.

Grouped 3-fold. GroupKFold assigns whole subjects to folds, never splitting a subject: fold 1 test = {A} = w0, w1; fold 2 test = {B} = w2, w3; fold 3 test = {C} = w4, w5. In every fold the tested subject is entirely absent from training, so no per-subject shortcut can leak. Suppose the reported mean accuracy is now 0.82.

Read-out. The gap 0.95 minus 0.82 equals 0.13, and that 13-point drop is exactly the leakage the random split was hiding: the same model, the same data, reported 95 percent one way and 82 percent the honest way, and only one of those numbers survives contact with a new subject. The number that survives grouped splitting is the one that predicts field performance on a subject the model has never seen.

A Note in Passing

Six verbs is a suspiciously tidy number, and yes, we could have argued for a seventh (label, perhaps, or calibrate). We folded those into the six because a map with forty landmarks is not a map, it is the territory again. The point of a spine is that you can feel every vertebra without a diagram.

How to hold the whole book in your head at once

Put the three pieces together and you hold a compact model of the entire volume. The verbs tell you what a chapter does, the level tags how deep it goes, the threads which cross-cutting concerns it must respect. Those three coordinates locate any chapter. Chapter 19, for instance, is an infer-and-represent chapter at level [R] that honors the calibration and leakage threads, and it teaches exactly that in Chapter 19, Time-Series Foundation Models. That is your mental table of contents. The rest of Part I fills in the measure foundations the other verbs stand on; from there you follow your own path across the arc until it converges, in the capstone, into one system.

Research Frontier

This section teaches the six verbs as distinct, modular stages, which is the right mental model for locating and fixing errors. The 2024 frontier is testing how far a single pretrained model can absorb represent, infer, and even fuse into one set of weights over raw sensor streams. Google's Large Sensor Model (Narayanswamy et al., 2024, arXiv:2410.13638) scales masked-reconstruction pretraining (a self-supervised objective where the model learns by predicting deliberately hidden spans of the raw signal) to roughly 40 million hours of wearable accelerometer and PPG data and then transfers to downstream tasks with little labeled data, and open families such as MOMENT (Goswami et al., 2024) and TimesFM (Das et al., 2024) do the same for general time series. The open question the capstone returns to is when this collapse of verbs into one model actually beats a modular pipeline of classical filters and small task-specific heads, and when the modular route still wins on data budget, latency, and interpretability.

Try It: See Leakage Inflate a Score

Make the invisible mistake visible on your own laptop with scikit-learn, in under thirty lines. This is the fastest way to feel why the map treats leakage-safe evaluation as a thread that touches every verb.

  1. Install and import the tools: pip install scikit-learn numpy, then load the Human Activity Recognition data with from sklearn.datasets import fetch_openml and fetch_openml("har", version=1), or any activity dataset that carries a subject identifier column.
  2. Train a RandomForestClassifier with an ordinary random 5-fold split using cross_val_score(clf, X, y, cv=5) and record the mean accuracy. This is the optimistic, leaky number.
  3. Retrain with GroupKFold(n_splits=5), passing groups=subject_ids so no person appears in both train and test, and record the mean accuracy again.
  4. Compare the two numbers. The grouped score will typically drop by several points, and that gap is the leakage the random split was hiding.
  5. Write one sentence explaining which verb (infer) produced the score and which thread (leakage-safe evaluation) just corrected it.

Exercise

Choose a sensory-AI system you know or want to build (a fall detector, a lidar-based robot, an electrocardiogram (ECG) patch, a bearing-fault monitor). For each of the six verbs, name one concrete operation your system performs, and match it to the Part in Figure 1 that would teach it. Then assign your reader profile a level ([F]/[C]/[A]/[R]) and cross out every chapter above your level. Finally, mark which of the five running threads is most likely to sink your project if ignored, and justify the choice in one sentence.

Self-Check

1. Why is infer the widest verb in the Part mapping while clean is the narrowest?

2. An advanced undergraduate wants a complete but not frontier picture. Which level tags should they read, and which should they skim?

3. Name the five running threads and explain, in one sentence each, why none of them can be confined to a single verb.

Lab 1

Survey a dozen public sensor datasets (for example UCI HAR, PhysioNet MIT-BIH, PAMAP2, KITTI, WESAD, DEAP, PTB-XL, and any four of your choosing). Build a single table that classifies each dataset along seven axes: sampling rate, dimensionality (channels), modality, task family, dominant noise source, label cost, and the deployment constraint it implies. Then, for each dataset, tag which of the six verbs its natural pipeline exercises most heavily and which reading-path track (undergraduate, graduate, edge, robotics, health, industrial) it best serves. Submit the table plus a one-paragraph reflection on which axis was hardest to pin down and why. This lab is your first practice at reading the whole field through the map you just built; you will reuse its table as a reference throughout Parts II through XIII.

Bibliography

Foundations: classical estimation and signal processing

Kalman, R. E. (1960). A New Approach to Linear Filtering and Prediction Problems. Journal of Basic Engineering, 82(1), 35-45.

The founding paper of recursive state estimation and the ancestor of the infer and fuse verbs developed in Part III.

Oppenheim, A. V., & Schafer, R. W. (2009). Discrete-Time Signal Processing (3rd ed.). Pearson.

The standard reference for the sampling, filtering, and spectral machinery that underlies the measure and clean verbs.

Thrun, S., Burgard, W., & Fox, D. (2005). Probabilistic Robotics. MIT Press.

The canonical treatment of probabilistic fuse: Bayes filters, localization, and SLAM that Part X builds on.

Representation learning and foundation models

Goodfellow, I., Bengio, Y., & Courville, A. (2016). Deep Learning. MIT Press.

The reference text for the represent verb as practiced in Part IV, from features to learned embeddings \(z\).

Das, A., Kong, W., Sen, R., & Zhou, Y. (2024). A decoder-only foundation model for time-series forecasting (TimesFM). ICML. arXiv:2310.10688.

A pretrained time-series foundation model that anchors the frontier infer discussion in Chapter 19.

Goswami, M., Szafer, K., Choudhry, A., Cai, Y., Li, S., & Dubrawski, A. (2024). MOMENT: A Family of Open Time-series Foundation Models. ICML. arXiv:2402.03885.

An open family of general-purpose time-series models illustrating the classical-versus-foundation-model thread across multiple tasks.

Narayanswamy, G., et al. (2024). Scaling Wearable Foundation Models (LSM). arXiv:2410.13638.

Google's Large Sensor Model, evidence that the foundation-model wave has reached raw wearable sensor streams, developed in Part V.

Uncertainty, evaluation, and the running threads

Angelopoulos, A. N., & Bates, S. (2023). Conformal Prediction: A Gentle Introduction. Foundations and Trends in Machine Learning, 16(4). arXiv:2107.07511.

A practical entry point to the uncertainty-and-calibration thread, giving distribution-free prediction intervals used from Chapter 18 onward.

Bommasani, R., et al. (2021). On the Opportunities and Risks of Foundation Models. arXiv:2108.07258.

The survey that named the foundation-model paradigm and frames both its promise and its privacy and safety risks for sensing.

What's Next

In Chapter 2, the arc begins for real with the first verb. That section opens up the measurement model \(x = h(s) + \eta\) and separates direct observables (what a sensor reports straight out) from indirect ones (what you must infer because the quantity you care about was never measured directly), the distinction that decides how much work every later verb has to do.