Indoor positioning method based on C-L-ATT network model

By adopting the C-L-ATT network model in indoor positioning technology, combining convolutional neural networks and adaptive gating mechanisms, long-term memory networks and multi-head fusion adaptive attention mechanisms, the problem of signal interference and insufficient accuracy in indoor positioning is solved. It realizes high-precision and real-time indoor positioning services.

CN119211839AInactive Publication Date: 2024-12-27WUHU TECH & INNOVATION RES INST AHUT +1
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411232624.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-04
Publication Date
2024-12-27
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

When facing complex indoor environments, existing indoor positioning technology has problems such as signal interference, insufficient positioning accuracy and high data processing complexity, which is difficult to meet the needs of high precision and real-time positioning.

Method used

Using an indoor positioning method based on the C-L-ATT network model, combining convolutional neural networks, improved adaptive gating mechanism long short-term memory networks and multi-head fusion adaptive attention mechanisms, an efficient deep learning model is constructed, and BLE signals are preprocessed Intensity data, extract spatial and temporal features to achieve high-precision positioning.

Benefits of technology

It significantly improves the robustness and stability of the positioning system, maintains high accuracy in complex environments, reduces computing complexity, and realizes real-time and efficient positioning services.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119211839A_ABST
    Figure CN119211839A_ABST
Patent Text Reader

Abstract

The invention discloses an indoor positioning method based on a C-L-ATT network model. According to the method, a novel convolutional long short-term memory network model C-L-ATT is provided, the network model is formed by mixing three networks, the C network is a traditional convolutional neural network, an improved adaptive gating mechanism long short-term memory network AG-L is added to the L network, and an improved multi-head fusion adaptive attention mechanism M-HA is added to the ATT network. The method comprises the following steps: carrying out division by using collected and preprocessed data, dividing a plurality of training subsets to train a C-L-ATT network model, and then positioning an unknown position by using the trained model. According to the invention, high-precision indoor position positioning can be realized, and reliable positioning service can be provided.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to an indoor positioning method based on a CL-ATT network model, and in particular to indoor positioning algorithm optimization. Background Art

[0002] With the rapid development of the Internet of Things (IoT) and smart devices, indoor positioning technology has been widely used in smart buildings, smart factories, logistics management, security monitoring and other fields. Compared with the mature application of GPS in outdoor positioning, the complexity and variability of indoor environments make accurate indoor positioning technology face many challenges.

[0003] Bluetooth Low Energy (BLE) technology has become an important choice in indoor positioning systems due to its low cost, low power consumption and easy deployment. The fingerprint grid positioning technology based on BLE evenly deploys multiple BLE devices in the indoor area, collects the signal strength value (RSSI) at each fingerprint grid point, builds a fingerprint grid database, and uses the database for real-time positioning. However, the traditional fingerprint grid positioning method has the following main problems in practical applications:

[0004] (1) Signal interference and instability: Obstacles such as walls, furniture, and crowds in indoor environments will reflect, attenuate, and cause multipath effects on BLE signals, resulting in instability and noise in RSSI data. This signal interference seriously affects positioning accuracy.

[0005] (2) The need for high-precision positioning: As application scenarios become more complex and diverse, the requirements for indoor positioning accuracy are getting higher and higher. Existing BLE-based positioning methods still have deficiencies in accuracy and stability, and are difficult to meet the needs of certain high-precision positioning applications.

[0006] (3) Data processing and computational complexity: Large-scale fingerprint grid data requires efficient processing and computational methods. Traditional positioning algorithms are often inefficient when processing large-scale data and are difficult to achieve real-time positioning.

[0007] After searching, the Chinese patent application number is CN202410090259.3, and the application publication date is April 26, 2024. The patent application document discloses a WIFI indoor positioning method and system based on convolutional neural network. The method includes: measuring and recording the received WiFi signal strength and the corresponding actual position coordinates at various locations inside the preset building to form an original data set; processing the above original data set, including cleaning invalid or incomplete records, normalizing the WiFi signal strength, and quantizing the actual position coordinates; using the processed data set to train the CNN model, wherein the input of the CNN model is the WiFi signal strength and the output is the corresponding position coordinates; testing the trained CNN model to calculate the positioning accuracy of the CNN model; if the preset positioning accuracy requirements are met, the CNN model is used to realize indoor navigation; the user device automatically collects the current WiFi signal strength, inputs the CNN model to obtain the predicted position, and provides navigation services in combination with map information. However, it relies on the performance of the convolutional neural network, is limited by the ability of CNN to process time series data and long-term dependencies, lacks the ability to process time series data and long-term dependencies, and has insufficient positioning accuracy in complex environments.

[0008] After searching, the patent application document with Chinese patent application number CN202111637172.6 and application publication date June 27, 2023 discloses a Wi-Fi indoor positioning method based on CNN-RNN. The method includes: in the model training stage, the coordinate origin is selected in the positioning area, a coordinate system is established, and a grid is drawn at a specific spacing; Wi-Fi fingerprints are collected at each grid point and converted into a differential matrix to establish a fingerprint library based on grid points; after the fingerprint library is expanded using data enhancement, a fingerprint library based on pedestrian trajectories is generated using a trajectory generation method, and used as training data to train a positioning model based on CNN and RNN; Wi-Fi information is collected in real time during the positioning stage, and converted into a differential matrix fingerprint, which is combined with the positioning result of the model at the previous moment and input into the positioning model. However, although the fingerprint information of the historical state and the positioning result of the previous moment are combined, the positioning accuracy and stability are still insufficient in complex or dynamically changing environments (such as crowded public places).

[0009] To this end, the present invention proposes an indoor positioning method based on the CL-ATT network model, which aims to achieve high-precision indoor positioning by combining convolutional neural networks, an improved adaptive gating mechanism long short-term memory network (AG-L) and an improved multi-head fusion adaptive attention mechanism (M-HA) by constructing an efficient deep learning model CL-ATT. Summary of the invention

[0010] The purpose of the present invention is to provide an indoor positioning method based on the CL-ATT network model, in particular, by constructing a long short-term memory network (AG-L) with an improved adaptive gating mechanism and an ATT network with an improved multi-head fusion adaptive attention mechanism (M-HA) to improve the feature extraction and recognition capabilities of the model and achieve high-precision indoor positioning. The method aims to effectively solve the problems of signal interference, instability, insufficient positioning accuracy and high data processing complexity in the prior art, especially in complex indoor environments.

[0011] To achieve the above object, the present invention provides the following technical solutions:

[0012] The present invention proposes an indoor positioning method based on a CL-ATT network model, comprising the following steps:

[0013] Deploy Bluetooth Low Energy (BLE) devices, divide fingerprint grids in the target area, and collect the signal strength value (RSSI) at each fingerprint grid point;

[0014] Construct a fingerprint grid database, pre-process the collected signal strength values, including denoising and standardization, and construct a fingerprint grid database according to the positions of fingerprint grid points;

[0015] A new deep learning model CL-ATT is built, which combines convolutional neural network, improved adaptive gating mechanism long short-term memory network (AG-L), and ATT network with improved multi-head fusion adaptive attention mechanism (M-HA) to improve the feature extraction and recognition capabilities of the model;

[0016] Using the preprocessed fingerprint grid database, the data set is divided into multiple data subsets, the CL-ATT model is trained, and the model parameters are adjusted so that it can accurately learn and extract the spatial and temporal features of the fingerprint data;

[0017] The trained CL-ATT model is used to test new fingerprint data to achieve high-precision indoor positioning and verify the model's anti-interference ability in complex indoor environments.

[0018] Furthermore, collecting the signal strength value at each fingerprint grid point includes:

[0019] Evenly deploy multiple Bluetooth Low Energy (BLE) devices in the target indoor area to ensure that the BLE signal covers the entire area;

[0020] The indoor area is divided into equidistant grid points at one-meter intervals, and each grid point is used as a fingerprint collection point;

[0021] Use a mobile device to collect signal strength values ​​(RSSI) from all deployed BLE devices at each fingerprint grid point.

[0022] Furthermore, the construction of the fingerprint grid database includes:

[0023] The preprocessed RSSI data is smoothed using the deep learning Kalman filter (L-Ka lman) model;

[0024] According to the positions of fingerprint grid points, the preprocessed RSSI data are organized into a fingerprint grid database, and the database is divided into multiple data subsets as training sets and test sets for the deep learning model.

[0025] Furthermore, the improved adaptive gating mechanism long short-term memory network (AG-L) includes:

[0026] Calculate the forget gate, which determines the state C of the memory unit at the previous time step t-1 How much information is retained in the equation is as follows:

[0027] f t =σ(W f ·[h t-1 , x t ]+b f )+γ·tanh(W f,adaptive ·[h t-1 , x t ]+bf f,adaptive )

[0028] Here, the standard forget gate σ(W f ·[h t-1 , x t ]+b f ) calculates the forgetting ratio of the current time step, and the adaptive term γ·tanh(Wf f,adaptive ·[h t-1 , x t ]+bf f,adaptive ) Improves the model's ability to adapt to different environments and signal changes;

[0029] Calculate the input gate, which determines the new information at the current time step How much of it is written into the memory cell state, the formula is as follows:

[0030] i t =σ(W i ·[h t-1 , x t ]+b i )+γ·tanh(W i,adaptive ·[h t-1 , xt ]+b i,adaptive )

[0031] The introduction of adaptive terms enables the input gate to more flexibly control the writing of new information, improving the flexibility of the model in processing different signals;

[0032] Calculate the candidate memory cell state, which represents the potential information of the current time step. The formula is as follows:

[0033]

[0034] The adaptive term of the output gate improves the flexibility and accuracy of output control;

[0035] Calculate the hidden state, hidden state h t is the output of the AG-L network, containing the information of the time step, and the formula is as follows:

[0036] h t =o t *tanh(C t )

[0037] Hidden state h t It will be used for calculations at the next time step and for the final output of the model.

[0038] Furthermore, the improved multi-head fusion adaptive attention mechanism (M-HA) includes:

[0039] Calculate the query, key, and value matrices. Extract the query (Q), key (K), and value (V) matrices from the hidden state output by the AG-L network. The matrix formula is as follows:

[0040] Q=h t W Q

[0041] K=h t W K

[0042] V=h t W V

[0043] Among them, h t represents the hidden state output by the AG-L network, containing the information of the current time step, W Q represents the weight of the query matrix, W K represents the weight of the bond matrix, W V represents the weight of the value matrix;

[0044] Calculate the attention score and introduce adaptive terms. Calculate the dot product of the query and the key to get the attention score, and introduce adaptive terms to dynamically adjust the weight. The formula is as follows:

[0045]

[0046] in, represents the similarity between the query vector Q and the key vector K, d k Indicates the dimension of the key vector used to scale the dot product result, represents the contribution of the value vector in the weighted sum, represents a learnable bias vector used to adjust the attention score;

[0047] Calculate the output of each attention head and use the attention weight to perform weighted summation on the value matrix to get the output of each attention head. The formula is as follows:

[0048]

[0049] Among them, head i represents the weighted summation of the value vector by the attention weight;

[0050] Concatenate and linearly transform the output of the attention head: Concatenate the outputs of all attention heads together and obtain the final attention output through linear transformation. The formula is as follows:

[0051] M-HA(Q,K,V)=Concat(head1,head2,...,head h )W O

[0052] Concat represents the concatenation operation that concatenates the outputs of all attention heads together for subsequent linear transformation. o Represents the output weight matrix used to transform the concatenated vector to the final output space.

[0053] Furthermore, the data set is divided into a plurality of data subsets, including:

[0054] The preprocessed fingerprint grid dataset is divided into a training set and a validation set. The training set is used to train the model, and the validation set is used to evaluate the performance of the model and adjust the hyperparameters during the training process. The training set accounts for 75% of the total dataset.

[0055] In order to further evaluate the performance of the model, the cross-validation technique is used. The data set is divided into k subsets, and one subset is selected as the validation set in turn, and the remaining subsets are used as the training set. K training and validation are performed, and finally the k validation results are averaged to obtain the comprehensive performance index of the model.

[0056] Ensure that the data samples contained in each data subset are representative and diverse, covering a variety of possible environmental changes and signal interference situations. This helps improve the generalization ability and robustness of the model.

[0057] Furthermore, the anti-interference capability and robustness of the verification model in a complex indoor environment include:

[0058] Simulate the dynamic environment in actual application scenarios and test the positioning performance of the model under the conditions of moving personnel and equipment under the condition of constantly changing signals;

[0059] Conduct long-term continuous testing to observe the stability and performance changes of the model during long-term operation;

[0060] Tests were conducted under a variety of indoor environmental conditions, such as changing indoor furniture layout, occupant density, and activity conditions, to evaluate the model’s adaptability and stability in the face of different environmental interferences.

[0061] Compared with the prior art, the present invention has the following beneficial effects:

[0062] 1. The present invention proposes an indoor positioning method based on the CL-ATT network model, which can accurately extract the spatial and temporal features of RSSI data after data preprocessing. The fusion of convolutional neural networks and improved adaptive gating mechanism long short-term memory network (AG-L) and improved multi-head fusion adaptive attention mechanism (M-HA) further enhances the model's ability to understand and process complex signal patterns. The present invention significantly enhances the model's adaptability to signal interference, improves the robustness and stability of the positioning system, and can maintain high positioning accuracy even in environments with large signal fluctuations.

[0063] 2. The present invention has been fully verified under a variety of complex indoor environmental conditions to ensure that the model exhibits high robustness and stability in dynamic changes and long-term operation. Through the application of efficient data preprocessing and deep learning algorithms, the computational complexity is reduced, allowing the present invention to operate efficiently in a real-time environment and realize real-time and efficient positioning services. BRIEF DESCRIPTION OF THE DRAWINGS

[0064] Figure 1 It is a schematic diagram of the overall process of the present invention;

[0065] Figure 2 Schematic diagram of fingerprint grid division;

[0066] Figure 3 This is the data preprocessing flow chart;

[0067] Figure 4 Comparison chart before and after data preprocessing;

[0068] Figure 5 This is a deep learning model architecture diagram;

[0069] Figure 6 This is a comparison chart of the actual positioning point and the predicted point. DETAILED DESCRIPTION

[0070] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0071] See also Figures 1 to 6 The present invention provides a technical solution: an indoor positioning method based on the CL-ATT network model, referring to Figure 1 ,An overall flow diagram of an indoor positioning method based on the CL-ATT network model, the system includes deploying low-power Bluetooth (BLE) devices, dividing fingerprint grids in the target area, collecting the signal strength value (RSS I) at each fingerprint grid point; building a fingerprint grid database, pre-processing the collected signal strength values, including denoising and normalization, and building a fingerprint grid database according to the locations of the fingerprint grid points;

[0072] A new deep learning model CL-ATT is built, which integrates convolutional neural network and improved adaptive gating mechanism long short-term memory network (AG-L) and improved multi-head fusion adaptive attention mechanism (M-HA) to improve the feature extraction and recognition capabilities of the model; using the preprocessed fingerprint grid database, the dataset is divided into multiple data subsets, the CL-ATT model is trained, and the model parameters are adjusted so that it can accurately learn and extract the spatial and temporal features of fingerprint data; the trained CL-ATT model is used to test the new fingerprint data to achieve high-precision indoor positioning.

[0073] Reference Figure 2 , is a fingerprint grid division diagram, which shows how to divide fingerprint grid points in indoor areas. The interval between each grid point is 1 meter. The specific details are as follows:

[0074] 1. The figure shows a floor plan of a room. The room is divided into multiple equally spaced grid points by grid lines. The position of each grid point is represented by a black circle. The grid lines indicate that the interval between each fingerprint point is 1 meter.

[0075] 2. Ensure that fingerprint collection points are evenly distributed throughout the indoor area to provide a basis for subsequent RSSI signal strength data collection;

[0076] 3. Through grid division, the signal strength of different locations in the room can be systematically collected to form a detailed fingerprint database;

[0077] 4. Use a mobile device to collect signal strength values ​​(RSSI) from all deployed BLE devices at each fingerprint grid point;

[0078] 5. The uniform distribution of grid points ensures that the signal data collected at each point are comparable and consistent, reducing data deviations caused by environmental factors.

[0079] refer to Figure 3 , is a data preprocessing flow chart, which preprocesses the collected RSSI data and then feeds the preprocessed data into the deep neural network for training. The specific details are as follows:

[0080] 1. In the data collection phase, RSSI signal strength values ​​are collected from fingerprint grid points, and the RSSI signal strength values ​​from all deployed BLE devices are collected at each fingerprint grid point using a mobile device;

[0081] 2. In the noise removal stage, the collected RSS I data is subjected to noise removal processing; the RSS I data is smoothed using a moving average filter, and the formula is as follows:

[0082]

[0083] in, is the denoised RSSI data, N is the window size, x t is the raw RSSI data;

[0084] 3. In the filtering stage, the RSSI data is smoothed using the deep learning Kalman filter (L-Kalman) model. The prediction step formula is as follows:

[0085]

[0086] in, is the predicted RSSI state, F t is the state transition matrix, P t|t-1 is the predicted error covariance matrix, Q t is the process noise covariance;

[0087] The update step formula is as follows:

[0088]

[0089] P t|t=(I- K t H t)P t|t-1

[0090] Among them, k t is the Kalman gain, z t is the observed RSSI data, H t is the observation matrix, R t is the observation noise covariance, x t|t is the updated RSSI status, P t|t is the updated error covariance matrix;

[0091] 4. In the data standardization stage, the RSSI data is standardized. The standardization formula is as follows:

[0092]

[0093] Among them, x is the original RSSI data, μ is the mean of the data, σ is the standard deviation of the data, and x' is the standardized RSSI data.

[0094] refer to Figure 4 , which is a comparison chart before and after the data preprocessing, the data is preprocessed by L-Kalman algorithm to obtain the data after preprocessing.

[0095] refer to Figure 5 , is a deep learning model architecture diagram, which extracts and optimizes the features of fingerprint data by integrating convolutional neural networks, improved adaptive gating mechanism long short-term memory network (AG-L) and improved multi-head fusion adaptive attention mechanism (M-HA). The specific steps are as follows:

[0096] 1. Convolutional neural network (CNN) layer, input RSSI data into the convolution layer, and extract local spatial features through convolution operation. The formula is as follows:

[0097] X (l) =f(W (l) *X (l-1 )+b (l) )

[0098] Among them, X (l) is the output of layer l, W (l) is the convolution kernel of layer l, b (l) is the bias of the lth layer, and is the activation function;

[0099] 2. Improved adaptive gating mechanism Long Short-Term Memory Network (AG-L) layer, the spatial features extracted by the convolutional layer are input into the AG-L layer, and the temporal dependency is captured by the AG-L unit. The calculation formula of the forget gate is as follows:

[0100] f t =σ(Wf ·[h t-1 , x t ]+b f )+γ·tanh(W f,adaptive ·[h t-1 , x t ]+b f,adaptive )

[0101] The input gate calculation formula is as follows:

[0102] i t =σ(W i ·[h t-1 , x t ]+b i )+γ·tanh(W i,adaptive ·[h t-1 , x t ]+b i,adaptive )

[0103] The output gate calculation formula is as follows:

[0104] o t =σ(W o ·[h t-1 , x t ]+b o )+γ·tanh(W o,adaptive ·[h t-1 , x t ]+b o,adaptive )

[0105] The candidate memory cell state calculation formula is as follows:

[0106]

[0107] The formula for updating the memory unit state is as follows:

[0108]

[0109] The formula for calculating the hidden state is as follows:

[0110] h t =o t *tanh(C t )

[0111] 3. The Multi-Head Fusion Adaptive Attention Mechanism (M-HA) layer takes the hidden state output by the AG-L layer as input and calculates the query, key, and value matrices as follows:

[0112] Q=h t W Q

[0113] K=h tW K

[0114] V=h t W V

[0115] The formula for calculating the attention score and introducing the adaptive term is as follows:

[0116]

[0117] The formula for calculating the output of each attention head is as follows:

[0118]

[0119] The output formula of concatenating and linearly transforming the attention head is as follows:

[0120] M-HA(Q,K,V)=Concat(head1,head2,...,head h )W o

[0121] 4. Output layer: Input the optimized features of the multi-head fusion adaptive attention mechanism into the fully connected layer, map the extracted features to the final output space through the fully connected layer, and generate the predicted position coordinates.

[0122] Through the above steps, the convolutional neural network and the improved adaptive gating mechanism long short-term memory network (AG-L) and the improved multi-head fusion adaptive attention mechanism (M-HA) are integrated. The model can efficiently extract and optimize spatial and temporal features from RSSI data to achieve high-precision indoor positioning.

[0123] refer to Figure 6 This is a comparison diagram of the actual positioning point and the predicted point. The coordinates of the position to be measured are generated by using the RSSI data collected at the position to be measured and the trained CL-ATT network model, and then compared with the actual coordinates to calculate the deviation distance.

[0124] The above description is only an embodiment of the present specification and is not intended to limit the present specification. For those skilled in the art, the present specification may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present specification shall be included in the scope of the claims of the present specification.

Claims

1. An indoor positioning method based on the CL-ATT network model, characterized in that: The method specifically comprises the following steps: S1, data collection, divide the fingerprint grid in the target area, and collect the signal strength value at each fingerprint grid point; S2, data preprocessing, preprocessing the collected signal strength values, including denoising and standardization, and building a fingerprint grid database according to the positions of fingerprint grid points; S3. Build the CL-ATT network model, in which the L network adds the improved adaptive gating mechanism long short-term memory network (AG-L) and the ATT network adds the improved multi-head fusion adaptive attention mechanism (M-HA) to improve the feature extraction and recognition capabilities of the model; S4, training the CL-ATT network model, dividing the data set into multiple data subsets, training the CL-ATT network model, and adjusting the model parameters so that it can accurately learn and extract the spatial and temporal features of the fingerprint data; S5 establishes the positioning coordinates and uses the trained CL-ATT network model to locate the unknown location.

2. The method according to claim 1, characterized in that: In the step S2, when preprocessing the signal strength value, a fusion long-term and short-term Kalman filter model (L-Kalman) is proposed based on the Kalman filter model; The L-Kalman model uses a long short-term memory network model to predict the signal strength value at the next moment, and combines the prediction results of deep learning to perform state prediction in the prediction stage of Kalman filtering; according to the standard process of Kalman filtering, the error covariance prediction, Kalman gain, state update and error covariance update are calculated.

3. The method according to claim 1, characterized in that In step S3, a CL-ATT network model is constructed, wherein the L network is added with an improved adaptive gating mechanism long short-term memory network (AG-L), and the AG-L algorithm includes: f t =σ(W f ·[h t-1 ,x t ]+b f )+γ·tanh(W f,adaptive ·[h t-1 ,x t ]+b f,adaptive ) i t =σ(W i ·[h t-1 ,x t ]+b i )+γ·tanh(W i,adaptive ·[h t-1 ,x t ]+b i,adaptive ) o t =σ(W o ·[h t-1 ,x t ]+b o )+γ·tanh(W o,adaptive ·[h t-1 ,x t ]+b o,adaptive ) h t =o t *tanh(C t ) In the above formula: σ represents the Sigmoid activation function; x t represents the input vector of the current time step; h t-1 represents the hidden state vector of the previous time step; f t Represents the forget gate output of the current time step, which determines the memory cell state C of the previous time step t-1 How much of it is retained? t Represents the input gate output of the current time step, which determines how much new information is written into the memory cell state o t Represents the output gate output of the current time step, which determines the state of the memory cell C t How much of it is output to the hidden state h t ; Represents the candidate memory cell state at the current time step; C t Represents the state of the memory cell at the current time step; W f ,W i ,W o ,W G They are the weight matrices of the forget gate, input gate, output gate, and candidate memory cell states; b f ,b i ,b o ,b C They are the bias vectors of the forget gate, input gate, output gate and candidate memory cell states respectively; W f,adaptive ,W i,adaptive ,W o,adaptive ,W C,adaptive represents the weight matrix of the adaptive term; b f,adaptive ,b i,adaptive ,b o,adaptive ,b C,adaptive represents the bias vector of the adaptive term; γ represents the adjustment parameter in the adaptive mechanism, which is used to control the influence of the adaptive part on the final output, and its value is between 0 and 1.

4. The method according to claim 3, characterized in that: The improved adaptive gating mechanism long short-term memory network (AG-L) first uses the forget gate f t Determine the memory cell state C at the previous time step t-1 How much information is retained in the input gate i t Determine the new information for the current time step How much of it is written into the memory cell state? Then, calculate the candidate memory cell state Represents the potential information of the current time step; then, update the memory cell state C t , combining the memory of the previous time step and the new information of the current time step; After that, the output gate o t Determines the state of the memory cell C t Output to hidden state h t The size of the output gate increases the flexibility of output control; finally, the hidden state h t It will be used for calculations at the next time step and for the final output of the model.

5. The method according to claim 1, characterized in that In step S3, the ATT network adds an improved multi-head fusion adaptive attention mechanism (M-HA), where M-HA is composed of multiple single-head fusion adaptive attention mechanisms; Among them, the single-head fusion adaptive attention mechanism algorithm is as follows: Where: represents the attention score of the i-th attention head, which is generated by the dot product of the query vector and the key vector; represents the attention weight of the i-th attention head, which is calculated by the attention score and the adaptive term through the softmax function; represents the adaptive term, which is a learnable bias vector used to adjust the attention score.

6. The method according to claim 5, characterized in that The output algorithm of each attention head is as follows: Where: head i represents the output of the i-th attention head; The multi-head fusion adaptive attention mechanism algorithm is as follows: M-HA(Q,K,V)=Concat(head1,head2,…,head h )W O The above formula can be fully expressed as: Where: Q represents the topic modulus, which is generated by the input features; K represents the key matrix, which is generated by the input features; V represents the value matrix, which is generated by the input features; are the weight matrices of the query, key, and value of the i-th attention head respectively; d k Represents the dimension of the key vector, used to scale the dot product result; Concat represents a concatenation operation, which concatenates the outputs of all attention heads together for subsequent linear transformation; W O Represents the output weight matrix, which is used to transform the concatenated vector to the final output space; The improved multi-head fusion adaptive attention mechanism (M-HA) is used to obtain the hidden state h output by the AG-L network. t The query, key and value matrices are constructed as follows: Q = h t W Q ,K=h t W K ,V=h t W V , then calculate the attention score and introduce adaptive terms; by calculating multiple attention heads in parallel, different features and relationships can be captured.

Citation Information

Cited By

  • Dynamic environment robust indoor positioning method based on multi-source unsupervised domain adaptation

    CN120676313A