Method and device for predicting walking track of tourist through WiFi signal
By setting up Wi-Fi probes in the scenic area, collecting and analyzing MAC data protocols, combining historical data and naive Bayes algorithms to predict tourists' walking trajectories, the problems of inaccurate calculations and privacy and security concerns in the existing technology are solved, and accurate prediction of tourist trajectories and scientific distribution of tourist flows in scenic areas are achieved.
Patent Information
- Application Number
- CN202411773093.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-04
- Publication Date
- 2025-04-11
AI Technical Summary
The prior art is affected by the camera installation location and recognition accuracy when calculating the tourist trajectory, resulting in inaccurate calculations, and tourists' concerns about privacy and security increase, and camera collection methods are not accepted.
By setting up Wi-Fi probes in the scenic area, collecting and analyzing MAC data protocols, calculating Wi-Fi signal attenuation, and calculating the time and residence time of tourists entering and leaving the scenic spots in real time. Combining historical data and naive Bayes algorithms, tourists’ walking trajectory is predicted.
Accurate prediction of tourists' walking trajectories is achieved, the intrusion of privacy is reduced, the scientific nature of the distribution of passenger flow in scenic spots is improved, and real-time, asynchronous and scalable prediction and analysis capabilities are provided.
Smart Images

Figure CN119815277A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a method for predicting a tourist's walking trajectory through WiFi signals. Background Art
[0002] In recent years, the contradiction between the growing tourism demand and the scarcity of tourism resources has gradually become prominent, and crowded tourist attractions have become a normal phenomenon. Taking the trajectory data of tourists as the data source, counting the passenger flow of each scenic spot, and making reasonable transformation suggestions based on the differences, improving the distribution structure of the passenger flow of scenic spots, further increasing the total passenger flow of scenic spots, promoting the development of scenic spots, and enhancing the overall core competitiveness of scenic spots have become the top priority of each scenic spot and the need for differentiated competition.
[0003] Currently, tourist trajectory calculation generally uses cameras for facial recognition and then calculates the entry and exit of tourists between different cameras. However, this calculation method is affected by the installation location of the camera and the camera's accuracy in recognizing some objects, resulting in inaccurate calculation of tourist trajectories and inability to accurately count the passenger flow in the scenic spot. Coupled with the increasing concern of tourists about privacy and security issues, the camera collection method is gradually not accepted by tourists. Summary of the invention
[0004] This application shows a method for predicting tourists' walking trajectories through WiFi signals.
[0005] In a first aspect, the present application shows a method for predicting a tourist's walking trajectory through WiFi signals, the method comprising:
[0006] Collect MAC data from Wi-Fi probes installed at different scenic spots in the scenic area;
[0007] Parsing the MAC data protocol collected by the Wi-Fi probe, wherein the MAC data protocol parsing includes frame data parsing and frame payload parsing;
[0008] Based on the calculation of Wi-Fi signal attenuation, the entry and exit time and residence time of tourists in and out of different attractions are calculated in real time;
[0009] Calculate the walking trajectory of tourists according to the order of entering and exiting the Wi-Fi probes;
[0010] Performing matrix data processing on the walking trajectory data;
[0011] Perform tourist movement line prediction analysis based on the tourist trajectory matrix data after the data processing;
[0012] The tourists' trajectory prediction data is obtained from the historical terminal data set through a highly personalized naive Bayes algorithm to predict the walking trajectory of tourists in the scenic area.
[0013] According to the method of the first aspect of the present application, the calculation formula for trajectory prediction is as follows:
[0014] P(A|B)=P(B|A)P(A) / P(B)
[0015] Where P(A) is the prior probability, P(B|A) is the likelihood, and P(B) is the normalization constant.
[0016] According to the method of the first aspect of the present application, the frame data parsing includes analyzing the frame header part, obtaining the instruction type, and analyzing the instruction; the frame payload parsing includes analyzing the device number, terminal MAC, collection time, RSSI, hotspot SSID, hotspot MAC, longitude and latitude coordinates and location number.
[0017] According to the method of the first aspect of the present application, the real-time calculation of the entry and exit time and residence time of tourists entering and exiting different attractions includes terminal association analysis between each Wi-Fi probe, stay time analysis and stay time impact analysis between each terminal.
[0018] According to the method of the first aspect of the present application, the indicators of the terminal association analysis include device number, MAC address and entry time, and the device number is the unique identification code of the Wi-Fi probe.
[0019] According to the method of the first aspect of the present application, the walking trajectory of tourists is calculated by arranging the entry time of each Wi-Fi probe node in the associated data set of the terminal MAC in ascending order, and then finding the time when different Wi-Fi probe nodes appear, and using this time as the departure time of the previous node to obtain the trajectory route of the terminal MAC.
[0020] According to the method of the first aspect of the present application, the obtained trajectory line data of each terminal MAC are aggregated to obtain trajectory line matrices of different orders, and each matrix reflects the user data of various trajectories through the size of the circle in which it is located.
[0021] On the second aspect, the present application shows a device for predicting the walking trajectory of tourists through WiFi signals, characterized in that it includes a Wi-Fi probe attenuation data analysis unit, a real-time time difference calculation unit, a trajectory calculation unit and a predicted trajectory unit, the Wi-Fi probe attenuation data analysis unit includes data protocol analysis to form a data model, the real-time time difference calculation unit includes the time trend of the distance change between the terminal and the Wi-Fi probe, the trajectory calculation unit includes an entry and exit time difference matrix for a single Mac terminal and multiple Wi-Fi probes to obtain the relative trajectory of the terminal, and the predicted trajectory unit includes the trajectory prediction data of tourists obtained by using a naive Bayes correction algorithm from a historical terminal data set.
[0022] In a third aspect, the present application shows an electronic device, which includes: a processor; a memory for storing processor-executable instructions; wherein the processor is configured to execute the method described in the first aspect above.
[0023] In a fourth aspect, the present application shows a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the method described in the first aspect above is implemented.
[0024] The technical solution provided by this application may have the following beneficial effects:
[0025] This application uses a mobile terminal based on Wi-Fi probes to identify users. Thanks to the current penetration rate of mobile phones, the relative position of the terminal user to the Wi-Fi is obtained through the attenuation of the Wi-Fi signal and a detection-type calculation formula. By setting up Wi-Fi probes in multiple scenic spots, the terminal can be seamlessly switched, and the length of time the terminal user stays in each scenic spot and the entry and exit time at each scenic spot node can be effectively obtained, thereby obtaining the route trajectory of the tourists' walking. Based on historical data such as the tourists' walking trajectory route data set, the naive Bayes formula algorithm allows the addition of various factor data (weather, holidays, temperature, etc.) to predict the subsequent tourists' walking trajectory routes, thereby providing predictive data support for the reasonable distribution of tourists in the scenic area and emergency response. At the same time, the method of this application has a low degree of coupling with the environment, and the user is not aware of it. The predictive analysis and calculation tasks are also real-time, asynchronous, and scalable. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] Figure 1 This is a flowchart of the steps of a method for predicting tourists' walking trajectories through WiFi signals in the present application.
[0027] Figure 2 This is a schematic diagram of the structure of a device for predicting tourists' walking trajectories through WiFi signals in the present application.
[0028] Figure 3 This is the terminal data model diagram of this application.
[0029] Figure 4 This is the walking timing diagram of the terminal MAC of this application.
[0030] Figure 5 It is a schematic diagram of the physical trajectory of this application.
[0031] Figure 6 This is a schematic diagram of the trajectory route collection of this application.
[0032] Figure 7 It is a block diagram of an electronic device of the present application.
[0033] Figure 8 It is a block diagram of a computer-readable storage medium of the present application. DETAILED DESCRIPTION
[0034] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0035] Before introducing the method for predicting tourists' walking trajectories through WiFi signals provided by this application, the professional terms involved in this application are first explained.
[0036] A Wi-Fi probe is a hardware device based on Wi-Fi detection technology. It can automatically identify mobile terminal devices (such as Android or iOS smartphones, laptops, tablets, etc.) with Wi-Fi receiving devices turned on within a specific range and obtain the MAC (Media Access Control) information of these devices.
[0037] The working principle of Wi-Fi probe is based on the IEEE802.11 protocol set, which defines two working modes of wireless access point (AP) and station (STA, i.e. client), as well as multiple types of wireless data frames. When a Wi-Fi device is within the listening range of a Wi-Fi probe, any frame information sent by a terminal, router or other Wi-Fi device may be intercepted by the probe. The probe obtains the required information by analyzing the MAC layer and physical layer information of these frames, such as the MAC address of the sending and receiving devices, frame type, signal strength, etc.
[0038] Reference Figure 1, shows a flowchart of a method for predicting a tourist's walking trajectory through WiFi signals of the present application, which can be applied to an electronic device, wherein the method specifically may include the following steps:
[0039] In step S101, MAC data of Wi-Fi probes installed at different scenic spots in the scenic area are collected;
[0040] In step S102, the MAC data protocol collected by the Wi-Fi probe is parsed, and the MAC data protocol parsing includes frame data parsing and frame payload parsing;
[0041] The frame data parsing includes analyzing the frame header part, obtaining the instruction type, and analyzing the instruction. The frame payload parsing includes analyzing the device number, terminal MAC, collection time, RSSI, hotspot SSID, hotspot MAC, longitude and latitude coordinates, and venue number.
[0042] Among them, RSSI (Received Signal Strength Indicator) is an indicator to measure the strength of wireless signals. It is usually expressed as the ratio of the received wireless signal power to the noise power, or simply expressed as the received signal power. The RSSI value is usually expressed in decibel milliwatts (dBm). The higher the value, the stronger the received signal.
[0043] In wireless communication systems, RSSI is used to evaluate the quality of the communication link. If the RSSI value is very low, it may mean that the signal is interfered or the distance between the transmitter and the receiver is too far, which may lead to a decrease in communication quality or interruption of communication.
[0044] Among them, the hotspot SSID refers to the name of the wireless network, also known as the network name or SSID (Service Set Identifier). It is an alphanumeric string of up to 32 characters that is used to identify a specific wireless network. The SSID is broadcast by the wireless access point (AP) so that wireless devices can identify and connect to the network.
[0045] When configuring a wireless network, administrators typically set an SSID for the network. Wireless devices (such as laptops, smartphones, etc.) then display these SSIDs when searching for available wireless networks, and users can select the network they want to connect to.
[0046] In step S103, based on the calculation of Wi-Fi signal attenuation, the entry and exit time and residence time of tourists entering and exiting different scenic spots are calculated in real time;
[0047] The real-time calculation of the entry and exit time and residence time of tourists entering and exiting different scenic spots includes terminal association analysis between each Wi-Fi probe, residence time analysis and analysis of the influence of residence time between each terminal. The indicators of the terminal association analysis include device number, MAC address and entry time. The device number is the unique identification code of the Wi-Fi probe.
[0048] In step S104, the walking trajectory of the tourists is calculated according to the order in which the tourists enter and exit between the Wi-Fi probes;
[0049] In step S105, matrix data processing is performed on the walking trajectory data;
[0050] In step S106, a tourist movement line prediction analysis is performed based on the tourist trajectory matrix data after the data processing;
[0051] The calculation of the tourist walking trajectory is carried out by arranging the entry time of each Wi-Fi probe node in the associated data set of the terminal MAC in ascending order, then finding the time when different Wi-Fi probe nodes appear, and using this time as the departure time of the previous node to obtain the trajectory route of the terminal MAC.
[0052] like Figure 4 and Figure 5 As shown, according to the walking sequence diagram and physical trajectory of the terminal MAC obtained in the above step S104, according to the scenic spot labels corresponding to each Wi-Fi node, the visiting order of the terminal MAC between the scenic spots and the length of stay at each scenic spot are dynamically drawn to analyze different points in the tourist's travel process;
[0053] like Figure 6 As shown, the trajectory line data of each terminal MAC obtained in the above steps S105 and S106 are aggregated, and trajectory line matrices of different orders are obtained. At the same time, each matrix will also reflect the user data of various trajectories through the size of the circle in which it is located.
[0054] In step S107, the tourists' trajectory prediction data is obtained from the historical terminal data set through a highly personalized naive Bayes algorithm to predict the walking trajectory of tourists in the scenic area.
[0055] The following is a specific example to illustrate the method provided by this application for predicting tourists' walking trajectories through WiFi signals.
[0056] The trajectory route matrix in this application lists the order of visits and the duration of stay of five tourists.
[0057] Tourist 1's tour sequence is 1-2-3-4-5-6, and he visits all 6 scenic spots in the scenic area. The tour duration of the above 6 scenic spots is basically the same;
[0058] Tourist 2's tour order is 2-4-5-6, and he only visits 4 scenic spots in the scenic area. The tour duration of scenic spots 2 and 4 is basically the same, which is longer than that of scenic spots 5 and 6.
[0059] Tourist 3's tour order is 1-4-5-6, and he only visits 4 scenic spots in the scenic area. The tour duration of scenic spots 1 and 4 is basically the same, which is longer than the tour duration of scenic spots 5 and 6.
[0060] Tourist 4's tour order is 1-3-4-5-6, and he only visits 5 scenic spots in the scenic area. The tour duration of the above 5 scenic spots is basically the same;
[0061] Tourist 5's tour order is 1-5-6, and he only visits 3 scenic spots in the scenic area. The tour duration of the above 3 scenic spots is basically the same;
[0062] It can be seen that each tourist has different visiting order and duration of stay at different attractions. By calculating the walking trajectories of tourists and then using the naive Bayes formula algorithm, various factor data (weather, holidays, temperature, etc.) can be added to predict the subsequent walking trajectory routes of tourists, thereby providing predictive data support for the reasonable distribution of tourist volume in scenic spots and emergency response.
[0063] The trajectory prediction unit of this application includes obtaining the tourist's trajectory prediction data from the historical terminal data set through a highly personalized naive Bayes algorithm, as described below:
[0064] The prior probability is calculated through the historical trajectory data expression;
[0065] Use Bayes' formula to convert into posterior probability.
[0066] The training samples are shown in Table 1:
[0067] Table 1
[0068] Sample No. weather Is it a holiday? Trajectory 1 1 0 12 2 1 0 12 3 2 1 12 4 2 0 23 5 1 0 13 6 1 1 13 7 1 0 12 8 2 0 12 9 2 1 12 10 1 0 12
[0069] The weather is clear = 1, cloudy = 2, rainy = 3; whether it is a holiday (1 = holiday, 0 = non-holiday). Later, it can be expanded according to other parameters to form a customized sample, such as adding temperature, humidity parameters, etc. The more references, the greater the accuracy.
[0070] The formula used is as follows:
[0071] P(A|B)=P(B|A)P(A) / P(B)
[0072] P(A) is the prior probability, that is, the probability of the global trajectory being 12. Among N tourists, there are several tourists whose trajectory is 12, and the probability is 7 / 10.
[0073] P(B|A) is the likelihood, which indicates the number of tourists in trajectory 12 whose weather is "1" and whether it is a holiday is "0", and its probability is 4 / 10.
[0074] P(B) is a standardized constant, which is the probability of the weather being "1" and whether it is a holiday being "0". In Table 1, it occurs 5 times among 10 tourists, that is, the probability is 5 / 10.
[0075] P(A|B) can be substituted into the solution and we get 14 / 25, which is about 0.56, or 56%.
[0076] Through the above Bayesian calculation, we can get a trend graph of tourist trajectories under certain conditions (weather + holidays), and then substitute the real-time tourist trajectories into the model for calculation to get the prediction of the tourist's next trajectory, which is 12 or 23 or 13.
[0077] The method and trajectory of calculating the length of time tourists stay between scenic spots by using the Wi-Fi signal attenuation method of the present application aims to obtain the terminal route trajectory by calculating the time difference between terminal entry and exit, and at the same time use the naive Bayes formula to predict the trajectory route of tourists based on historical data, so as to better support the subsequent terminal data tracking, terminal label marking, scenic spot tourist emergency diversion and other data management processes.
[0078] The present application designs a real-time calculation through Wi-Fi signal attenuation, uses an algorithm to calculate the residence time of tourists between multiple nodes and the entry and exit time between multiple nodes, and then obtains the walking trajectory of tourists according to the order of tourists entering and exiting each device; performs matrix data processing on the tourist trajectory data; performs tourist movement line prediction and analysis based on the tourist trajectory matrix data after data processing, and then predicts and analyzes the current tourist trajectory through historical trajectory data, providing effective data support for subsequent data analysis, etc.
[0079] Reference Figure 2, shows a device for predicting tourists' walking trajectories through WiFi signals of the present application, including a Wi-Fi probe attenuation data parsing unit, a real-time time difference calculation unit, a trajectory calculation unit and a predicted trajectory unit, wherein the Wi-Fi probe attenuation data parsing unit includes data protocol parsing to form a data model, the real-time time difference calculation unit includes a time trend of distance change between a terminal and a Wi-Fi probe, the trajectory calculation unit includes an entry and exit time difference matrix for a single Mac terminal and multiple Wi-Fi probes to obtain a relative trajectory of the terminal, and the predicted trajectory unit includes obtaining tourists' trajectory prediction data based on a naive Bayes correction algorithm from a historical terminal data set.
[0080] The Wi-Fi probe attenuation data parsing unit of the present application includes MAC data protocol parsing, and the parsing of data frame data and frame payload. The MAC data protocol defines how data is sent and received between nodes, ensuring that multiple devices can fairly obtain bandwidth when sharing a transmission medium, avoiding conflicts and collisions, thereby controlling data access and improving the efficiency and reliability of data transmission.
[0081] The specific instructions for the Wi-Fi probe attenuation data analysis unit are as follows:
[0082] The processing flow of this unit includes parsing the MAC data protocol collected by the Wi-Fi probe. After the server collects the data from the Wi-Fi probe, it undergoes parsing, processing, and storage.
[0083] The frame data parsing includes analyzing the frame header part, obtaining the instruction type, and analyzing the instruction, if it is a data instruction type.
[0084] The frame payload parsing work includes parsing the frame payload part, which is 190 bytes in total, from which the device number, terminal MAC, collection time, RSSI, hotspot SSID, hotspot MAC, latitude and longitude coordinates, venue number, etc., totaling 190 bytes of content are analyzed.
[0085] The data processing is to cache the collected effective frame payload content. After 30 seconds, the cached data is sent to the data processing service, which then sinks it to the storage unit.
[0086] The real-time time difference calculation unit of the present application includes terminal association analysis, stay time analysis, analysis of the influence of stay time between terminals, etc. The specific description is as follows:
[0087] After being processed by the above units, the terminal data already has a relatively complete data structure and various parameters. The indicators that need to be processed for terminal association analysis include: device number (Dev), MAC address, and entry time (InputTime). The terminal data model is as follows: Figure 3 As shown, the device number is the unique identification code of the Wi-Fi probe device. By deploying multiple Wi-Fi probes, different device number records are formed, and for the same terminal MAC, a separate data set is formed.
[0088] By arranging the entry time in the associated data set of the terminal MAC in ascending order, and then comparing the entry time between each data record, and then finding the time when different Wi-Fi probe nodes appear, this time is used as the departure time, and the duration is calculated to form the residence time in a certain device scenario. This depends on achieving seamless switching as much as possible in the deployment of each device.
[0089] The trajectory calculation unit of the present application includes the analysis of the sequence of tourists entering and leaving between various Wi-Fi probe nodes and the analysis of different points during the tourists' travel.
[0090] This application can be used for the detection of tourist walking trajectories in various scenic spots and fixed area scenarios, as well as early warning of tourist volume trends. The tourist trajectory route product introduces precise granularity Wi-Fi probe analysis, allowing scenic spot product development to better collect terminal information for subsequent portrait services, thereby optimizing the tourist-level governance link of the entire scenic spot.
[0091] The analysis of the time spent by tourists at various scenic spots establishes an internal mapping relationship for tourists. It also combines the time sequence and sequential relationship to reflect certain correlations and its causes and consequences. Therefore, the scope of application can be said to be very wide, and it is also a core tool for the management of tourist data assets.
[0092] Through effective data analysis of Wi-Fi, we can understand the range of scenic spot routes affected by a certain piece of real-time data. There is no need to redo all calculation tasks during the data correction phase, which can greatly reduce the amount of calculation and improve the efficiency of task completion.
[0093] The predictive analysis of tourist trajectories provides data-level early warning and judgment support for emergency response for the development of subsequent tourist trajectory trends. It also provides tourist prediction data support for scenic spot operators' precise marketing methods for scenic spots, and can effectively guide tourists to marketing attractions.
[0094] It should be noted that, for the method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations, but those skilled in the art should be aware that the present application is not limited by the order of the actions described, because according to the present application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all optional embodiments, and the actions involved are not necessarily required by the present application.
[0095] Optionally, an embodiment of the present application further provides an electronic device, comprising: a processor, a memory, and a computer program stored in the memory and executable on the processor. When the computer program is executed by the processor, the various processes of the above-mentioned method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be described here.
[0096] The embodiment of the present application also provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, each process of the above method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it is not repeated here. The computer-readable storage medium is, for example, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
[0097] Figure 7 800 is a block diagram of an electronic device 800 shown in the present application. For example, the electronic device 800 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.
[0098] Reference Figure 7 , the electronic device 800 may include one or more of the following components: a processing component 802 , a memory 804 , a power component 806 , a multimedia component 808 , an audio component 810 , an input / output (I / O) interface 812 , a sensor component 814 , and a communication component 816 .
[0099] The processing component 802 generally controls the overall operation of the electronic device 800, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the above method. In addition, the processing component 802 may include one or more modules to facilitate the interaction between the processing component 802 and other components. For example, the processing component 802 may include a multimedia module to facilitate the interaction between the multimedia component 808 and the processing component 802.
[0100] The memory 804 is configured to store various types of data to support operations on the device 800. Examples of such data include instructions for any application or method operating on the electronic device 800, contact data, phone book data, messages, images, videos, etc. The memory 804 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.
[0101] The power supply component 806 provides power to the various components of the electronic device 800. The power supply component 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the electronic device 800.
[0102] The multimedia component 808 includes a screen that provides an output interface between the electronic device 800 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 808 includes a front camera and / or a rear camera. When the device 800 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and the rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
[0103] The audio component 810 is configured to output and / or input audio signals. For example, the audio component 810 includes a microphone (MIC), and when the electronic device 800 is in an operating mode, such as a call mode, a recording mode, and a voice recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 804 or sent via the communication component 816. In some embodiments, the audio component 810 also includes a speaker for outputting audio signals.
[0104] I / O interface 812 provides an interface between processing component 802 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: a home button, a volume button, a start button, and a lock button.
[0105] The sensor assembly 814 includes one or more sensors for providing various aspects of status assessment for the electronic device 800. For example, the sensor assembly 814 can detect the open / closed state of the device 800, the relative positioning of components, such as the display and keypad of the electronic device 800, and the sensor assembly 814 can also detect the position change of the electronic device 800 or a component of the electronic device 800, the presence or absence of contact between the user and the electronic device 800, the orientation or acceleration / deceleration of the electronic device 800, and the temperature change of the electronic device 800. The sensor assembly 814 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 814 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 814 may also include an accelerometer, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
[0106] The communication component 816 is configured to facilitate wired or wireless communication between the electronic device 800 and other devices. The electronic device 800 can access a wireless network based on a communication standard, such as WiFi, a carrier network (such as 2G, 3G, 4G or 5G), or a combination thereof. In an exemplary embodiment, the communication component 816 receives a broadcast signal or broadcast operation information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 816 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.
[0107] In an exemplary embodiment, the electronic device 800 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the above methods.
[0108] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 804 including instructions, and the instructions can be executed by a processor 820 of an electronic device 800 to perform the above method. For example, the non-transitory computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.
[0109] Figure 819 is a block diagram of a computer-readable storage medium 1900 shown in the present application. For example, the computer-readable storage medium 1900 may be provided as a server.
[0110] Reference Figure 8 , the computer-readable storage medium 1900 includes a processing component 1922, which further includes one or more processors, and a memory resource represented by a memory 1932 for storing instructions, such as an application, that can be executed by the processing component 1922. The application stored in the memory 1932 may include one or more modules, each corresponding to a set of instructions. In addition, the processing component 1922 is configured to execute instructions to perform the above method.
[0111] The computer readable storage medium 1900 may also include a power supply component 1926 configured to perform power management of the computer readable storage medium 1900, a wired or wireless network interface 1950 configured to connect the computer readable storage medium 1900 to a network, and an input / output (I / O) interface 1958. The computer readable storage medium 1900 may operate based on an operating system stored in the memory 1932, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™ or the like.
[0112] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article 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, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element.
[0113] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, a magnetic disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to execute the methods described in each embodiment of the present application.
[0114] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.
[0115] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed in the present application can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0116] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0117] In the embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0118] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0119] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0120] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as USB flash drives, mobile hard drives, ROM, RAM, magnetic disks, or optical disks.
[0121] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
Claims
1. A method for predicting tourists' walking trajectories through WiFi signals, characterized in that: The method comprises: Collect MAC data from Wi-Fi probes installed at different scenic spots in the scenic area; Parsing the MAC data protocol collected by the Wi-Fi probe, wherein the MAC data protocol parsing includes frame data parsing and frame payload parsing; Based on the calculation of Wi-Fi signal attenuation, the entry and exit time and residence time of tourists in and out of different attractions are calculated in real time; Calculate the walking trajectory of tourists according to the order of entering and exiting the Wi-Fi probes; Performing matrix data processing on the walking trajectory data; Perform tourist movement line prediction analysis based on the tourist trajectory matrix data after the data processing; The tourists' trajectory prediction data is obtained from the historical terminal data set through a highly personalized naive Bayes algorithm to predict the walking trajectory of tourists in the scenic area.
2. The method for predicting tourists' walking trajectories through WiFi signals according to claim 1, characterized in that: The calculation formula for the trajectory prediction is as follows: P(A|B)=P(B|A)P(A) / P(B) Where P(A) is the prior probability, P(B|A) is the likelihood, and P(B) is the normalization constant.
3. The method for predicting tourists' walking trajectories through WiFi signals according to claim 1, characterized in that: The frame data analysis includes analyzing the frame header part, obtaining the instruction type, and analyzing the instruction; the frame payload analysis includes analyzing the device number, terminal MAC, collection time, RSSI, hotspot SSID, hotspot MAC, longitude and latitude coordinates and venue number.
4. The method for predicting tourists' walking trajectories through WiFi signals according to claim 1, characterized in that: The real-time calculation of the entry and exit time and residence time of tourists entering and exiting different scenic spots includes terminal association analysis between various Wi-Fi probes, residence time analysis, and residence time influence analysis between various terminals.
5. The method for predicting tourists' walking trajectories through WiFi signals according to claim 4, characterized in that: The indicators of the terminal association analysis include device number, MAC address and entry time, and the device number is the unique identification code of the Wi-Fi probe.
6. The method for predicting tourists' walking trajectories through WiFi signals according to claim 1, characterized in that: The calculation of the tourist walking trajectory is carried out by arranging the entry time of each Wi-Fi probe node in the associated data set of the terminal MAC in ascending order, then finding the time when different Wi-Fi probe nodes appear, and using this time as the departure time of the previous node to obtain the trajectory route of the terminal MAC.
7. The method for predicting tourists' walking trajectories through WiFi signals according to claim 6, characterized in that: The obtained trajectory line data of each terminal MAC are aggregated to obtain trajectory line matrices of different orders, and each matrix reflects the user data of various trajectories through the size of the circle in which it is located.
8. A device for predicting tourists' walking trajectories through WiFi signals, characterized in that: It includes a Wi-Fi probe attenuation data analysis unit, a real-time time difference calculation unit, a trajectory calculation unit and a predicted trajectory unit. The Wi-Fi probe attenuation data analysis unit includes data protocol analysis to form a data model. The real-time time difference calculation unit includes a time trend of distance change between a terminal and a Wi-Fi probe. The trajectory calculation unit includes an entry and exit time difference matrix for a single Mac terminal and multiple Wi-Fi probes to obtain the relative trajectory of the terminal. The predicted trajectory unit includes trajectory prediction data of tourists obtained from a historical terminal data set through a naive Bayes correction algorithm.
9. An electronic device, characterized in that: include: A processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program implements the method according to any one of claims 1 to 7 when executed by the processor.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.