Business district consumer population dynamic prediction method and system based on unmanned aerial vehicle identification
Through drones, the visible light image sequence of the business district is obtained, and the multi-task feature extraction and space-time dynamic prediction model is used to solve the problem of insufficient resource consumption and timeliness in traditional methods, real-time and accurate prediction of the consumer population in the business district is achieved, and the scientific nature of business district operation and management is improved.
Patent Information
- Application Number
- CN202510931831.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-07
- Publication Date
- 2025-08-08
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Traditional business district consumer population prediction methods rely on manual surveys and ground sensors, consume resources and cannot reflect the dynamic changes of consumer population in real time and accurately. Analysis based on historical data ignores the spatial and temporal correlation.
The visible light image sequence marked with continuous timestamps is obtained by low-altitude drones, and a pre-trained multi-task feature extraction network is used to generate three-dimensional feature tensors, combining the spatiotemporal dynamic prediction model and confidence verification module to predict consumer population distribution.
It realizes comprehensive, real-time and accurate prediction of the consumer population in the business district, improves the credibility and reliability of the prediction results, and helps scientific business district operation management and resource optimization.
Smart Images

Figure CN120451841A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of artificial intelligence technology, and in particular to a method and system for dynamically predicting the consumer population in a business district based on drone identification. Background Art
[0002] In the commercial operations sector, accurately predicting consumer demographics within a commercial district is crucial for business planning, resource allocation, and marketing strategy development. Traditional methods for predicting consumer demographics in commercial districts rely primarily on manual surveys, ground-based sensor data collection, and simple statistical analysis based on historical data. Manual surveys are not only labor-intensive, material-intensive, and time-consuming, but also lack the accuracy and timeliness of survey results, failing to reflect real-time dynamics of the consumer population within the commercial district. While ground-based sensors can collect crowd flow data to a certain extent, their coverage is limited, capturing only localized information and requiring high installation and maintenance costs. Simple statistical analysis based on historical data ignores the spatiotemporal correlations and complexity of consumer demographics within a commercial district, making it difficult to accurately predict future consumer demographic distribution. Summary of the Invention
[0003] In view of the above-mentioned problems, in combination with the first aspect of the present invention, an embodiment of the present invention provides a method for dynamically predicting the consumer population in a business district based on drone identification, the method comprising: Acquire a drone visible light image sequence containing continuous time stamps, wherein the drone visible light image sequence is composed of multiple frames of images continuously captured by a low-altitude drone in a commercial area; Performing end-to-end feature extraction on the visible light image sequence of the UAV through a pre-trained multi-task feature extraction network to generate a three-dimensional feature tensor containing crowd density distribution features, individual movement trajectory features, and group aggregation morphology features; Calling the spatiotemporal dynamic prediction model to perform time series correlation and spatial mapping processing on the three-dimensional feature tensor to generate consumer population distribution prediction results for multiple consecutive time periods in the future in the business district area; Perform historical trend matching analysis on the consumer population distribution prediction results through a confidence verification module, and output verification data including prediction confidence scores and key change periods; A dynamic prediction report including a correspondence between a time dimension and a spatial region is generated based on the verification data.
[0004] On the other hand, an embodiment of the present invention also provides a system for dynamically predicting the consumer population in a business district based on drone identification, including a processor and a machine-readable storage medium, wherein the machine-readable storage medium is connected to the processor, the machine-readable storage medium is used to store programs, instructions or codes, and the processor is used to execute the programs, instructions or codes in the machine-readable storage medium to implement the above method.
[0005] Based on the above aspects, the embodiments of the present invention can comprehensively and real-timely acquire crowd dynamic information in a commercial district by acquiring a sequence of visible light images from a drone containing continuous timestamps. Using a pre-trained multi-task feature extraction network to perform end-to-end feature extraction on the image sequence, a three-dimensional feature tensor can be simultaneously generated, including crowd density distribution characteristics, individual movement trajectory characteristics, and group aggregation morphology characteristics. This comprehensively and accurately characterizes the dynamic characteristics of the consumer population in the commercial district. The spatiotemporal dynamic prediction model performs temporal correlation and spatial mapping on the three-dimensional feature tensor, fully considering the temporal and spatial correlation of the consumer population dynamics in the commercial district. This allows for more accurate predictions of the consumer population distribution in the commercial district for multiple consecutive time periods in the future. The confidence verification module performs historical trend matching analysis on the prediction results and outputs verification data including prediction confidence scores and key change periods, thereby improving the credibility and reliability of the prediction results. Finally, based on the verification data, a dynamic prediction report is generated, which contains the correspondence between the time dimension and the spatial region. This helps the commercial district achieve more scientific operation management and optimize resource allocation, thereby enhancing commercial competitiveness. BRIEF DESCRIPTION OF THE DRAWINGS
[0006] Figure 1 The figure is a schematic diagram of the execution flow of the method for dynamically predicting the consumer population in a commercial district based on drone identification provided by an embodiment of the present invention.
[0007] Figure 2 Schematic diagram of exemplary hardware and software components of a system for predicting dynamic consumer population in a commercial district based on drone identification provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0008] The present invention will be described in detail below with reference to the accompanying drawings. Figure 1 The figure is a flow chart of a method for dynamically predicting the consumer population in a business district based on drone identification provided by an embodiment of the present invention. The method for dynamically predicting the consumer population in a business district based on drone identification is introduced in detail below.
[0009] Step S110: Acquire a drone visible light image sequence containing continuous time stamp marks, wherein the drone visible light image sequence is composed of multiple frames of images continuously captured by a low-altitude drone in a commercial area.
[0010] This embodiment focuses on a specific business district. In order to accurately predict the dynamic situation of the consumer population in this business district, a low-altitude drone is deployed over the business district to collect images according to a pre-set flight route and time interval. Each time a frame of image is collected, it is automatically marked with a continuous timestamp. Thus, multiple frames of images with time information together constitute a visible light image sequence of the drone. For example, the drone flies along the main streets and key areas of the business district, taking an image at fixed intervals. As the flight process continues, images with different timestamps are continuously accumulated, and the images cover the scene information of the business district at different times. This image sequence contains information such as the activities of people in the business district, the business status of stores, and real-time changes in the surrounding environment.
[0011] Step S120: performing end-to-end feature extraction on the UAV visible light image sequence through a pre-trained multi-task feature extraction network to generate a three-dimensional feature tensor including crowd density distribution features, individual movement trajectory features, and group aggregation morphology features.
[0012] After acquiring the drone visible light image sequence, the next step is to extract features from these images to uncover key information related to consumer demographics within the shopping district. The pre-trained multi-task feature extraction network, trained on a large amount of data, possesses robust feature extraction capabilities. It processes the input drone visible light image sequence end-to-end, directly outputting the required features from the raw drone visible light image data. Specifically, the multi-task feature extraction network extracts three features from the drone visible light image sequence: crowd density distribution, individual movement trajectory, and group aggregation morphology. Crowd density distribution reflects the density of people in different areas of the shopping district, while individual movement trajectory records the movement paths of individuals within the district, helping to analyze consumer behavior preferences and shopping habits. Group aggregation morphology describes the shape and size of crowd gatherings, revealing popular activity areas and crowd aggregation patterns within the district. These three features are then integrated into a three-dimensional feature tensor.
[0013] Step S121: Input the drone visible light image sequence into the input processing layer of the multi-task feature extraction network, perform pixel value normalization processing on the drone visible light image sequence through the input processing layer and adjust it to the uniform resolution size preset by the multi-task feature extraction network, and generate preprocessed multi-frame images.
[0014] When a drone visible light image sequence enters the multi-task feature extraction network, it first reaches the input processing layer. The input processing layer's primary task is to preprocess the drone visible light image sequence to ensure image data quality and consistency. Specifically, this input processing layer performs two key operations: first, pixel value normalization. Because pixel value ranges may vary across images, this can affect feature extraction. Therefore, the input processing layer adjusts the pixel values of the drone visible light images to a uniform range, making them comparable across all drone visible light images. Second, it adjusts the drone visible light images to a uniform resolution size preset by the multi-task feature extraction network. The resolutions of different drone visible light images may vary, and multi-task feature extraction networks are typically designed with a preset input resolution requirement. Adjusting the drone visible light images to a uniform resolution ensures that the multi-task feature extraction network can properly process all input images. After these two operations, multiple pre-processed frames are generated. For example, the pixel values of the originally captured images may vary significantly due to factors such as lighting and camera equipment. Normalization normalizes the pixel values to a suitable range. At the same time, images of different resolutions are uniformly adjusted to the network preset resolution, making the images consistent in size.
[0015] Step S122: Multi-scale convolution feature extraction is performed on the single-frame image through the spatial feature encoding subnetwork of the multi-task feature extraction network to extract the local contour features of the crowd, the spatial context association features and the global structure features of the scene respectively, wherein the spatial feature encoding subnetwork includes a shallow convolution module, a middle-layer hollow convolution module and a deep global pooling module connected in sequence.
[0016] After obtaining the preprocessed multi-frame images, the single-frame image is fed into the spatial feature encoding subnetwork of the multi-task feature extraction network. This subnetwork performs multi-scale convolutional feature extraction on the single-frame image to obtain feature information at different levels and scales. The spatial feature encoding subnetwork consists of a shallow convolutional module, a mid-layer dilated convolutional module, and a deep global pooling module.
[0017] The shallow convolution module is the first layer of the spatial feature encoding subnetwork, primarily responsible for extracting the local outline features of the crowd. In image processing, convolution is a commonly used feature extraction method. By sliding a convolution kernel across an image, local features can be extracted. The shallow convolution module uses a smaller convolution kernel, which can capture local details of the crowd in the image, such as human edges and posture, thereby obtaining local outline features.
[0018] The middle-layer atrous convolution module follows the shallow convolution module, and its primary task is to extract spatial contextual features. Unlike traditional convolution operations, atrous convolution inserts holes between convolution kernel elements, thereby expanding the receptive field of the convolution. This means that the middle-layer atrous convolution module can capture information from a wider range of areas in the image, thereby capturing the spatial connections between different regions. For example, it can detect the relationship between a crowd and surrounding environmental elements such as shops and passageways, as well as the relative positions and interactions between people. By extracting spatial contextual features, we can better understand the overall structure of the scene in the image and the context of the crowd's activities.
[0019] The deep global pooling module is the final layer of the spatial feature encoding subnetwork, used to extract the global structural features of the scene. Global pooling compresses and integrates information from the entire image, generating a vector that represents the image's global features. By globally pooling the feature maps output by the mid-layer atrous convolution module, the deep global pooling module captures macroscopic information about the entire scene, such as the overall layout of the business district and the distribution of major activity areas.
[0020] Through the sequential processing of the above three modules, the spatial feature encoding subnetwork can extract the local contour features of the crowd, the spatial context association features and the global structure features of the scene from a single frame image.
[0021] Step S123: The temporal dimension of the spatial features of the continuous frame images is aggregated by the temporal association subnetwork of the multi-task feature extraction network to generate a temporal feature vector containing time dependency.
[0022] After acquiring the spatial features of a single frame, further analyzing the dynamic changes of a crowd over time requires processing the spatial features of consecutive frames. The temporal correlation subnetwork of the multi-task feature extraction network aggregates attention on the spatial features of consecutive frames, generating a temporal feature vector that incorporates temporal dependencies.
[0023] Step S1231: splicing the spatial features of consecutive frames in the time dimension to generate a temporal feature cube containing multi-frame features. The length of the time dimension of the temporal feature cube is equal to the number of continuously acquired image frames.
[0024] First, the spatial features of consecutive frames are spliced together along the temporal dimension. After each image frame is processed by the spatial feature encoding subnetwork, a set of spatial features is generated. These spatial features of consecutive frames are arranged in chronological order and spliced together to form a temporal feature cube containing features from multiple frames. The temporal dimension of this temporal feature cube is equal to the number of consecutively acquired image frames. It integrates spatial features at different moments to form a feature structure with a temporal dimension. This splicing process preserves the temporal order information between consecutive frames.
[0025] Step S1232: Calculate the importance weight of each frame's spatial features to the current frame prediction through the temporal attention layer of the temporal association subnetwork, and the importance weight is obtained by calculating the cosine similarity between the current frame features and the historical frame features.
[0026] Next, the temporal attention layer of the temporal association subnetwork calculates the importance weight of each frame's spatial features to the current frame's prediction. In order to determine the importance of each frame's features, the cosine similarity calculation method can be used. Cosine similarity is an indicator that measures the similarity between two vectors. In this step, the cosine similarity between the current frame features and the historical frame features is calculated to evaluate the contribution of the historical frame features to the current frame's prediction. For each historical frame, its cosine similarity with the current frame features is calculated, and the obtained similarity value is the importance weight of the historical frame features. The importance weight reflects the importance of the historical frame features in predicting the current frame. The higher the weight, the more influential the historical frame features are on the prediction of the current frame.
[0027] Step S1233: Use the time attention weight to perform weighted summation on the temporal feature cube to generate a context feature vector focused on the key historical frames. The context feature vector strengthens the historical information that has a significant impact on the current frame prediction.
[0028] After obtaining the importance weights of the spatial features of each frame, these weights are used to perform a weighted summation on the temporal feature cube. Specifically, the spatial features of each frame in the temporal feature cube are multiplied by the corresponding importance weights, and then the weighted features of all frames are added together to obtain a context feature vector. This context feature vector focuses on key historical frames that have a significant impact on the prediction of the current frame. Through weighted summation, the information of these key historical frames is strengthened, while the information of historical frames that have less influence on the prediction of the current frame is weakened. In this way, the context feature vector can more accurately reflect the historical trends and information related to the current frame.
[0029] Step S1234: Add the context feature vector and the spatial feature of the current frame element by element to generate an enhanced current frame feature, where the enhanced current frame feature includes both the local information of the current frame and the trend information of the historical frames.
[0030] The resulting contextual feature vector is added element-by-element to the spatial features of the current frame. This addition integrates trend information from previous frames into the spatial features of the current frame, generating enhanced current frame features. These enhanced current frame features incorporate both local information from the current frame, such as the current position and posture of the crowd, and trend information from previous frames, such as the crowd's movement direction and speed. This fusion of local information and historical trend information provides a more comprehensive description of the current scene.
[0031] Step S1235: The enhanced continuous frame features are temporally modeled through the bidirectional long short-term memory network of the temporal association subnetwork. The bidirectional long short-term memory network captures the long-term dependency of crowd movement from the past to the future and from the future to the past, and outputs a temporal feature vector containing forward and backward trends.
[0032] Finally, the enhanced continuous frame features are fed into the Bidirectional Long Short-Term Memory (Bi-LSTM) network of the temporal association subnetwork for temporal modeling. The Bi-LSTM is a recurrent neural network capable of processing sequential data. It features memory and forgetting mechanisms, effectively capturing long-term dependencies in sequential data. In this step, the Bi-LSTM processes the enhanced continuous frame features in two directions: past to future and future to past. The past-to-future direction captures forward trends in crowd movement, predicting future movement based on historical data. The future-to-past direction captures backward trends in crowd movement, reviewing relevant information from historical data based on possible future scenarios. Through bidirectional processing, the Bi-LSTM network more comprehensively captures long-term dependencies in crowd movement, ultimately outputting a temporal feature vector containing both forward and backward trends. This temporal feature vector integrates the spatial characteristics and temporal dimensions of the continuous frame images.
[0033] Step S124: Decoupling the spatial features and the temporal features through the feature decoupling subnetwork of the multi-task feature extraction network, and separating the crowd density distribution features representing the number of people per unit area, the individual movement trajectory features representing the individual position change path, and the group aggregation morphology features representing the shape of the group aggregation area through the orthogonal constraint loss function.
[0034] After obtaining spatial and temporal features, these features need to be further separated and refined to obtain more targeted feature information. The feature decoupling subnetwork of the multi-task feature extraction network can decouple spatial and temporal features, using an orthogonal constraint loss function to separate different types of features.
[0035] During feature decoupling, the orthogonality constraint loss function ensures a certain degree of independence between the separated features and avoids mutual interference. By minimizing the orthogonality constraint loss function, the feature decoupling subnetwork adjusts and optimizes the input spatial and temporal features, ensuring that the ultimately separated crowd density distribution features, individual movement trajectory features, and group aggregation morphology features are as orthogonal as possible.
[0036] Crowd density distribution features characterize the number of people per unit area. During the decoupling process, the feature decoupling subnetwork extracts information related to crowd size distribution from spatial and temporal features. By analyzing the distribution of people in different areas, it calculates the number of people per unit area, thereby generating crowd density distribution features. This crowd density distribution feature is crucial for understanding the density and distribution patterns of people within a business district. For example, it can help businesses identify popular areas and potential consumer hotspots.
[0037] Individual movement trajectory features are used to characterize the path of individual location changes. The feature decoupling subnetwork tracks each person's position changes across different image frames. By analyzing individual movement trajectories, it extracts feature information related to individual movement. This feature information can reflect consumers' behavioral preferences and shopping habits within the business district, such as whether they frequently visit certain stores and whether their movement routes are regular.
[0038] Cluster morphology features characterize the shape of clustered areas. The feature decoupling subnetwork identifies clustered areas and analyzes their shape and size. By analyzing cluster morphology, we can understand the distribution of popular activity areas and clustering patterns within a business district, such as whether there are centralized activity venues and whether the crowds are dispersed or concentrated.
[0039] Through the processing of the feature decoupling sub-network, the spatial features and temporal features are decoupled into crowd density distribution features, individual movement trajectory features and group aggregation morphology features.
[0040] Step S125: The density distribution features, movement trajectory features, and aggregation morphology features are scaled uniformly by the feature calibration subnetwork of the multi-task feature extraction network to generate a three-dimensional feature tensor, wherein the scale uniformization process adjusts the variance and mean of each feature dimension based on the statistical distribution of the historical annotation data.
[0041] After obtaining crowd density distribution features, individual movement trajectory features, and group aggregation morphology features, these features may vary in scale and range. To facilitate subsequent processing and analysis, these features need to be scaled uniformly. The feature calibration subnetwork of the multi-task feature extraction network scales these density distribution features, movement trajectory features, and aggregation morphology features, ultimately generating a three-dimensional feature tensor.
[0042] Scale normalization is performed based on the statistical distribution of historically labeled data. This data is accurately labeled and collected during model training. Statistical analysis of this data provides statistical information, such as the variance and mean of each feature dimension. The feature calibration subnetwork uses this statistical information to adjust the current density distribution, movement trajectory, and cluster morphology. Specifically, it adjusts the variance and mean of each feature dimension to ensure consistent scale across different features.
[0043] For density distribution features, we adjust their variance and mean to unify their scale to an appropriate range. This prevents large scale differences in density distribution features from affecting subsequent analysis and processing. For example, if population density values in some areas are too high and those in other areas are too low, rescaling can bring these values into a relatively balanced range, facilitating comparison and analysis.
[0044] Similar processing is performed on trajectory features. Since different individuals' trajectory features may vary in length, speed, and other aspects, adjusting their variance and mean can unify the scale of trajectory features, making them comparable in feature representation.
[0045] Aggregate morphological features are also scaled. Aggregates can vary in shape and size, and by adjusting the variance and mean, they can be scaled to make the representation of different clusters more consistent.
[0046] After scaling in the feature calibration subnetwork, the density distribution features, movement trajectory features, and clustering morphology features are integrated to generate a three-dimensional feature tensor. This 3D feature tensor contains information on crowd density distribution, individual movement trajectories, and clustering morphology.
[0047] Step S130: calling the spatiotemporal dynamic prediction model to perform time series correlation and space mapping processing on the three-dimensional feature tensor, and generating prediction results of consumer population distribution in the business district area for multiple consecutive time periods in the future.
[0048] After obtaining a three-dimensional feature tensor that includes crowd density distribution characteristics, individual movement trajectory characteristics, and group aggregation morphology characteristics, the next step is to predict the consumer population distribution in the business district over multiple consecutive time periods in the future. A spatiotemporal dynamic prediction model is used to perform temporal correlation and spatial mapping on the three-dimensional feature tensor to generate the corresponding prediction results.
[0049] Step S131: input the three-dimensional feature tensor into the fusion layer of the spatiotemporal dynamic prediction model, calculate the association weights between the density distribution features, movement trajectory features and aggregation morphology features through the self-attention mechanism of the fusion layer, and generate a fusion feature matrix.
[0050] When the three-dimensional feature tensor is input to the fusion layer of the spatiotemporal dynamics prediction model, the fusion layer uses a self-attention mechanism to calculate the correlation weights between density distribution features, movement trajectory features, and clustering morphology features. The self-attention mechanism automatically focuses on the correlations between different parts of the input features. In this step, the fusion layer calculates the correlation between each of the density distribution features, movement trajectory features, and clustering morphology features.
[0051] Specifically, the self-attention mechanism encodes each feature, converting it into a query vector, a key vector, and a value vector. It then calculates the similarity between the query vector and the key vector to determine the attention weights of each feature on the other features. These weights reflect the strength of the association between different features; higher weights indicate a closer association between the two features.
[0052] After obtaining the association weights, the fusion layer uses these weights to perform a weighted combination of the density distribution features, movement trajectory features, and aggregation morphology features. Each feature is multiplied by its corresponding association weight and then summed up to form a fused feature matrix. This fused feature matrix integrates information from the density distribution features, movement trajectory features, and aggregation morphology features, highlighting the relationships between them.
[0053] Step S132: Perform time series analysis on the fusion feature matrix through the time series modeling layer of the spatiotemporal dynamic prediction model, extract the periodic law of changes in the consumer population in the historical period by using the gated recurrent unit of the time series modeling layer, and generate time series context features reflecting time dependence.
[0054] After obtaining the fused feature matrix, it is input into the time series modeling layer of the spatiotemporal dynamic forecasting model. The main task of the time series modeling layer is to perform time series analysis on the fused feature matrix to extract the cyclical patterns of changes in the consumer population over the historical period.
[0055] The time series modeling layer uses a gated recurrent unit (GRU) to accomplish this task. A GRU is a recurrent neural network with a gating mechanism that effectively captures long-term dependencies in sequence data. When processing the fused feature matrix, the GRU sequentially processes the features of each time step in the matrix.
[0056] The GRU consists of two key components: an update gate and a reset gate. The update gate controls how much of the hidden state information from the previous moment is passed to the current moment, while the reset gate determines how much of the hidden state information from the previous moment is reset. By controlling these two gates, the GRU can dynamically adjust the transmission and updating of information based on the characteristics of the input.
[0057] As the fused feature matrix is processed, the GRU continuously updates its hidden state, thereby learning the cyclical patterns in consumer population changes over historical periods. For example, if the consumer population consistently shows similar growth or decline trends within a specific time period, the GRU can capture these cyclical patterns.
[0058] After processing by the gated recurrent unit, the output hidden state sequence contains information about the time-dependent changes in the consumer population over the historical period. This information is integrated to generate temporal context features that reflect this time dependency. This temporal context feature is crucial for predicting the distribution of consumer population in future periods because it provides a reference for historical trends, helping the model better predict future changes.
[0059] Step S133: using the spatial division layer of the spatiotemporal dynamic prediction model, the business district area is divided into grid-like sub-region units based on the density of the business district's geographical boundaries and historical population distribution, and each sub-region unit corresponds to a spatial dimension in the feature matrix.
[0060] This step aims to rationally divide the business district into smaller areas, allowing for more accurate consumer population distribution forecasts. First, we need to obtain information about the business district's geographic boundaries and historical population distribution. This information is then used to create a grid-like sub-area unit, assigning each sub-area a specific weight and spatial dimension.
[0061] Step S1331: Obtain geographic boundary coordinate data of the business district area. The geographic boundary coordinate data is obtained by fusing satellite maps with field survey data and is used to determine the overall coverage of the business district area.
[0062] To accurately define the scope of a business district, a combination of satellite maps and field survey data is necessary. Satellite maps provide a general outline and geographic location of the business district at a macro level, while field survey data can supplement the details that may be missing from satellite maps, such as hidden passages and the boundaries of unique buildings. By fusing these two types of data, we can obtain precise geographic boundary coordinates for the business district, thereby clarifying the overall coverage of the business district area.
[0063] Step S1332: Determine the division density of the sub-region units according to the density of historical population distribution, wherein the division density of densely populated areas is greater than that of sparsely populated areas.
[0064] The density of historical population distribution reflects the popularity and attractiveness of different areas within a business district. For densely populated areas, a higher partition density is required to more accurately capture population changes, meaning the sub-area units are smaller. In sparsely populated areas, the partition density can be lower, with larger sub-area units. This partitioning method can be flexibly adjusted based on actual population distribution, improving the accuracy of analyzing demographic characteristics in different areas.
[0065] Step S1333: performing non-uniform grid division on the commercial area based on the division density, generating a grid matrix containing sub-area units of different areas, wherein each unit of the grid matrix corresponds to a unique spatial index.
[0066] Based on the determined density, the commercial district is divided into a non-uniform grid. This method, unlike traditional uniform division, better accommodates the uneven distribution of population within the commercial district. The resulting grid matrix contains sub-area units of varying sizes, each assigned a unique spatial index that allows for rapid location and identification of specific sub-area units.
[0067] Step S1334: extracting the historical population distribution data stored in the model training phase, wherein the historical population distribution data includes the historical average population value of each sub-region unit in different time periods.
[0068] During the model training phase, a wealth of historical population distribution data has been stored. This data records the historical average population size of each sub-regional unit over different time periods. Extracting this historical population distribution data helps us understand the population distribution characteristics and changes in each sub-regional unit.
[0069] Step S1335: Calculate the ratio of the historical average population value of each sub-region unit to the overall average of the business district, and use the ratio as the initial weight parameter of the corresponding sub-region unit.
[0070] By calculating the ratio of each sub-region's historical average population to the overall average for the business district, we can measure its importance within the district. This ratio is used as the initial weight parameter for the corresponding sub-region. A larger weight parameter indicates a greater influence on the district's population distribution.
[0071] Step S1336: normalize the initial weight parameters so that the sum of the weight parameters of all sub-region units is 1.
[0072] To ensure that the weights of each sub-region unit are comparable and reasonable in subsequent calculations and analyses, the initial weight parameters need to be normalized. The result of normalization is that the sum of the weight parameters of all sub-region units is 1. This can avoid deviations in the calculation results caused by an unreasonable sum of weights and ensure the stability and accuracy of the model.
[0073] Step S134: Input the temporal context features and the historical population distribution weights of each sub-regional unit into the spatial mapping layer of the spatiotemporal dynamic prediction model, and calculate the population prediction value of each sub-regional unit in the future period through the fully connected neural network of the spatial mapping layer.
[0074] After obtaining the temporal context features and the historical population distribution weights for each sub-regional unit, they are input into the spatial mapping layer of the spatiotemporal dynamic prediction model. The main function of the spatial mapping layer is to combine the temporal context features and the historical population distribution weights to calculate the predicted population value of each sub-regional unit in the future period.
[0075] The spatial mapping layer uses a fully connected neural network, a common neural network architecture in which each neuron is connected to all neurons in the previous layer. In this step, the input to the fully connected neural network includes temporal context features and the historical population distribution weights of each subregion unit.
[0076] Temporal context features contain information about the time-dependent changes in consumer population over a historical period, while the historical population distribution weights of each sub-regional unit reflect the importance of each sub-regional unit within the overall business district. A fully connected neural network processes these inputs, transforming and integrating them through a series of neuron calculations and activation functions.
[0077] During the computational process of a fully connected neural network, each neuron performs a weighted summation of its inputs based on the weight of its connection, and then applies a nonlinear transformation to the result using an activation function. By computing across multiple layers of neurons, a fully connected neural network can learn the complex relationship between input information and the future population size of each subregional unit.
[0078] Finally, the fully connected neural network outputs a population forecast for each sub-regional unit in the future. These forecasts are calculated based on historical data and time-dependent information, reflecting the likely population changes of each sub-regional unit in the future.
[0079] Step S135: The predicted values of each sub-regional unit are normalized through the output layer of the spatiotemporal dynamic prediction model so that the sum of the predicted values of all sub-regional units maintains a consistent ratio with the total number of consumer population in the current time period, thereby generating a consumer population distribution prediction result for each sub-regional unit in multiple consecutive time periods in the future.
[0080] After obtaining the population forecast for each subregional unit in the future, these forecasts need to be normalized to ensure the rationality and consistency of the forecast results. The output layer of the spatiotemporal dynamic forecasting model completes this task.
[0081] The purpose of normalization is to ensure that the sum of the predicted values of all sub-regional units is proportional to the total consumer population of the current period. This is because in reality, the total consumer population within a business district is limited, and the sum of the population of each sub-regional unit should be equal to the total consumer population.
[0082] The output layer will adjust the predicted values of each sub-region unit, scale and redistribute the predicted values so that their sum is proportional to the total consumer population in the current period. This can ensure that the prediction results are reasonable overall and avoid the situation where the predicted total consumer population is too different from the actual situation.
[0083] After normalization, a consumer population distribution forecast for each sub-regional unit is generated, including multiple consecutive time periods in the future. This consumer population distribution forecast is a multi-dimensional information set that includes the predicted population size of each sub-regional unit at different time periods in the future.
[0084] Step S140: Perform historical trend matching analysis on the consumer population distribution prediction result through the confidence verification module, and output verification data including the prediction confidence score and key change periods.
[0085] After obtaining consumer population distribution forecasts for a business district over multiple consecutive time periods, these forecasts need to be verified to assess their reliability and accuracy. The confidence verification module analyzes the consumer population distribution forecasts for historical trend matching and outputs verification data including the forecast confidence score and key change periods.
[0086] Step S141: extracting time series data from the consumer population distribution prediction result, wherein the time series data includes the population prediction value of each sub-region unit in each time period in the future.
[0087] First, extract time series data from the consumer population distribution forecast results. This time series data contains the predicted population values for each sub-regional unit at each future time period. By extracting this data, the forecast results can be converted into a chronological sequence, which facilitates subsequent analysis and processing.
[0088] For example, for each sub-regional unit, the predicted population values for different time periods in the future are arranged in chronological order to form a time series. The above time series data can clearly show the future trend of the population of each sub-regional unit.
[0089] Step S142: Obtain a historical verification dataset stored during the model training phase, where the historical verification dataset includes actual consumer population values and corresponding drone image sequences for the same time span as the prediction period.
[0090] To perform historical trend matching analysis, we need to obtain the historical validation dataset stored during the model training phase. This historical validation dataset contains the actual consumer population values and the corresponding drone image sequences for the same time span as the forecast period.
[0091] The historical validation dataset, collected and organized during the model training process, records the actual consumer demographics of the business district over a period of time and the corresponding drone imagery. Using this historical validation dataset, we can compare the prediction results with historical reality to assess their accuracy.
[0092] Step S143: Input the time series data and the actual values in the historical verification data set into the comparative analysis submodule of the confidence verification module, and evaluate the linear correlation between the prediction result and the historical trend by calculating the Pearson correlation coefficient between the time series data and the actual values in the historical verification data set.
[0093] The extracted time series data and the actual values in the historical validation dataset are input into the comparative analysis submodule of the confidence verification module. The comparative analysis submodule calculates the Pearson correlation coefficient between the time series data and the actual values in the historical validation dataset to assess the linear correlation between the forecast results and the historical trend.
[0094] The Pearson correlation coefficient is an indicator that measures the linear correlation between two variables, and its value range is between -1 and 1. When the correlation coefficient is close to 1, it indicates that there is a strong positive linear correlation between the two variables; when the correlation coefficient is close to -1, it indicates that there is a strong negative linear correlation; when the correlation coefficient is close to 0, it indicates that there is almost no linear correlation between the two variables.
[0095] In this step, by calculating the Pearson correlation coefficient between the time series data and the actual values in the historical validation dataset, we can understand the linear relationship between the forecast results and the historical trend. A high correlation coefficient indicates that the forecast results are consistent with the historical trend and the forecast reliability is high. A low correlation coefficient indicates that the forecast results are significantly different from the historical trend and require further analysis and adjustment.
[0096] Step S144: Calculate the prediction confidence score based on the Pearson correlation coefficient. The prediction confidence score is mapped to the range of 0-1 through normalization. The higher the value, the more consistent the prediction result is with the historical pattern.
[0097] The prediction confidence score was calculated based on the calculated Pearson correlation coefficient. To facilitate comparison and evaluation, the prediction confidence score was normalized to the range of 0-1.
[0098] The purpose of normalization is to convert the Pearson correlation coefficient to a value between 0 and 1, so that different prediction results can be compared under the same standard. Through normalization, the Pearson correlation coefficient is scaled and adjusted so that its value range is between 0 and 1.
[0099] The higher the prediction confidence score, the more consistent the prediction is with historical patterns, and the more reliable the prediction is. For example, a prediction confidence score of 0.9 indicates that the prediction closely matches historical trends, and the prediction is highly accurate. A prediction confidence score of 0.2, on the other hand, indicates that the prediction differs significantly from historical trends, and the prediction is less reliable.
[0100] Step S145: Analyze the second-order difference sequence of the time series data to identify key change periods, including: This step uses second-order difference analysis on time series data to identify key periods of change in the growth or decline trend of the consumer population.
[0101] Step S1451: traverse the time series data period by period, calculate the difference between the population prediction value of the current period and the prediction value of the previous period, and generate a first-order difference sequence, which represents the change range of the population in each period.
[0102] The purpose of traversing time series data period by period is to obtain information about population changes in each period. By calculating the difference between the current period's population forecast and the previous period's forecast, we can obtain a first-order difference series. This first-order difference series intuitively reflects the magnitude of population change in each period, providing a preliminary understanding of the increase or decrease in population over time.
[0103] Step S1452: Perform a second difference process on the first-order difference sequence, calculate the difference between the first-order difference value of the current period and the first-order difference value of the previous period, and generate a second-order difference sequence. The second-order difference sequence represents the amplitude of the change rate of the population size.
[0104] After obtaining the first-order difference series, it is subjected to a second-difference process, that is, the difference between the first-order difference of the current period and the first-order difference of the previous period is calculated to generate a second-order difference series. The second-order difference series can more deeply reflect the changes in the rate of change of population size and help to identify the acceleration or deceleration points of population growth or decline.
[0105] Step S1453: Calculate the mean and standard deviation parameters of the second-order difference sequence, where the mean represents the amplitude of the average rate of change, and the standard deviation represents the degree of dispersion of the rate of change.
[0106] The purpose of calculating the mean and standard deviation parameters of the second-order difference series is to further analyze the statistical characteristics of population changes. The mean reflects the average level of the second-order difference series, that is, the amplitude of the average rate of change; the standard deviation indicates the dispersion of the rate of change around the mean, reflecting the stability of the change.
[0107] Step S1454: Set the preset threshold to the mean plus N times the standard deviation, and the preset threshold is used to distinguish normal fluctuations from trend reversals.
[0108] To accurately distinguish normal fluctuations in population size from trend reversals, a preset threshold is required. Typically, the threshold is set to the mean plus a set multiple (N) of the standard deviation. This setting can filter out minor fluctuations, focusing only on periods of significant change, and improving the accuracy of identifying key periods of change.
[0109] Step S1455: traverse the second-order difference sequence and mark all period indexes whose absolute values exceed a preset threshold as key change periods. The key change periods represent the acceleration or deceleration turning points of the growth or decline trend of the consumer population.
[0110] Traversing the second-order difference sequence, we identify all time periods whose absolute values exceed a preset threshold and mark these periods as key change periods. These key change periods correspond to turning points in the acceleration or deceleration of consumer population growth or decline, providing important guidance for business district operations and decision-making.
[0111] Step S1456: Merge the key change periods that continuously exceed the preset threshold to generate a key change period interval including a start period and an end period. The key change period interval is used to centrally display the time range of trend turning points in the dynamic forecast report.
[0112] To more clearly and centrally display the timeframe for trend reversals in dynamic forecast reports, key change periods that continuously exceed a preset threshold are merged. The resulting merged key change period intervals include both the start and end periods, enabling users of dynamic forecast reports to more intuitively understand the duration and scope of demographic trend reversals.
[0113] Step S146: Associating the key change period with the input three-dimensional feature tensor through the attribution analysis submodule of the confidence verification module, and extracting the feature dimension that has the greatest impact on the trend turning point as supplementary information for the verification data.
[0114] The attribution analysis submodule of the confidence verification module associates key change periods with the input three-dimensional feature tensor to extract the feature dimensions that have the greatest impact on trend reversals.
[0115] The three-dimensional feature tensor contains information on crowd density distribution, individual movement trajectories, and group aggregation patterns. During key periods of change, the three-dimensional feature tensor may undergo significant changes, leading to a turning point in the growth or decline of the consumer population.
[0116] The attribution analysis submodule analyzes the changes in each dimension of the three-dimensional feature tensor during key periods of change. By comparing the degree of change in different feature dimensions and their contribution to trend reversals, it extracts the feature dimensions that have the greatest impact on trend reversals.
[0117] Information from these characteristic dimensions can serve as supplementary information for validation data, helping to further understand the causes and influencing factors of key change periods. For example, if the characteristics of individual movement trajectories are found to have significantly changed during a key change period, it may indicate a shift in consumer behavior preferences, which can provide important insights into adjusting marketing strategies for a business district.
[0118] Step S150: generating a dynamic prediction report including a correspondence between a time dimension and a spatial region based on the verification data.
[0119] After obtaining verification data including prediction confidence scores and key change periods, it is necessary to generate a dynamic forecast report based on this data, which includes the correspondence between time dimensions and spatial areas, so as to provide intuitive and comprehensive information for business district management and decision-making.
[0120] Step S151: establishing a two-dimensional data matrix of time dimension and space region, wherein the row index of the two-dimensional data matrix is the future time period division unit, and the column index is the business circle region unit.
[0121] First, create a two-dimensional data matrix that combines time and space. The rows of this matrix represent future time periods, while the columns represent business districts. This matrix structure integrates temporal and spatial information for easy display and analysis.
[0122] For example, divide the future into multiple consecutive time periods, with each period as a row of the matrix; divide the business district into multiple sub-regional units, with each sub-regional unit as a column of the matrix. In this way, each element in the matrix corresponds to the relevant information of a sub-regional unit in a certain time period.
[0123] Step S152: Fill the predicted population value of each sub-region unit in each time period in the verification data into the corresponding position of the two-dimensional data matrix, and mark the prediction confidence score of each corresponding position.
[0124] Populate the corresponding positions of the two-dimensional data matrix with the predicted population values for each sub-regional unit in each time period from the validation data. At the same time, annotate each corresponding position with a prediction confidence score to intuitively understand the reliability of each predicted value.
[0125] For example, for a sub-regional unit's population forecast for a certain period of time, fill it in the corresponding row and column position in the two-dimensional data matrix. Then, mark the corresponding prediction confidence score next to the position, such as using color depth or numerical value to indicate the score.
[0126] Step S153: Filtering abnormal cells with confidence scores lower than a preset threshold from the two-dimensional data matrix, wherein the abnormal cells represent sub-regions and time periods where the deviation between the prediction result and the historical law is greater than the set deviation threshold.
[0127] Filter outlier cells from the two-dimensional data matrix whose confidence scores are below a preset threshold. These outlier cells represent sub-regions and time periods where the deviation between the forecast results and historical patterns exceeds the set deviation threshold.
[0128] The preset threshold is a standard set based on actual conditions to distinguish between normal and abnormal predictions. When the prediction confidence score for a cell falls below the preset threshold, it indicates that the prediction results for that subregion during that time period may have significant errors and require further attention and analysis.
[0129] Step S154: highlight the row index corresponding to the key change period, and associate the main influencing feature dimensions output by the attribution analysis submodule with the highlighted index.
[0130] The row indices corresponding to key change periods are highlighted to highlight these important periods. At the same time, the highlighted indices are associated with the main influencing feature dimensions output by the attribution analysis submodule to better understand the causes of key change periods.
[0131] For example, the row index corresponding to the key change period is highlighted in a two-dimensional data matrix using a special color or mark. Then, the main influencing feature dimensions extracted by the attribution analysis submodule, such as crowd density distribution characteristics and individual movement trajectory characteristics, are displayed next to the highlighted mark, helping users quickly understand the factors affecting key changes.
[0132] Step S155: converting the two-dimensional data matrix into a visual heat map, wherein the visual heat map represents the predicted population value through a color gradient, and superimposes the marking symbols of the abnormal cells and the timeline annotations of the key change periods.
[0133] This step converts the two-dimensional data matrix into a visual heat map to intuitively display the consumer population distribution forecast results, while overlaying relevant information on abnormal cells and key change periods to facilitate user analysis and decision-making.
[0134] Step S1551: defining a color mapping rule for the visualized heat map, wherein the color mapping rule maps the population prediction value to a continuous color gradient from blue to red.
[0135] To clearly display the predicted population values on the heat map, you need to define a color mapping rule. The predicted population values are mapped to a continuous color gradient from blue to red, where blue generally indicates a low population and red indicates a high population. This color setting allows users to intuitively judge the population density of different areas by the depth of the color.
[0136] Step S1552: Assign a color value corresponding to the position in the two-dimensional data matrix to each sub-region unit, and adjust the color value according to the ratio of the predicted value to the historical average value to highlight the area above or below the historical level.
[0137] Each subregional unit in the two-dimensional data matrix is assigned a color based on its corresponding predicted population value. The color is also adjusted based on the ratio of the predicted value to the historical average. If the predicted value is higher than the historical average, the color becomes more red; if it is lower, the color becomes more blue. This adjustment highlights areas where the population differs significantly from historical levels, helping users quickly identify anomalies.
[0138] Step S1553: superimposing marker symbols of abnormal cells in the visualized heat map, wherein the size of the marker symbols is inversely proportional to the confidence score.
[0139] Markers for outlier cells are superimposed on the heatmap to highlight subregions and time periods where forecasts deviate significantly from historical patterns. The size of the marker is inversely proportional to the confidence score; the lower the confidence score, the larger the marker. This makes it easier for users to notice these anomalies and further analyze possible causes.
[0140] Step S1554: Add a timeline annotation at the bottom of the visualized heat map. The timeline annotation corresponds to a key change period interval, and distinguishes the growth turning area and the decline turning area by horizontal strips of different colors.
[0141] Add timeline annotations to the bottom of the heat map to correspond to key periods of change. By using different colored horizontal strips to distinguish between growth and decline turning points, users can intuitively see the temporal distribution of turning points in population growth or decline, helping to analyze trends and patterns in population change.
[0142] Step S1555: adding coordinate axis labels to the visualized heat map, wherein the coordinate axis labels include a specific time period description of the time dimension and a sub-area name of the space dimension.
[0143] To make heat maps easier to understand and interpret, you need to add axis labels. Axis labels include descriptions of specific time periods in the time dimension and subregion names in the spatial dimension. This allows users to accurately locate specific time and spatial locations based on axis labels and obtain corresponding population data.
[0144] Step S1556: performing resolution adjustment and edge smoothing processing on the visualized heat map to generate a final visualized heat map.
[0145] To improve the visual quality and visual appeal of the heat map, we perform resolution adjustment and edge smoothing. Resolution adjustment makes the heat map clearer, and edge smoothing eliminates jagged edges, making the image more aesthetically pleasing and natural. After these processes, the final visualized heat map is generated, providing users with intuitive and accurate information on consumer demographic distribution.
[0146] Step S156: Integrate the visualized heat map, the abnormal cell list, and the key change period analysis into a structured document to generate a dynamic prediction report containing the correspondence between the time dimension and the spatial area.
[0147] Integrate the visualized heat map, abnormal cell list, and key change period analysis into a structured document to generate a dynamic forecast report that includes the correspondence between time dimensions and spatial areas.
[0148] The structured document can be in a common format, such as PDF or Word. Place the heat map in a suitable location within the document, along with a list of abnormal cells and detailed analysis of key change periods.
[0149] The above dynamic forecast report provides comprehensive and intuitive information for the management and decision-making of the business district, helping managers understand the distribution of consumer population in each sub-region at different time periods in the future, the reliability of the forecast and the influencing factors of key changes, so as to make more reasonable decisions.
[0150] For example, in one possible implementation, the multi-task feature extraction network, spatiotemporal dynamic prediction model, and confidence verification module optimize parameters through joint training, specifically including: In order to enable the multi-task feature extraction network, spatiotemporal dynamic prediction model and confidence verification module to work better together and improve the accuracy of prediction, they need to be jointly trained to optimize the parameters.
[0151] Step S211: Construct a multi-label training dataset including sample drone images, density distribution labels, movement trajectory labels, aggregation morphology labels, actual population distribution labels and historical verification labels.
[0152] A multi-label training dataset is constructed, which contains sample drone images and multiple labels corresponding to these images. The sample drone images are selected from a series of visible light images collected by drones and used as input data for the model.
[0153] The density distribution label indicates the density distribution of the crowd in the sample drone image. The movement trajectory label records the movement trajectory of individuals in the image. The gathering shape label describes the shape and size of the crowd gathering. The actual population distribution label shows the actual consumer population distribution corresponding to the sample image. The historical verification label contains historical verification information covering the same time span as the prediction period.
[0154] By collecting and organizing this data, a rich multi-label training dataset is constructed, providing abundant information and supervisory signals for model training. When collecting sample drone imagery, it is important to ensure that the images cover the business district at different time periods and in different scenarios to improve the model's generalization capabilities. Labeling various types of labels requires professional personnel to follow unified standards to ensure accuracy and consistency. For example, when labeling density distribution, the number of people in different areas of the image must be accurately counted; when labeling movement trajectories, the positional changes of individuals in consecutive frames must be clearly recorded.
[0155] Step S212: Initialize the network parameters of the multi-task feature extraction network, the spatiotemporal dynamic prediction model, and the confidence verification module.
[0156] Before training begins, the network parameters of the multi-task feature extraction network, spatiotemporal dynamic prediction model, and confidence verification module need to be initialized. Network parameters are variables that the model needs to learn and adjust during training; they determine the model's performance and output. There are various ways to initialize parameters, with random initialization being a common method. This random initialization assigns an initial value to each network parameter, providing a starting point for model training. These parameters can then be continuously adjusted based on training data to optimize model performance. During initialization, it is important to ensure that the parameter initialization method and range for each module are appropriate to avoid parameters that are too large or too small, which can affect the model's convergence speed and stability.
[0157] Step S213: Input the sample drone images in the multi-label training data set into the multi-task feature extraction network, generate a sample three-dimensional feature tensor and pass it to the spatiotemporal dynamic prediction model, the spatiotemporal dynamic prediction model generates a consumer population distribution prediction result based on the sample three-dimensional feature tensor, and the confidence verification module generates verification data based on the consumer population distribution prediction result.
[0158] Sample drone images from the multi-label training dataset are input into the multi-task feature extraction network. The multi-task feature extraction network processes the sample drone images according to the previously described steps. First, the input processing layer normalizes the image pixels and adjusts the resolution to generate preprocessed multi-frame images. Next, the spatial feature encoding subnetwork performs multi-scale convolutional feature extraction on the single-frame image, extracting local crowd contour features, spatial contextual features, and global scene structure features. The temporal association subnetwork then aggregates spatial features from consecutive frames in the temporal dimension, generating a temporal feature vector that incorporates temporal dependencies. The feature decoupling subnetwork then decouples spatial and temporal features, separating crowd density distribution features, individual movement trajectory features, and group aggregation morphology features. Finally, the feature calibration subnetwork rescales these features to generate a sample 3D feature tensor.
[0159] The generated three-dimensional sample feature tensor is then passed to the spatiotemporal dynamic prediction model. The fusion layer of the spatiotemporal dynamic prediction model uses a self-attention mechanism to calculate the correlation weights between the density distribution features, movement trajectory features, and clustering morphology features in the sample three-dimensional feature tensor, generating a fused feature matrix. The temporal modeling layer uses gated recurrent units to perform time series analysis on the fused feature matrix, extracting cyclical patterns in consumer population changes over historical periods and generating temporal contextual features that reflect temporal dependence. The spatial partitioning layer divides the commercial district into grid-like sub-regions based on the district's geographic boundaries and historical population density. Each sub-region corresponds to a spatial dimension in the feature matrix. The spatial mapping layer inputs the temporal contextual features and the historical population distribution weights of each sub-region into a fully connected neural network to calculate the population forecast for each sub-region in the future. The output layer normalizes the forecast values for each sub-region to generate a consumer population distribution forecast.
[0160] The confidence verification module generates verification data based on the consumer population distribution forecast results. It first extracts time series data from the consumer population distribution forecast results. This data is then input into the comparative analysis submodule, along with the actual values in the historical verification dataset. The Pearson correlation coefficient is calculated to assess the linear correlation between the forecast results and historical trends. The forecast confidence score is calculated based on the Pearson correlation coefficient and normalized to the range of 0-1. Simultaneously, the second-order difference sequence of the time series data is analyzed to identify key periods of change. Finally, the attribution analysis submodule correlates key periods of change with the input three-dimensional feature tensor, extracting the feature dimensions that have the greatest impact on trend reversals as supplementary information for the verification data.
[0161] Step S214: Calculate the decoupling loss of the multi-task feature extraction network, the prediction loss of the spatiotemporal dynamic prediction model, and the verification loss of the confidence verification module, and perform standardized weighted summation of the decoupling loss, the prediction loss, and the verification loss to generate a joint loss function. The decoupling loss is used to reflect the degree of orthogonal separation between the three-dimensional feature tensor of the sample and the density distribution label, the movement trajectory label, and the aggregation morphology label. The prediction loss is used to reflect the difference between the consumer population distribution prediction result and the actual population distribution label. The verification loss is used to reflect the degree of matching between the verification data and the historical verification label.
[0162] To evaluate the model's performance, we need to calculate the decoupling loss of the multi-task feature extraction network, the prediction loss of the spatiotemporal dynamics prediction model, and the verification loss of the confidence verification module. The decoupling loss of the multi-task feature extraction network measures the degree of orthogonal separation between the sample's three-dimensional feature tensor and its density distribution label, movement trajectory label, and aggregate shape label. A low decoupling loss indicates that the feature decoupling subnetwork is able to effectively separate different types of features, resulting in a better match between the separated features and their corresponding labels.
[0163] The prediction loss of the spatiotemporal dynamic prediction model reflects the difference between the predicted consumer population distribution and the actual population distribution label. The smaller the prediction loss, the closer the model's prediction results are to the actual situation and the stronger the model's predictive ability.
[0164] The verification loss of the confidence verification module is used to evaluate the degree of match between the verification data and the historical verification labels, which can reflect the evaluation accuracy of the confidence verification module on the prediction results.
[0165] After calculating these three losses, they are normalized and weighted to generate a joint loss function. Normalization ensures that the dimensions of the different losses are consistent, preventing significant differences in the loss ranges from affecting the final joint loss. Weighted summation assigns appropriate weights to each loss based on the importance of each module. For example, if the prediction accuracy of the spatiotemporal dynamics prediction model is considered more important, a larger weight can be assigned to the prediction loss. This joint loss function allows for a comprehensive evaluation of the performance of the entire system.
[0166] Step S215: Use a stochastic gradient descent optimizer to perform backpropagation calculation on the joint loss function, and synchronously update the parameters of the multi-task feature extraction network, the spatiotemporal dynamic prediction model and the confidence verification module based on the gradient information.
[0167] After obtaining the joint loss function, backpropagation is performed on it using a stochastic gradient descent optimizer. Backpropagation is an algorithm for calculating gradients. Based on the value of the joint loss function, it calculates the gradient of each network parameter with respect to the loss function. The gradient represents the rate of change of the loss function in parameter space. This gradient information indicates the direction in which each parameter should be adjusted to reduce the value of the joint loss function.
[0168] The stochastic gradient descent optimizer synchronously updates the parameters of the multi-task feature extraction network, the spatiotemporal dynamic prediction model, and the confidence verification module based on the calculated gradient information. During each parameter update, the stochastic gradient descent optimizer adjusts the parameters according to the set learning rate. The learning rate determines the step size of each parameter update. If the learning rate is too large, the model may skip the optimal solution in the parameter space; if the learning rate is too small, the model converges very slowly.
[0169] During parameter updates, the stochastic gradient descent optimizer randomly selects a batch of samples from the multi-label training dataset for training, rather than using the entire dataset. This improves training efficiency and enhances the model's generalization capabilities. With each parameter update, the model's performance improves, and the value of the joint loss function gradually decreases.
[0170] Step S216: During the training process, the joint loss value is periodically evaluated using the validation data set. When the validation loss value does not decrease within a continuous preset period, the training is stopped, and the parameters of the trained multi-task feature extraction network, spatiotemporal dynamic prediction model, and confidence verification module are frozen to generate stable model parameters that can be used for actual prediction.
[0171] During model training, you need to periodically evaluate the joint loss using a validation dataset. This dataset, separate from the training dataset, is used to test the model's performance on unseen data. By calculating the joint loss on the validation dataset, you can understand the model's generalization ability and whether it is overfitting.
[0172] If the model's loss on the training dataset continues to decrease, but the loss on the validation dataset begins to increase, the model may be overfitting. To prevent overfitting, stop training when the validation loss does not decrease within a preset number of consecutive cycles. This indicates that the model has reached a relatively stable state and further training may not lead to better results.
[0173] After training stops, parameters of the trained multi-task feature extraction network, spatiotemporal dynamic prediction model, and confidence verification module are frozen. Parameter freezing fixes the model's parameters and prevents them from being updated. This ensures the model's stability in practical applications and prevents prediction results from being affected by random parameter changes.
[0174] After parameter freezing, stable model parameters are generated for actual predictions. These parameters can be saved and directly loaded in real-world applications to dynamically predict the consumer population in a business district. During actual prediction, simply input the newly acquired drone visible light image sequence into the trained model. Following the previously described steps, the consumer population distribution forecast for the business district area can be generated for multiple consecutive time periods in the future. This is then verified using the confidence verification module, ultimately generating a dynamic forecast report that maps the temporal dimension to the spatial region.
[0175] Throughout the training and application process, attention should be paid to data privacy protection. The visible light image sequences collected by drones and the related label data may contain some privacy-sensitive information, such as the appearance and movement trajectory of individuals. In order to prevent the leakage of these privacy-sensitive data, encryption technology can be used to encrypt the data. For example, when storing data, a symmetric encryption algorithm is used to encrypt the data and store it in the database. Only authorized personnel can use the key to decrypt it. During data transmission, secure transmission protocols such as SSL / TLS protocols are used to ensure that the data is not stolen or tampered with during transmission. At the same time, during model training and prediction, the processing of privacy-sensitive data must comply with relevant laws, regulations and ethical standards to ensure that the use of data is legal, compliant and secure.
[0176] Figure 2 This diagram illustrates exemplary hardware and software components of a drone-based system 100 for predicting the dynamics of consumer population in a commercial district, as provided in some embodiments of the present application. For example, processor 120 may be used in drone-based system 100 for predicting the dynamics of consumer population in a commercial district, and may be used to perform the functions described in the present application.
[0177] The system 100 for predicting the dynamic consumer population in a commercial district based on drone identification can be a general-purpose server or a special-purpose server, both of which can be used to implement the method for predicting the dynamic consumer population in a commercial district based on drone identification described herein. Although only one server is shown in this application, for convenience, the functions described herein can be implemented in a distributed manner on multiple similar platforms to balance the processing load.
[0178] For example, the system 100 for predicting the dynamics of consumer population in a business district based on drone identification may include a network port 110 connected to a network, one or more processors 120 for executing program instructions, a communication bus 130, and storage media 140 in different forms, such as a disk, ROM, or RAM, or any combination thereof. Exemplarily, the system 100 for predicting the dynamics of consumer population in a business district based on drone identification may also include program instructions stored in ROM, RAM, or other types of non-transitory storage media, or any combination thereof. The method of the present application can be implemented according to these program instructions. The system 100 for predicting the dynamics of consumer population in a business district based on drone identification also includes an input / output (I / O) interface 150 between the computer and other input and output devices.
[0179] For ease of explanation, only one processor is described in the system 100 for predicting the dynamics of consumer population in a business district based on drone identification. However, it should be noted that the system 100 for predicting the dynamics of consumer population in a business district based on drone identification in this application may also include multiple processors, so the steps performed by one processor described in this application may also be performed jointly or individually by multiple processors. For example, if the processor of the system 100 for predicting the dynamics of consumer population in a business district based on drone identification executes steps A and B, it should be understood that steps A and B may also be executed jointly by two different processors or individually in one processor. For example, the first processor executes step A, the second processor executes step B, or the first processor and the second processor execute steps A and B together.
[0180] In addition, an embodiment of the present invention further provides a readable storage medium, in which computer-executable instructions are preset. When a processor executes the computer-executable instructions, the above-mentioned method for dynamically predicting the consumer population in a business district based on drone identification is implemented.
[0181] It should be noted that in order to simplify the description of the present invention and thus help understand one or more embodiments of the invention, in the foregoing description of the embodiments of the present invention, multiple features are sometimes combined into one embodiment, figure or description thereof.
Claims
1. A method for predicting the dynamics of consumer population in a commercial district based on drone identification, characterized by: The method comprises: Acquire a drone visible light image sequence containing continuous time stamps, wherein the drone visible light image sequence is composed of multiple frames of images continuously captured by a low-altitude drone in a commercial area; Performing end-to-end feature extraction on the visible light image sequence of the UAV through a pre-trained multi-task feature extraction network to generate a three-dimensional feature tensor containing crowd density distribution features, individual movement trajectory features, and group aggregation morphology features; Calling the spatiotemporal dynamic prediction model to perform time series correlation and spatial mapping processing on the three-dimensional feature tensor to generate consumer population distribution prediction results for multiple consecutive time periods in the future in the business district area; Perform historical trend matching analysis on the consumer population distribution prediction results through a confidence verification module, and output verification data including prediction confidence scores and key change periods; A dynamic prediction report including a correspondence between a time dimension and a spatial region is generated based on the verification data.
2. The method for predicting the dynamics of consumer population in a commercial district based on drone identification according to claim 1 is characterized in that: The pre-trained multi-task feature extraction network performs end-to-end feature extraction on the UAV visible light image sequence to generate a three-dimensional feature tensor containing crowd density distribution features, individual movement trajectory features, and group aggregation morphology features, including: Inputting the UAV visible light image sequence into an input processing layer of a multi-task feature extraction network, performing pixel value normalization processing on the UAV visible light image sequence through the input processing layer and adjusting the pixel values to a uniform resolution size preset by the multi-task feature extraction network, thereby generating a pre-processed multi-frame image; Multi-scale convolutional feature extraction is performed on a single-frame image through the spatial feature encoding subnetwork of the multi-task feature extraction network to extract the local contour features of the crowd, the spatial context association features, and the global structure features of the scene, respectively. The spatial feature encoding subnetwork includes a shallow convolution module, a middle-layer hole convolution module, and a deep global pooling module connected in sequence. The temporal association subnetwork of the multi-task feature extraction network performs attention aggregation on the spatial features of consecutive frame images in the temporal dimension to generate a temporal feature vector containing time dependency, wherein the temporal association subnetwork uses a bidirectional long short-term memory network to capture the forward and backward crowd movement trends; The spatial features and temporal features are decoupled by the feature decoupling subnetwork of the multi-task feature extraction network, and the crowd density distribution feature representing the number of people per unit area, the individual movement trajectory feature representing the path of individual position change, and the group gathering morphological feature representing the shape of the group gathering area are separated by the orthogonal constraint loss function; The feature calibration subnetwork of the multi-task feature extraction network is used to perform scale normalization processing on the density distribution features, movement trajectory features and aggregation morphology features to generate a three-dimensional feature tensor, wherein the scale normalization processing adjusts the variance and mean of each feature dimension based on the statistical distribution of historical annotation data.
3. The method for predicting the dynamics of consumer population in a commercial district based on drone identification according to claim 2 is characterized in that: The method of performing attention aggregation in the time dimension on the spatial features of consecutive frame images through the temporal association subnetwork of the multi-task feature extraction network to generate a temporal feature vector containing time dependency includes: The spatial features of consecutive frames are spliced in the time dimension to generate a time series feature cube containing multi-frame features. The time dimension length of the time series feature cube is equal to the number of continuously acquired image frames. The importance weight of each frame’s spatial features to the current frame prediction is calculated through the temporal attention layer of the temporal association subnetwork. The importance weight is obtained by calculating the cosine similarity between the current frame features and the historical frame features. Use the temporal attention weight to perform weighted summation on the temporal feature cube to generate a contextual feature vector focused on key historical frames. The contextual feature vector strengthens the historical information that has a significant impact on the current frame prediction. Adding the context feature vector and the spatial feature of the current frame element by element to generate an enhanced current frame feature, wherein the enhanced current frame feature includes both local information of the current frame and trend information of historical frames; The enhanced continuous frame features are temporally modeled through the bidirectional long short-term memory network of the temporal association subnetwork. The bidirectional long short-term memory network captures the long-term dependencies of crowd movement from the past to the future and from the future to the past, respectively, and outputs a temporal feature vector containing forward and backward trends.
4. The method for predicting the dynamics of consumer population in a commercial district based on drone identification according to claim 1 is characterized in that: The calling of the spatiotemporal dynamic prediction model performs time series correlation and spatial mapping processing on the three-dimensional feature tensor to generate consumer population distribution prediction results for multiple consecutive time periods in the future in the business district, including: Inputting the three-dimensional feature tensor into the fusion layer of the spatiotemporal dynamic prediction model, calculating the correlation weights among density distribution features, movement trajectory features, and aggregation morphology features through the self-attention mechanism of the fusion layer, and generating a fusion feature matrix; Performing time series analysis on the fused feature matrix through the time series modeling layer of the spatiotemporal dynamic prediction model, extracting the periodicity of changes in consumer population within a historical period by using the gated recurrent unit of the time series modeling layer, and generating time series context features reflecting time dependency; Using the spatial partitioning layer of the spatiotemporal dynamic prediction model, the business district area is divided into grid-like sub-region units based on the geographical boundaries of the business district and the density of historical population distribution, and each sub-region unit corresponds to a spatial dimension in the feature matrix; Inputting the temporal context features and the historical population distribution weights of each sub-regional unit into the spatial mapping layer of the spatiotemporal dynamic prediction model, and calculating the population prediction value of each sub-regional unit in the future period through the fully connected neural network of the spatial mapping layer; The predicted values of each sub-regional unit are normalized through the output layer of the spatiotemporal dynamic prediction model so that the sum of the predicted values of all sub-regional units maintains a consistent proportion with the total consumer population of the current period, thereby generating a consumer population distribution prediction result for each sub-regional unit for multiple consecutive periods in the future.
5. The method for predicting the dynamics of consumer population in a commercial district based on drone identification according to claim 4 is characterized in that: The spatial division layer of the spatiotemporal dynamic prediction model is used to divide the business district area into grid-like sub-region units based on the geographical boundaries of the business district and the density of historical population distribution, including: Obtaining geographic boundary coordinate data of the business district area, which is obtained by fusing satellite maps with field survey data, and is used to determine the overall coverage of the business district area; Determine the division density of the sub-regional units according to the density of historical population distribution, wherein the division density of the densely populated area is greater than the division density of the sparsely populated area; Performing non-uniform grid division on the commercial area based on the division density to generate a grid matrix containing sub-area units of different areas, wherein each unit of the grid matrix corresponds to a unique spatial index; Extracting historical population distribution data stored during the model training phase, wherein the historical population distribution data includes historical average population values of each sub-regional unit in different time periods; Calculate the ratio of the historical average population value of each sub-region unit to the overall average of the business district, and use the ratio as the initial weight parameter of the corresponding sub-region unit; The initial weight parameters are normalized so that the sum of the weight parameters of all sub-region units is 1.
6. The method for predicting the dynamics of consumer population in a commercial district based on drone identification according to claim 1 is characterized in that: The confidence verification module performs historical trend matching analysis on the consumer population distribution prediction results and outputs verification data including prediction confidence scores and key change periods, including: Extracting time series data from the consumer population distribution prediction result, wherein the time series data includes the population prediction value of each sub-region unit in each future time period; Obtain the historical validation dataset stored during the model training phase. The historical validation dataset contains the actual consumer population values and the corresponding drone image sequences for the same time span as the forecast period. Inputting the time series data and the actual values in the historical verification data set into the comparative analysis submodule of the confidence verification module, and evaluating the linear correlation between the prediction result and the historical trend by calculating the Pearson correlation coefficient between the time series data and the actual values in the historical verification data set; Calculating a prediction confidence score based on the Pearson correlation coefficient. The prediction confidence score is mapped to a range of 0-1 through normalization. A higher value indicates that the prediction result is more consistent with historical patterns. Analyze the second-order difference sequence of the time series data, and identify the period when the absolute value of the second-order difference exceeds a preset threshold as a key change period, wherein the second-order difference sequence represents the magnitude of the change rate of population size, and the key change period corresponds to the turning point of the growth or decline trend of the consumer population; The key change period is associated with the input three-dimensional feature tensor through the attribution analysis submodule of the confidence verification module, and the feature dimension that has the greatest impact on the trend turning point is extracted as supplementary information for the verification data.
7. The method for predicting the dynamics of consumer population in a commercial district based on drone identification according to claim 6 is characterized in that: The analyzing the second-order difference sequence of the time series data to identify key change periods includes: Traversing the time series data period by period, calculating the difference between the population forecast value of the current period and the forecast value of the previous period, and generating a first-order difference sequence, which represents the change range of the population in each period; Perform a second-order difference process on the first-order difference sequence, calculate the difference between the first-order difference of the current period and the first-order difference of the previous period, and generate a second-order difference sequence. The second-order difference sequence represents the magnitude of the change rate of population size. Calculate the mean and standard deviation parameters of the second-order difference sequence, where the mean represents the amplitude of the average change rate, and the standard deviation represents the degree of dispersion of the change rate; The preset threshold is set to the mean plus N times the standard deviation, and the preset threshold is used to distinguish normal fluctuations from trend reversals; Traverse the second-order difference sequence and mark all period indices whose absolute values exceed the preset threshold as key change periods. Key change periods represent the turning points of acceleration or deceleration of the growth or decline trend of the consumer population; The key change periods that continuously exceed the preset threshold are merged to generate a key change period interval including a start period and an end period. The key change period interval is used to centrally display the time range of trend turning points in the dynamic forecast report.
8. The method for predicting the dynamics of consumer population in a commercial district based on drone identification according to claim 1 is characterized in that: Generating a dynamic prediction report including a correspondence between a time dimension and a spatial region based on the verification data includes: Establishing a two-dimensional data matrix of time dimension and space region, wherein the row index of the two-dimensional data matrix is the future time period division unit, and the column index is the business circle region unit; Fill the predicted population value of each sub-region unit in each time period in the verification data into the corresponding position of the two-dimensional data matrix, and mark the prediction confidence score of each corresponding position; Screening abnormal cells with confidence scores lower than a preset threshold from the two-dimensional data matrix, wherein the abnormal cells represent sub-regions and time periods where the deviation between the prediction result and the historical pattern is greater than the set deviation threshold; Highlight the row index corresponding to the key change period, and associate the main influencing feature dimensions output by the attribution analysis submodule with the highlighted annotation; Converting the two-dimensional data matrix into a visual heat map, wherein the visual heat map represents the predicted population value through a color gradient, and superimposes the marker symbols of the abnormal cells and the timeline annotations of the key change periods; Integrate heat maps, abnormal cell lists, and key change period analysis into structured documents to generate dynamic forecast reports that include the correspondence between time dimensions and spatial areas.
9. The method for predicting the dynamics of consumer population in a commercial district based on drone identification according to claim 8, characterized in that: The step of converting the two-dimensional data matrix into a visual heat map comprises: defining a color mapping rule for the visualized heat map, wherein the color mapping rule maps the population prediction value to a continuous color gradient from blue to red; Assign a color value corresponding to the position in the two-dimensional data matrix to each sub-region unit. The color value is adjusted according to the ratio of the predicted value to the historical average value, highlighting the areas above or below the historical level. Superimposing marker symbols of abnormal cells in the visualized heat map, where the size of the marker symbols is inversely proportional to the confidence score; Add a timeline annotation at the bottom of the visual heat map, the timeline annotation corresponds to the key change period interval, and distinguishes the growth turning point area and the decline turning point area by horizontal strips of different colors; Adding axis labels to the visualized heat map, wherein the axis labels include a specific time period description of the time dimension and a sub-area name of the space dimension; The visualization heat map is subjected to resolution adjustment and edge smoothing processing to generate a final visualization heat map.
10. A system for predicting the dynamics of consumer population in a commercial district based on drone identification, characterized in that: It includes a processor and a memory, the memory is connected to the processor, the memory is used to store programs, instructions or codes, and the processor is used to execute the programs, instructions or codes in the memory to implement the method for dynamically predicting the consumer population in a business district based on drone identification as described in any one of claims 1 to 9.
Citation Information
Patent Citations
Urban people flow prediction method based on space-time dynamic neural network
CN112257934A
Early warning analysis method based on intelligent vision and server
CN119810757A
Commercial vitality prediction and business district evaluation method based on multi-modal feature fusion
CN119918981A
Historical and cultural block spatial evolution simulation method and system based on GIS space-time analysis
CN120256969A
Unmanned aerial vehicle intelligent identification method and system for shielding target
CN120259926A
Cited By
Crowd density prediction method and device, equipment, storage medium and program product
CN121214346A