A scenic spot tourist identification method and system based on multi-scale travel chain features

By employing a multi-scale travel chain feature approach, combined with XGBoost and Transformer Encoder models, the problem of low tourist identification accuracy in existing technologies is solved, achieving accurate identification and improved stability of tourists in scenic areas. This approach is suitable for scenic area visitor flow analysis and tourism behavior research.

CN123179267APending Publication Date: 2026-11-27CENT SOUTH UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611154236.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-31
Publication Date
2026-11-27

AI Technical Summary

Technical Problem

Existing tourist identification methods rely on mobile phone signaling and GPS location data, resulting in low identification accuracy. They are unable to distinguish tourists from surrounding residents and scenic area staff, and they ignore the spatiotemporal differences in tourists' short-term travel chains and long-term behavioral patterns, leading to limited identification effectiveness.

Method used

We employ a multi-scale travel chain feature approach, which constructs multi-dimensional spatiotemporal behavioral features by acquiring user mobile phone data and scenic spot lists. We then use the XGBoost model and the Transformer Encoder model for comprehensive discrimination, and combine weighted fusion to improve recognition accuracy.

Benefits of technology

It enables accurate identification of tourists in scenic areas, reduces misjudgments, and improves the accuracy and stability of identification, making it suitable for scenic area visitor flow analysis and tourism behavior research.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123179267A_ABST
    Figure CN123179267A_ABST
Patent Text Reader

Abstract

The present application relates to a kind of scenic spot tourist identification method and system based on multi-scale travel chain feature, method includes: according to user mobile phone data to obtain complete travel chain, and according to the list of scenic spots to obtain scenic spot AOI data;Filter to reach the candidate scenic spot tourists inside scenic spot;Multi-dimensional spatiotemporal behavior feature extraction is carried out to complete travel chain, and according to pre-set XGBoost model and pre-set Transformer Encoder model respectively to obtain prediction probability value;Weighted fusion is carried out, and final tourist discriminant probability value is obtained.From single stay, short-term travel chain and long-term behavior three level dimensions, spatiotemporal behavior feature is extracted, and different behavior types of tourists and non-tourists are comprehensively judged, to realize the accurate identification of scenic spot tourists;It can fully depict the comprehensive characteristics of tourists in time distribution, space movement and behavior continuity, reduce the misjudgment caused by single rule identification, improve the accuracy and stability of scenic spot tourist identification.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of tourism data processing, and particularly relates to a method and system for identifying scenic spot tourists based on multi-scale travel chain characteristics. Background Art

[0002] With the rapid development of the tourism industry, especially the rise of [inbound tourism], tourist groups exhibit diverse characteristics in terms of age, socio-economic attributes, travel habits, and the like. To achieve personalized travel route recommendation and tourist behavior analysis, it is necessary to accurately identify real tourists in scenic spots. Mobile phone data contains rich spatiotemporal information; if tourists can be identified, their travel habits, itinerary time, and route choices can be analyzed, providing important support for intelligent recommendation of travel routes.

[0003] Existing tourist identification methods have the following problems:

[0004] Common tourist identification methods are mostly based on location data such as mobile phone signaling and GPS, and make judgments by setting simple rules such as stay duration and visit frequency, which have problems such as low identification accuracy and difficulty in distinguishing tourists from surrounding residents, scenic spot staff, and the like. In addition, existing methods often ignore the spatiotemporal characteristic differences of tourists in short-term travel chains and long-term behavior patterns, resulting in limited identification effects. Therefore, there is a need for an identification technology that can comprehensively utilize the multi-dimensional spatiotemporal behavior characteristics of tourists and integrate modern machine learning methods, so as to improve the accuracy and applicability of tourist identification. Summary of the Invention

[0005] To solve the above technical problems, the present invention provides a method and system for identifying scenic spot tourists based on multi-scale travel chain characteristics.

[0006] The technical solution adopted by the present invention is as follows:

[0007] In a first aspect, a method for identifying scenic spot tourists based on multi-scale travel chain characteristics is provided, including:

[0008] Obtaining user mobile phone data and a scenic spot list table in a target research area;

[0009] Obtaining a complete travel chain of mobile phone users according to the user mobile phone data, and obtaining scenic spot AOI data according to the scenic spot list table;

[0010] Screening mobile phone users who have reached the interior of a scenic spot according to the complete travel chain and the scenic spot AOI data, as candidate scenic spot tourists;

[0011] Extracting multi-dimensional spatiotemporal behavior characteristics of the complete travel chains of the candidate scenic spot tourists to obtain multi-dimensional spatiotemporal behavior characteristic data;

[0012] Multi-dimensional spatiotemporal behavioral feature data are input into the pre-set XGBoost model and the pre-set TransformerEncoder model respectively to obtain the first tourist prediction probability value and the second tourist prediction probability value.

[0013] The predicted probability values ​​of the first tourist and the predicted probability values ​​of the second tourist are weighted and fused to obtain the final tourist discrimination probability value.

[0014] Furthermore, obtain user mobile phone data and a list of scenic spots within the target research area, including:

[0015] Collect mobile phone data of all mobile phone users in the target study area during a preset time period. The mobile phone data includes the latitude and longitude location information, time information and user information of each mobile phone GPS positioning. The user information includes socioeconomic attribute information.

[0016] Collect a list of all scenic spots within the target study area.

[0017] Furthermore, based on user mobile phone data, the complete travel chain of the mobile phone user is obtained, and based on the list of scenic spots, the AOI data of the scenic spots is obtained, including:

[0018] Step S1: Determine the trajectory point sequence for each mobile phone user based on the latitude and longitude location information and time information in the user's mobile phone data. and the corresponding time series Each trajectory point Includes latitude and longitude coordinates The corresponding timestamp is n represents the total number of trajectory points;

[0019] Step S2: Use the geodesic formula to calculate the distance from the centroid c of the current stopping point to the trajectory point. The distance is:

[0020] ;

[0021] Wherein, the expression for the centroid c is: , , S is the set of stopping points; For trajectory points latitude and longitude coordinates;

[0022] Step S3, when When the distance is not greater than the preset distance value m, the trajectory point will be... Add the dwell point set S and update the centroid c = , track points As a new starting point;

[0023] Step S4, when When the distance is greater than the preset distance value m, calculate the duration of the set of dwell points S. , For trajectory points timestamp, For trajectory points The timestamp; when the duration is not less than the preset time, the trajectory point As a stop point, add it to the stop point set S, and the trajectory point As a new starting point, execute steps S2 and S3 until all trajectory points have been traversed, obtaining the final set of stopping points; when the duration is less than the preset time, the trajectory point... Not used as a stopover point;

[0024] Step S5: Combine the timestamps of each stop in the final stop set to establish the complete travel chain for the mobile phone user in chronological order;

[0025] Step S6: Obtain the AOI data of the scenic spots based on the list of scenic spots and map software.

[0026] Furthermore, based on the complete travel chain and scenic area AOI data, mobile phone users who have arrived inside the scenic area are selected as candidate scenic area tourists, including:

[0027] Based on the complete travel chain and scenic area AOI data, determine the number of stops each mobile phone user makes within the scenic area;

[0028] Mobile phone users who have at least one stop within the scenic area are selected as candidate tourists.

[0029] Furthermore, multi-dimensional spatiotemporal behavioral features were extracted from the complete travel chain of tourists at candidate scenic spots, resulting in multi-dimensional spatiotemporal behavioral feature data, including:

[0030] Visitors to candidate scenic spots are divided into tourist groups and non-tourist groups. Non-tourist groups include scenic spot workers and residents near the scenic spots.

[0031] For each mobile phone user in both tourist and non-tourist groups, feature extraction was performed across three dimensions: single stay, short-term travel chain, and long-term behavior, yielding multi-dimensional spatiotemporal behavioral feature data. This multi-dimensional spatiotemporal behavioral feature data includes single stay characteristics, short-term travel chain characteristics, and long-term behavior characteristics. Single stay characteristics include single stay duration, arrival time, and holidays. Short-term travel chain characteristics include stay sequence patterns, time intervals between events, and travel distance. Long-term behavior characteristics include historical visit frequency, visit cycle patterns, and the proportion of nighttime stays.

[0032] Furthermore, multi-dimensional spatiotemporal behavioral feature data are input into a pre-built XGBoost model and a pre-built Transformer Encoder model, respectively, to obtain the first and second predicted probability values ​​of tourists to the candidate scenic spots, including:

[0033] Based on each stay event, tabular input features are extracted and constructed from multi-dimensional spatiotemporal behavioral feature data.

[0034] Input the tabular input features into the pre-set XGBoost model and output the first tourist prediction probability value;

[0035] Based on the sequence of stay events within a preset short time period, the sequence spatiotemporal behavioral feature data of the stay event sequence is extracted from the multidimensional spatiotemporal behavioral feature data to form a sequence input matrix;

[0036] Input the sequence input matrix into a preset Transformer Encoder model, and output the second tourist prediction probability value.

[0037] Furthermore, the pre-built XGBoost model construction process is as follows:

[0038] Acquire historical spatiotemporal behavioral characteristics of historical tourist groups and historical non-tourist groups within the target study area, and use them as tabular input features;

[0039] Extracting the input vector of historical stay events t from tabular input features. d represents dimension;

[0040] input vector As input, the initial XGBoost model is trained by constructing multiple weak learner CART regression trees and performing gradient boosting iterative optimization to obtain the pre-set XGBoost model;

[0041] The optimization objective of the pre-built XGBoost model is:

[0042] ;

[0043] in, This represents the actual label corresponding to the historical dwell event t. , When the value is 0, the actual label is "non-tourist". When the value is 1, the actual label is "tourist"; T represents the total number of historical stay events.

[0044] Indicates the model's predicted probability;

[0045] This represents the k-th CART regression tree;

[0046] Represents regularization terms for tree structures;

[0047] loss function Logistic regression loss is used, and its expression is:

[0048] ;

[0049] The pre-built XGBoost model combines the weighted results of multiple CART regression trees and transforms them using the sigmoid function to obtain the predicted probability value of the first tourist. .

[0050] Furthermore, the pre-built Transformer Encoder model construction process is as follows:

[0051] Obtain historical spatiotemporal behavioral characteristics data of historical tourist groups and historical non-tourist groups in the target study area within the most recent N days, and arrange them in chronological order to obtain the historical stay event sequence G. T represents the total number of historical stay events;

[0052] For each historical dwell event t, the features are encoded using linear mapping or an embedding layer to obtain an initial vector. ;d represents dimension;

[0053] Each historical stay event t is assigned a positional code based on the order of historical stay events in the historical stay event sequence G. , thus obtaining the event vector ;

[0054] The historical sequence input matrix is ​​constructed by using the event vectors of all historical stay events. ;

[0055] Input the historical sequence into the matrix Input the initial Transformer Encoder model for training to obtain the pre-set Transformer Encoder model;

[0056] The pre-built Transformer Encoder model consists of multiple stacked multi-head self-attention mechanisms and feedforward networks;

[0057] The multi-head self-attention mechanism is used to calculate the correlation between any two historical dwell events, and the expression is:

[0058] ;

[0059] Where Q represents the query item matrix, K represents the key matrix. V represents the value matrix. ; Indicates the dimension of K; , and All are preset matrices;

[0060] Feedforward networks are used for the output of each layer. Feature transformation is performed, and the expression is:

[0061] ;

[0062] in, and For preset weights, and This is the default value;

[0063] Each layer incorporates residual connections and a LayerNorm structure, and after stacking L layers, the final sequence is output. ;

[0064] For each historical dwell event t, extract the encoded result of the corresponding sequence position. Input a pre-built Transformer Encoder model with a fully connected classification layer MLP, and output the second tourist prediction probability value. ; To pre-set the fully connected weights, This is the preset fully connected value.

[0065] Furthermore, the predicted probability values ​​of the first tourist and the second tourist are weighted and fused to obtain the final tourist discrimination probability value, including:

[0066] Predict the probability value of the first visitor Second tourist prediction probability value Substituting into the weighted fusion calculation formula, we obtain the final tourist discrimination probability value. The expression for the weighted fusion calculation formula is:

[0067] ;

[0068] in, [0, 1] represents the preset weight parameters.

[0069] Secondly, a tourist identification system for scenic areas based on multi-scale travel chain features is provided, including:

[0070] The data acquisition module is used to acquire user mobile phone data and scenic spot list within the target research area;

[0071] The data processing module is used to obtain the complete travel chain of the mobile phone user based on the user's mobile phone data, and to obtain the AOI data of the scenic spot based on the scenic spot list.

[0072] The tourist screening module is used to filter mobile phone users who arrive at the scenic area based on the complete travel chain and scenic area AOI data, as candidate scenic area tourists;

[0073] The spatiotemporal behavior feature extraction module is used to extract multi-dimensional spatiotemporal behavior features from the complete travel chain of tourists in candidate scenic spots, and obtain multi-dimensional spatiotemporal behavior feature data.

[0074] The dual-model tourist identification module is used to input multi-dimensional spatiotemporal behavioral feature data into a pre-set XGBoost model and a pre-set Transformer Encoder model respectively to obtain the first tourist prediction probability value and the second tourist prediction probability value.

[0075] The fusion module is used to weight and fuse the predicted probability values ​​of the first tourist and the predicted probability values ​​of the second tourist to obtain the final tourist discrimination probability value.

[0076] The beneficial effects achieved by this invention are as follows:

[0077] Acquire user mobile phone data and a list of scenic spots within the target study area; obtain the complete travel chain of mobile phone users based on the user mobile phone data, and obtain the AOI data of scenic spots based on the list of scenic spots; filter mobile phone users who have arrived inside the scenic spots based on the complete travel chain and the scenic spot AOI data as candidate scenic spot tourists; extract multi-dimensional spatiotemporal behavioral features from the complete travel chain of the candidate scenic spot tourists to obtain multi-dimensional spatiotemporal behavioral feature data; input the multi-dimensional spatiotemporal behavioral feature data into a pre-built XGBoost model and a pre-built Transformer Encoder model respectively to obtain the first tourist prediction probability value and the second tourist prediction probability value; perform weighted fusion of the first tourist prediction probability value and the second tourist prediction probability value to obtain the final tourist discrimination probability value.

[0078] Spatiotemporal behavioral features are extracted from three dimensions: single stay, short-term travel chain, and long-term behavior. Based on this, different behavioral types of tourists and non-tourists are comprehensively distinguished to achieve accurate identification of tourists in scenic areas.

[0079] It can fully characterize the comprehensive features of tourists in terms of time distribution, spatial movement and behavioral continuity, reduce misjudgments caused by identification based on a single rule, improve the accuracy and stability of tourist identification in scenic areas, and is suitable for scenic area visitor flow analysis and tourism behavior research based on mobile phone location data. Attached Figure Description

[0080] Figure 1This is a flowchart of the scenic area tourist identification method based on multi-scale travel chain features according to the present invention;

[0081] Figure 2 This is a structural diagram of the scenic area tourist identification system based on multi-scale travel chain features of the present invention. Detailed Implementation

[0082] The present invention will be further described below with reference to the accompanying drawings. The following embodiments are only used to more clearly illustrate the technical solution of the present invention, and should not be used to limit the scope of protection of the present invention.

[0083] like Figure 1 As shown in the figure, an embodiment of the present invention provides a method for identifying tourists in scenic areas based on multi-scale travel chain features, the specific contents of which include:

[0084] 101. Obtain user mobile phone data and a list of scenic spots within the target research area;

[0085] In this embodiment, user mobile phone data of all mobile phone users within the target study area during a preset time period is collected. The user mobile phone data includes the latitude and longitude location information, time information, and user information of each mobile phone GPS positioning. The user information includes socio-economic attribute information. A list of scenic spots within the target study area is also collected. The scenic spots can be red tourism scenic spots.

[0086] Specifically, this could involve studying the latitude and longitude location information and time information of users' mobile phone GPS positioning for each time in region A, as well as the users' socioeconomic attribute data.

[0087] For example: User ID 1280 generated a GPS location record on May 23, 2023. The longitude of the location is 112.995752, the latitude is 28.215910, and the location time is 09:42:32 on 2023-05-23; The list of scenic spots has the name of the scenic spot in the first column and whether it is a scenic spot in the second column; for example: Scenic spot name: Lei Feng Park, whether it is a red scenic spot: yes.

[0088] 102. Obtain the complete travel chain of the mobile phone user based on the user's mobile phone data, and obtain the AOI data of the scenic spot based on the list of scenic spots;

[0089] The spatial location records of each mobile phone user are sorted by time to establish the complete travel chain of the mobile phone user. The record table is shown in Table 1 below.

[0090] Table 1 User Spatiotemporal Information Record Table

[0091]

[0092] In Table 1, ID is used to uniquely identify mobile phone users, stime is the start time of the stop point, etime is the end time of the stop point, and lon and lat are the longitude and latitude of the stop point.

[0093] Step S1: Determine the trajectory point sequence for each mobile phone user based on the latitude and longitude location information and time information in the user's mobile phone data. and the corresponding time series Each trajectory point Includes latitude and longitude coordinates The corresponding timestamp is n is the total number of trajectory points;

[0094] Step S2: Use the geodesic formula to calculate the distance from the centroid c of the current stopping point to the trajectory point. The distance is:

[0095] ;

[0096] Wherein, the expression for the centroid c is: , , S is the set of stopping points; For trajectory points latitude and longitude coordinates;

[0097] Step S3, when When the distance is not greater than the preset distance value m, the trajectory point will be... Add the dwell point set S and update the centroid c = , track points As a new starting point;

[0098] Step S4, when When the distance is greater than the preset distance value m, calculate the duration of the set of dwell points S. , For trajectory points timestamp, For trajectory points The timestamp; when the duration is not less than the preset time, the trajectory point As a stop point, add it to the stop point set S, and the trajectory point As a new starting point, execute steps S2 and S3 until all trajectory points have been traversed, obtaining the final set of stopping points; when the duration is less than the preset time, the trajectory point... Not designated as a stopover point; the preset time can be 20 minutes.

[0099] Step S5: Combine the timestamps of each stop in the final stop set to establish the complete travel chain for the mobile phone user in chronological order;

[0100] Step S6: Obtain the AOI data of the scenic spots based on the list of scenic spots and map software;

[0101] The Python program is used to implement this. First, the name of the scenic spot is input, such as Leifeng Park. The Python program obtains the AOI information of Leifeng Park [[112.6520, 28.0459], ..., [112.6520, 28.0459]] by connecting to the Baidu Map Developer Platform API interface. At this time, the obtained data is still in the BD-09 coordinate system, which needs to be converted to the WGS84 coordinate system. This part is also completed in the Python program. Finally, the AOI data of the scenic spot is obtained [[112.6401, 28.0434], ..., [112.6401, 28.0434]].

[0102] 103. Based on the complete travel chain and scenic area AOI data, mobile phone users who have arrived inside the scenic area are selected as candidate scenic area tourists.

[0103] In this embodiment, based on the user spatiotemporal information record table and the scenic area AOI data, the number of stops for each mobile phone user within the scenic area is determined; mobile phone users with at least one stop within the scenic area are selected as candidate scenic area tourists.

[0104] Specifically, based on the gpd.sjoin() function in the Python program, the user's spatiotemporal information record table is matched with the scenic area AOI data to select users whose stay points are inside the scenic area;

[0105] For example, user represents the spatiotemporal information record table data of users, jignqu_aoi represents the AOI data of scenic spots, sample data of users is shown in Table 1, and the finally obtained joined data is shown in Table 2.

[0106] Table 2. Spatiotemporal Information Record of Stops within the Scenic Area

[0107]

[0108] In Table 2, ID is used to uniquely identify mobile phone users, stime is the start time of the stop point, etime is the end time of the stop point, and lon and lat are the longitude and latitude of the stop point.

[0109] 104. Multi-dimensional spatiotemporal behavioral features were extracted from the complete travel chain of tourists in the candidate scenic spots to obtain multi-dimensional spatiotemporal behavioral feature data.

[0110] In this embodiment, the tourists in the candidate scenic area are divided into tourist groups and non-tourist groups. The non-tourist group includes scenic area workers and residents near the scenic area. Three groups are selected from the user information: tourists, scenic area workers, and residents near the scenic area. For tourists, tourists from other places are selected as the analysis object for tourist behavior analysis. The identity of scenic area workers is identified through their socioeconomic attribute information. For residents near the scenic area, they are defined as users whose residence is within 200 meters of the scenic area.

[0111] For each mobile phone user in both tourist and non-tourist groups, feature extraction was performed on the complete travel chain of each user across three dimensions: single stay, short-term travel chain, and long-term behavior, to obtain multi-dimensional spatiotemporal behavioral feature data.

[0112] Multidimensional spatiotemporal behavioral characteristic data includes single-stay characteristics, short-term travel chain characteristics, and long-term behavioral characteristics;

[0113] Characteristics of a single stay include: duration of stay, arrival time, and holidays;

[0114] The characteristics of short-term travel chains include: stop sequence patterns, time intervals between events, and travel distance. The stop sequence pattern is that different users may have the same stop sequence and the same travel purpose, so stop sequences with the same travel purpose are grouped into the same pattern.

[0115] Long-term behavioral characteristics include: historical visit frequency, visit cycle patterns, and nighttime stay ratio.

[0116] 105. Input the multi-dimensional spatiotemporal behavioral feature data into the pre-set XGBoost model and the pre-set TransformerEncoder model respectively to obtain the first tourist prediction probability value and the second tourist prediction probability value.

[0117] In this embodiment, (1) tabular input features are extracted and constructed from multi-dimensional spatiotemporal behavioral feature data based on each stay event;

[0118] Extract and construct tabular input features from multi-dimensional spatiotemporal behavioral feature data of a single dwelling event. The tabular input features include, but are not limited to:

[0119] Time characteristics: arrival time, length of stay, whether it is a holiday or weekend;

[0120] Spatial characteristics: AOI type of the stop point, distance from the core scenic spot of the area, and distance from the stop point to the user's residence;

[0121] Behavioral statistics: Number of visits to the scenic area, total stay time, and most active time period in the past 30 days;

[0122] Discrete feature values ​​are encoded using one-hot encoding, while continuous values ​​are encoded using normalized encoding, ultimately forming the input vector.

[0123] The construction process of the pre-built XGBoost model is as follows:

[0124] Acquire historical spatiotemporal behavioral characteristics of historical tourist groups and historical non-tourist groups within the target study area, and use them as tabular input features;

[0125] Extracting the input vector of historical stay events t from tabular input features. d represents dimension;

[0126] input vector As input, the initial XGBoost model is trained by constructing multiple weak learner CART regression trees and performing gradient boosting iterative optimization to obtain the pre-set XGBoost model;

[0127] The optimization objective of the pre-built XGBoost model is:

[0128] ;

[0129] in, This represents the actual label corresponding to the historical dwell event t. , When the value is 0, the actual label is "non-tourist". When the value is 1, the actual label is "tourist"; T represents the total number of historical stay events.

[0130] Indicates the model's predicted probability;

[0131] This represents the k-th CART regression tree;

[0132] Represents regularization terms for tree structures;

[0133] loss function Logistic regression loss is used, and its expression is:

[0134] .

[0135] (2) Input the tabular input features into the preset XGBoost model and output the first tourist prediction probability value;

[0136] The pre-built XGBoost model combines the weighted results of multiple CART regression trees and transforms them using the sigmoid function to obtain the predicted probability value of the first tourist. ;

[0137] First visitor predicted probability value This indicates the degree of similarity between the stay event and tourist behavior patterns at the statistical characteristics level.

[0138] (3) Based on the sequence of stay events within a preset short time period, extract the sequence spatiotemporal behavior feature data of the stay event sequence from the multidimensional spatiotemporal behavior feature data to form a sequence input matrix;

[0139] (4) Input the sequence input matrix into the preset Transformer Encoder model and output the second tourist prediction probability value.

[0140] The process of building a pre-built Transformer Encoder model is as follows:

[0141] Obtain historical spatiotemporal behavioral characteristics data of historical tourist groups and historical non-tourist groups in the target study area within the most recent N days, and arrange them in chronological order to obtain the historical stay event sequence G. T represents the total number of historical stay events; historical stay events Includes the following features:

[0142] Dwell duration characteristics: Dwell duration (minutes), whether the dwell time is abnormally long;

[0143] Spatial category characteristics: the AOI category to which the event location belongs, and whether it is located in a scenic area;

[0144] Temporal context features: time period, weekday / weekend markers, holiday markers;

[0145] Behavioral attributes: arrival / departure time, time interval between events.

[0146] Each historical dwell time event is mapped to a d-dimensional vector. The specific method is as follows:

[0147] Event Embedding:

[0148] Each feature is encoded through a linear mapping or an embedding layer, for example:

[0149] Classification features (AOI category, time period) → Embedding;

[0150] Numerical characteristics (stay time) → linear transformation or bucketing embedding;

[0151] Ultimately, this forms the event vector: ;

[0152] Positional Encoding:

[0153] To preserve event sequence information, the historical stay event sequence G introduces position encoding for each historical stay event t. , thus obtaining the event vector ;

[0154] The historical sequence input matrix is ​​constructed by using the event vectors of all historical stay events. ;

[0155] Input the historical sequence into the matrix Input the initial Transformer Encoder model for training to obtain the pre-set Transformer Encoder model;

[0156] The pre-built Transformer Encoder model consists of multiple stacked multi-head self-attention mechanisms and feedforward networks;

[0157] Multi-head self-attention is used to calculate the correlation between any two historical dwell events, expressed as:

[0158] ;

[0159] Where Q represents the query item matrix, K represents the key matrix. ; Let K be the transpose of K; V represents the value matrix. ; Indicates the dimension of K; , and All are preset matrices;

[0160] Feedforward networks are used for the output of each layer. Feature transformation is performed, and the expression is:

[0161] ;

[0162] in, and For preset weights, and This is the default value;

[0163] Each layer incorporates residual connections and a LayerNorm structure, and after stacking L layers, the final sequence is output. ;

[0164] For each historical dwell event t, extract the encoded result of the corresponding sequence position. Input a pre-built Transformer Encoder model with a fully connected classification layer MLP, and output the second tourist prediction probability value. ; To pre-set the fully connected weights, This is the preset fully connected value.

[0165] Second tourist prediction probability value Let represent the probability that a tourist stays in the scenic area corresponding to a stay event.

[0166] 106. The predicted probability values ​​of the first tourist and the predicted probability values ​​of the second tourist are weighted and fused to obtain the final tourist discrimination probability value.

[0167] In this embodiment, in order to simultaneously utilize the complementary advantages of the XGBoost model and the Transformer Encoder model, a fusion discrimination mechanism based on the dual model outputs is used to comprehensively calculate the "tourist probability" of each stay event, thereby improving the stability and accuracy of the identification.

[0168] Independent model training and probability output:

[0169] Both the XGBoost and Transformer Encoder models are trained under supervised supervision using labeled dwell event samples. The labels are from:

[0170] The system uses two labels: one for non-tourist groups (scenic area staff and surrounding residents), and another for tourists (representing visitors from other areas). The two models learn recognition rules for tourist and non-tourist behavior (spatiotemporal statistics vs. behavioral sequence structure), respectively. After training, each model outputs a probability for each visitation event: the predicted probability value for the first tourist. Second tourist prediction probability value , ;

[0171] Weighted Fusion:

[0172] The outputs of the two models are fused using a weighted method:

[0173] ;

[0174] in: [0,1] represents the preset weight parameters, and the optimal value can be determined through validation set grid search, Bayesian optimization, or dynamic adjustment.

[0175] Adaptive threshold determination mechanism:

[0176] Final tourist discrimination probability value after fusion The output needs to automatically determine the classification threshold based on the sample labels. Unlike the traditional fixed threshold of 0.5, this embodiment uses a threshold optimized based on the ROC curve, selecting the Youden's J point, which has the largest true positive rate (TPR) minus the false positive rate (FPR), as the threshold.

[0177] ;

[0178] Finally, an adaptive threshold is obtained through the validation set. And it applies to all dwell events:

[0179] ;

[0180] in, =1 indicates a pause event. For tourist behavior; =0 indicates a dwell time event. This is not the behavior of tourists.

[0181] The beneficial effects achieved by the embodiments of the present invention are as follows:

[0182] Acquire user mobile phone data and a list of scenic spots within the target study area; obtain the complete travel chain of mobile phone users based on the user mobile phone data, and obtain the AOI data of scenic spots based on the list of scenic spots; filter mobile phone users who have arrived inside the scenic spots based on the complete travel chain and the scenic spot AOI data as candidate scenic spot tourists; extract multi-dimensional spatiotemporal behavioral features from the complete travel chain of the candidate scenic spot tourists to obtain multi-dimensional spatiotemporal behavioral feature data; input the multi-dimensional spatiotemporal behavioral feature data into a pre-built XGBoost model and a pre-built Transformer Encoder model respectively to obtain the first tourist prediction probability value and the second tourist prediction probability value; perform weighted fusion of the first tourist prediction probability value and the second tourist prediction probability value to obtain the final tourist discrimination probability value.

[0183] Spatiotemporal behavioral features are extracted from three dimensions: single stay, short-term travel chain, and long-term behavior. Based on this, different behavioral types of tourists and non-tourists are comprehensively distinguished to achieve accurate identification of tourists in scenic areas.

[0184] It can fully characterize the comprehensive features of tourists in terms of time distribution, spatial movement and behavioral continuity, reduce misjudgments caused by identification based on a single rule, improve the accuracy and stability of tourist identification in scenic areas, and is suitable for scenic area visitor flow analysis and tourism behavior research based on mobile phone location data.

[0185] Based on the above embodiments, a method for identifying tourists in scenic areas based on multi-scale travel chain features is described. The following embodiments illustrate a system for identifying tourists in scenic areas based on multi-scale travel chain features.

[0186] like Figure 2 As shown, this embodiment of the invention provides a scenic area tourist identification system based on multi-scale travel chain features, including:

[0187] Data acquisition module 201 is used to acquire user mobile phone data and scenic spot list within the target research area;

[0188] The data processing module 202 is used to obtain the complete travel chain of the mobile phone user based on the user's mobile phone data, and to obtain the scenic spot AOI data based on the scenic spot list table;

[0189] The tourist screening module 203 is used to screen mobile phone users who have arrived inside the scenic area based on the complete travel chain and scenic area AOI data, as candidate scenic area tourists;

[0190] The spatiotemporal behavior feature extraction module 204 is used to extract multi-dimensional spatiotemporal behavior features from the complete travel chain of tourists in candidate scenic spots, and obtain multi-dimensional spatiotemporal behavior feature data.

[0191] The dual-model tourist identification module 205 is used to input multi-dimensional spatiotemporal behavioral feature data into the preset XGBoost model and the preset Transformer Encoder model respectively to obtain the first tourist prediction probability value and the second tourist prediction probability value.

[0192] The fusion module 206 is used to perform weighted fusion of the first tourist prediction probability value and the second tourist prediction probability value to obtain the final tourist discrimination probability value.

[0193] The beneficial effects achieved by this invention are as follows:

[0194] Spatiotemporal behavioral features are extracted from three dimensions: single stay, short-term travel chain, and long-term behavior. Based on this, different behavioral types of tourists and non-tourists are comprehensively distinguished to achieve accurate identification of tourists in scenic areas.

[0195] It can fully characterize the comprehensive features of tourists in terms of time distribution, spatial movement and behavioral continuity, reduce misjudgments caused by identification based on a single rule, improve the accuracy and stability of tourist identification in scenic areas, and is suitable for scenic area visitor flow analysis and tourism behavior research based on mobile phone location data.

[0196] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0197] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0198] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0199] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0200] The above are merely embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention are included within the scope of the claims of the present invention pending approval.

Claims

1. A method for identifying tourists in scenic areas based on multi-scale travel chain features, characterized in that, include: Obtain user mobile phone data and a list of scenic spots within the target research area; The complete travel chain of mobile phone users is obtained based on user mobile phone data, and the AOI data of scenic spots is obtained based on the list of scenic spots; Mobile phone users who arrive inside the scenic area are selected as candidate tourists based on the complete travel chain and scenic area AOI data. Multi-dimensional spatiotemporal behavioral features were extracted from the complete travel chain of tourists in candidate scenic spots to obtain multi-dimensional spatiotemporal behavioral feature data. Multi-dimensional spatiotemporal behavioral feature data are input into the pre-set XGBoost model and the pre-set Transformer Encoder model respectively to obtain the first tourist prediction probability value and the second tourist prediction probability value. The predicted probability values ​​of the first tourist and the predicted probability values ​​of the second tourist are weighted and fused to obtain the final tourist discrimination probability value.

2. The method for identifying tourists in scenic areas based on multi-scale travel chain features according to claim 1, characterized in that, Obtain user mobile phone data and a list of scenic spots within the target research area, including: Collect mobile phone data of all mobile phone users in the target study area during a preset time period. The mobile phone data includes the latitude and longitude location information, time information and user information of each mobile phone GPS positioning. The user information includes socio-economic attribute information. Collect a list of all scenic spots within the target study area.

3. The method for identifying tourists in scenic areas based on multi-scale travel chain features according to claim 2, characterized in that, Based on user mobile phone data, the complete travel chain of the mobile phone user is obtained, and based on the list of scenic spots, the AOI data of the scenic spots is obtained, including: Step S1: Determine the trajectory point sequence for each mobile phone user based on the latitude and longitude location information and time information in the user's mobile phone data. and the corresponding time series Each trajectory point Includes latitude and longitude coordinates The corresponding timestamp is n represents the total number of trajectory points; Step S2: Use the geodesic formula to calculate the distance from the centroid c of the current stopping point to the trajectory point. The distance is: ; Wherein, the expression for the centroid c is: , , S is the set of stopping points; For trajectory points latitude and longitude coordinates; Step S3, when When the distance is not greater than the preset distance value m, the trajectory point will be... Add the dwell point set S and update the centroid c = , track points As a new starting point; Step S4, when When the distance is greater than the preset distance value m, calculate the duration of the set of stopping points S. , For trajectory points timestamp, For trajectory points The timestamp; when the duration is not less than the preset time, the trajectory point will be... As a stop point, add it to the stop point set S, and the trajectory point As a new starting point, execute steps S2 and S3 until all trajectory points have been traversed, obtaining the final set of stopping points; when the duration is less than the preset time, the trajectory point... Not used as a stopover point; Step S5: Combine the timestamps of each stop in the final stop set to establish the complete travel chain for the mobile phone user in chronological order; Step S6: Obtain the AOI data of the scenic spots based on the list of scenic spots and map software.

4. The method for identifying tourists in scenic areas based on multi-scale travel chain features according to claim 3, characterized in that, Based on the complete travel chain and scenic area AOI data, mobile phone users who have arrived inside the scenic area are selected as candidate scenic area tourists, including: Based on the complete travel chain and scenic area AOI data, determine the number of stops each mobile phone user makes within the scenic area; Mobile phone users who have at least one stop within the scenic area are selected as candidate tourists.

5. The method for identifying tourists in scenic areas based on multi-scale travel chain features according to claim 4, characterized in that, Multi-dimensional spatiotemporal behavioral features were extracted from the complete travel chain of tourists at candidate scenic spots to obtain multi-dimensional spatiotemporal behavioral feature data, including: Visitors to candidate scenic spots are divided into tourist groups and non-tourist groups. Non-tourist groups include scenic spot workers and residents near the scenic spots. For each mobile phone user in both tourist and non-tourist groups, feature extraction was performed across three dimensions: single stay, short-term travel chain, and long-term behavior, yielding multi-dimensional spatiotemporal behavioral feature data. This multi-dimensional spatiotemporal behavioral feature data includes single stay characteristics, short-term travel chain characteristics, and long-term behavior characteristics. Single stay characteristics include single stay duration, arrival time, and holidays. Short-term travel chain characteristics include stay sequence patterns, time intervals between events, and travel distance. Long-term behavior characteristics include historical visit frequency, visit cycle patterns, and the proportion of nighttime stays.

6. The method for identifying tourists in scenic areas based on multi-scale travel chain features according to claim 5, characterized in that, Multi-dimensional spatiotemporal behavioral feature data are input into a pre-built XGBoost model and a pre-built Transformer Encoder model, respectively, to obtain the first and second predicted probability values ​​of tourists to candidate scenic spots, including: Based on each stay event, tabular input features are extracted and constructed from multi-dimensional spatiotemporal behavioral feature data. Input the tabular input features into the pre-set XGBoost model and output the first tourist prediction probability value; Based on the sequence of stay events within a preset short time period, the sequence spatiotemporal behavioral feature data of the stay event sequence is extracted from the multidimensional spatiotemporal behavioral feature data to form a sequence input matrix; Input the sequence input matrix into a preset Transformer Encoder model, and output the second tourist prediction probability value.

7. The method for identifying tourists in scenic areas based on multi-scale travel chain features according to claim 6, characterized in that, The construction process of the pre-built XGBoost model is as follows: Acquire historical spatiotemporal behavioral characteristics of historical tourist groups and historical non-tourist groups within the target study area, and use them as tabular input features; Extracting the input vector of historical stay events t from tabular input features. d represents dimension; input vector As input, the initial XGBoost model is trained by constructing multiple weak learner CART regression trees and performing gradient boosting iterative optimization to obtain the pre-set XGBoost model; The optimization objective of the pre-built XGBoost model is: ; in, This represents the actual label corresponding to the historical dwell event t. , When the value is 0, the actual label is "non-tourist". When the value is 1, the actual label is "tourist"; T represents the total number of historical stay events. Indicates the model's predicted probability; This represents the k-th CART regression tree; Represents regularization terms for tree structures; loss function Logistic regression loss is used, and its expression is: ; The pre-built XGBoost model combines the weighted results of multiple CART regression trees and transforms them using the sigmoid function to obtain the predicted probability value of the first tourist. .

8. The method for identifying tourists in scenic areas based on multi-scale travel chain features according to claim 6, characterized in that, The process of building a pre-built Transformer Encoder model is as follows: Obtain historical spatiotemporal behavioral characteristics data of historical tourist groups and historical non-tourist groups in the target study area within the most recent N days, and arrange them in chronological order to obtain the historical stay event sequence G. T represents the total number of historical stay events; For each historical dwell event t, the features are encoded using linear mapping or an embedding layer to obtain an initial vector. ;d represents dimension; Each historical stay event t is assigned a positional code based on the order of historical stay events in the historical stay event sequence G. , thus obtaining the event vector ; The historical sequence input matrix is ​​constructed by using the event vectors of all historical stay events. ; Input the historical sequence into the matrix Input the initial Transformer Encoder model for training to obtain the pre-set Transformer Encoder model; The pre-built Transformer Encoder model consists of multiple stacked multi-head self-attention mechanisms and feedforward networks; The multi-head self-attention mechanism is used to calculate the correlation between any two historical dwell events, and the expression is: ; Where Q represents the query item matrix, K represents the key matrix. ; Let K be the transpose of K; V represents the value matrix. ; Indicates the dimension of K; , and All are preset matrices; Feedforward networks are used for the output of each layer. Feature transformation is performed, and the expression is: ; in, and As preset weights, and This is the default value; Each layer incorporates residual connections and a LayerNorm structure, and after stacking L layers, the final sequence is output. ; For each historical dwell event t, extract the encoded result of the corresponding sequence position. Input a pre-built TransformerEncoder model with a fully connected classification layer MLP, and output the second tourist prediction probability value. ; To pre-set the weights of the fully connected components, This is the preset fully connected value.

9. The method for identifying tourists in scenic areas based on multi-scale travel chain features according to any one of claims 1-8, characterized in that, The predicted probability values ​​of the first tourist and the second tourist are weighted and fused to obtain the final tourist discrimination probability value, including: Predict the probability value of the first visitor Second tourist prediction probability value Substituting into the weighted fusion calculation formula, we obtain the final tourist discrimination probability value. The expression for the weighted fusion calculation formula is: ; in, [0, 1] represents the preset weight parameters.

10. A tourist identification system for scenic areas based on multi-scale travel chain features, characterized in that, include: The data acquisition module is used to acquire user mobile phone data and scenic spot list within the target research area; The data processing module is used to obtain the complete travel chain of the mobile phone user based on the user's mobile phone data, and to obtain the AOI data of the scenic spot based on the scenic spot list. The tourist screening module is used to filter mobile phone users who arrive at the scenic area based on the complete travel chain and scenic area AOI data, as candidate scenic area tourists; The spatiotemporal behavior feature extraction module is used to extract multi-dimensional spatiotemporal behavior features from the complete travel chain of tourists in candidate scenic spots, and obtain multi-dimensional spatiotemporal behavior feature data. The dual-model tourist identification module is used to input multi-dimensional spatiotemporal behavioral feature data into a pre-set XGBoost model and a pre-set Transformer Encoder model respectively to obtain the first tourist prediction probability value and the second tourist prediction probability value. The fusion module is used to weight and fuse the predicted probability values ​​of the first tourist and the predicted probability values ​​of the second tourist to obtain the final tourist discrimination probability value.