A Wi-Fi tracking method based on environmental obstacle constraint adaptation
By constructing a constrained adaptive Wi-Fi tracking model and a grayscale map automatic update mechanism, the problem of low positioning accuracy of device-free Wi-Fi tracking systems in complex indoor environments is solved, and efficient adaptive tracking is achieved under environmental changes.
Patent Information
- Application Number
- CN202411947263.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-27
- Publication Date
- 2025-10-10
- Estimated Expiration
- 2044-12-27
AI Technical Summary
Existing device-free Wi-Fi tracking systems ignore physical space constraints in complex indoor environments, resulting in low positioning accuracy and difficulty in adapting to environmental changes, requiring frequent retraining or labeling of models.
By building a constrained adaptive model, using environmental obstacle information for adaptive tracking, and combining the grayscale map automatic update mechanism and constraint enhancement training, the model's adaptability to environmental changes and positioning accuracy are improved.
It significantly reduces tracking errors and can automatically adapt to environmental changes without human intervention, thus improving positioning accuracy and system feasibility in complex scenarios.
Smart Images

Figure CN119835756B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of Wi-Fi tracking methods, in particular to a Wi-Fi tracking method based on environmental obstacle constraint adaptation. BACKGROUND
[0002] Device-free Wi-Fi tracking has become a research hotspot in the field of indoor tracking. This innovative approach does not require users to carry specific devices or sensors, which makes it show great potential in many emerging application scenarios, especially in the fields of elderly care and smart home. In addition, the seamless integration and privacy protection characteristics of this technology make users less worried about the leakage of personal information, so it is easier to be widely accepted and applied.
[0003] At present, the working principle of most device-free Wi-Fi tracking systems is that the movement of the user changes the propagation path of the signal, allowing the extraction of location features from the collected signal readings. Generally speaking, the smaller the signal noise, the higher the positioning accuracy.
[0004] Device-free Wi-Fi tracking implementation is usually divided into two categories: model-based methods and data-driven methods. Model-based methods extract signal features from raw Wi-Fi readings and then build models to infer user trajectories. However, it ignores the limitations in the physical space, such as the fact that human motion cannot pass through objects in the environment, which leads to a deviation of the prediction result from the actual situation, resulting in higher errors. Data-driven methods use deep learning techniques to integrate more information and improve positioning accuracy. However, when the environmental layout changes, such as rearranging furniture, the universality of the neural network will be affected. Adaptation to these changes usually requires re-collecting data or re-training the model, thereby reducing its practicality and scalability. In order to solve the above problems, the present application proposes a Wi-Fi tracking method based on environmental obstacle constraint adaptation. SUMMARY
[0005] 1. The technical problem to be solved by the present application
[0006] The purpose of the present application is to propose a Wi-Fi tracking method based on environmental obstacle constraint adaptation to effectively reduce the impact of noise caused by obstacles and the like in complex indoor scenes on tracking. The present application adaptively considers environmental obstacle constraints during tracking, making the generated trajectory more consistent with the actual situation and enabling automatic response to changes in environmental obstacle layout. The present application improves tracking accuracy in complex and variable scenarios without increasing labor costs, thereby enhancing the feasibility of deploying Wi-Fi device-free tracking in real indoor scenarios.
[0007] 2. Technical solution
[0008] To achieve the above object, the present application provides the following technical solutions:
[0009] A Wi-Fi tracking method based on environmental obstacle constraint adaptation, which adaptively considers environmental obstacle constraints during tracking to make the generated trajectory conform to the actual situation and automatically respond to changes in environmental obstacle layout, and the specific implementation method is as follows:
[0010] Building a constraint adaptive model: designing a device-free Wi-Fi tracking model containing environmental information, taking environmental obstacle features as input, generating fusion features for different environmental features while closely integrating with the tracking process;
[0011] Building a map automatic update mechanism: obtaining real-time accurate environmental information to improve tracking accuracy, using grayscale images generated from historical trajectory data to maintain and update the input map, and automatically adapting to the changing environmental layout;
[0012] Conducting constraint enhancement training: selecting trajectories near obstacles by filtering simulation data to improve the model's ability to learn constraint information; in the training stage, through data filtering and sequential freezing modules, the ability to learn constraints is enhanced.
[0013] Preferably, the constraint adaptive model comprises a PLCR extractor, a map encoder, a fusion module and a decision module;
[0014] The PLCR extractor is used to quickly retrieve preliminary trajectory features from the PLCR map; the method for obtaining PLCR by using the PLCR extractor comprises the following steps: first, based on CSI ratio and various filtering techniques, clean up the CSI data; then, apply short-time Fourier transform (STFT) to determine the time distribution of DFS and calculate the relevant PLCR; finally, use long short-term memory (LSTM) to extract the PLCR feature sequence and generate an initial trajectory feature vector;
[0015] The map encoder is used to identify the distribution and location of obstacles in the environment, first constructs an obstacle map as an input map, then designs an encoder to divide the constructed obstacle map into multiple sub-blocks, and extracts the distribution of 0 pixel values in each sub-block area image to obtain obstacle features;
[0016] The fusion module is used to integrate the map features into the preliminary trajectory features; the fusion module extends the map features by adding an additional dimension matching the sequence length in the initial trajectory features, and connects the two along the additional dimension to obtain a combined feature; and further adopts a Gated Recurrent Unit (GRU) network to process the obtained combined feature, dynamically refines the trajectory features with the obstacle information, to obtain rich fusion features;
[0017] The decision module is used to map the integrated features to the output trajectory, maps the fusion features by using a fully connected layer, and generates the final two-dimensional predicted trajectory coordinates; the decision module captures the influence of the fusion features on the predicted trajectory coordinates, and helps to constrain the adaptive model to learn the unreachable area caused by obstacles in the output space.
[0018] Preferably, the automatic map construction updating mechanism specifically includes the following contents:
[0019] Construct a probability grayscale map: introduce a probability matrix and a grayscale map, and represent the presence of obstacles in the environment area as a probability value, the size of which is proportional to the possibility of the presence of obstacles at that position; each value in the probability matrix corresponds to the probability of the presence of obstacles in the real environment;
[0020] Update the probability matrix: estimate the probability of the presence of obstacles at each point in the area using the historical trajectory of user behavior, and complete the update of the probability matrix;
[0021] Update the dynamic grayscale map: dynamically update the locally stored input map using the locally stored probability matrix, specifically including:
[0022] 1) Initialize the input map according to the environmental conditions;
[0023] 2) Generate predicted trajectories from the collected user data;
[0024] 3) Update the probability matrix according to the predicted trajectories, and determine whether the input map needs to be updated.
[0025] Preferably, the goal of the constraint-enhanced training is to:
[0026] 1) Minimize the distance between the predicted trajectory and the target trajectory;
[0027] 2) Minimize the intersection between the predicted trajectory and the obstacles;
[0028] The training target implementation process includes the following:
[0029] Use the mean square error to measure the distance between the predicted trajectory and the target trajectory:
[0030]
[0031] Among them, n represents the number of points on the target trajectory, (x i ,y i ) represents a point on the target trajectory, represents a point on the predicted trajectory;
[0032] An additional loss function is defined to quantitatively evaluate the intersection between the predicted trajectory and the obstacle to ensure that the loss function also supports gradient propagation. The F.grid_sample function in the PyTorch framework is used to query and extract pixel values from the specified position of the grid. The pixel value is extracted from the input obstacle map corresponding to each predicted trajectory point. The degree of intersection between the predicted trajectory and the obstacle is quantified by calculating the difference between the pixel value and the 1-pixel map, and then the obstacle loss is obtained. The specific function is expressed as:
[0033]
[0034] Among them, L OC Indicates the loss of obstacles, Represents the pixel value in the input obstacle map corresponding to the predicted trajectory point.
[0035] Preferably, the strategy of limiting enhanced training is:
[0036] The PLCR extractor, map encoder, fusion module, and decision module are divided into two parts for modular training. The specific contents are as follows:
[0037] The first part is the tracking network, which includes the PLCR extractor and decision model, and is used to implement basic tracking functions;
[0038] The second part is the map network, which consists of a map extractor and a fusion module, used to extract environmental information as auxiliary features;
[0039] The specific training process is as follows:
[0040] 1) Establish the basic tracking effect of the tracking network;
[0041] 2) Initialize the map network to ensure its compatibility with the tracking network;
[0042] 3) Filtering the training data to select cases where the predicted trajectory intersects with obstacles;
[0043] 4) Using the filtered data, combined with the mean square error and obstacle error, a fusion loss is designed to perform adversarial training on the map network.
[0044] 3. Beneficial effects
[0045] (1) The present invention uses a neural network to learn the constraints imposed by obstacles on the motion trajectory, integrates environmental information and adaptively uses environmental information for tracking, and uses the distribution of objects in the environment to correct trajectories that are inconsistent with physical logic, thereby significantly reducing tracking errors.
[0046] (2) This paper introduces a grayscale map to represent the probability of obstacle presence, which is updated using historical trajectory data. This method can operate continuously in a changing environment, automatically detect changes in obstacle layouts, and dynamically update and maintain the obstacle map to adapt to the new configuration without the need for retraining or relabeling.
[0047] (3) Through a large number of experiments, the present invention verifies that the proposed Wi-Fi tracking technology based on environmental obstacle constraint adaptation can reduce tracking errors by up to 49.48% in various complex environments, and successfully deploys the model on embedded devices with low computing power and low memory, meeting the requirements of low latency and low energy consumption. BRIEF DESCRIPTION OF THE DRAWINGS
[0048] Figure 1 This is a flow chart of a Wi-Fi tracking method based on environmental obstacle constraint adaptation proposed by the present invention;
[0049] Figure 2 This is a flowchart of the map construction method and obstacle feature extraction mentioned in Example 1 of the present invention;
[0050] Figure 3 This is a schematic diagram of the dynamic grayscale map self-update mechanism mentioned in Example 1 of the present invention;
[0051] Figure 4 A comparison chart of the prediction effect (a) of the baseline model mentioned in Example 1 of the present invention and the prediction effect (b) of the present invention;
[0052] Figure 5 These are the overall error comparison statistics diagram (a) of scenario 1 and the overall error comparison statistics diagram (b) of scenario 2 mentioned in Example 1 of the present invention. DETAILED DESCRIPTION
[0053] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the specific embodiments of the present invention are described in detail below with reference to the accompanying drawings.
[0054] In the following description, many specific details are set forth to facilitate a full understanding of the present invention. However, the present invention may also be implemented in other ways different from those described herein. Those skilled in the art may make similar generalizations without violating the connotation of the present invention. Therefore, the present invention is not limited to the specific embodiments disclosed below.
[0055] Secondly, the term "one embodiment" or "embodiment" herein refers to a specific feature, structure, or characteristic that may be included in at least one implementation of the present invention. The phrase "in one embodiment" appearing in various places throughout this specification does not necessarily refer to the same embodiment, nor does it refer to a separate or selective embodiment that is mutually exclusive of other embodiments.
[0056] The present invention proposes a device-free Wi-Fi tracking method that dynamically integrates environmental information, representing objects that hinder the user's movement in an indoor environment (such as furniture and walls) as obstacles, and recording the layout of obstacles in the environment as environmental information, while obstacle constraints indicate that the user's movement trajectory cannot pass through these objects. The environmental obstacle constraint-adaptive Wi-Fi tracking framework designed by the present invention designs a lightweight dual-branch model to effectively integrate environmental information with Wi-Fi signal characteristics. At the same time, the present invention proposes an automatic map update mechanism that enables the system to adapt to changes in the environmental layout without human intervention. Finally, a data-driven phased training strategy is implemented to improve the model's ability to learn constraints. The present invention successfully solves the challenges of traditional device-free tracking methods that ignore the restrictions of environmental objects on human movement and require extensive retraining or map reconstruction when the environmental layout changes.
[0057] Explanation of terms:
[0058] Wi-Fi passive positioning is a technology that determines a user's location by analyzing Wi-Fi signals reflected off the human body. Unlike active positioning, Wi-Fi passive positioning does not require users to carry additional equipment, such as sensors. Instead, it locates the user by analyzing the physical characteristics of the reflected signals.
[0059] Channel State Information (CSI) is a type of information used to represent channel conditions in wireless communications. CSI includes data such as the signal's amplitude, frequency, and phase, reflecting the effects of factors such as power attenuation and scattering on signal propagation.
[0060] A recurrent neural network (RNN) is a neural network architecture specifically designed for processing sequential data. By establishing connections between nodes and introducing data dependencies in the temporal dimension, RNNs enable the model to possess a certain level of memory and the ability to process temporal information.
[0061] The path length change rate (PLCR) refers to the rate at which a signal's path length changes after reflecting from the human body. It is a key factor contributing to Doppler frequency shift (DFS). Based on Fresnel zone theory, analyzing the PLCR can determine the normal velocity along a specific signal link. By synthesizing the normal velocities of multiple links, the user's actual velocity and direction can be determined, enabling positioning.
[0062] Feature fusion refers to the integration of information from different sources or feature sets during data processing and analysis to improve model performance and accuracy. Feature fusion combines the strengths of individual features and synthesizes information from multiple features to achieve a more comprehensive and effective data representation.
[0063] Environmental Obstacle Constraints refer to objects in the environment, such as furniture and walls, that impede a user's movement. This restricts their range of movement and makes certain areas inaccessible, creating physical spatial constraints imposed by obstacles. These constraints prevent human movement from traversing obstacles and dictate that movement paths adhere to physical logic.
[0064] Based on the above content, the following describes a Wi-Fi tracking method based on environmental obstacle constraint adaptation proposed by the present invention in conjunction with a specific example. The specific content is as follows.
[0065] Example 1:
[0066] This paper uses a lightweight model to integrate environmental information and Wi-Fi features, enabling the use of environmental information to correct predicted trajectories. It also proposes a probabilistic grayscale map that is updated based on historical trajectory data and establishes an automatic update mechanism, allowing the model to effectively adapt to new layouts and avoiding manual map reconstruction. Furthermore, it adopts a data-driven strategy to accurately simulate environmental constraints by generating data that reflects real-world obstacles. It introduces obstacle loss to minimize trajectory error and ensure minimal intersection with obstacles. The specific implementation method includes the following three parts:
[0067] Build a constrained adaptive model:
[0068] To leverage environmental information to improve tracking accuracy and enable the model to handle diverse obstacle distributions, this paper innovatively incorporates environmental features as model input, thereby constructing a Wi-Fi-based device-free tracking model with adaptively learned obstacle constraints. The model's input consists of two components: PLCR features derived from Wi-Fi data and image features based on the layout of environmental obstacles. The model utilizes the Wi-Fi modality as the primary modality, incorporating environmental information while maintaining pristine tracking performance. Furthermore, by utilizing images as an auxiliary source of tracking information, the constraints imposed on user motion by environmental obstacles are incorporated into the tracking model. This approach integrates these two heterogeneous signal types, ensuring that the model can effectively adapt to various obstacle layouts.
[0069] The model mainly consists of four modules: a PLCR extractor that quickly retrieves preliminary trajectory features from the PLCR map; a map encoder that identifies the distribution and location of obstacles in the environment; a fusion module that integrates map features into preliminary trajectory features; and a decision module that maps the integrated features to the output trajectory.
[0070] PLCR Extractor: User movement changes the reflection path length, causing the received signal frequency to change accordingly, which is called Doppler frequency shift (DFS). In order to achieve device-free tracking, it is necessary to analyze the DFS and the corresponding PLCR and convert the PLCR into the user's actual speed. The method for obtaining PLCR includes the following steps: first, the CSI data is cleaned based on the CSI ratio and various filtering techniques; then, the short-time Fourier transform (STFT) is applied to determine the time distribution of DFS and calculate the related PLCR. Finally, the long short-term memory (LSTM) is used to extract the PLCR feature sequence and generate the initial trajectory feature vector.
[0071] Map Encoder: In order to extract the obstacle features required for learning constraints from the environment, we first need to build an input map and then design an encoder to extract obstacle features from the image. In practical applications, there are various effective methods to obtain a planar top view of the environment obstacle layout. Figure 2As shown, first, a proportional blank two-dimensional schematic diagram (called a blank map) is created based on the actual area of the environment, and all pixel values are set to 1. According to the view layout, the pixels corresponding to the area occupied by the obstacle are marked as 0 on the blank map. Finally, all pixel values are merged into a black and white image, namely the obstacle map, which serves as the input of the model. This labeling method can clearly represent the spatial distribution of obstacles in the environment and avoids the cumbersome description of the environmental space. The present invention designs a map encoder, which divides the obstacle map into multiple sub-blocks and extracts the distribution of 0 pixel values in each sub-area image to obtain obstacle features.
[0072] Fusion module: The initial trajectory features are three-dimensional vectors of variable size (B, L, H), where B corresponds to the batch size, L represents the sequence length (variable length, depending on the duration of actual data collection), and H represents the number of features at each time step. The map features are represented as a two-dimensional vector of fixed length, denoted as (B, R), where B represents the batch size and R represents the number of features. The present invention expands the map features by adding an extra dimension that matches the size of L in the initial trajectory features, and connects the two along this dimension to obtain combined features. In order to utilize environmental information to achieve coordinate-level correction, the module uses a gated recurrent unit (GRU) network to process the connected combined features, so that the trajectory features can be dynamically refined using obstacle information to obtain rich fusion features.
[0073] Decision Module: This module uses a fully connected layer to map the fused features and generate the final two-dimensional predicted trajectory coordinates. The fully connected layer effectively captures the impact of the fused features on the predicted trajectory coordinates, helping the model learn to identify inaccessible areas in the output space caused by obstacles.
[0074] Build an automatic map update mechanism:
[0075] In practical applications, the initial distribution of obstacles can be difficult to determine and may change dynamically over time, necessitating regular updates to map information. While the manual update process is straightforward, the frequent need for updates makes it cumbersome and inefficient. Therefore, this paper proposes a probabilistic grayscale map concept and an automatic map update mechanism to address situations where the initial environment layout is unknown or the layout of environmental objects changes frequently. This method eliminates the need for secondary annotation of the input map and additional model training, thereby improving the system's flexibility and efficiency in practical applications.
[0076] Probabilistic grayscale map: In environments where the initial positions of obstacles are unknown or change frequently, re-marking map input may be delayed or inaccurate. When the static binary obstacle feature map does not reflect the current state, significant errors may result, especially when the new trajectory intersects with the area previously occupied by the obstacle. To solve this problem, the present invention introduces a probability matrix and a grayscale map. Specifically, the presence of obstacles in the environment area is represented as a probability value, where a higher value indicates a greater likelihood of an obstacle appearing at that location. Each value in the probability matrix corresponds to the probability of an obstacle existing in the real environment.
[0077] User behavior probability matrix update: This method uses historical test trajectories to estimate the probability of an obstacle at each point in the area. Since the probability of obstacles appearing in areas covered by historical trajectories is low, the probability of areas covered by these user behaviors can be reduced during the update process.
[0078] Dynamic grayscale map update: This paper proposes a mechanism to update the input map based on historical test trajectories. This mechanism establishes an automatic update framework and dynamically updates the locally stored input map using the locally stored probability matrix, such as Figure 3 It consists of three parts: 1) Initializing the input map according to environmental conditions; 2) Generating predicted trajectories from collected user data; 3) Updating the probability matrix based on the predicted trajectory to determine whether the input map needs to be updated. This framework ensures the timeliness and accuracy of the input map and provides a robust data foundation for trajectory correction using environmental information. During the tracking process, only the initialization of the map is required. Figure 1 The input map is then stored locally, eliminating the need for the user to input map information for each trajectory prediction. The received PLCR features are combined with the locally stored map to generate the current predicted user trajectory, thereby updating the probability matrix. When the map needs to be updated, a grayscale map is generated based on the updated probability matrix to reduce potential discrepancies in trajectory predictions due to outdated map information. Finally, the grayscale map replaces the input map, enabling automatic updating of map information. This mechanism allows the input map to be automatically updated without the need for manual reconstruction.
[0079] Limiting Plyometric Training:
[0080] After determining the model architecture and workflow, the model is trained to adapt it to the task. During model training, two main objectives are expected to be achieved: 1) minimizing the distance between the predicted trajectory and the target trajectory and 2) minimizing the intersection between the predicted trajectory and obstacles.
[0081] Obstacle loss: Existing methods use mean squared error (MSE) to measure the distance between the predicted trajectory and the label:
[0082]
[0083] Where n represents the number of points on the trajectory, (x i ,y i ) represents a point on the marker trajectory, represents a point on the predicted trajectory. However, L MSE Without considering the inaccessible areas caused by obstacles, it cannot fully meet the training requirements. Therefore, an additional loss function must be defined to quantitatively evaluate the intersection between the predicted trajectory and obstacles to ensure that this loss function also supports gradient propagation. By utilizing the F.grid_sample function in the PyTorch framework (which accepts input tensors and grid tensors), efficient querying and extracting pixel values from the locations specified by the grid are performed. Using this function, pixel values are extracted from the input obstacle map corresponding to each predicted trajectory point. The degree of intersection between the predicted trajectory and the obstacle is quantified by calculating the difference between these pixel values and the 1-pixel map, thereby obtaining the obstacle loss L OC :
[0084]
[0085] Model training strategy: The model designed by the present invention has a dual-branch structure with Wi-Fi features as the main form. In addition, since the model needs to learn how to use obstacle restrictions to correct trajectories and reduce errors while ensuring basic tracking accuracy, the present invention divides the four modules into two parts for modular training: the first is the tracking network, which includes a PLCR extractor and a decision model to achieve basic tracking functions; the second is the map network, which consists of a map extractor and a fusion module to extract environmental information as an auxiliary feature. The training process is divided into four stages: the first stage is to establish the basic tracking effect of the tracking network; the second stage is to initialize the map network to ensure its compatibility with the tracking network; the third stage is to screen the training data to select cases where the predicted trajectory intersects with obstacles; the fourth stage is to use the screened data and the fusion loss that combines the mean square error and the obstacle error to perform adversarial training on the map network. By gradually freezing the model training and data augmentation, the model's ability to use obstacle restrictions to correct trajectories and reduce errors is enhanced.
[0086] Comparative experimental verification:
[0087] In order to verify the trajectory correction effect and versatility of the present invention, two different environments (tracking ranges of 3m×6m and 6m×6m respectively) were selected for testing, and a network without obstacle restrictions was used as a comparison for the proposed method, which was recorded as the baseline model. Figure 4-5 As shown, Figure 4Comparison of tracking effects of the same data under the baseline model (a) and the present invention model (b); Figure 5 The overall error comparison statistics for scenario 1 (a) and scenario 2 (b) are shown. Figure 4-5 It can be seen from the content that the trajectory predicted by the present invention can pass through fewer obstacles and achieve higher tracking accuracy.
[0088] The above description is only a preferred specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any technician familiar with the technical field can make equivalent replacements or changes based on the technical solutions and improved concepts of the present invention within the technical scope disclosed by the present invention, and these changes should be covered by the scope of protection of the present invention.
Claims
1. A Wi-Fi tracking method based on environmental obstacle constraint adaptation, characterized in that: This method adaptively considers environmental obstacle constraints during tracking, making the generated trajectory consistent with the actual situation and automatically responding to changes in the layout of environmental obstacles. The specific implementation method is as follows: Build a constrained adaptive model: Design a device-free Wi-Fi tracking model that incorporates environmental information. This model takes environmental obstacle features as input, tightly integrates with the tracking process, and generates fused features tailored to different environmental characteristics. Build an automatic map update mechanism: obtain real-time and accurate environmental information to improve tracking accuracy, maintain and update the input map using grayscale images generated from historical trajectory data, and automatically adapt to the changing environment layout; Constraint-augmented training: Trajectories near obstacles are selected by filtering simulated data to improve the model’s ability to learn constraints. During training, data filtering and sequential freezing modules are used to enhance the ability to learn constraints. The goals of constraint-augmented training are: 1) Minimize the distance between the predicted trajectory and the target trajectory; 2) Minimize the intersection between the predicted trajectory and the obstacle; The training goal achievement process includes the following: The mean square error is used to measure the distance between the predicted trajectory and the target trajectory: in, n represents the number of points on the target trajectory, ( x i , y i ) represents a point on the target trajectory, represents a point on the predicted trajectory; An additional loss function is defined to quantitatively evaluate the intersection between the predicted trajectory and the obstacle to ensure that the loss function also supports gradient propagation. The F.grid_sample function in the PyTorch framework is used to query and extract pixel values from the specified position of the grid. The pixel value is extracted from the input obstacle map corresponding to each predicted trajectory point. The degree of intersection between the predicted trajectory and the obstacle is quantified by calculating the difference between the pixel value and the 1-pixel map, and then the obstacle loss is obtained. The specific function is expressed as: in, L OC Indicates the loss of obstacles, Represents the pixel value in the input obstacle map corresponding to the predicted trajectory point.
2. The Wi-Fi tracking method based on environmental obstacle constraint adaptation according to claim 1, characterized in that: The constraint adaptive model includes a PLCR extractor, a map encoder, a fusion module and a decision module; The PLCR extractor is used to quickly retrieve preliminary trajectory features from the PLCR map; The method for obtaining PLCR using the PLCR extractor includes the following steps: first, the CSI data is cleaned based on the CSI ratio and various filtering techniques; then, a short-time Fourier transform is applied to determine the temporal distribution of the DFS and calculate the associated PLCR; finally, a long short-term memory is used to extract the PLCR feature sequence and generate the initial trajectory feature vector; The map encoder is used to identify the distribution and location of obstacles in the environment. First, an obstacle map is constructed as an input map. Then, an encoder is designed to divide the constructed obstacle map into multiple sub-blocks and extract the distribution of zero pixel values in the image of each sub-block area to obtain obstacle features. The fusion module is used to integrate map features into preliminary trajectory features. The fusion module expands the map features by adding an extra dimension that matches the sequence length of the initial trajectory features and concatenates the two along the extra dimension to obtain a combined feature. The combined feature is further processed using a gated recurrent unit network, and the trajectory features are dynamically refined using obstacle information to obtain a rich fused feature. The decision module is used to map the integrated features to the output trajectory, use a fully connected layer to map the fused features, and generate the final two-dimensional predicted trajectory coordinates; the decision module captures the impact of the fused features on the predicted trajectory coordinates, helping the constraint adaptive model learn the inaccessible areas caused by obstacles in the output space.
3. The Wi-Fi tracking method based on environmental obstacle constraint adaptation according to claim 2, characterized in that: The map automatic update mechanism specifically includes the following contents: Constructing a probabilistic grayscale map: A probability matrix and a grayscale map are introduced to represent the presence of obstacles in the environment as a probability value. The size of the probability value is proportional to the likelihood of an obstacle appearing at that location. Each value in the probability matrix corresponds to the probability of an obstacle existing in the real environment. Update the probability matrix: Use the user's historical behavior trajectory to estimate the probability of an obstacle at each point in the area and complete the update of the probability matrix; Update dynamic grayscale map: Use the locally stored probability matrix to dynamically update the locally stored input map, including: 1) Initialize the input map based on environmental conditions; 2) Generate predicted trajectories from collected user data; 3) Update the probability matrix based on the predicted trajectory to determine whether the input map needs to be updated.
4. The Wi-Fi tracking method based on environmental obstacle constraint adaptation according to claim 3, characterized in that: The strategy of the restriction enhancement training is: The PLCR extractor, map encoder, fusion module, and decision module are divided into two parts for modular training. The specific contents are as follows: The first part is the tracking network, which includes the PLCR extractor and decision model, and is used to implement basic tracking functions; The second part is the map network, which consists of a map extractor and a fusion module, used to extract environmental information as auxiliary features; The specific training process is as follows: 1) Establish the basic tracking effect of the tracking network; 2) Initialize the map network to ensure its compatibility with the tracking network; 3) Filtering the training data to select cases where the predicted trajectory intersects with obstacles; 4) Using the filtered data, combined with the mean square error and obstacle error, a fusion loss is designed to perform adversarial training on the map network.