Real-time query method and query device for scenic spot sightseeing vehicle
By constructing and decomposing the time series of sightseeing bus arrival time and establishing a time prediction system based on the regression model, the problem of inaccurate prediction of the arrival time and residence time of scenic spot sightseeing buses is solved, and the prediction accuracy and tour experience are improved.
Patent Information
- Application Number
- CN202510294057.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-12
- Publication Date
- 2025-06-27
AI Technical Summary
In the existing technology, the arrival and residence time predictions of scenic spot sightseeing buses are inaccurate, resulting in tourists waiting time too long, the tour experience is reduced, and the utilization rate of sightseeing buses is not high, and resources are wasted.
By obtaining the historical arrival time and stay time of the sightseeing bus to reach the tourist locations in each scenic spot, a time series is constructed, and the trend components, seasonal components and residual components are decomposed. Based on these components and influence characteristics (such as date, weather, passenger flow, emergencies), a regression model is established to form a time prediction model to predict the actual arrival time and residence time of the sightseeing vehicle.
It improves the prediction accuracy of the arrival time and stay time of sightseeing buses, reduces the waiting time of tourists, improves the tour experience, and optimizes the resource utilization rate of sightseeing buses.
Smart Images

Figure CN120218332A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data prediction, and in particular to a real-time query method for sightseeing vehicles in a scenic area, a query device, a computer-readable storage medium, a computer program product, and a real-time query system for sightseeing vehicles in a scenic area. Background Art
[0002] In modern tourism, the sightseeing experience of large scenic spots or parks is an important part of tourist satisfaction. With the increase in the number of tourists, how to efficiently use sightseeing resources, especially sightseeing buses, has become a major challenge for scenic spot management. Traditionally, the sightseeing bus services provided by scenic spots are often based on fixed routes and schedules. This model will cause the actual arrival time of the sightseeing bus to be inconsistent with the standard time under peak passenger flow, different weather conditions or other influencing factors, further causing tourists to wait too long and the sightseeing experience to decline. At the same time, the utilization rate of the sightseeing bus may not be high, resulting in a waste of resources.
[0003] In recent years, with the development of the Internet of Things, big data analysis, and artificial intelligence technologies, the tourism industry has begun to explore how to use these technologies to optimize tourists' sightseeing experience, especially in sightseeing bus services. However, existing technologies often only consider a limited number of factors when planning sightseeing bus services, such as the distance between scenic spots and the speed of sightseeing buses. This simplified analysis cannot fully reflect the dynamic changes within the scenic area, such as fluctuations in passenger flow, changes in weather conditions, and holiday effects, which have a significant impact on the operating time and tour experience of sightseeing buses. This leads to a deviation between the predicted results and the actual situation, causing tourists to face the problem of waiting too long or missing the best time to visit, reducing their tour satisfaction. Summary of the invention
[0004] The main purpose of the present application is to provide a real-time query method for scenic spot sightseeing buses, a query device, a computer-readable storage medium, a computer program product and a real-time query system for scenic spot sightseeing buses, so as to at least solve the problem of inaccurate prediction of the arrival time and stay time of scenic spot sightseeing buses in the prior art.
[0005] To achieve the above object, according to one aspect of the present application, a real-time query method for scenic area sightseeing vehicles is provided, including: obtaining a plurality of sightseeing locations in a target scenic area, and obtaining a plurality of historical arrival times, a plurality of historical stay times, and a plurality of influencing characteristics for the sightseeing vehicles to reach each of the sightseeing locations, where the influencing characteristics are influencing factors for the historical arrival time and the historical stay time; constructing a time series for each of the historical arrival times and each of the historical stay times corresponding to each of the sightseeing locations in chronological order, and decomposing the time series to obtain a trend component, a seasonal component, and a residual component, where the trend component includes the average values of the historical arrival times corresponding to each of the sightseeing locations and the average values of the historical stay times, the seasonal component is used to represent the influence degree of weekends and holidays on the historical arrival time and each of the historical stay times, and the residual component is the average difference between the historical arrival times and the historical stay times in common situations and the historical arrival times and the historical stay times corresponding to uncommon situations; establishing a corresponding regression model according to the trend component, the seasonal component, the residual component, and the influencing characteristics to form a time prediction model; inputting the standard arrival time, the standard stay time, and the current influencing characteristics of the sightseeing vehicles to reach each of the sightseeing locations into the time prediction model to obtain the actual arrival time and the actual stay time of the sightseeing vehicles to reach each of the sightseeing locations; and pushing the actual arrival time and the actual stay time of the sightseeing vehicles to reach each of the sightseeing locations to the client of the target user.
[0006] Optionally, after obtaining a plurality of historical arrival times, a plurality of historical stay times, and a plurality of influencing characteristics for the sightseeing vehicles to reach each of the sightseeing locations, the method further includes: processing each non-numerical influencing characteristic by using a numerical encoding method to obtain a numerical influencing characteristic.
[0007] Optionally, decompose the time series to obtain a trend component, a seasonal component, and a residual component, including: processing the time series using a moving average method to obtain the trend component; calculating the average difference between each of the historical arrival times and each of the historical residence times on holidays and each of the historical arrival times and each of the historical residence times on non-holidays to obtain a holiday difference; calculating the average difference between each of the historical arrival times and each of the historical residence times on weekends and each of the historical arrival times and each of the historical residence times on weekdays to obtain a weekend difference; performing a weighted average on the holiday difference and the weekend difference to obtain the seasonal component; calculating the average difference between each of the historical arrival times and each of the historical residence times under common difference factors and each of the historical arrival times and each of the historical residence times under uncommon difference factors to obtain the residual component, where the common difference factors include that the weather condition is common weather, the passenger flow size is within a predetermined range, and there are no emergencies, and the uncommon difference factors include that the weather condition is extreme weather, the passenger flow size is not within the predetermined range, and there are emergencies.
[0008] Optionally, establish a corresponding regression model based on the trend component, the seasonal component, the residual component, and the influencing characteristics to form a time prediction model, including: constructing a trend regression model T A,t =β0 + β1t + ∈ t1 , where T A,t is the trend component, β0 is the intercept of the trend regression model, β1 is the slope of the trend regression model, t is the standard arrival time and the standard residence time, and ∈ t1 is the first error term; constructing a seasonal regression model S A,t =β2holiday t +β3weekend t +∈ t2 , where S A,t is the seasonal component, β2 is the influence degree of holidays on the seasonal component, β3 is the influence degree of weekends on the seasonal component, holiday t is the holiday identifier, weekend t is the weekend identifier, and ∈ t2 is the second error term, and the holiday identifier and the weekend identifier are the influencing characteristics; constructing a residual regression model R A,t =β4thing t +β5weather t +β6traffic t +∈ t3 , where R A,tis the residual component, β4 is the influence degree of the emergency event on the residual component, β5 is the influence degree of the weather condition on the residual component, β6 is the influence degree of the passenger flow volume on the residual component, thing t is the emergency event identifier, weather t is the weather condition identifier, traffic t is the passenger flow volume identifier, ∈ t3 is the third error term, and the emergency event identifier, the weather condition identifier, and the passenger flow volume identifier are the influence features; the trend regression model, the seasonal regression model, and the residual regression model are combined to form the time prediction model.
[0009] Optionally, the method further includes: establishing a connection between the seasonal regression model and the residual regression model to obtain an interaction term, and adding the interaction term to the time prediction model for secondary training to obtain an optimized time prediction model, where the interaction term is a parameter term calculated by combining the parameters in the seasonal regression model and the parameters in the residual regression model.
[0010] Optionally, pushing the actual arrival time and the actual stay time of each sightseeing vehicle at each sightseeing location to the client of the target user includes: obtaining the actual arrival time and the actual stay time of the sightseeing vehicle at each sightseeing location, and obtaining the time spent by the target user to reach each sightseeing location; adding the actual arrival time and the actual stay time of the sightseeing vehicle at each sightseeing location to obtain the departure time; taking the sightseeing vehicles whose current time is less than the difference between the departure time and the time spent as target sightseeing vehicles, and pushing the target sightseeing vehicles, the actual arrival time of the target sightseeing vehicles, and the actual stay time of the target sightseeing vehicles to the client of the target user.
[0011] To achieve the above object, according to one aspect of the present application, a real-time query device for scenic area sightseeing vehicles is provided, including: an acquisition unit, configured to acquire a plurality of sightseeing locations in a target scenic area, and acquire a plurality of historical arrival times, a plurality of historical stay times, and a plurality of influencing features for the sightseeing vehicles to reach each of the sightseeing locations, where the influencing features are influencing factors that affect the historical arrival time and the historical stay time; a decomposition unit, configured to construct a time series for each of the historical arrival times and each of the historical stay times corresponding to each of the sightseeing locations in chronological order, and decompose the time series to obtain a trend component, a seasonal component, and a residual component, where the trend component includes the average values of the historical arrival times and the average values of the historical stay times corresponding to each of the sightseeing locations, the seasonal component is used to represent the influence degree of weekends and holidays on the historical arrival time and each of the historical stay times, and the residual component is the average difference between the historical arrival times and the historical stay times in common situations and the historical arrival times and the historical stay times corresponding to uncommon situations; a construction unit, configured to establish a corresponding regression model according to the trend component, the seasonal component, the residual component, and the influencing features to form a time prediction model; a prediction unit, configured to input the standard arrival time, the standard stay time of the sightseeing vehicle to reach each of the sightseeing locations, and the current influencing features into the time prediction model to obtain the actual arrival time and the actual stay time of the sightseeing vehicle to reach each of the sightseeing locations; a control unit, configured to push the actual arrival time and the actual stay time of the sightseeing vehicle to reach each of the sightseeing locations to the client of the target user.
[0012] According to another aspect of the present application, a computer-readable storage medium is provided, where the computer-readable storage medium includes a stored program, and when the program runs, it controls any one of the methods in the device where the computer-readable storage medium is located.
[0013] According to yet another aspect of the present application, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, it implements any one of the methods.
[0014] According to still another aspect of the present application, a real-time query system for scenic area sightseeing vehicles is provided, including: one or more processors, a memory, and one or more programs, where the one or more programs are stored in the memory and are configured to be executed by the one or more processors, and the one or more programs include those for executing any one of the methods.
[0015] Applying the technical solution of the present application in the above-mentioned real-time query method for scenic area sightseeing vehicles, it includes: obtaining multiple sightseeing locations in the target scenic area, and obtaining multiple historical arrival times, multiple historical stay times, and multiple influencing characteristics of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations. The above-mentioned influencing characteristics are the influencing factors that affect the above-mentioned historical arrival time and the above-mentioned historical stay time; constructing a time series for each of the above-mentioned historical arrival times and each of the above-mentioned historical stay times corresponding to each of the above-mentioned sightseeing locations in chronological order, and decomposing the above-mentioned time series to obtain a trend component, a seasonal component, and a residual component. The above-mentioned trend component includes the average value of each of the above-mentioned historical arrival times corresponding to the above-mentioned sightseeing locations and the average value of each of the above-mentioned historical stay times. The above-mentioned seasonal component is used to represent the influence degree of weekends and holidays on the above-mentioned historical arrival time and each of the above-mentioned historical stay times. The above-mentioned residual component is the average difference between the above-mentioned historical arrival time and the above-mentioned historical stay time in common situations and the above-mentioned historical arrival time and the above-mentioned historical stay time corresponding to uncommon situations; establishing a corresponding regression model based on the above-mentioned trend component, the above-mentioned seasonal component, the above-mentioned residual component, and the above-mentioned influencing characteristics to form a time prediction model; inputting the standard arrival time, standard stay time of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations, and the current above-mentioned influencing characteristics into the above-mentioned time prediction model to obtain the actual arrival time and actual stay time of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations; pushing the above-mentioned actual arrival time and the above-mentioned actual stay time of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations to the client of the target user. Through the present application, by obtaining multiple historical arrival times and multiple historical stay times of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations to construct a time series, and decomposing the time series to obtain a trend component, a seasonal component, and a residual component, and then establishing a time prediction model based on the trend component, the seasonal component, the residual component, and the obtained influencing characteristics to predict the actual arrival time and actual stay time of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations, and pushing the actual arrival time and actual stay time of arriving at each sightseeing location to the client of the target user, it avoids the user waiting for a long time in the scenic area due to the uncertain arrival time and stay time of the sightseeing vehicle, and solves the problem of inaccurate prediction of the arrival time and stay time of the scenic area sightseeing vehicle in the prior art. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] Figure 1 FIG. shows a hardware structure block diagram of a mobile terminal for implementing a real-time query method for scenic area sightseeing vehicles provided in an embodiment of the present application;
[0017] Figure 2 FIG. shows a flowchart of a real-time query method for scenic area sightseeing vehicles provided in an embodiment of the present application;
[0018] Figure 3Shows a module processing diagram of a real-time query method for scenic area sightseeing vehicles provided according to an embodiment of the present application;
[0019] Figure 4 Shows a construction flowchart of a time prediction model for a real-time query method for scenic area sightseeing vehicles provided according to an embodiment of the present application;
[0020] Figure 5 Shows a structural block diagram of a real-time query device for scenic area sightseeing vehicles provided according to an embodiment of the present application.
[0021] Among them, the above-mentioned drawings include the following reference numerals:
[0022] 102, processor; 104, memory; 106, transmission device; 108, input / output device. Detailed implementation manners
[0023] It should be noted that, without conflict, the embodiments in the present application and the features in the embodiments may be combined with each other. The present application will be described in detail below with reference to the drawings and in combination with the embodiments.
[0024] In order to enable those skilled in the art to better understand the solutions of the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without making creative efforts shall fall within the protection scope of the present application.
[0025] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and do not have to be used to describe a specific order or sequence. It should be understood that such data may be interchanged under appropriate circumstances so as to describe the embodiments of the present application here. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device including a series of steps or units does not necessarily have to be limited to those clearly listed steps or units, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0026] As introduced in the background art, the sightseeing vehicle service provided in the prior art in scenic areas often relies on fixed routes and schedules. Due to external factors, the actual arrival time of the sightseeing vehicle often does not match the standard time. To solve this technical problem, the embodiments of the present application provide a real-time query method for scenic area sightseeing vehicles, a query device, a computer-readable storage medium, a computer program product, and a real-time query system for scenic area sightseeing vehicles.
[0027] The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention.
[0028] The method embodiments provided in the embodiments of this application can be executed on a mobile terminal, a computer terminal, or a similar computing device. Taking the operation on a mobile terminal as an example, Figure 1 is a hardware structure block diagram of a mobile terminal for a real-time query method of a scenic area sightseeing vehicle according to an embodiment of the present invention. As Figure 1 shown, the mobile terminal may include one or more ( Figure 1 only one is shown in the figure) processors 102 (the processor 102 may include, but is not limited to, processing devices such as a microprocessor MCU or a field programmable gate array FPGA) and a memory 104 for storing data. Among them, the above-mentioned mobile terminal may further include a transmission device 106 for communication functions and an input / output device 108. Those of ordinary skill in the art can understand that Figure 1 the structure shown is only schematic and does not limit the structure of the above-mentioned mobile terminal. For example, the mobile terminal may further include more or fewer components than Figure 1 shown in the figure, or have a different configuration from Figure 1 shown in the figure.
[0029] The memory 104 can be used to store computer programs. For example, software programs and modules of application software, such as the computer program corresponding to a real-time query method of a scenic area sightseeing vehicle in an embodiment of the present invention. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, that is, implements the above-mentioned method. The memory 104 may include a high-speed random access memory, and may further include a non-volatile memory, such as one or more magnetic storage devices, flash memories, or other non-volatile solid-state memories. In some instances, the memory 104 may further include a memory remotely disposed relative to the processor 102, and these remote memories may be connected to the mobile terminal through a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an enterprise internal network, a local area network, a mobile communication network, and combinations thereof. The transmission device 106 is used to receive or send data via a network. Specific examples of the above-mentioned network may include a wireless network provided by a communication provider of the mobile terminal. In one instance, the transmission device 106 includes a network adapter (abbreviated as NIC), which can be connected to other network devices through a base station and thus can communicate with the Internet. In one instance, the transmission device 106 may be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.
[0030] In this embodiment, a real-time query method for scenic area sightseeing vehicles running on a mobile terminal, a computer terminal or a similar computing device is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order than here.
[0031] Figure 2 It is a flowchart of a real-time query method for scenic area sightseeing vehicles according to an embodiment of the present application. As Figure 2 shown, the method includes the following steps:
[0032] Step S201, obtain multiple sightseeing locations of the target scenic area, and obtain multiple historical arrival times, multiple historical stay times and multiple influencing features of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations, where the influencing features are influencing factors for the above-mentioned historical arrival time and the above-mentioned historical stay time;
[0033] Specifically, collect historical data of each sightseeing point in the target scenic area, including the historical arrival time (i.e., the historical arrival moment) of the sightseeing vehicle arriving at each sightseeing point, the historical stay time (i.e., the historical stay duration), and a series of influencing features that affect the change of these times. These influencing features include date attributes (such as weekdays, weekends, holidays), weather conditions, real-time passenger flow, and whether there are emergencies in the scenic area. Emergencies such as vehicle accidents or major events held in the sightseeing area. By collecting the historical arrival time, the historical stay time, and the influencing features at that time, it can effectively provide basic data for the subsequent analysis of predicted times.
[0034] Step S202, construct a time series by arranging the above-mentioned historical arrival times and the above-mentioned historical stay times corresponding to each of the above-mentioned sightseeing locations in chronological order, and decompose the above-mentioned time series to obtain a trend component, a seasonal component and a residual component. The above-mentioned trend component includes the average value of the above-mentioned historical arrival times corresponding to the above-mentioned sightseeing locations and the average value of the above-mentioned historical stay times, the above-mentioned seasonal component is used to represent the influence degree of weekends and holidays on the above-mentioned historical arrival time and the above-mentioned historical stay times, and the above-mentioned residual component is the average difference between the above-mentioned historical arrival time and the above-mentioned historical stay time in common situations and the above-mentioned historical arrival time and the above-mentioned historical stay time in uncommon situations;
[0035] Specifically, by sorting out the historical arrival times and historical residence times of the sightseeing buses at each scenic spot in the target scenic area, a time series arranged in chronological order can be formed. Each sequence element in the time series includes the historical arrival time (specific year, month, day, and specific time point) and the residence time (time period). Using data decomposition techniques, the time series is subdivided into three key parts: the trend component, the seasonal component, and the residual component. Among them, the trend component reveals the average values of the historical arrival times and the average values of the historical residence times. For the differences in residence times, mainly considering that when the passenger flow is large or in other situations, the sightseeing bus can reach the full load when arriving at the scenic spot and can directly depart, or if the specified passenger volume is not reached, the driver chooses to wait at this scenic spot, which will result in different collected residence times. The seasonal component quantifies the impact of the tourist behavior patterns during weekends and holidays on the time series, while the residual component captures the average differences between the arrival times and residence times under atypical conditions (such as special weather conditions, emergencies, or abnormal passenger flows) and those in common situations.
[0036] Step S203, establish a corresponding regression model based on the above-mentioned trend component, the above-mentioned seasonal component, the above-mentioned residual component, and the above-mentioned influencing characteristics to form a time prediction model;
[0037] Specifically, the construction of the time prediction model involves using the trend component to capture the long-term trends of the residence times and arrival times of the sightseeing buses at each scenic spot; the seasonal component is used to quantify the impact of periodic changes such as weekends and holidays on the arrival times and residence times; the residual component focuses on the impacts brought by atypical factors such as weather, passenger flow fluctuations, and emergencies. By integrating these components and influencing characteristics, comprehensively understand the time patterns of the operation of the sightseeing buses from different perspectives to construct a time prediction model to predict the arrival times and residence times of the sightseeing buses at each scenic spot.
[0038] Step S204, input the standard arrival times, standard residence times of the above-mentioned sightseeing buses at each of the above-mentioned scenic spots, and the current above-mentioned influencing characteristics into the above-mentioned time prediction model to obtain the actual arrival times and actual residence times of the above-mentioned sightseeing buses at each of the above-mentioned scenic spots;
[0039] Specifically, the preset arrival time (i.e., the standard arrival time) and the standard stay time of the sightseeing vehicle at each sightseeing location in the target scenic area, without being adjusted by influencing factors, together with the date attributes, weather conditions, passenger flow status, emergencies, etc. collected in real time (i.e., the current influencing characteristics), are used as key input data and fed into the trained time prediction model. This model takes into account the actual arrival time and actual stay time under the current environmental conditions based on deep learning. For example, when inputting "standard arrival time 8:00 and standard stay time 5 minutes" as the standard arrival time and standard stay time of the sightseeing vehicle at the scenic area entrance, the model will comprehensively analyze the real-time influencing characteristics such as the current date attributes, passenger flow, weather, and emergencies, and give the prediction of the actual arrival time of the sightseeing vehicle at each scenic spot. Based on the input and influencing characteristics, the predicted output calculated by the model may be "actual arrival time 8:10 and actual stay time 4 minutes".
[0040] Step S205: Push the above-mentioned actual arrival time and the above-mentioned actual stay time of each of the above-mentioned sightseeing vehicles at each of the above-mentioned sightseeing locations to the client of the target user.
[0041] Specifically, the actual arrival time and actual stay time of the sightseeing vehicle at each sightseeing point in the scenic area are connected to the personal client devices of tourists through instant messaging technology, such as smartphones or special information receiving software for the scenic area. Ensure that each tourist can obtain time guidance customized for the current conditions, helping them accurately master the actual arrival time of the sightseeing vehicle at each scenic spot and the expected stay duration, so as to optimize their personal tour rhythm, avoid ineffective waiting, and improve the travel efficiency and experience.
[0042] Through this embodiment, in the above-mentioned real-time query method for scenic area sightseeing vehicles, a plurality of sightseeing locations in the target scenic area are obtained, and a plurality of historical arrival times, a plurality of historical stay times, and a plurality of influencing features for the sightseeing vehicles to reach each of the above-mentioned sightseeing locations are obtained. The above-mentioned influencing features are the influencing factors for the above-mentioned historical arrival times and the above-mentioned historical stay times; the respective above-mentioned historical arrival times and the respective above-mentioned historical stay times corresponding to each of the above-mentioned sightseeing locations are constructed into a time series in chronological order, and the above-mentioned time series is decomposed to obtain a trend component, a seasonal component, and a residual component. The above-mentioned trend component includes the average value of the above-mentioned historical arrival times corresponding to each of the above-mentioned sightseeing locations and the average value of the above-mentioned historical stay times. The above-mentioned seasonal component is used to represent the influence degree of weekends and holidays on the above-mentioned historical arrival times and the respective above-mentioned historical stay times. The above-mentioned residual component is the average difference between the above-mentioned historical arrival times and the above-mentioned historical stay times in common situations and the above-mentioned historical arrival times and the above-mentioned historical stay times corresponding to uncommon situations; a corresponding regression model is established according to the above-mentioned trend component, the above-mentioned seasonal component, the above-mentioned residual component, and the above-mentioned influencing features to form a time prediction model; the standard arrival times, standard stay times, and the current above-mentioned influencing features of the sightseeing vehicles to reach each of the above-mentioned sightseeing locations are input into the above-mentioned time prediction model to obtain the actual arrival times and actual stay times of the sightseeing vehicles to reach each of the above-mentioned sightseeing locations; the above-mentioned actual arrival times and the above-mentioned actual stay times of the sightseeing vehicles to reach each of the above-mentioned sightseeing locations are pushed to the client of the target user. Through this application, a plurality of historical arrival times and a plurality of historical stay times of the sightseeing vehicles to reach each of the above-mentioned sightseeing locations are obtained to construct a time series, and the time series is decomposed to obtain a trend component, a seasonal component, and a residual component. Then, a time prediction model is established according to the trend component, the seasonal component, the residual component, and the obtained influencing features to predict the actual arrival times and actual stay times of the sightseeing vehicles to reach each of the above-mentioned sightseeing locations, and the actual arrival times and actual stay times of reaching each sightseeing location are pushed to the client of the target user, avoiding the situation that users wait for a long time in the scenic area due to the uncertain arrival time and stay time of the sightseeing vehicles, and solving the problem of inaccurate prediction of the arrival time and stay time of the scenic area sightseeing vehicles in the prior art.
[0043] In order to enable the influencing features to be used for constructing a time prediction model, in an optional implementation manner, after obtaining a plurality of historical arrival times, a plurality of historical stay times, and a plurality of influencing features for the sightseeing vehicles to reach each of the above-mentioned sightseeing locations, the above-mentioned method further includes:
[0044] Step S301, process each non-numerical above-mentioned influencing feature by using a numerical encoding method to obtain a numerical above-mentioned influencing feature.
[0045] Specifically, a numerical encoding method is adopted to convert non-numerical influencing features into numerical forms recognizable by a computer. This conversion process is completed by assigning specific numerical values to each feature state. In the present invention, binary variables are used to process weekends and weekdays to obtain a weekend identifier. If the day is Saturday or Sunday, the identifier takes a value of 1, indicating a weekend; when the date is from Monday to Friday, the value is 0, indicating a weekday. Binary variables are used to process holidays to obtain a holiday identifier. If the day is a holiday, the value is 1, and if the day is not a holiday, the value is 0. Categorical variables are used to process the weather conditions to obtain a weather condition identifier. If the weather condition on that day is sunny, the value is 0; if the weather condition is cloudy, the value is 1; if the weather condition is rainy, the value is 2; if the weather condition is snowy, the value is 3. Ternary variables are used to process the passenger flow volume to obtain a passenger flow volume identifier. If the passenger flow volume on that day is low, the value is 0; if the passenger flow volume is medium, the value is 1; if the passenger flow volume is high, the value is 2. The specific passenger flow judgment standard is subject to the judgment of the scenic area person in charge. Ternary variables are used to process emergencies to obtain an emergency identifier. If an emergency that attracts passengers occurs on that day, the value is 2; if an emergency that reduces passengers occurs on that day, the value is 1; if there is no emergency on that day, the value is 0.
[0046] In order to obtain a trend component, a seasonal component, and a residual component to construct a time prediction model, in an alternative embodiment, the above step S202 includes:
[0047] Step S2021, processing the above time series by using a moving average method to obtain the above trend component;
[0048] Specifically, the time series data of the historical arrival time and historical stay time of the sightseeing bus are smoothed to extract the trend component. The trend component represents the long-term trend gradually emerging over time in the time series data, which can help us understand the overall change direction of the sightseeing bus tour time.
[0049] Step S2022, calculating the average difference between the historical arrival times and historical stay times of holidays and those of non-holidays to obtain a holiday difference;
[0050] Specifically, by quantitatively calculating the mean differences in the historical arrival times and historical residence times of the sightseeing buses at each scenic spot during holidays and non-holiday periods, we can obtain the key indicator of holiday differences, which reflects the impact of holidays on the time pattern of the sightseeing buses. For example, by comparing the arrival times at the entrance A of a certain scenic area during the Spring Festival holiday and on weekdays, it is found that the average arrival time during the Spring Festival holiday is about 15 minutes longer than on weekdays, and the residence time also increases by 10 minutes accordingly. In this way, we convert the variation in the difference between holidays and non-holidays in the time series into specific numerical values, providing data support for subsequent model construction.
[0051] Step S2023, calculate the average differences between each of the above historical arrival times and each of the above historical residence times on weekends and each of the above historical arrival times and each of the above historical residence times on weekdays to obtain the weekend differences.
[0052] Specifically, by calculating the average differences in the historical arrival times and historical residence times on weekends and weekdays, the weekend differences can be accurately quantified, that is, the changes in the arrival times and residence times of the sightseeing buses at each scenic spot on weekends compared to weekdays. For example, we find that the average arrival time at the scenic spot B in the scenic area on weekends is 20 minutes later than on weekdays, and the residence time also increases by 15 minutes accordingly, which intuitively reflects the impact of the increased tourist flow and the change in the tour rhythm on the time pattern of the sightseeing buses on weekends.
[0053] Step S2024, perform a weighted average on the above holiday differences and the above weekend differences to obtain the above seasonal component.
[0054] Specifically, by assigning different weight coefficients to the holiday differences and the weekend differences respectively, the importance of these two differences is adjusted to more accurately capture their impact on the arrival times and residence times of the sightseeing buses.
[0055] Step S2025, calculate the average differences between each of the above historical arrival times and each of the above historical residence times under common difference factors and each of the above historical arrival times and each of the above historical residence times under uncommon difference factors to obtain the residual component. The above common difference factors include that the weather condition is common weather, the passenger flow size is within a predetermined range, and there are no emergencies. The above uncommon difference factors include that the weather condition is extreme weather, the passenger flow size is not within the above predetermined range, and there are the above emergencies.
[0056] Specifically, a comparative analysis strategy is adopted. By analyzing the historical data of the arrival and stay times of sightseeing vehicles under common difference factors and uncommon difference factors, residual components are extracted. The common difference factors cover relatively stable situations such as daily weather conditions (non-extreme weather), expected passenger flow, and no emergencies. In contrast, the uncommon difference factors include extreme weather events, unexpected surges or drops in passenger flow, and emergencies, etc., which are special situations that may cause fluctuations in time series data. By calculating the average differences in historical arrival times and stay times under the two difference factors, we can isolate the residual components, which contain abnormal changes beyond the normal pattern, providing information on the time changes of the sightseeing vehicle tour time in the face of extreme conditions for model establishment.
[0057] In order to construct a time prediction model, in an optional implementation manner, a corresponding regression model is established based on the above-mentioned trend component, the above-mentioned seasonal component, the above-mentioned residual component, and the above-mentioned influencing characteristics to form a time prediction model. The above-mentioned step S203 includes:
[0058] Step S2031, construct a trend regression model T based on the above-mentioned trend component A,t =β0 + β1t + ∈ t1 , where T A,t is the above-mentioned trend component, β0 is the intercept of the above-mentioned trend regression model, β1 is the slope of the above-mentioned trend regression model, t is the above-mentioned standard arrival time and the above-mentioned standard stay time, and ∈ t1 is the first error term;
[0059] Specifically, the trend component obtained from the average values of each historical arrival time and each historical stay time, as well as the standard arrival time corresponding to the average value of each historical arrival time and the standard stay time corresponding to the average value of each historical stay time, are used to train the model to obtain the regression coefficients β0 and β1. For example, if the average value of each historical arrival time within a certain period of the calculated trend component is 8:10, the average value of each historical stay time is 15 minutes, the standard arrival time corresponding to this historical arrival time and this historical stay time is 8:00, and the standard stay time is 10 minutes, that is, the trend regression model is trained with the trend component, the standard arrival time, and the standard stay time to obtain the regression coefficients and the first error term.
[0060] Step S2032, construct a seasonal regression model S based on the above-mentioned seasonal component A,t =β2holiday t +β3weekend t +∈ t2 , where S A,tFor the above seasonal component, β2 is the influence degree of holidays on the above seasonal component, β3 is the influence degree of weekends on the above seasonal component, and holiday t is the holiday identifier, and weekend t is the weekend identifier, and ∈ t2 is the second error term. The above holiday identifier and the above weekend identifier are the above influence features;
[0061] Specifically, taking the seasonal component S A,t as the dependent variable, and taking the holiday identifier and the weekend identifier as independent variables to train the seasonal regression model, and obtaining the regression coefficients β2, β3 and the second error term.
[0062] Step S2033, constructing a residual regression model R A,t = β4thing t + β5weather t + β6traffic t + ∈ t3 , where R A,t is the above residual component, β4 is the influence degree of the above unexpected event on the above residual component, β5 is the influence degree of the above weather condition on the above residual component, β6 is the influence degree of the above passenger flow volume on the above residual component, thing t is the unexpected event identifier, weather t is the weather condition identifier, traffic t is the passenger flow volume identifier, and ∈ t3 is the third error term. The above unexpected event identifier, the above weather condition identifier and the above passenger flow volume identifier are the above influence features;
[0063] Specifically, taking the residual component R A,t as the dependent variable, and taking the weather condition identifier, the passenger flow volume identifier and the unexpected event identifier as independent variables to train the seasonal regression model, and obtaining the regression coefficients β4, β5, β6 and the third error term.
[0064] Step S2034, combining the above trend regression model, the above seasonal regression model and the above residual regression model to form the above time prediction model.
[0065] Specifically, combining the trend regression model, the seasonal regression model and the residual regression model into a comprehensive time prediction model y A,t = β0 + β1t + β2holiday t + β3weekend t + β4thing t + β5weather t+β6traffic t +∈ t , where y A,t is the actual arrival time and actual stay time of the sightseeing vehicle, and ∈ t is the sum of the first error term, the second error term, and the third error term. Since the actual influence characteristics of each scenic area are different, a corresponding regression model can also be established according to the influence characteristics of the actual situation of the scenic area to update the time prediction model.
[0066] To optimize the model, in an optional implementation, the above method further includes:
[0067] Step S302, establish a connection between the above seasonal regression model and the above residual regression model to obtain an interaction term, and add the above interaction term to the above time prediction model for secondary training to obtain an optimized time prediction model. The above interaction term is a parameter term calculated by combining the parameters in the above seasonal regression model and the parameters in the above residual regression model.
[0068] Specifically, the interaction term aims to capture the combined influence of weather, passenger flow changes, and emergencies on the usage time of the sightseeing vehicle under weekend or holiday conditions. The addition of the interaction term enables the model to respond more sensitively to complex changes in the actual situation. For example, during holidays, the impact of the passenger flow size on the arrival time is different from that on non-holiday arrival times. That is, during holidays, it may cause a sharp increase in the passenger flow. Therefore, the model can also add interaction terms according to the actual situation to predict the arrival time and stay time under more complex influence characteristics. For example, on the basis of the time prediction model, add the interaction term β2holiday t *traffic t to form an optimized time prediction model. This interaction term expresses that during holidays, it may cause a sharp increase in the passenger flow, so it may lead to further time changes in the actual arrival time and stay time of the sightseeing vehicle. Other interaction terms can also be added according to the actual situation of the scenic area, such as the interaction term β3weekend t *traffic t between weekend and passenger flow size and the interaction term β3weekend t *weather t and so on.
[0069] To enable the target user to view the actual arrival time and actual stay time of the sightseeing vehicle, in an optional implementation, push the above actual arrival time and the above actual stay time of each above sightseeing vehicle arriving at each above sightseeing location to the client of the target user. The above step S205 includes:
[0070] Step S2051: Obtain the actual arrival time and the actual stay time of the sightseeing bus at each of the above-mentioned sightseeing locations, and obtain the time taken by the target user to reach each of the above-mentioned sightseeing locations.
[0071] Step S2052: Add the actual arrival time and the actual stay time of the sightseeing bus at each of the above-mentioned sightseeing locations to obtain the departure time.
[0072] Step S2053: Regard the sightseeing buses whose current time is less than the difference between the departure time and the time taken as the target sightseeing buses, and push the target sightseeing buses, their actual arrival times, and their actual stay times to the client of the target user.
[0073] Specifically, obtain and record the actual arrival time and the actual stay time of the sightseeing bus at each sightseeing location within the scenic area. At the same time, obtain the actual moving time, that is, the time taken, for the target user to reach each sightseeing point. Subsequently, by adding the actual arrival time and the actual stay time of each sightseeing location, we accurately calculate the total departure time of the sightseeing bus at each location, which is the exact time for the sightseeing bus to leave each scenic spot. By comparing the current time with the departure time and the difference from the actual moving time of the target user, we can identify the target sightseeing buses that can promptly respond to the tourists' needs and push the information of these sightseeing buses to the client of the user. This calculation process not only considers the travel time of the sightseeing bus itself but also fully takes into account the activity time of the tourists, thus providing accurate and reliable travel information for the path planning of the target user, enabling the target user to quickly find the most suitable sightseeing bus, avoiding long waits, and improving the sightseeing efficiency and experience.
[0074] It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. And although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order than here.
[0075] Figure 3 The module processing diagram of a real-time query method for a scenic area sightseeing bus according to an embodiment of the present application is shown, as Figure 3 shown:
[0076] The big data collection and processing module is used to collect data on the arrival time, stay time and influencing characteristics of the scenic spot sightseeing vehicles. Among them, the date recording module is used to collect the date attributes of the scenic spot on the day and determine whether the day is a weekend or a weekday; the holiday setting module is used to collect the holiday attributes of the scenic spot on the day and determine whether the day is a holiday or a non-holiday; the passenger flow setting module is used to obtain the size of the passenger flow, which can be obtained according to the number of tourists who use the software to reserve the scenic spot or the size of the passenger flow can be set by the staff based on the actual passenger flow size of the scenic spot; the video vehicle collection module is used to obtain the arrival time and stay time of the target sightseeing vehicle at each tourist location; the weather setting module is used to obtain the weather condition information of the scenic spot on the day, and the weather condition information includes sunny, cloudy, rainy and snowy days; the major event or incident module is used to obtain whether there is an emergency event in the scenic spot on the day, and the emergency event includes an accident-type event or a large-scale event held in the scenic spot. After obtaining the arrival time, stay time and influencing characteristics of the scenic area sightseeing buses collected by each module, data cleaning, processing of missing values and outliers are performed to make the obtained data more in line with the actual data specifications, avoid outliers from interfering with the acquired data and affecting the training of subsequent models, and then perform time series decomposition of the arrival time and stay time based on the influence of the influencing characteristics to obtain trend components, seasonal components and residual components.
[0077] Figure 4 A flowchart of constructing a time prediction model of a scenic spot sightseeing car real-time query method provided according to an embodiment of the present application is shown, such as Figure 4 As shown:
[0078] The steps of using the deep learning algorithm model to obtain the time prediction model, that is, the comprehensive regression model, are as follows:
[0079] S1: Time series decomposition: decompose the time series composed of the arrival time and the stay time of the sightseeing bus into three components: trend component, seasonal component and residual component, so as to improve the data basis for subsequent model training;
[0080] S2: Establishment of trend regression model, by constructing a mathematical model to calculate the average value of each arrival time and the average value of each stay time corresponding to the tourist attractions, eliminating the influence of data over time;
[0081] S3: Establish a seasonal regression model to quantify the impact of holidays and weekends on the arrival time and stay time of sightseeing buses, and ensure that the prediction model can reflect the changes brought about by these cyclical factors;
[0082] S4: Establish a residual regression model to analyze the impact of other factors on the arrival time and stay time of sightseeing buses, and improve the comprehensiveness and accuracy of the prediction;
[0083] S5: Establish the comprehensive regression model. Integrate the results of the trend regression model, seasonal regression model, and residual regression model. By considering the interactions of all influencing factors, construct a time prediction model to provide tourists with the accurate arrival time and stay time of the sightseeing bus at each sightseeing location.
[0084] The embodiment of the present application also provides a real-time query device for scenic area sightseeing buses. It should be noted that the real-time query device for scenic area sightseeing buses in the embodiment of the present application can be used to execute the method for real-time query of scenic area sightseeing buses provided by the embodiment of the present application. The device is used to implement the above embodiments and preferred implementation manners, and those that have been described will not be repeated. As used hereinafter, the term "module" can be a combination of software and / or hardware that can achieve a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, implementation in hardware, or a combination of software and hardware is also possible and contemplated.
[0085] The following introduces a real-time query device for scenic area sightseeing buses provided by the embodiment of the present application.
[0086] Figure 5 is a structural block diagram of a real-time query device for scenic area sightseeing buses according to an embodiment of the present application. As Figure 5 shown, the device includes:
[0087] An acquisition unit 10, configured to acquire multiple sightseeing locations in a target scenic area, and acquire multiple historical arrival times, multiple historical stay times, and multiple influencing features of the sightseeing bus arriving at each of the above-mentioned sightseeing locations, where the influencing features are influencing factors that affect the above-mentioned historical arrival time and the above-mentioned historical stay time;
[0088] Specifically, collect the historical data of each sightseeing point in the target scenic area, including the historical arrival time (i.e., the historical arrival moment) of the sightseeing bus arriving at each sightseeing point, the historical stay time (i.e., the historical stay duration), and a series of influencing features that affect the change of these times. These influencing features include date attributes (such as weekdays, weekends, holidays), weather conditions, the size of the real-time passenger flow, and whether there are emergencies in the scenic area. Emergencies include events such as vehicle accidents or major events held in the scenic area. By collecting the historical arrival time, historical stay time, and the influencing features at that time, it can effectively provide basic data for the subsequent analysis of predicted time.
[0089] A decomposition unit 20 is configured to construct a time series in chronological order for each of the above historical arrival times and each of the above historical residence times corresponding to each of the above scenic spots, and decompose the time series to obtain a trend component, a seasonal component, and a residual component. The trend component includes the average value of each of the above historical arrival times corresponding to the above scenic spots and the average value of each of the above historical residence times. The seasonal component is used to represent the influence degree of weekends and holidays on the above historical arrival times and each of the above historical residence times. The residual component is the average difference between the above historical arrival times and the above historical residence times in common situations and the above historical arrival times and the above historical residence times corresponding to uncommon situations.
[0090] Specifically, by sorting out the historical arrival times and historical residence times of the sightseeing buses at each scenic spot in the target scenic area, a time series arranged in chronological order can be formed. Each sequence element in the time series includes the historical arrival time (specific year, month, day, and specific time point) and the residence time (time period). Using data decomposition technology, the time series is subdivided into three key parts: a trend component, a seasonal component, and a residual component. Among them, the trend component reveals the average value of each historical arrival time and the average value of each historical residence time. For the differences in residence times, mainly considering that in the case of large passenger flows or other situations, when the sightseeing bus arrives at the scenic spot, it can reach the full-load capacity and can directly depart, or it has not reached the specified passenger volume, and the driver chooses to wait at this scenic spot, which will result in different collected residence times. The seasonal component quantifies the impact of the tourist behavior patterns during weekends and holidays on the time series, while the residual component captures the average difference between the arrival times and residence times under atypical conditions (such as special weather conditions, emergencies, or abnormal passenger flows) and common situations.
[0091] A construction unit 30 is configured to establish a corresponding regression model based on the above trend component, the above seasonal component, the above residual component, and the above influence characteristics to form a time prediction model.
[0092] Specifically, the construction of the time prediction model involves using the trend component to capture the long-term trends of the residence times and arrival times of the sightseeing buses at each scenic spot; the seasonal component is used to quantify the influence of periodic changes such as weekends and holidays on the arrival times and residence times; the residual component focuses on the influence brought by atypical factors such as weather, passenger flow fluctuations, and emergencies. By comprehensively considering these components and influence characteristics, the time pattern of the operation of the sightseeing bus is comprehensively understood from different perspectives to construct a time prediction model to predict the arrival times and residence times of the sightseeing bus at each scenic spot.
[0093] A prediction unit 40, configured to input the standard arrival time, the standard stay time of the sightseeing vehicle at each of the above-mentioned sightseeing locations, and the current above-mentioned influencing features into the above-mentioned time prediction model, so as to obtain the actual arrival time and the actual stay time of each of the above-mentioned sightseeing vehicles at each of the above-mentioned sightseeing locations;
[0094] Specifically, the preset arrival time (i.e., the standard arrival time) and the standard stay time of the sightseeing vehicle at each sightseeing location in the target scenic area, together with the date attribute, weather condition, passenger flow status, unexpected events, etc. collected in real time (i.e., the current influencing features), are used as key input data and sent into the trained time prediction model. This model takes into account the actual arrival time and the actual stay time under the current environmental conditions based on deep learning. For example, inputting "standard arrival time 8:00 and standard stay time 5 minutes" as the standard arrival time and the standard stay time of the sightseeing vehicle at the scenic area entrance, the model will comprehensively analyze the real-time influencing features such as the current date attribute, passenger flow, weather, and unexpected events, and give the predicted actual arrival time of the sightseeing vehicle at each scenic spot. According to the input and the influencing features, the calculated predicted output may be "actual arrival time 8:10 and actual stay time 4 minutes".
[0095] A control unit 50, configured to push the above-mentioned actual arrival time and the above-mentioned actual stay time of each of the above-mentioned sightseeing vehicles at each of the above-mentioned sightseeing locations to the client of the target user.
[0096] Specifically, the actual arrival time and the actual stay time of the sightseeing vehicle at each sightseeing point in the scenic area are connected to the personal client devices of tourists through instant communication technology, such as smart phones or special information receiving software for the scenic area, etc. Ensure that each tourist can obtain time guidance customized for the current conditions, help them accurately master the actual arrival time of the sightseeing vehicle at each scenic spot and the expected stay duration, so as to optimize their personal tour rhythm, avoid ineffective waiting, and improve the travel efficiency and experience.
[0097] Through this embodiment, in the above-mentioned real-time query device for scenic area sightseeing vehicles, an acquisition unit is configured to acquire multiple sightseeing locations in a target scenic area, and acquire multiple historical arrival times, multiple historical stay times, and multiple influencing features of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations. The above-mentioned influencing features are influencing factors that affect the above-mentioned historical arrival time and the above-mentioned historical stay time; a decomposition unit is configured to construct time series for each of the above-mentioned historical arrival times and each of the above-mentioned historical stay times corresponding to each of the above-mentioned sightseeing locations in chronological order, and decompose the above-mentioned time series to obtain a trend component, a seasonal component, and a residual component. The above-mentioned trend component includes the average values of each of the above-mentioned historical arrival times and each of the above-mentioned historical stay times corresponding to the above-mentioned sightseeing locations. The above-mentioned seasonal component is used to represent the influence degree of weekends and holidays on the above-mentioned historical arrival time and each of the above-mentioned historical stay times. The above-mentioned residual component is the average difference between the above-mentioned historical arrival time and the above-mentioned historical stay time in common situations and the above-mentioned historical arrival time and the above-mentioned historical stay time in uncommon situations; a construction unit is configured to establish a corresponding regression model based on the above-mentioned trend component, the above-mentioned seasonal component, the above-mentioned residual component, and the above-mentioned influencing features to form a time prediction model; a prediction unit is configured to input the standard arrival time, the standard stay time of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations, and the current above-mentioned influencing features into the above-mentioned time prediction model to obtain the actual arrival time and the actual stay time of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations; a control unit is configured to push the above-mentioned actual arrival time and the above-mentioned actual stay time of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations to the client of the target user. Through this application, by acquiring multiple historical arrival times and multiple historical stay times of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations to construct a time series, and decomposing the time series to obtain a trend component, a seasonal component, and a residual component, and then establishing a time prediction model based on the trend component, the seasonal component, the residual component, and the acquired influencing features to predict the actual arrival time and the actual stay time of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations, and pushing the actual arrival time and the actual stay time of arriving at each sightseeing location to the client of the target user, it avoids the situation that users wait for a long time in the scenic area due to the uncertain arrival time and stay time of the sightseeing vehicle, and solves the problem of inaccurate prediction of the arrival time and stay time of scenic area sightseeing vehicles in the prior art.
[0098] In order to enable the influencing features to be used for constructing a time prediction model, in an alternative embodiment, after acquiring multiple historical arrival times, multiple historical stay times, and multiple influencing features of the sightseeing vehicle arriving at each of the above-mentioned sightseeing locations, the above-mentioned device further includes:
[0099] An encoding unit is configured to process each non-numerical above-mentioned influencing feature by using a numerical encoding method to obtain a numerical above-mentioned influencing feature.
[0100] Specifically, a numerical coding method is adopted to convert non-numerical influencing features into numerical forms recognizable by a computer. This conversion process is completed by assigning specific numerical values to each feature state. In the present invention, binary variables are used to process weekends and weekdays to obtain a weekend identifier. If the day is Saturday or Sunday, the identifier takes a value of 1, indicating a weekend; when the date is from Monday to Friday, the value is 0, indicating a weekday. Binary variables are used to process holidays to obtain a holiday identifier. If the day is a holiday, the value is 1, and if the day is not a holiday, the value is 0. Categorical variables are used to process the weather conditions to obtain a weather condition identifier. If the weather condition on the day is sunny, the value is 0; if the weather condition is cloudy, the value is 1; if the weather condition is rainy, the value is 2; if the weather condition is snowy, the value is 3. Ternary variables are used to process the passenger flow volume to obtain a passenger flow volume identifier. If the passenger flow volume on the day is low, the value is 0; if the passenger flow volume is medium, the value is 1; if the passenger flow volume is high, the value is 2. The specific passenger flow evaluation criteria are subject to the evaluation of the scenic area manager. Ternary variables are used to process emergencies to obtain an emergency identifier. If an emergency that attracts passengers occurs on the day, the value is 2; if an emergency that reduces passengers occurs on the day, the value is 1; if there is no emergency on the day, the value is 0.
[0101] In order to obtain a trend component, a seasonal component, and a residual component to construct a time prediction model, in an alternative embodiment, the above decomposition unit includes:
[0102] A first decomposition module for processing the above time series by using a moving average method to obtain the above trend component;
[0103] Specifically, the time series data of the historical arrival time and historical stay time of the sightseeing bus are smoothed to extract the trend component. The trend component represents the long-term trend gradually emerging over time in the time series data, which helps us understand the overall change direction of the sightseeing bus tour time.
[0104] A second decomposition module for calculating the average difference between the historical arrival times and historical stay times of holidays and the historical arrival times and historical stay times of non-holidays to obtain a holiday difference;
[0105] Specifically, by quantitatively calculating the mean differences in the historical arrival times and historical residence times of the sightseeing buses at each scenic spot during holidays and non-holiday periods, we can obtain the key indicator of holiday differences, which reflects the impact of holidays on the time pattern of the sightseeing buses. For example, by comparing the arrival times at the entrance A of a certain scenic area during the Spring Festival holiday and on weekdays, it is found that the average arrival time during the Spring Festival holiday is about 15 minutes longer than on weekdays, and the residence time also increases by 10 minutes accordingly. In this way, we convert the variation in the difference between holidays and non-holidays in the time series into specific numerical values, providing data support for subsequent model construction.
[0106] The third decomposition module is used to calculate the average differences between the above-mentioned historical arrival times and the above-mentioned historical residence times on weekends and the above-mentioned historical arrival times and the above-mentioned historical residence times on weekdays to obtain the weekend differences.
[0107] Specifically, by calculating the average differences in the historical arrival times and historical residence times between weekends and weekdays, the weekend differences can be accurately quantified, that is, the changes in the arrival times and residence times of the sightseeing buses at each scenic spot on weekends compared to weekdays. For example, we find that the average arrival time at the scenic spot B in the scenic area on weekends is 20 minutes later than on weekdays, and the residence time also increases by 15 minutes accordingly, which intuitively reflects the impact of the increased tourist flow and the changed tour rhythm on the time pattern of the sightseeing buses on weekends.
[0108] The fourth decomposition module is used to perform a weighted average on the above-mentioned holiday differences and the above-mentioned weekend differences to obtain the above-mentioned seasonal component.
[0109] Specifically, by assigning different weight coefficients to the holiday differences and the weekend differences respectively, the importance of these two differences is adjusted to more accurately capture their impact on the arrival times and residence times of the sightseeing buses.
[0110] The fifth decomposition module is used to calculate the average differences between the above-mentioned historical arrival times and the above-mentioned historical residence times under common difference factors and the above-mentioned historical arrival times and the above-mentioned historical residence times under uncommon difference factors to obtain the residual component. The above-mentioned common difference factors include that the weather condition is common weather, the passenger flow volume is within a predetermined range, and there are no unexpected events. The above-mentioned uncommon difference factors include that the above-mentioned weather condition is extreme weather, the above-mentioned passenger flow volume is not within the above-mentioned predetermined range, and there are the above-mentioned unexpected events.
[0111] Specifically, a comparative analysis strategy is adopted. By analyzing the historical data of the arrival and stay times of sightseeing vehicles under common difference factors and uncommon difference factors, residual components are extracted. The common difference factors cover relatively stable situations such as daily weather conditions (non-extreme weather), expected passenger flow, and no emergencies. In contrast, the uncommon difference factors include extreme weather events, unexpected surges or drops in passenger flow, and emergencies, etc., which are special situations that may cause fluctuations in time series data. By calculating the average differences in historical arrival times and stay times under the two difference factors, we can isolate the residual components, which contain abnormal changes beyond the normal pattern and provide information on the time changes of the sightseeing vehicle tour time in the face of extreme conditions for model establishment.
[0112] In order to construct a time prediction model, in an alternative implementation, a corresponding regression model is established based on the above-mentioned trend component, seasonal component, residual component, and influence characteristics to form a time prediction model. The above-mentioned construction unit includes:
[0113] The first construction module is used to construct a trend regression model T according to the above-mentioned trend component A,t =β0 + β1t + ∈ t1 , where T A,t is the above-mentioned trend component, β0 is the intercept of the above-mentioned trend regression model, β1 is the slope of the above-mentioned trend regression model, t is the above-mentioned standard arrival time and the above-mentioned standard stay time, and ∈ t1 is the first error term;
[0114] Specifically, the trend component obtained from the average values of each historical arrival time and each historical stay time, as well as the standard arrival time corresponding to the average value of each historical arrival time and the standard stay time corresponding to the average value of each historical stay time, are used to train the model to obtain the regression coefficients β0 and β1. For example, if the average value of each historical arrival time within a certain period of the calculated trend component is 8:10, the average value of each historical stay time is 15 minutes, the standard arrival time corresponding to this historical arrival time and this historical stay time is 8:00, and the standard stay time is 10 minutes, that is, the trend regression model is trained with the trend component, standard arrival time, and standard stay time to obtain the regression coefficients and the first error term.
[0115] The second construction module is used to construct a seasonal regression model S according to the above-mentioned seasonal component A,t =β2holiday t +β3weekend t +∈ t2 , where S A,tFor the above seasonal component, β2 is the influence degree of holidays on the above seasonal component, β3 is the influence degree of weekends on the above seasonal component, and holiday t is the holiday identifier, and weekend t is the weekend identifier, and ∈ t2 is the second error term. The above holiday identifier and the above weekend identifier are the above influence characteristics;
[0116] Specifically, taking the seasonal component S A,t as the dependent variable, and taking the holiday identifier and the weekend identifier as independent variables to train the seasonal regression model, obtaining the regression coefficients β2, β3 and the second error term.
[0117] The third construction module is used to construct a residual regression model R based on the above residual component A,t = β4thing t + β5weather t + β6traffic t + ∈ t3 , where R A,t is the above residual component, β4 is the influence degree of the above unexpected event on the above residual component, β5 is the influence degree of the above weather condition on the above residual component, β6 is the influence degree of the above passenger flow volume on the above residual component, thing t is the unexpected event identifier, weather t is the weather condition identifier, traffic t is the passenger flow volume identifier, and ∈ t3 is the third error term. The above unexpected event identifier, the above weather condition identifier and the above passenger flow volume identifier are the above influence characteristics;
[0118] Specifically, taking the residual component R A,t as the dependent variable, and taking the weather condition identifier, the passenger flow volume identifier and the unexpected event identifier as independent variables to train the seasonal regression model, obtaining the regression coefficients β4, β5, β6 and the third error term.
[0119] The fourth construction module is used to form the above time prediction model by combining the above trend regression model, the above seasonal regression model and the above residual regression model.
[0120] Specifically, combining the three models of the trend regression model, the seasonal regression model and the residual regression model into a comprehensive time prediction model y A,t = β0 + β1t + β2holiday t + β3weekend t + β4thing t + β5weather t+β6traffic t +∈ t , where y A,t is the actual arrival time and actual stay time of the sightseeing vehicle, and ∈ t is the sum of the first error term, the second error term, and the third error term. Since the actual impact characteristics of each scenic area are different, a corresponding regression model can also be established according to the impact characteristics of the actual situation of the scenic area to update the time prediction model.
[0121] To optimize the model, in an optional implementation, the above device further includes:
[0122] An optimization unit, configured to establish a connection between the above seasonal regression model and the above residual regression model to obtain an interaction term, and add the above interaction term to the above time prediction model for secondary training to obtain an optimized time prediction model, where the above interaction term is a parameter term calculated by combining the parameters in the above seasonal regression model and the parameters in the above residual regression model.
[0123] Specifically, the interaction term is intended to capture the combined impact of weather, passenger flow changes, and emergencies on the usage time of the sightseeing vehicle under weekend or holiday conditions. The addition of the interaction term enables the model to respond more sensitively to complex changes in the actual situation. For example, during holidays, the impact of the passenger flow size on the arrival time is different from that on non-holiday arrival times. That is, during holidays, it may cause a sharp increase in the passenger flow. Therefore, the model can also add interaction terms according to the actual situation to predict the arrival time and stay time under more complex impact characteristics. For example, on the basis of the time prediction model, add the interaction term β2holiday t *traffic t to form an optimized time prediction model. This interaction term expresses that during holidays, it may cause a sharp increase in the passenger flow, so it may lead to further time changes in the actual arrival time and stay time of the sightseeing vehicle. Other interaction terms can also be added according to the actual situation of the scenic area, such as the interaction term β3weekend t *traffic t between weekend and passenger flow size and the interaction term β3weekend t *weather t etc.
[0124] To enable the target user to view the actual arrival time and actual stay time of the sightseeing vehicle, in an optional implementation, push the above actual arrival time and the above actual stay time of each above sightseeing vehicle arriving at each above sightseeing location to the client of the target user. The above control unit includes:
[0125] The first control module is used to obtain the actual arrival time and the actual stay time of the sightseeing vehicle at each of the above-mentioned sightseeing locations, and obtain the time taken by the target user to reach each of the above-mentioned sightseeing locations;
[0126] The second control module is used to add the actual arrival time and the actual stay time of the sightseeing vehicle at each of the above-mentioned sightseeing locations to obtain the departure time;
[0127] The third control module is used to regard the sightseeing vehicle whose current time is less than the difference between the departure time and the time taken as the target sightseeing vehicle, and push the target sightseeing vehicle, the actual arrival time of the target sightseeing vehicle, and the actual stay time of the target sightseeing vehicle to the client of the target user.
[0128] Specifically, obtain and record the actual arrival time and the actual stay time of the sightseeing vehicle at each sightseeing location within the scenic area. At the same time, obtain the actual moving time, that is, the time taken, for the target user to reach each sightseeing point. Subsequently, by adding the actual arrival time and the actual stay time of each sightseeing location, we accurately calculate the total departure time of the sightseeing vehicle at each location, which is the exact time for the sightseeing vehicle to leave each scenic spot. By comparing the current time with the departure time and the difference from the actual moving time of the target user, we can identify the target sightseeing vehicle that can promptly respond to the needs of tourists and push the information of this sightseeing vehicle to the client of the user. This calculation process not only considers the travel time of the sightseeing vehicle itself but also fully takes into account the activity time of tourists, thereby providing accurate and reliable travel information for the path planning of the target user, enabling the target user to quickly find the most suitable sightseeing vehicle, avoiding long waits, and improving the sightseeing efficiency and experience.
[0129] The above-mentioned real-time query device for scenic area sightseeing vehicles includes a processor and a memory. The above-mentioned acquisition unit, decomposition unit, construction unit, prediction unit, control unit, etc. are all stored in the memory as program units, and the corresponding functions are implemented by the processor executing the above-mentioned program units stored in the memory. The above-mentioned modules are all located in the same processor; or, the above-mentioned each module is separately located in different processors in any combination form.
[0130] The processor contains a kernel, and the corresponding program unit is retrieved from the memory by the kernel. One or more kernels can be set, and the accuracy of predicting the arrival time and stay time of the scenic area sightseeing vehicle can be improved by adjusting the kernel parameters.
[0131] The memory may include non-permanent memory in a computer-readable medium, forms such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash memory (flash RAM), and the memory includes at least one storage chip.
[0132] An embodiment of the present invention provides a computer-readable storage medium. The computer-readable storage medium includes a stored program. When the program runs, it controls the device where the computer-readable storage medium is located to execute the above real-time query method for scenic area sightseeing vehicles.
[0133] Specifically, a real-time query method for scenic area sightseeing vehicles includes:
[0134] Step S201: Obtain multiple sightseeing locations in a target scenic area, and obtain multiple historical arrival times, multiple historical stay times, and multiple influencing features for the sightseeing vehicle to reach each of the above-mentioned sightseeing locations. The influencing features are the influencing factors that affect the above historical arrival time and the above historical stay time.
[0135] Step S202: Construct a time series for each of the above historical arrival times and each of the above historical stay times corresponding to each of the above sightseeing locations in chronological order, and decompose the time series to obtain a trend component, a seasonal component, and a residual component. The trend component includes the average value of each of the above historical arrival times corresponding to the sightseeing location and the average value of each of the above historical stay times. The seasonal component is used to represent the influence degree of weekends and holidays on the above historical arrival time and each of the above historical stay times. The residual component is the average difference between the above historical arrival time and the above historical stay time in common situations and the above historical arrival time and the above historical stay time in uncommon situations.
[0136] Step S203: Establish a corresponding regression model based on the above trend component, the above seasonal component, the above residual component, and the above influencing features to form a time prediction model.
[0137] Step S204: Input the standard arrival time, standard stay time, and current above influencing features of the sightseeing vehicle to reach each of the above sightseeing locations into the above time prediction model to obtain the actual arrival time and actual stay time of the sightseeing vehicle to reach each of the above sightseeing locations.
[0138] Step S205: Push the above actual arrival time and the above actual stay time of the sightseeing vehicle to reach each of the above sightseeing locations to the client of the target user.
[0139] An embodiment of the present invention provides a processor. The processor is used to run a program. When the program runs, it executes the above real-time query method for scenic area sightseeing vehicles.
[0140] Specifically, a real-time query method for scenic area sightseeing vehicles includes:
[0141] Step S201, obtain multiple sightseeing locations of the target scenic area, and obtain multiple historical arrival times, multiple historical stay times, and multiple influencing features for the sightseeing vehicle to reach each of the above-mentioned sightseeing locations. The above-mentioned influencing features are the influencing factors for the above-mentioned historical arrival time and the above-mentioned historical stay time;
[0142] Step S202, construct a time series for each of the above-mentioned historical arrival times and each of the above-mentioned historical stay times corresponding to each of the above-mentioned sightseeing locations in chronological order, and decompose the above-mentioned time series to obtain a trend component, a seasonal component, and a residual component. The above-mentioned trend component includes the average value of each of the above-mentioned historical arrival times corresponding to the above-mentioned sightseeing locations and the average value of each of the above-mentioned historical stay times. The above-mentioned seasonal component is used to represent the influence degree of weekends and holidays on the above-mentioned historical arrival time and each of the above-mentioned historical stay times. The above-mentioned residual component is the average difference between the above-mentioned historical arrival time and the above-mentioned historical stay time in common situations and the above-mentioned historical arrival time and the above-mentioned historical stay time corresponding to uncommon situations;
[0143] Step S203, establish a corresponding regression model based on the above-mentioned trend component, the above-mentioned seasonal component, the above-mentioned residual component, and the above-mentioned influencing features to form a time prediction model;
[0144] Step S204, input the standard arrival time, the standard stay time, and the current above-mentioned influencing features for the sightseeing vehicle to reach each of the above-mentioned sightseeing locations into the above-mentioned time prediction model to obtain the actual arrival time and the actual stay time for the sightseeing vehicle to reach each of the above-mentioned sightseeing locations;
[0145] Step S205, push the above-mentioned actual arrival time and the above-mentioned actual stay time for the sightseeing vehicle to reach each of the above-mentioned sightseeing locations to the client of the target user.
[0146] This application also provides a computer program product, which when executed on a data processing device, is adapted to execute a program initialized with at least the following method steps:
[0147] Step S201, obtain multiple sightseeing locations of the target scenic area, and obtain multiple historical arrival times, multiple historical stay times, and multiple influencing features for the sightseeing vehicle to reach each of the above-mentioned sightseeing locations. The above-mentioned influencing features are the influencing factors for the above-mentioned historical arrival time and the above-mentioned historical stay time;
[0148] Step S202: Construct a time series by arranging the above-mentioned historical arrival times and historical residence times corresponding to each of the above-mentioned scenic spots in chronological order, and decompose the time series to obtain a trend component, a seasonal component, and a residual component. The trend component includes the average values of the above-mentioned historical arrival times and the average values of the above-mentioned historical residence times corresponding to the above-mentioned scenic spots. The seasonal component is used to represent the influence degree of weekends and holidays on the above-mentioned historical arrival times and the above-mentioned historical residence times. The residual component is the average difference between the above-mentioned historical arrival times and the above-mentioned historical residence times in common situations and those in uncommon situations.
[0149] Step S203: Establish a corresponding regression model based on the above-mentioned trend component, the above-mentioned seasonal component, the above-mentioned residual component, and the above-mentioned influence characteristics to form a time prediction model.
[0150] Step S204: Input the standard arrival times, standard residence times of the sightseeing vehicles arriving at each of the above-mentioned scenic spots, and the current above-mentioned influence characteristics into the above-mentioned time prediction model to obtain the actual arrival times and actual residence times of the sightseeing vehicles arriving at each of the above-mentioned scenic spots.
[0151] Step S205: Push the above-mentioned actual arrival times and actual residence times of the sightseeing vehicles arriving at each of the above-mentioned scenic spots to the client of the target user.
[0152] The embodiment of the present application also provides a real-time query system for scenic area sightseeing vehicles, including: one or more processors, a memory, and one or more programs. Among them, the above-mentioned one or more programs are stored in the above-mentioned memory and are configured to be executed by the above-mentioned one or more processors, including executing any one of the above-mentioned methods in the above-mentioned real-time query method for scenic area sightseeing vehicles.
[0153] Specifically, a real-time query method for scenic area sightseeing vehicles includes:
[0154] Step S201: Obtain multiple scenic spots in the target scenic area, and obtain multiple historical arrival times, multiple historical residence times, and multiple influence characteristics of the sightseeing vehicles arriving at each of the above-mentioned scenic spots. The above-mentioned influence characteristics are the influencing factors that affect the above-mentioned historical arrival times and the above-mentioned historical residence times.
[0155] Step S202: Construct a time series for each of the above historical arrival times and each of the above historical stay times corresponding to each of the above sightseeing locations in chronological order, and decompose the above time series to obtain a trend component, a seasonal component, and a residual component. The above trend component includes the average value of each of the above historical arrival times corresponding to the above sightseeing locations and the average value of each of the above historical stay times. The above seasonal component is used to represent the influence degree of weekends and holidays on the above historical arrival times and each of the above historical stay times. The above residual component is the average difference between the above historical arrival times and the above historical stay times in common situations and the above historical arrival times and the above historical stay times corresponding to uncommon situations.
[0156] Step S203: Establish a corresponding regression model based on the above trend component, the above seasonal component, the above residual component, and the above influence characteristics to form a time prediction model.
[0157] Step S204: Input the standard arrival time, the standard stay time of the above sightseeing vehicles arriving at each of the above sightseeing locations, and the current above influence characteristics into the above time prediction model to obtain the actual arrival time and the actual stay time of each of the above sightseeing vehicles arriving at each of the above sightseeing locations.
[0158] Step S205: Push the above actual arrival time and the above actual stay time of each of the above sightseeing vehicles arriving at each of the above sightseeing locations to the client of the target user.
[0159] Obviously, those skilled in the art should understand that the above modules or steps of the present invention can be implemented by a general-purpose computing device. They can be concentrated on a single computing device or distributed on a network composed of multiple computing devices. They can be implemented by program codes executable by the computing device. Thus, they can be stored in a storage device and executed by the computing device. And in some cases, the steps shown or described can be executed in a different order than here, or they can be separately made into individual integrated circuit modules, or multiple of them can be made into a single integrated circuit module to implement. In this way, the present invention is not limited to any specific combination of hardware and software.
[0160] Those skilled in the art should understand that the embodiments of the present application can be provided as a method, a system, or a computer program product. Therefore, the present application can adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present application can adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.
[0161] This application is described with reference to the flowcharts and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It should be understood that each flow and / or block in the flowchart and / or block diagram, and combinations of flows and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to the processors of general-purpose computers, special-purpose computers, embedded processors, or other programmable data processing devices to generate a machine, such that the instructions executed by the processors of the computer or other programmable data processing devices produce means for implementing the functions specified in the Figure 1 one or more flows and / or blocks Figure 1 one or more blocks.
[0162] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, such that the instructions stored in the computer-readable memory produce a manufacture including instruction means that implement the functions specified in the Figure 1 one or more flows and / or blocks Figure 1 one or more blocks.
[0163] These computer program instructions can also be loaded onto a computer or other programmable data processing device, such that a series of operational steps are performed on the computer or other programmable device to generate a computer-implemented process, and thus the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in the Figure 1 one or more flows and / or blocks Figure 1 one or more blocks.
[0164] In a typical configuration, a computing device includes one or more processors (CPUs), an input / output interface, a network interface, and memory.
[0165] The memory may include non-permanent memory in the form of computer-readable media, random access memory (RAM), and / or non-volatile memory such as read-only memory (ROM) or flash memory. The memory is an example of computer-readable media.
[0166] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.
[0167] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.
[0168] From the above description, it can be seen that the above embodiments of the present application achieve the following technical effects:
[0169] 1) The present application provides a real-time query method for sightseeing buses in a scenic area. A time series is constructed by acquiring multiple historical arrival times and multiple historical stay times of the sightseeing buses at the above-mentioned tourist spots, and the time series is decomposed to obtain trend components, seasonal components and residual components. A time prediction model is then established based on the trend components, seasonal components and residual components as well as the acquired influencing features to predict the actual arrival time and actual stay time of the sightseeing buses at the above-mentioned tourist spots, and the actual arrival time and actual stay time at each tourist spot are pushed to the client of the target user, thereby avoiding the users from waiting for a long time in the scenic area due to the uncertainty of the arrival time and stay time of the sightseeing buses when visiting the scenic area, and solving the problem of inaccurate prediction of the arrival time and stay time of the sightseeing buses in the prior art.
[0170] 2) A real-time query device for sightseeing buses in a scenic area according to the present application constructs a time series by acquiring multiple historical arrival times and multiple historical stay times of the sightseeing buses at the above-mentioned tourist spots, and decomposes the time series to obtain trend components, seasonal components and residual components. Then, a time prediction model is established based on the trend components, seasonal components and residual components as well as the acquired influencing features to predict the actual arrival time and actual stay time of the sightseeing buses at the above-mentioned tourist spots, and the actual arrival time and actual stay time at each tourist spot are pushed to the client of the target user, thereby avoiding the users from waiting for a long time in the scenic area due to the uncertainty of the arrival time and stay time of the sightseeing buses when visiting the scenic area, and solving the problem of inaccurate prediction of the arrival time and stay time of the sightseeing buses in the prior art.
[0171] The above description is only the preferred embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the present application may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.
Claims
1. A method for real-time query of sightseeing vehicles in a scenic area, characterized in that: include: Acquire multiple sightseeing spots in the target scenic area, and acquire multiple historical arrival times, multiple historical stay times, and multiple influencing features of sightseeing vehicles arriving at each of the sightseeing spots, wherein the influencing features are influencing factors that affect the historical arrival times and the historical stay times; Constructing a time series according to the chronological order of the historical arrival times and the historical stay times corresponding to the tourist spots, and decomposing the time series to obtain a trend component, a seasonal component and a residual component, wherein the trend component includes the average value of the historical arrival times and the average value of the historical stay times corresponding to the tourist spots, the seasonal component is used to indicate the degree of influence of weekends and holidays on the historical arrival times and the historical stay times, and the residual component is the average difference between the historical arrival time and the historical stay time under common circumstances and the historical arrival time and the historical stay time corresponding to uncommon circumstances; Establishing a corresponding regression model according to the trend component, the seasonal component, the residual component and the influencing feature to form a time prediction model; Inputting the standard arrival time, standard stay time and current influencing features of the sightseeing vehicles at each sightseeing spot into the time prediction model to obtain the actual arrival time and actual stay time of each sightseeing vehicle at each sightseeing spot; The actual arrival time and the actual stay time of each sightseeing vehicle at each sightseeing spot are pushed to the client of the target user.
2. The method according to claim 1, characterized in that After obtaining a plurality of historical arrival times, a plurality of historical stay times and a plurality of influencing features of the sightseeing vehicles arriving at the sightseeing spots, the method further comprises: A numerical coding method is used to process each non-numerical influencing feature to obtain a numerical influencing feature.
3. The method according to claim 1, characterized in that Decompose the time series to obtain trend components, seasonal components and residual components, including: Processing the time series by using a moving average method to obtain the trend component; Calculate the average difference between each of the historical arrival times and each of the historical stay times on holidays and each of the historical arrival times and each of the historical stay times on non-holidays to obtain a holiday difference; Calculate the average difference between the historical arrival time and the historical stay time on weekends and the historical arrival time and the historical stay time on weekdays to obtain the weekend difference; The seasonal component is obtained by performing weighted averaging on the holiday difference and the weekend difference; The average differences between the historical arrival times and the historical stay times under common difference factors and the historical arrival times and the historical stay times under uncommon difference factors are calculated to obtain residual components. The common difference factors include that the weather condition is common weather, the passenger flow size is within a predetermined range, and there are no emergencies; the uncommon difference factors include that the weather condition is extreme weather, the passenger flow size is not within the predetermined range, and there are emergencies.
4. The method according to claim 3, characterized in that A corresponding regression model is established according to the trend component, the seasonal component, the residual component and the influencing feature to form a time prediction model, including: Construct a trend regression model T based on the trend components A,t =β0+β1t+∈ t1 , where T A,t is the trend component, β0 is the intercept of the trend regression model, β1 is the slope of the trend regression model, t is the standard arrival time and the standard stay time, ∈ t1 is the first error term; Construct a seasonal regression model S based on the seasonal components A,t =β2holiday t +β3weekend t +∈ t2 , where S A,t is the seasonal component, β2 is the impact of holidays on the seasonal component, β3 is the impact of weekends on the seasonal component, t For holiday marking, weekend t is the weekend mark, ∈ t is the second error term, and the holiday identifier and the weekend identifier are the influencing features; Construct a residual regression model R based on the residual components A,t =β4thing t +β5weather t +β6traffic t +∈ t3 , where R A,t is the residual component, β4 is the impact of the emergency on the residual component, β5 is the impact of the weather conditions on the residual component, β6 is the impact of the passenger flow on the residual component, and t is the emergency event identifier, weather t Weather conditions, traffic t is the passenger flow size identifier, ∈ t3 is the third error term, and the emergency event identifier, the weather condition identifier and the passenger flow size identifier are the influencing features; The trend regression model, the seasonal regression model and the residual regression model are combined into the time prediction model.
5. The method according to claim 4, characterized in that The method further comprises: A connection is established between the seasonal regression model and the residual regression model to obtain an interaction term, and the interaction term is added to the time prediction model for secondary training to obtain an optimized time prediction model, wherein the interaction term is a parameter term calculated by combining the parameters in the seasonal regression model with the parameters in the residual regression model.
6. The method according to claim 1, characterized in that Pushing the actual arrival time and the actual stay time of each sightseeing vehicle at each sightseeing spot to the client of the target user includes: Acquire the actual arrival time and the actual stay time of the sightseeing bus at each sightseeing spot, and acquire the time taken by the target user to arrive at each sightseeing spot; Adding the actual arrival time and the actual stay time of the sightseeing bus at each of the sightseeing spots to obtain the departure time; The sightseeing bus whose current time is less than the difference between the departure time and the consuming time is taken as the target sightseeing bus, and the target sightseeing bus, the actual arrival time of the target sightseeing bus and the actual stay time of the target sightseeing bus are pushed to the client of the target user.
7. A real-time query device for sightseeing vehicles in a scenic area, characterized in that: include: An acquisition unit is used to acquire multiple sightseeing spots in a target scenic area, and acquire multiple historical arrival times, multiple historical stay times, and multiple influencing features of sightseeing vehicles arriving at each of the sightseeing spots, wherein the influencing features are influencing factors that affect the historical arrival times and the historical stay times; a decomposition unit, for constructing a time series according to the chronological order of the historical arrival times and the historical stay times corresponding to the tourist spots, and decomposing the time series to obtain a trend component, a seasonal component and a residual component, wherein the trend component includes an average value of the historical arrival times corresponding to the tourist spots and an average value of each historical stay time, the seasonal component is used to indicate the degree of influence of weekends and holidays on the historical arrival times and each historical stay time, and the residual component is an average difference between the historical arrival time and the historical stay time under common circumstances and the historical arrival time and the historical stay time corresponding to uncommon circumstances; A construction unit, used to establish a corresponding regression model according to the trend component, the seasonal component, the residual component and the influencing feature to form a time prediction model; A prediction unit, used for inputting the standard arrival time, standard stay time and current influencing features of the sightseeing vehicles at each sightseeing spot into the time prediction model to obtain the actual arrival time and actual stay time of each sightseeing vehicle at each sightseeing spot; The control unit is used to push the actual arrival time and the actual stay time of each sightseeing vehicle at each sightseeing spot to the client of the target user.
8. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored program, wherein when the program is executed, the device where the computer-readable storage medium is located is controlled to execute the method according to any one of claims 1 to 6.
9. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.
10. A real-time query system for sightseeing buses in scenic spots, characterized in that: include: One or more processors, a memory, and one or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by the one or more processors, and the one or more programs include methods for executing any one of claims 1 to 6.