What Is Channel State Information (CSI)? A Deep Dive into WiFi-DensePose Implementation

Channel State Information (CSI) is a fine-grained description of Wi-Fi signal propagation that captures amplitude and phase data across multiple sub-carriers, enabling privacy-preserving human sensing applications like pose estimation.

In the WiFi-DensePose repository, Channel State Information serves as the foundational sensing modality that transforms ordinary Wi-Fi signals into structured data for human pose detection. Unlike coarse metrics such as RSSI, CSI exposes the multipath characteristics of the RF environment, revealing how signals bounce off objects and people within the transmission field.

Understanding Channel State Information in Wi-Fi Networks

What CSI Measures

Channel State Information represents the channel frequency response between a transmitter and receiver. In v1/src/hardware/csi_extractor.py, the implementation captures:

  • Amplitude and phase for each sub-carrier across multiple antennas
  • Multipath propagation effects that reveal environmental reflections
  • Temporal variations caused by moving objects and human bodies

The raw CSI data arrives as byte strings from hardware drivers (Intel 5300, Atheros, ESP32, or modified router firmware) and gets parsed into structured CSIData objects containing UTC timestamps, amplitude/phase matrices, carrier frequency, bandwidth, sub-carrier count, antenna configuration, and SNR values.

From RF Signals to Human Sensing

Because Channel State Information reflects subtle movements within the signal field, it functions as a privacy-preserving sensing modality. Unlike cameras that capture identifiable images, CSI only records signal distortions caused by human presence. The WiFi-DensePose pipeline leverages these distortions to detect body position and movement without visual surveillance.

How WiFi-DensePose Processes Channel State Information

The Three-Layer CSI Pipeline

The repository implements a logical three-layer architecture for handling Channel State Information:

  1. Hardware Extraction – Low-level drivers stream raw CSI packets
  2. CSI Extractor – Parses raw bytes into structured CSIData objects
  3. CSI Processor – Preprocesses data, extracts features, and runs detection logic

CSI Extraction Layer

Located in v1/src/hardware/csi_extractor.py, the extraction layer handles hardware abstraction through specialized parsers:

  • ESP32CSIParser – Processes data from ESP32-based modules
  • RouterCSIParser – Handles commercial router firmware outputs

The CSIExtractor class selects the appropriate parser based on configuration and validates incoming data streams. For example, a raw byte string such as:


b"CSI_DATA:1234567890,3,56,2400,20,15.5,[1.0,2.0,3.0],[0.5,1.5,2.5]"

Gets transformed into a CSIData dataclass containing structured matrices for amplitude and phase, along with metadata required for downstream signal processing.

CSI Processing Layer

The CSIProcessor class in v1/src/core/csi_processor.py implements the signal processing pipeline for Channel State Information:

Preprocessing Steps:

  • Denoising of amplitude matrices
  • Hamming window application
  • Signal normalization

Feature Extraction: The processor computes a rich feature set including:

  • amplitude_mean and amplitude_variance
  • phase_difference calculations
  • Correlation matrices
  • Doppler shift estimates
  • Power spectral density (PSD)

Human Detection: These features feed into a lightweight motion-analysis model that outputs a HumanDetectionResult containing a human-detected flag, confidence score, and motion metrics.

Practical Implementation: Working with CSI Data in Python

Extracting Channel State Information from ESP32 Hardware

from src.hardware.csi_extractor import CSIExtractor

config = {
    "hardware_type": "esp32",
    "sampling_rate": 100,      # Hz

    "buffer_size": 256,
    "timeout": 2.0,
    "validation_enabled": True,
}
extractor = CSIExtractor(config=config)

# Connect to the hardware (mocked in tests)

await extractor.connect()
csi_sample = await extractor.extract_csi()
print("Timestamp:", csi_sample.timestamp)
print("Amplitude shape:", csi_sample.amplitude.shape)

Processing CSI for Human Detection

from src.core.csi_processor import CSIProcessor

proc_cfg = {
    "sampling_rate": 100,
    "window_size": 32,
    "overlap": 0.5,
    "noise_threshold": -80.0,          # dB

    "human_detection_threshold": 0.75,
}
processor = CSIProcessor(config=proc_cfg)

features = processor.preprocess_csi_data(csi_sample)
features = processor.extract_features(features)
result = processor.detect_human_presence(features)

if result and result.human_detected:
    print(f"Human detected! Confidence={result.confidence:.2f}")
else:
    print("No human activity.")

Continuous CSI Streaming

async def on_csi(csi):
    # Process each frame as it arrives

    detection = processor.detect_human_presence(
        processor.extract_features(
            processor.preprocess_csi_data(csi)
        )
    )
    if detection and detection.human_detected:
        print("⚡ Human activity!", detection.confidence)

await extractor.start_streaming(callback=on_csi)

Summary

  • Channel State Information (CSI) provides fine-grained amplitude and phase data for every Wi-Fi sub-carrier, revealing multipath propagation effects invisible to RSSI metrics.
  • The WiFi-DensePose repository implements a three-layer pipeline: hardware extraction (v1/src/hardware/csi_extractor.py), structured parsing into CSIData objects, and signal processing (v1/src/core/csi_processor.py).
  • CSIExtractor handles multiple hardware types through specialized parsers (ESP32CSIParser, RouterCSIParser), converting raw byte strings into structured matrices.
  • CSIProcessor denoises signals, extracts features (amplitude variance, phase difference, Doppler shift), and outputs HumanDetectionResult objects for privacy-preserving human sensing.

Frequently Asked Questions

What is the difference between Channel State Information and RSSI?

Channel State Information captures per-sub-carrier amplitude and phase across multiple antennas, exposing detailed multipath propagation characteristics. RSSI (Received Signal Strength Indicator) provides only a single coarse value representing total received power. CSI enables fine-grained motion detection and pose estimation, while RSSI can only detect coarse presence or absence.

Can Channel State Information work with any Wi-Fi router?

No, CSI extraction requires specific hardware and firmware modifications. The WiFi-DensePose repository supports ESP32-based modules, Intel 5300 NICs, Atheros chipsets, and select commercial routers running modified firmware. Standard consumer routers typically do not expose raw CSI data without custom firmware like OpenWrt with specific patches.

How does WiFi-DensePose ensure privacy when using Channel State Information?

CSI-based sensing preserves privacy by capturing only signal propagation distortions rather than visual images. The system analyzes how Wi-Fi signals bounce off human bodies, extracting only amplitude and phase matrices without recording identifiable facial features or clothing details. This makes Channel State Information suitable for privacy-sensitive environments where camera deployment is inappropriate.

What hardware is required to extract Channel State Information?

You need Wi-Fi hardware capable of reporting physical layer information. Supported configurations include ESP32 development boards with CSI-enabled firmware, Linux laptops with Intel 5300 or Atheros wireless cards, or commercial routers flashed with custom firmware. The WiFi-DensePose CSIExtractor class abstracts these hardware differences through its parser architecture, allowing developers to switch between ESP32 and router sources by changing configuration parameters.

Have a question about this repo?

These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:

Share the following with your agent to get started:
curl -s "https://instagit.com/install.md"

Works with
Claude Codex Cursor VS Code OpenClaw Any MCP Client

Maintain an open-source project? Get it listed too →