A method for generating CSI pseudo data

By using the CSI data generation model, the problem of imbalanced datasets in WLAN sensing technology is solved. It generates reliable multi-class CSI pseudo data, improves the recognition ability and computational efficiency of AI models, corrects phase errors caused by hardware, and achieves a more balanced data distribution.

CN118172592BActive Publication Date: 2026-08-04SHANGHAI INST OF MICROSYSTEM & INFORMATION TECH CHINESE ACAD OF SCI
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
SHANGHAI INST OF MICROSYSTEM & INFORMATION TECH CHINESE ACAD OF SCI
Filing Date
2024-02-29
Publication Date
2026-08-04

AI Technical Summary

Technical Problem

In existing WLAN sensing technologies, the uneven distribution of datasets, especially the low frequency of certain behaviors or events, leads to poor performance of AI algorithms in identifying these categories, affecting model performance and application potential.

Method used

A CSI data generation model is adopted, which generates reliable multi-class CSI pseudo data by inputting noisy image data into an encoder, a diffusion model and a decoder. The process includes the encoder extracting feature maps, the diffusion model generating pseudo feature maps and the decoder restoring them to CSI pseudo data. The image analysis model with a transformer architecture is used for training to generate reliable multi-class CSI pseudo data.

Benefits of technology

It improves dataset balance, enhances the robustness of AI models, optimizes computational efficiency, corrects phase discontinuities caused by hardware, generates more credible pseudo-data, and achieves a more balanced data distribution.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118172592B_ABST
    Figure CN118172592B_ABST
Patent Text Reader

Abstract

This invention relates to a method for generating CSI pseudo-data, comprising the following steps: inputting noisy data into a CSI data generation model to obtain CSI pseudo-data. The CSI data generation model includes: an encoder for extracting feature maps from the input image; a diffusion model for generating pseudo-feature maps based on the feature maps; and a decoder for restoring the pseudo-feature maps back to CSI pseudo-data. This invention can generate reliable multi-class CSI pseudo-data, and by embedding the encoder and decoder into the diffusion model, it achieves a lightweight CSI data generation model, saving significant computational power.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of infinite sensing technology, and in particular to a method for generating CSI pseudo data. Background Technology

[0002] WLAN sensing technology, as a technology that utilizes wireless local area networks (WLANs) for environmental perception and user behavior recognition, has made significant progress in recent years. This technology can be used for applications such as object perception, activity recognition, gesture recognition, and localization, and it is a privacy-friendly sensing technology that does not require the subject to wear any devices. The core of this technology lies in external perception through the analysis of Channel State Information (CSI). CSI is data describing the effects of wireless signal attenuation due to obstruction and multipath effects during transmission, containing rich high-dimensional features that can be used to capture and understand various events occurring in the environment, such as human movement and changes in location. To effectively mine the high-dimensional features and their autocorrelation and cross-correlation in this data, researchers currently widely use AI algorithms, especially deep learning models, to process CSI data. These AI algorithms can identify specific patterns and information from complex CSI data, thereby achieving complex tasks such as walking detection, posture recognition, and even sentiment analysis.

[0003] To achieve accurate environmental perception and behavior recognition, it is typically necessary to collect and analyze CSI data across multiple categories. These data categories may involve different environmental conditions, user behavior types, or interaction patterns. However, in reality, data for certain specific categories may be relatively sparse. For example, some behaviors or events occur with low frequency, making it difficult to collect large amounts of data for those categories. Furthermore, privacy and security concerns may limit the collection of certain types of behavioral data, especially in situations involving personal spaces or sensitive locations. This imbalance in dataset distribution can cause AI algorithms to perform poorly when processing such data. Due to insufficient sample sizes for certain categories in the training data, the model may not be able to fully learn the characteristics of these few categories, thus affecting its ability to recognize these categories in practical applications. This problem not only reduces the overall performance of the model but also limits the application potential of WLAN sensing technology in a wider range of scenarios. Therefore, addressing the problem of imbalanced dataset distribution is crucial for improving the accuracy and reliability of WLAN sensing technology. Summary of the Invention

[0004] The technical problem to be solved by the present invention is to provide a method for generating CSI pseudo data that can generate reliable multi-class CSI pseudo data while saving computing power.

[0005] The technical solution adopted by this invention to solve its technical problem is: to provide a CSI pseudo data generation method, including the following steps:

[0006] Noisy image data is input into a CSI data generation model to obtain CSI pseudo data. The CSI data generation model includes:

[0007] An encoder is used to extract feature maps from an input image;

[0008] A diffusion model is used to generate a pseudo-feature map based on the feature map;

[0009] A decoder is used to restore the pseudo-feature map to CSI pseudo-data.

[0010] Furthermore, the CSI data generation model is trained using the following method:

[0011] Deploy multiple wireless sensing terminals to collect CSI data at different times;

[0012] The CSI data acquired by different wireless sensing terminals are expanded along the time dimension and the subcarrier dimension and then fused into an image-like matrix.

[0013] An image analysis model based on a transformer architecture is constructed using the encoder and the decoder. The image analysis model is then trained using the image-like matrix to obtain the trained encoder and the decoder.

[0014] The CSI data generation model is trained using the image matrix to obtain the trained diffusion model.

[0015] Furthermore, the CSI data includes channel amplitude information and phase information.

[0016] Furthermore, the encoder is an improved ViT encoder, comprising:

[0017] An image segmentation module is used to segment the input image into several image blocks of a preset size;

[0018] The location embedding module is used to convert the image patch into an image patch vector and fuse the image patch vector with a two-dimensional hybrid location vector, wherein the two-dimensional hybrid location vector includes a fixed location code corresponding to the subcarrier dimension and a learnable location code corresponding to the time dimension.

[0019] The feature extraction module is used to extract the autocorrelation features of the fused image block vectors to obtain the feature map of the input image.

[0020] Furthermore, after the step of expanding and fusing the CSI data acquired by different wireless sensing terminals along the time dimension and subcarrier dimension into an image-like matrix, the method further includes a step of performing phase correction on the CSI data.

[0021] Furthermore, the channels of the image-like matrix include all the channel amplitude information and phase information acquired by the wireless sensing terminal.

[0022] Furthermore, the step of expanding and fusing the CSI data acquired by different wireless sensing terminals along the time and subcarrier dimensions into an image-like matrix includes:

[0023] For the CSI data acquired by any of the wireless sensing terminals, the channel amplitude information and the phase information are expanded along the time dimension and the subcarrier dimension to obtain the amplitude matrix and the phase matrix, respectively.

[0024] The amplitude matrix and phase matrix corresponding to all wireless sensing terminals are stitched together to obtain the image matrix.

[0025] Furthermore, the diffusion model includes:

[0026] The input module is used to expand the feature depth of the input feature map;

[0027] The U-net module is used to compress the spatial dimension of the input feature map through downsampling operations, and then reconstruct the spatial dimension of the compressed input feature map through upsampling operations. The residual module is used to perform class embedding during the downsampling and upsampling operations.

[0028] The output module is used to predict pseudo-feature maps based on the reconstructed input feature maps.

[0029] Furthermore, the loss function of the CSI data generation model for

[0030]

[0031] Where C is a constant, ∈ t The real noise added to the diffusion process, ∈ θ Let x0 be the fitting function for the model to predict noise during the reverse diffusion process, and t be the diffusion time step. Calculated as the mean.

[0032] Beneficial effects

[0033] By adopting the above-mentioned technical solution, the present invention has the following advantages and positive effects compared with the prior art:

[0034] (1) This invention expands CSI data into amplitude and phase matrices and splices them into a multi-channel image matrix, enabling the CSI data generation model to learn the complex distribution of CSI data in high-dimensional space;

[0035] (2) This invention vectorizes the labels corresponding to multi-class CSI data and embeds them into various processes of the U-Net architecture, enabling it to generate reliable new multi-class CSI data, thereby balancing the dataset and improving the robustness of the AI ​​model.

[0036] (3) When processing CSI data, this invention uses an encoder and decoder based on ViT (Vision Transformer) for data compression and reconstruction. On the one hand, it can better extract the effective information in the sparse CSI matrix, and on the other hand, it greatly optimizes the computational efficiency of the C-DDPMs model.

[0037] (4) By improving the ViT encoder, the present invention addresses the asymmetry of different dimensions of CSI data during position embedding by embedding fixed position codes in the subcarrier dimension and learnable position codes in the time dimension, thereby making the information contained in the extracted feature map more accurate and effective.

[0038] (5) By preprocessing the collected CSI data, especially by correcting the phase information, this invention can correct the phase discontinuity and phase error caused by imperfect hardware, making the pseudo data generated by the model more credible and the data distribution more balanced. Attached Figure Description

[0039] Figure 1 This is a structural diagram of the CSI data generation model according to an embodiment of the present invention;

[0040] Figure 2 This is a structural diagram of the ViT encoder and decoder according to an embodiment of the present invention;

[0041] Figure 3 This is a visual schematic diagram of the phase correction preprocessing of input CSI data according to an embodiment of the present invention;

[0042] Figure 4 This is a schematic diagram of the channel amplitude information and phase information of CSI data in a confined space according to an embodiment of the present invention;

[0043] Figure 5 This is a schematic diagram of the CSI pseudo-data generation process according to an embodiment of the present invention. Detailed Implementation

[0044] The present invention will be further illustrated below with reference to specific embodiments. It should be understood that these embodiments are for illustrative purposes only and are not intended to limit the scope of the invention. Furthermore, it should be understood that after reading the teachings of this invention, those skilled in the art can make various alterations or modifications to the invention, and these equivalent forms also fall within the scope defined by the appended claims.

[0045] This invention relates to a CSI pseudo-data generation method based on a diffusion model. It learns and mines the distribution characteristics of sparse data through a U-net network and generates multi-class CSI pseudo-data using randomly sampled Gaussian noise as input. This expands the sparse data categories without disrupting the original data distribution, thus balancing the training dataset. Specific steps include:

[0046] The first step, CSI data acquisition, is fundamental to WLAN sensing technology. First, CSI data is collected in a predetermined environment using a commercial router configured with the Nexmon tool. During data acquisition, the transmitter periodically sends wireless data packets, and the sniffer records multi-dimensional CSI data based on channel estimation results. The collected CSI data includes channel amplitude and phase information, reflecting characteristics such as signal attenuation and multipath effects.

[0047] The second step is data preprocessing: To improve the accuracy and efficiency of subsequent processing, the raw CSI data needs to be preprocessed. Preprocessing steps include data denoising, filtering, and normalization to eliminate background noise and signal variations caused by non-human activity. In addition, phase correction is required to correct phase errors caused by hardware limitations. Phase correction includes the following two steps:

[0048] 1) The phase unfolding step aims to correct phase discontinuities caused by hardware defects. Specifically, for consecutive subcarriers k and k+1, their phases are respectively... and Unwinding is performed based on the difference between adjacent phases to ensure phase continuity.

[0049] 2) The linear fitting step for phase error aims to further reduce the errors caused by packet detection delay (PDD), sampling frequency offset (SFO), and carrier frequency offset (CFO). A linear term for error correction is calculated by linearly fitting the expanded phase data. Let the subcarrier index be k. j Phase is The formula for calculating linear fitting is as follows:

[0050]

[0051]

[0052]

[0053] Where δ represents the sampling frequency offset, N is the total number of subcarriers, and β is the initial phase offset. This is achieved by subtracting the calculated linear term ak from the measured phase. j +b can provide more accurate phase information.

[0054] The third step is CSI-based image conversion: CSI, as a set of features presented by wireless signals propagating in the environment, can accurately reflect dynamic changes in the environment. This invention optimizes the processing method for sensing applications by converting multidimensional CSI data into an N-channel image. The specific value of N depends on the number of antennas used in the device. The amplitude and corrected phase are expanded in both the time dimension T and the subcarrier dimension K, both forming a two-dimensional CSI matrix. a {t×k} and CSI p {t×k} is used to superimpose several two-dimensional matrices of amplitude and phase to form a multi-channel image.

[0055] The fourth step is the compression and reconstruction of CSI images: When the number of antennas is large or the bandwidth is wide, the data volume of a single original CSI image will increase significantly. If the original data is directly input into the diffusion model based on the C-DDPMs algorithm for training, it will consume a lot of computing resources, usually requiring a server equipped with multiple high-performance GPUs. At the same time, the complexity of the input pattern also makes it difficult to extract key feature information. Therefore, this invention designs a ViT-based encoder and decoder to achieve the compression and reconstruction of CSI images, greatly reducing the computational pressure of C-DDPMs and optimizing the model's running efficiency. The ViT encoder and decoder need to be jointly pre-trained using the original CSI dataset. When embedded in the C-DDPMs model, the encoder and decoder are in a frozen state and their parameters are not updated.

[0056] Unlike the standard ViT model, in order to be suitable for CSI data, a two-dimensional hybrid position coding method is used in the encoder. Fixed position coding is used in the subcarrier dimension and learnable position coding is used in the time dimension, which can effectively add reasonable embedding vectors to address the asymmetry of these two dimensions.

[0057] After the raw CSI data is segmented and linearly vectorized, the image size changes from [S,T,A] to [S',T',dim], and the size of each segmentation patch is [ps,pt,A]. For images, the order of each patch also contains information; therefore, positional encoding information needs to be added to each patch so that subsequent feature extraction modules can learn the positional information. Compared to traditional RGB images, the "length" and "width" of CSI images are replaced by "subcarrier set" and "time series." The subcarrier set depends on the Wi-Fi protocol version and signal bandwidth of the device used. A sine / cosine positional encoding method is used, as shown in the following formula:

[0058]

[0059]

[0060] Among them, P s (x,y) represents the value of the x-th subcarrier and the y-th depth (total depth is dim) in the coding matrix.

[0061] Time series analysis involves capturing features such as the behavior, actions, and gait of a target object. Because these features are highly dynamic, such as the speed of actions and the pace of gait, a non-strict dynamic encoding method is used to capture these dynamic features. Specifically, a set of encoded data is first randomly initialized. This data serves as dynamic parameters and is trained along with the ViT model. Iterative updates are then performed based on the ViT model's loss function, ultimately yielding a learnable positional encoding P in the time dimension. t (θ).

[0062] These two positional encoding layers are superimposed on the image matrix. Since it is an additive superposition, the size is still [S',T',dim]. This is then input into the feature encoder for multi-layer multi-head self-attention and forward processing calculations to obtain the final CSI encoded feature map.

[0063] Step 5, C-DDPMs algorithm flow:

[0064] 1) The C-DDPMs model receives training set data in batches, compresses it using a ViT encoder, and then performs forward training to calculate the prediction noise. The loss value is calculated by comparing the difference between the predicted noise and the actual noise. The model parameters are optimized using backpropagation and the Adam optimizer. The loss function used in this invention is as follows:

[0065]

[0066] Where C is a constant, ∈ t The real noise added to the diffusion process, ∈ θ Let x0 be the fitting function for the model to predict noise during the reverse diffusion process, and t be the diffusion time step. Calculated as the mean.

[0067] The calculation of the loss value does not require traversing the entire set of time steps in the diffusion process, but only sampling multiple time steps to cover different stages of the diffusion process.

[0068] The single model training process is as follows:

[0069] a. Input Layer: The core of the model is a U-Net architecture, which expands the input CSI image x starting from a head module. t The channel dimension.

[0070] b. Embedding Layer: Time Embedding and Conditional Embedding are two key modules. They vectorize the progressive diffusion step size t and the category label, represented as t0. emb and C emb These two vectors are embedded in a series of residual blocks (ResBlocks) during the downsampling and upsampling processes.

[0071] c. Downsampling Layer: Downsampling blocks consist of several ResBlocks and downsampling operations (DownSample). The high-dimensional data output from the head is processed by down blocks for feature extraction, compressing the spatial dimension of the feature map while enhancing the feature depth. ResBlocks are connected via residuals.

[0072] d. Middle Blocks: Middle Blocks receive high-dimensional features from the downsampling layer and further deepen the feature extraction.

[0073] e. Upsampling layer: Up blocks consist of several ResBlocks and upsampling operations. Up blocks receive the output of intermediate layers and reconstruct the spatial dimensions.

[0074] f. Output Layer: The tail module compresses the dimensionality of the feature map output from the upsampling layer, generating prediction noise. Its dimensions are the same as the input CSI image x. t Consistent.

[0075] 2) The trained C-DDPMs model receives Gaussian noise as input, gradually removes the noise, and generates data.

[0076] The data generation process is as follows:

[0077] a. Input noise sampling: Data is sampled from isotropic Gaussian noise, with dimensions consistent with the compressed CSI features. Figure 1 To.

[0078] b. Image denoising: Based on the time steps used in the training process, predictive noise is generated and removed iteratively until a CSI feature map is generated.

[0079] c. Use the ViT decoder to reconstruct the CSI feature map into a CSI class image.

[0080] d. Synthetic data output: After image reconstruction is completed, CSI image data generated by different labels are imported into their respective data subsets to expand sparse data classification.

[0081] To make the objectives, technical solutions, and advantages of this disclosure clearer, the application of this embodiment in indoor wireless identification of personnel will be described below with reference to the accompanying drawings.

[0082] like Figure 1 As shown, the CSI data generation model comprises seven parts: a ViT encoder, a diffusion model, and a ViT decoder. The diffusion model includes a head module, downsampling blocks, intermediate blocks, upsampling blocks, and a tail module. The ViT encoder is a pre-trained module; its parameters remain fixed throughout the model training process and do not require updating. The encoder is responsible for compressing the 4-channel CSI raw image into a feature image. The head module expands the feature depth of the CSI feature map to 128 layers through a single convolutional layer. The downsampling blocks consist of 4 residual blocks and 3 downsampled layers. The residual blocks enhance the feature depth; each residual block receives input, performs group regularization, activation, convolution, temporal embedding, and conditional embedding, and then outputs the result. The output is connected to the upsampling blocks via residual connections. The downsampled layers compress the spatial dimension by accumulating the results of two convolutional layers. The intermediate blocks consist of two residual blocks, further enhancing the feature depth. The upsampling block consists of 4 residual blocks and 3 upsample layers. The upsample layer reconstructs the spatial dimensions through one deconvolutional layer and one convolutional layer. The tail module converts the feature depth to 2 layers through one deconvolutional layer and outputs the predicted noise value. calculate and the true value ∈ t The loss value is calculated, and the model parameters are optimized through backpropagation. The ViT decoder, like the ViT encoder, is a pre-trained module. During the data generation phase, after the model generates CSI feature map data, this feature is further input into the decoder to reconstruct a CSI image.

[0083] Figure 2 The specific structure of the ViT encoder and decoder is shown. The ViT encoder consists of patch segmentation, linear feature extraction, hybrid positional encoding embedding, and an encoder. It segments the original CSI image into several patches of the same size. Each patch is vectorized through a linear layer, and then positional information is added to the vector group through two-dimensional hybrid positional encoding. The vector group is then input into the encoder to complete feature encoding. The encoder consists of multi-layer attention and forward processing. In the ViT decoder, during the data generation stage, the CSI feature map generated by the C-DDPMs model is transformed from the feature map to the original image through multi-layer attention, cross-attention, and forward processing, and finally generates a reliable CSI amplitude and phase map.

[0084] Figure 3 This diagram illustrates the preprocessing of CSI data for phase correction. From left to right, it shows the original phase (a), the unwound phase (b), and the linearly fitted phase (c). On the coordinate axis, the x and y axes represent time and subcarrier indices, respectively. Each data set contains phase values ​​at 256 time points, spaced 10 ms apart. The number of subcarriers is reduced from the original 256 by removing the control subcarriers, leaving 234. The processed phase data reveals its inherent characteristics from its previously chaotic state.

[0085] Figure 4 This paper presents visualizations of CSI channel amplitude and corrected phase information for empty and occupied rooms, collected via a commercial router. (a) and (b) show the channel amplitude and phase information for an empty room, respectively, while (c) and (d) show the CSI for occupied rooms. The images reveal that the CSI changes are relatively stable in empty rooms, while CSI fluctuations are significant due to the substantial multipath effect caused by human activity. The channel amplitude and phase information are superimposed to form a CSI image, which is then used to train a CSI data generation model.

[0086] Figure 5 This diagram illustrates the process of generating CSI amplitude images by progressively denoising a model using trained CSI data. The experiment involved a 500-step diffusion and denoising process. The diffusion process was performed manually, progressively adding noise to the original image to create isotropic Gaussian noise. The denoising process used a C-DDPMs model to predict the distribution of the noise added at each step, using the Gaussian noise as input to progressively remove noise and generate a high-fidelity CSI pseudo-image. It can be seen that distinctive CSI amplitudes are gradually generated from chaotic noise. Generating sparse CSI data using the C-DDPMs model can supplement these sparse datasets, making the dataset distribution more balanced and thus optimizing the feature learning ability of the classification model.

Claims

1. A method for generating CSI pseudo data, characterized in that, Includes the following steps: Noisy image data is input into the CSI data generation model to obtain CSI pseudo data, which includes channel amplitude information and phase information; The CSI data generation model includes: An encoder is used to extract feature maps from an input image; A diffusion model is used to generate a pseudo-feature map based on the feature map; A decoder is used to restore the pseudo-feature map to CSI pseudo-data; The encoder is an improved ViT encoder, comprising: An image segmentation module is used to segment the input image into several image blocks of a preset size; The location embedding module is used to convert the image patch into an image patch vector and fuse the image patch vector with a two-dimensional hybrid location vector, wherein the two-dimensional hybrid location vector includes a fixed location code corresponding to the subcarrier dimension and a learnable location code corresponding to the time dimension. The feature extraction module is used to extract the autocorrelation features of the fused image patch vectors to obtain the feature map of the input image; The CSI data generation model is trained using the following method: Deploy multiple wireless sensing terminals to collect CSI data at different times; The CSI data acquired by different wireless sensing terminals are expanded along the time dimension and the subcarrier dimension and then fused into an image-like matrix. An image analysis model based on a transformer architecture is constructed using the encoder and the decoder. The image analysis model is then trained using the image-like matrix to obtain the trained encoder and the decoder. The CSI data generation model is trained using the image matrix to obtain the trained diffusion model.

2. The method according to claim 1, characterized in that, After the step of expanding and fusing the CSI data acquired by different wireless sensing terminals along the time dimension and subcarrier dimension into an image-like matrix, the method further includes a step of phase correction of the CSI data.

3. The method according to claim 1, characterized in that, The channels of the image matrix include all the channel amplitude information and phase information acquired by the wireless sensing terminal.

4. The method according to claim 3, characterized in that, The step of fusing the CSI data acquired by different wireless sensing terminals along the time and subcarrier dimensions into an image-like matrix includes: For the CSI data acquired by any of the wireless sensing terminals, the channel amplitude information and the phase information are expanded along the time dimension and the subcarrier dimension to obtain the amplitude matrix and the phase matrix, respectively. The amplitude matrix and phase matrix corresponding to all wireless sensing terminals are stitched together to obtain the image matrix.

5. The method according to claim 1, characterized in that, The diffusion model includes: The input module is used to expand the feature depth of the input feature map; The U-net module is used to compress the spatial dimension of the input feature map through downsampling operations, and then reconstruct the spatial dimension of the compressed input feature map through upsampling operations. The residual module is used to perform class embedding during the downsampling and upsampling operations. The output module is used to predict pseudo-feature maps based on the reconstructed input feature maps.

6. The method according to claim 1, characterized in that, The loss function of the CSI data generation model for in, It is a constant. Real noise added to the diffusion process. This is the fitting function for the model to predict noise during the reverse diffusion process. The original CSI image. For diffusion time step, Calculated as the mean.