A hotel visitor detection method based on image enhancement
Obtaining the behavioral characteristics of visitors in hotels through image enhancement technology, combining Markov model and decision tree model for prediction, solves the problem that the existing technology cannot obtain visitors' behavior, improves the quality of hotel services and visitor satisfaction, and uses encrypted storage Protects visitors' privacy.
Patent Information
- Application Number
- CN202410073789.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-01-18
- Publication Date
- 2024-12-10
- Estimated Expiration
- 2044-01-18
AI Technical Summary
The existing hotel registration system cannot obtain visitors' action information in the hotel, resulting in the inability to improve service quality.
Using image enhancement detection method, by obtaining the visitor's face information, clothing information and posture information, combining the Markov model and decision tree model to predict behavior, and starting related equipment, such as elevators, to capture the visitors' behavior habits in real time , improve service quality.
Real-time capture and prediction of visitor behavior habits is achieved, the hotel's service management capabilities and visitor satisfaction are improved, and the privacy of visitors is protected through encrypted storage.
Smart Images

Figure CN118262421B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of hotels, and in particular to a hotel visitor detection method based on image enhancement. Background Art
[0002] With the development of the national economy, business trips and tourism have become part of people's daily lives. At present, hotels will register and check the information of visitors staying in the hotel to achieve planned management of the guests, thereby improving the safety and service quality of the hotel.
[0003] However, the existing registration system is not only time-consuming, but also only serves the purpose of registration. It is impossible to understand the activities of visitors in the hotel, which is not conducive to improving service quality. Summary of the invention
[0004] The present invention discloses a hotel visitor detection method based on image enhancement. The hotel visitor detection method based on image enhancement can solve the problem that the existing hotel registration mechanism cannot obtain the visitor's actions in the hotel, which is not conducive to improving service quality.
[0005] In a first aspect, the present application provides a method for detecting a visitor to a hotel based on image enhancement, wherein the visitor is a visitor who passes through a first scene, a second scene, and a third scene in the hotel, wherein the first scene is different from the second scene and the third scene, and the method comprises:
[0006] In the first scenario, first facial information of the visitor is obtained, and feature extraction is performed to obtain first facial features of the visitor;
[0007] According to the first facial feature, using an image enhancement algorithm, determining the clothing information and posture information of the visitor, and obtaining the clothing feature and posture feature;
[0008] In the second scenario, predicting the next behavior of the visitor based on at least one or more of the first facial feature, the clothing feature, and the posture feature to obtain a prediction result;
[0009] In the third scenario, according to the prediction result, the equipment of the third scenario is started, wherein the equipment at least includes an elevator;
[0010] The prediction result and the first facial feature are encrypted and stored to obtain basic data of the visitor's visit to the hotel.
[0011] In some real-time methods, in the first scene, the step of obtaining the first face information of the visitor and performing feature extraction to obtain the first face feature of the visitor includes:
[0012] In the first scenario, obtaining first facial information of the visitor;
[0013] Matching the first facial information with the reservation information of the hotel's booked room to obtain the visitor's check-in room information;
[0014] Extracting features from the first facial information of the visitor to obtain the first facial features of the visitor;
[0015] The room information is matched with the first facial feature of the visitor and stored to obtain basic information of the visitor.
[0016] In some real-time methods, the step of determining the clothing information and posture information of the visitor by using an image enhancement algorithm according to the first facial feature, and obtaining the clothing feature and posture feature includes:
[0017] Determine first clothing information and second clothing information of the visitor using an image enhancement algorithm according to the first facial feature, wherein the first clothing information and the second clothing information represent clothing information at a first time and clothing information at a second time corresponding to a preset time period;
[0018] Extracting features from the first clothing information and the second clothing information respectively to obtain first clothing features and second clothing features;
[0019] According to the first clothing feature, obtain basic clothing features;
[0020] Obtaining a supplementary clothing feature by comparing the second clothing feature with the first clothing feature;
[0021] Combining the clothing supplementary feature with the clothing basic feature to obtain the clothing feature;
[0022] Determine, based on the first facial feature, multiple postures of the visitor within a preset time period, and obtain posture information of the multiple postures;
[0023] A convolutional neural network is used to extract features from the posture information of the multiple postures to obtain posture features.
[0024] In some real-time manners, in the second scene, the next behavior of the visitor is predicted based on at least one or more of the first facial features, the clothing features, and the posture features, and the step of obtaining the prediction result includes:
[0025] Obtain behavioral data of historical visitors and personal information characteristics of such historical visitors;
[0026] Modeling the behavior data of the historical visitors using a Markov model to obtain a state transition matrix or state transition probability of the historical visitors;
[0027] Construct a feature vector using the state transition matrix or state transition probability of the historical visitor and the personal information features of the historical visitor to obtain feature training data of the historical visitor;
[0028] Using the initial decision tree model, training the feature training data to obtain a target decision tree model;
[0029] In the second scene, the visitor is determined based on at least one or more of the first facial feature, the clothing feature, and the posture feature;
[0030] The target decision tree model is used to predict the next behavior of the visitor and obtain a prediction result.
[0031] In some real-time methods, in the third scenario, according to the prediction result, the step of starting the device includes:
[0032] Acquire information of the device in the third scenario;
[0033] According to the information of the device, matching is performed with the predicted result to obtain the target device;
[0034] The predicted result is executed using the target device.
[0035] In some real-time methods, the step of encrypting and storing the prediction result and the first facial feature to obtain basic data of the visitor visiting the hotel includes:
[0036] Acquire execution device information, wherein the execution device information indicates the device actually used by the visitor;
[0037] Using the execution device information, adjusting the predicted result to obtain an actual result;
[0038] The actual result and the first facial feature are encrypted and stored to obtain basic data of the visitor's visit to the hotel.
[0039] In some real-time manners, the step of encrypting and storing the actual result and the first facial feature to obtain basic data of the visitor visiting the hotel includes:
[0040] Performing a hash operation on the first facial feature or the personal information of the visitor using a hash algorithm to obtain a first hash value of the visitor;
[0041] Using the hash value as a key for the basic data of the visitor accessing the hotel to obtain a first hash code;
[0042] If the said visitor visits the said hotel again:
[0043] Acquire the second facial information of the visitor, and perform feature extraction on the second facial information to obtain the second facial features of the visitor;
[0044] Performing a hash operation on the second facial feature using a hash algorithm to obtain a second hash code of the visitor;
[0045] Compare and verify the second hash code with the first hash code to obtain a comparison result;
[0046] If the comparison result is the same:
[0047] When the basic data of the visitor's visit to the hotel is used as training data for the Markov model and the target decision tree model, the weight of the basic data of the visitor's visit to the hotel is increased.
[0048] In some real-time methods, the step of encrypting and storing the actual result and the first facial feature to obtain basic data of the visitor visiting the hotel further includes:
[0049] If the said visitor visits the said hotel again:
[0050] Obtaining the personal information of the visitor, and performing feature extraction on the personal information of the visitor to obtain a second hash code of the visitor;
[0051] Compare and verify the second hash code with the first hash code to obtain a comparison result;
[0052] If the comparison result is the same:
[0053] When the basic data of the visitor's visit to the hotel is used as training data for the Markov model and the target decision tree model, the weight of the basic data of the visitor's visit to the hotel is increased.
[0054] In some real-time methods, the step of encrypting and storing the prediction result and the first facial feature to obtain basic data of the visitor visiting the hotel also includes:
[0055] Acquire an intermediate server and a central server, wherein the intermediate server stores the first hash code, and the central server stores basic data of the visitor visiting the hotel;
[0056] Establishing a hash code mapping in the central server, and a unique matching relationship between the hash code mapping and the basic data of the visitor visiting the hotel, to obtain a first mapping hash code, wherein the first mapping hash code has a corresponding relationship with the hash code of the first hash code;
[0057] If the first hash code sent by the intermediate server to the central server corresponds to the first mapping hash code, the basic data of the visitor visiting the hotel in the central server will be called.
[0058] In a second aspect of the present application, a hotel visitor detection system based on image enhancement is provided, which is applied to the aforementioned hotel visitor detection method based on image enhancement, wherein the visitor is a visitor, and the visitor passes through a first scene, a second scene, and a third scene in the hotel, and the first scene is different from the second scene and the third scene, and the system comprises:
[0059] An acquisition module, used for acquiring the first facial information of the visitor in the first scene, and performing feature extraction to obtain the first facial features of the visitor;
[0060] The acquisition module is further used to determine the clothing information and posture information of the visitor according to the first facial feature by using an image enhancement algorithm to obtain the clothing feature and posture feature;
[0061] A prediction module, configured to predict the next behavior of the visitor in the second scene based on at least one or more of the first facial feature, the clothing feature and the posture feature, and obtain a prediction result;
[0062] An execution module, configured to start a device of the third scene according to the prediction result in the third scene, wherein the device at least includes an elevator;
[0063] The storage module is used to encrypt and store the prediction result and the first facial feature to obtain basic data of the visitor visiting the hotel.
[0064] Beneficial effects of the present invention:
[0065] The present application discloses a method for detecting hotel visitors based on image enhancement. In the first scene, the first facial information of the visitor is obtained, and feature extraction is performed to obtain the first facial feature of the visitor; based on the first facial feature, the image enhancement algorithm is used to determine the clothing information and posture information of the visitor to obtain the clothing feature and posture feature; in the second scene, the next behavior of the visitor is predicted based on at least one or more of the first facial feature, the clothing feature and the posture feature to obtain a prediction result; in the third scene, the device of the third scene is started based on the prediction result, wherein the device at least includes an elevator; the prediction result and the first facial feature are encrypted and stored to obtain the basic data of the visitor's visit to the hotel. The above method is used to capture the behavioral habits of visitors in the hotel, and the behavioral habits are used to improve the hotel's service quality for visitors. BRIEF DESCRIPTION OF THE DRAWINGS
[0066] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0067] Figure 1 The present invention is a flowchart of a hotel visitor detection method based on image enhancement. DETAILED DESCRIPTION
[0068] The technical solution of the present invention will be clearly and completely described below in conjunction with the embodiments. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0069] In the description of the present invention, it should be understood that the terms "center", "longitudinal", "lateral", "length", "width", "thickness", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", "clockwise", "counterclockwise" and the like indicate orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings, and are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the referred device or element must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as limiting the present invention.
[0070] In addition, the terms "first" and "second" are used for descriptive purposes only and cannot be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Therefore, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features. In the description of the present invention, the meaning of "multiple" is two or more, unless otherwise clearly and specifically defined. In addition, the terms "installed", "connected", and "connected" should be understood in a broad sense. For example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, and it can be the internal connection of two elements. For those of ordinary skill in the art, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0071] At present, when a hotel checks in, it will register visitors for management purposes, but the activities of visitors in the hotel are often ignored. For example, visitors often register their information at the registration desk in the hotel (the first scenario). After checking in, they will take the elevator to the room. During this process, the visitor will leave the registration desk and walk to the elevator (the second scenario), get to the elevator (the third scenario), enter the corridor (the third scenario), and arrive at the room (the fourth scenario). In this process, the first three scenarios experienced are only for illustrative purposes, and also include underground garages, restaurants and other scenarios. If the behavior habits of visitors in the hotel are obtained and used as data to improve service quality, it will effectively improve the hotel's service management capabilities and improve visitor satisfaction.
[0072] Therefore, the first aspect of the present application provides a hotel visitor detection method based on image enhancement.
[0073] A method for detecting hotel visitors based on image enhancement, in which the visitor is a visitor, who often passes through multiple scenes in a hotel, such as a registration desk (first scene), a section between the registration desk and an elevator (second scene), an elevator or a corridor (third scene), and also a room (fourth scene), a restaurant (fifth scene), a rest area (sixth scene), etc. This application is exemplified by the first three scenes, but should not be limited to these three scenes, and may also include other scenes.
[0074] It should be noted that surveillance cameras are installed in each scene in the hotel to capture the activities of visitors in the scene. The cameras in each scene can be set according to the number so as to obtain visitor images from multiple angles. In addition, the images or videos obtained by the camera are placed in the server, and the number of servers can be set as needed. For example, the number of servers is at least two, and the server has a conventional hard disk and CPU, etc. This application will not repeat them, wherein one serves as an intermediate server and the other serves as a hub server, the hub server is connected to the intermediate server, and the intermediate server is connected to the cameras in each scene, and the hub server and the intermediate server both have data processing capabilities.
[0075] like Figure 1 , a hotel visitor detection method based on image enhancement includes:
[0076] S100, in a first scenario, obtaining first facial information of a visitor, and performing feature extraction to obtain first facial features of the visitor.
[0077] Among them, visitors need to go to the hotel registration desk to check in or register when booking a hotel room online or checking in on site. At this time, there is a camera at the registration desk, which can be set on the desktop or on the roof of the registration desk. However, since there is usually a table in front of the registration desk, it is difficult for the camera to capture the visitor's full appearance, including the face and body. Therefore, the camera at the registration desk is only used to obtain the visitor's facial image.
[0078] Specifically, obtaining the first facial feature of the visitor includes steps S101 to S104.
[0079] S101, in a first scenario, obtaining first facial information of a visitor.
[0080] S102, matching the first facial information with the reserved room information of the hotel to obtain the room information of the visitor.
[0081] S103, extracting features from the first facial information of the visitor to obtain the first facial features of the visitor.
[0082] S104, matching the check-in room information with the first facial feature of the visitor and storing them to obtain basic information of the visitor.
[0083] As mentioned above, it is difficult for the camera installed at the registration desk to capture the visitor's entire body. Therefore, only the visitor's facial information is captured by the camera. In this way, after the visitor's facial image, i.e., the first facial information, is obtained by the camera, the first facial information can be subjected to feature extraction. The facial feature extraction can use conventional facial image feature extraction methods, which are not limited in this application. In addition, after the first facial information is obtained, it will be matched with the information left when booking a room in the hotel, so that the visitor's room information can be obtained.
[0084] It should be noted that if the registration is done on-site at the hotel, the step of matching the reservation information of the hotel's booked room will be omitted. In addition, if the visitor does not retain facial information when booking a room online, the visitor's personal information, such as ID card information, can also be used for matching, the purpose of which is to determine whether the visitor has booked a room. If a room has been booked, the room will be bound to the visitor.
[0085] It should also be noted that after obtaining the first facial information, in the case of feature extraction, the first facial feature is matched with the room, that is, a corresponding relationship is established, and then the basic information of the visitor is obtained and stored for backup. The basic information of the visitor includes the first facial feature and the room. In this way, in the subsequent steps, if the third scene is the corridor where the house is located, the light is dim, and all the features of the visitor cannot be identified, resulting in errors in the judgment, the room can be used as one of the features of the visitor. For example, a person who walks out of the room can be identified as a visitor. It can be understood that the room can only be used as one of the features, and it is also necessary to combine other features identified by the camera for comprehensive judgment, that is, it can also include the visitor's posture and clothes, etc. In this way, even if the corridor is dimly lit in the third scene, multiple features can be used for comprehensive judgment to identify the identity of the visitor.
[0086] S200, determining the clothing information and posture information of the visitor according to the first facial feature by using an image enhancement algorithm, and obtaining clothing features and posture features.
[0087] Among them, as mentioned above, after obtaining the first face information of the visitor at the registration counter, the visitor's clothing information and posture information cannot be obtained. However, these clothing information and posture information can be used to identify the visitor in some occasions, such as when the visitor wears a hat and the brim of the hat covers the face, the clothing information and posture information can be used to identify the visitor. Similarly, it is applicable to dim scenes, when one of the face information, clothing information and posture information is difficult to identify, so that other information can be used to make a comprehensive judgment, thereby ensuring that the visitor's location is obtained.
[0088] Specifically, obtaining clothing features and posture features includes steps S201 to S206.
[0089] S201, determining first clothing information and second clothing information of a visitor according to a first facial feature by using an image enhancement algorithm.
[0090] The first clothing information and the second clothing information represent the corresponding clothing information at the first time and the clothing information at the second time within a preset time period.
[0091] Specifically, some scenes in the hotel do not use bright lights, so it is necessary to use conventional image enhancement algorithms to enhance the quality of the image, such as enhancing the resolution of photos taken by the camera, so that the enhanced image can be better feature extracted.
[0092] It should be noted that after the visitor leaves the registration counter, when he is at a certain distance from the registration counter, the camera arranged at the registration counter can capture the visitor's entire body. In this way, the camera can be used to capture the visitor, and the visitor's first facial feature can be used to determine which person in the captured image is the visitor. In other words, there may be multiple people in the image captured by the camera. In this case, it is impossible to directly determine which person in the image is the visitor. At this time, other parts of the human body corresponding to the first facial feature can be used to determine the visitor's clothing information.
[0093] It should also be noted that the first clothing information and the second clothing information correspond to different times. For example, the clothing information at the first time can be the time when the visitor's whole body can be photographed, so that the visitor's clothing information can be easily obtained. However, since the shooting angle of the camera is fixed, the visitor's body may not be photographed from the front, but from the back. Therefore, the first clothing information can only extract the clothing information of the visitor's back. The second clothing information represents the visitor's clothing information at the second time. The second time can be separated from the first time by a certain time, such as 5 seconds, 10 seconds or 15 seconds, and the second clothing information obtained at the second time can be the visitor's clothing information photographed by another camera. That is to say, in the first scene, multiple cameras can be arranged in the hotel, and the clothing information of the visitor at other angles can be photographed by other cameras. It can be understood that the second time can also overlap with the first time. For example, two cameras are arranged at the registration desk, one of which is used to photograph the visitor's clothing information at one angle, and the other camera photographs the visitor's clothing information at another angle.
[0094] It should also be noted that a third time may also be included, and the clothing information of the visitor is obtained at the third time. For example, the time interval between the third time and the second time is longer, for example, a few hours. In other words, the clothing information of the visitor at different times or angles is captured by different cameras, thereby forming multiple images of the clothing. The present application does not limit the time points of the first time, the second time, and the third time, and the time interval, and its purpose is to obtain the clothing information of the visitor at different angles.
[0095] S201, extracting features from the first clothing information and the second clothing information respectively to obtain first clothing features and second clothing features.
[0096] Among them, as in the aforementioned steps, after obtaining the first clothing information and the second clothing information, feature extraction is performed on the first clothing information and the second clothing information respectively, thereby obtaining the first clothing feature and the second clothing feature. It can be understood that the extraction method of the first clothing feature and the second clothing feature can use the same method as the face feature extraction method, or a different feature extraction method can be used. The present application does not limit the feature extraction method.
[0097] S202, obtaining basic clothing features according to the first clothing features.
[0098] S203, obtaining a supplementary clothing feature by comparing the second clothing feature with the first clothing feature.
[0099] Among them, after obtaining the first clothing feature, the first clothing feature is used as the basic clothing feature, that is, this basic clothing feature can express the visitor, or express the clothing information of part of the visitor, but it needs to be iterated so that the basic clothing feature can be more perfect. In this way, the second clothing feature is compared with the first clothing feature, the same clothing features and different clothing features are found, the same clothing features are eliminated, the different clothing features are retained, and this feature is used as the clothing supplementary feature, so as to use this clothing supplementary feature to supplement the basic clothing feature.
[0100] S204, combining the clothing supplementary features with the clothing basic features to obtain clothing features.
[0101] Among them, after obtaining the supplementary features of clothes and the basic features of clothes in the above steps, the supplementary features of clothes are added to the basic features of clothes, thus forming an iteration of the basic features of clothes, thereby improving the basic features of clothes. It should be noted that for the supplement of the basic features of clothes, multiple supplementary features of clothes can be used for supplementation, that is, the images of the visitor at multiple angles can be obtained by using a camera, so that the images at different angles can be used for feature extraction as supplementary features of clothes to iterate the basic features of clothes, and finally obtain the features of clothes. In this way, the features of clothes can represent the visitor. At this time, the visitor has the first facial features and the features of clothes.
[0102] S205, determining multiple postures of the visitor within a preset time period according to the first facial feature, and obtaining posture information of the multiple postures.
[0103] S206, using a convolutional neural network, extracting features from the posture information of the multiple postures to obtain posture features.
[0104] Among them, the visitor's posture information is obtained by the same purpose and method as in the previous steps to obtain the clothing information, which will not be repeated here. The posture information can be obtained through multiple images, that is, the visitor's posture information is determined by the difference in the visitor's body movements in two images with a set time interval. Specifically, after obtaining multiple images of the visitor with a set time interval, a conventional convolutional neural network is used to extract features from the obtained multiple images, and the visitor's posture features are determined using information such as feature changes. It should be noted that the extraction of posture features is a conventional method, and this application does not limit this. The innovation of this application lies in the application of posture features.
[0105] It should be noted that the second scene may overlap with the first scene, and the second scene is not completely different from the first scene. In the second scene, the visitor's first facial features, clothing features, and posture features are obtained, and the visitor can be judged using these three types of features. It is understandable that since the hotel scene is different from the brightly lit scene, in some scenes, a certain type of visitor's features cannot be accurately identified, so these three types of features are needed for comprehensive judgment.
[0106] It should also be noted that when a certain type of feature is determined and other features change, such as clothing features, the conventional feature updating network is used to update the new features of the visitor to ensure that the three types of features of the visitor can represent the visitor. It should be noted that when the feature updating network is used, the original features are retained. For example, when a visitor changes clothes in the room, he or she has new clothing features, but it does not mean that the visitor will not put on the original clothes again. This can save computing power to a certain extent. That is, when the visitor puts on the original clothes again, the features of the original clothes are used to determine the visitor.
[0107] S300, in the second scenario, predicting the next behavior of the visitor based on at least one or more of the first facial feature, clothing feature and posture feature to obtain a prediction result.
[0108] Specifically, obtaining the prediction result includes steps S301 to S306.
[0109] S301, obtaining the behavior data of historical visitors and the personal information characteristics of historical visitors.
[0110] Among them, the behavior data of historical visitors represents the behavior of historical visitors of the hotel after checking in to the hotel, as well as the chain of these actions before and after, that is, after a visitor enters the hotel, what are the behaviors of the visitor, and the before and after correlation of the behaviors. For example, after the visitor enters the hotel, the sequential behaviors include: the first behavior is to register at the registration desk, the second behavior is to take the elevator, the third behavior is to enter the room, and the fourth behavior is to have a meal. Summarizing and counting these behaviors can derive all the behaviors of the visitor after entering the hotel. In addition, in order to accurately form the prediction results, the age, gender and address of the visitor need to be considered, and this information can be obtained from the personal information characteristics. When the personal information is the ID card, the ID card marks the visitor's gender, age and address, etc., and these gender, age and address information may produce different habits. Therefore, after obtaining the behavior summary statistics, it is also necessary to mark the behavior information, that is, mark the gender, age and address information on the behavior, so that the population corresponding to each behavior can be further counted, thereby improving the accuracy of the preset results.
[0111] S302, using a Markov model to model the behavior data of historical visitors, and obtaining a state transition matrix or state transition probability of the historical visitors.
[0112] Among them, the conventional Markov model is used to process the behaviors of historical visitors. It is assumed that the current behavior is only related to the previous behavior, that is, it satisfies the Markov property. The model training is completed after a large amount of historical visitor data.
[0113] S303, constructing a feature vector from the state transition matrix or state transition probability of the historical visitor and the personal information features of the historical visitor to obtain feature training data of the historical visitor.
[0114] Among them, the historical visitor behavior data is used as training data and trained in the Markov model. That is, in predicting visitor behavior, the visitor's behavior sequence can be modeled as a Markov chain, and the next possible state can be predicted by observing the historical state.
[0115] Specifically, given the observed behavior of the current visitor, the transition probability matrix and state transition probability in the Markov model are used as the behavioral features of the historical visitors.
[0116] The personal information characteristics of historical visitors include characteristics formed by the visitor's ID card.
[0117] S304, using the initial decision tree model, training the feature training data to obtain a target decision tree model.
[0118] S305, in the second scene, determining the visitor based on at least one or more of the first facial feature, clothing feature, and posture feature.
[0119] S306, using the target decision tree model, predicting the visitor's next behavior to obtain a prediction result.
[0120] Specifically, after combining the Markov model with the decision tree, the implementation steps are as follows: First, use the Markov model to model the behavior data of historical visitors to obtain a state transition matrix or state transition probability. Then, the state transition probability or state sequence obtained by the Markov model is used as the historical behavior feature, and together with other related features (such as the personal information features of historical visitors, etc.), it forms a complete feature vector. Use these feature vectors as training data to establish a decision tree model, and by learning these feature vectors (historical data), find out the association between different behavioral habits. Finally, use the combined model of the trained Markov model and the decision tree to predict the behavior habits of the current visitor, and comprehensively consider the modeling and classification capabilities of the Markov model and the decision tree. The Markov model can be fully utilized to capture the state transition law of historical behavior, and the decision tree can also be used to conduct a comprehensive analysis of multiple features, so as to more accurately predict the behavior of the current visitor.
[0121] S400: In the third scenario, according to the prediction result, start the device of the third scenario.
[0122] Among them, the equipment includes at least an elevator.
[0123] Specifically, starting the device of the third scenario includes steps S401 to S403.
[0124] S401, obtaining information of devices in the third scenario.
[0125] S402, matching the device information with the prediction result to obtain the target device.
[0126] S403, using the target device to execute the prediction result.
[0127] Specifically, in the third scenario where the elevator is an intelligent elevator, when the prediction result is that the visitor registers at the registration desk, checks in, and needs to pass through the corridor and take the elevator to the room in the next step, the elevator is started and stopped on the first floor so that when the visitor arrives at the elevator, he can take the elevator directly to the floor where the room is located.
[0128] It should be noted that the equipment includes at least elevators, and may also include other intelligent devices, such as corridor lights, coffee machines, smart trash cans, smart air conditioners, and smart speakers. These devices are all remotely controlled. For example, according to the predicted results, the corridor lights increase brightness, coffee is automatically brewed, the lid of the trash can is automatically opened, the air conditioner is turned on to adjust to a suitable temperature, the speaker is turned on to play music, etc. It can be understood that these devices themselves have intelligent functions and are existing conventional devices. This application does not improve the equipment, but only uses these devices to increase the intelligence of the hotel. When these devices are connected to the server, the server can form operation instructions according to the predicted results, and the devices execute according to the operation instructions.
[0129] S500: Encrypt and store the prediction result and the first facial feature to obtain basic data of the visitor visiting the hotel.
[0130] The step of obtaining basic data of visitors visiting a hotel includes steps S501 to S503.
[0131] S501, obtaining execution device information, wherein the execution device information indicates the device actually used by the visitor.
[0132] S502, using the execution device information, adjusting the predicted result to obtain the actual result.
[0133] S503, encrypting and storing the actual result and the first facial feature to obtain basic data of the visitor visiting the hotel.
[0134] Among them, as in the above steps, the prediction result is obtained, but the prediction result can only indicate that the visitor has a greater probability of selecting the target device for operation, but it cannot represent the visitor's true intention. That is to say, the device executed according to the prediction result will still have an error with the device actually used. At this time, the execution device information is obtained, and the execution device information is used to correct the device predicted to be executed in the prediction result, so as to obtain the actual result. This actual result is relative to the prediction result. This actual result represents the visitor's habits in the hotel, that is, as the visitor's habit data in the hotel, it can also be called basic data. When the hotel has mastered the habit data of these visitors, when the visitor stays in the hotel next time, or the visitor performs the same or similar behavior the next day, the target device will be adjusted. That is to say, according to the visitor's habits, the visitor's behavior habits in the hotel are given weights in the Markov model and the decision tree model, and the visitor's behavior habits in the hotel are given higher weights. In this way, when using the Markov model and the decision tree model, the prediction results obtained will further conform to the visitor's behavior, improving the convenience and satisfaction of the visitor.
[0135] In addition, the basic data of visitors visiting the hotel will be encrypted and stored to prevent the leakage of visitors' behavioral habits.
[0136] It should be noted that, S503, the step of encrypting and storing the actual result and the first facial feature to obtain basic data of the visitor visiting the hotel includes S5031 to S5034.
[0137] S5031, using a hash algorithm to perform a hash operation on the first facial feature or the visitor's personal information to obtain a first hash value of the visitor.
[0138] S5032, using the hash value as a key for the visitor to access the basic data of the hotel to obtain a first hash code.
[0139] Among them, the behavior habits of visitors belong to the privacy of visitors, so the basic data of visitors' visits to the hotel needs to be encrypted. Specifically, the encryption storage method is to use a hash algorithm to calculate the visitor's first facial features and / or the visitor's personal information, so that a first hash value corresponding to the visitor can be formed, and then the hash value is converted into a first hash code of a fixed length for use as a secret key. In other words, the basic data of visitors' visits to the hotel are encrypted using a hash algorithm to ensure the privacy of the visitors.
[0140] S5033, if the visitor visits the hotel again:
[0141] Acquire the second facial information of the visitor, and perform feature extraction on the second facial information to obtain the second facial features of the visitor;
[0142] Performing a hash operation on the second facial feature using a hash algorithm to obtain a second hash code of the visitor;
[0143] The second hash code is compared and verified with the first hash code to obtain a comparison result.
[0144] For example, when a visitor checks into a hotel again, the hotel can extract features from the second facial information of the visitor based on the face. The feature extraction method can adopt the aforementioned feature extraction method, which is not limited in this application, thereby obtaining the visitor's second facial features. Next, the second facial features are hashed using a hash algorithm to obtain a second hash code, and finally the second hash code is compared with the first hash code for verification. When the comparison results are the same, it means that the verification is successful.
[0145] If the above verification is successful, the basic data of visitors' visits to the hotel can be used as behavioral habit data for serving visitors, so that more accurate services can be provided to visitors.
[0146] It should be noted that a visitor's revisit to the hotel does not only mean that the visitor leaves the hotel, checks out, and then checks in again. It can also be understood as the visitor staying in the hotel on the second or third day, and using the basic data of the visitor's visit to the hotel as the behavioral habit data of the service visitor to update the Markov model and decision tree model. In other words, assuming that the visitor stays in the hotel for a week, the basic data of the visitor's visit to the hotel is constantly updated and adjusted, so that the Markov model and decision tree model can be continuously trained using the basic data of the visitor's visit to the hotel, thereby increasing the accuracy of the prediction results.
[0147] S5034, if the comparison result is the same:
[0148] When using the basic data of visitors visiting the hotel as training data for the Markov model and the target decision tree model, the weight of the basic data of visitors visiting the hotel is increased.
[0149] Among them, when the comparison results are the same, the Markov model and the target decision tree model will increase the weight of the basic data of visitors visiting the hotel, so that the prediction results obtained by using the Markov model and the target decision tree model can be more in line with the behavioral habits of visitors.
[0150] Specifically, the amount of weight increase can be set as needed, using time as the weighted calculation standard. That is, the longer the time interval between the next stay at the hotel and the current stay at the hotel, the lower the weight value assigned. However, it should be understood that even if the lowest weight is assigned, the historical data weight formed with other visitors should be high.
[0151] It should be noted that, S503, encrypting and storing the actual result and the first facial feature, and obtaining the basic data of the visitor visiting the hotel also includes steps S5035 and S5036.
[0152] S5035, if the visitor visits the hotel again:
[0153] The visitor's personal information is obtained, and features are extracted from the visitor's personal information to obtain a second hash code of the visitor.
[0154] The second hash code is compared and verified with the first hash code to obtain a comparison result.
[0155] It should be noted that this method is applicable to situations where the face cannot be recognized due to personal reasons of the visitor, such as significant changes in the face or injuries.
[0156] S5036, if the comparison result is the same:
[0157] When using the basic data of visitors visiting the hotel as training data for the Markov model and the target decision tree model, the weight of the basic data of visitors visiting the hotel is increased.
[0158] Among them, the above method is to use the visitor's personal information as facial features and calculate the hash algorithm, which is the same as the method used for facial feature verification and comparison results, and will not be repeated here.
[0159] It should also be noted that in order to improve the security of visitor privacy, S503, the actual result and the first facial feature are encrypted and stored, and obtaining the basic data of the visitor's visit to the hotel also includes steps S5037 and S50310.
[0160] S5037, obtain the intermediate server and the central server.
[0161] The intermediate server stores the first hash code, and the central server stores the basic data of visitors visiting the hotel.
[0162] S5038, establishing a hash code mapping in the central server, and a unique matching relationship between the hash code mapping and basic data of the visitor visiting the hotel, to obtain a first mapping hash code.
[0163] The first mapping hash code has a corresponding relationship with the hash code of the first hash code.
[0164] S5039: If the first hash code sent by the intermediate server to the central server corresponds to the first mapping hash code, the basic data of the visitor visiting the hotel in the central server will be called.
[0165] Among them, the intermediate server and the central server are pre-established. The first hash code is stored in the intermediate server, and the first hash code of the intermediate server is used to match the second hash code formed by the visitor visiting the hotel again. When the comparison and verification are successful, the first hash code is used to send a call request to the central server. Next, the central server calls the basic data of the visitor's visit to the hotel and assigns a higher weight to it, and trains it in the Markov model and the target decision tree model.
[0166] It should be noted that, for the sake of ease of understanding, the present application sends the first hash code from the intermediate server to the central server. In fact, a matching table should be stored in the intermediate server. For example, the first hash code matches the first verification hash code in the intermediate server. The first verification hash code is stored in the intermediate server. The first verification hash code and the matching table of the first hash code in the first verification hash code form a corresponding relationship. In this way, the intermediate server sends the first verification hash code to the central server, and the first mapping hash code stored in the central server forms a matching relationship with the first verification hash code. That is to say, when the visitor's second hash code is successfully compared and verified with the first hash code of the intermediate server, the first verification hash code needs to be compared and verified with the first mapping hash code. This method can ensure the security of the central server. In this way, the first comparison verification is completed in the intermediate server, thereby preventing the central server from being attacked.
[0167] The algorithms or models mentioned in this application are conventional and have not been improved.
[0168] In summary, the present invention provides a method for detecting hotel visitors based on image enhancement. The image enhancement algorithm is used to process the pictures of the visitors in the hotel so that the images formed under different lighting conditions can have a better recognition effect. Next, the enhanced images are used to form the characteristics of the visitors, and the behavioral habits of the visitors are mined according to the characteristics of the visitors. The behavior of the visitors is predicted in combination with the behavioral habits of historical visitors, so as to improve the service quality of the hotel and the satisfaction of the visitors. In addition, since the living habits of the visitors are mined, which belongs to the privacy of the visitors, the basic data formed by the visitors' visit to the hotel are encrypted in multiple ways, thereby ensuring the security of the basic data of the visitors in the hotel. The basic data of the visitors in the hotel are also used for the important behavioral habit data of the visitors when they visit the hotel next time, forming the prediction results and improving the accuracy of the prediction.
[0169] A second aspect of the present application provides a hotel visitor detection system based on image enhancement, which is applied to the aforementioned hotel visitor detection method based on image enhancement, wherein the visitor is a visitor, and the visitor passes through a first scene, a second scene, and a third scene in the hotel, and the first scene is different from the second scene and the third scene, and the system comprises:
[0170] An acquisition module, used for acquiring the first facial information of the visitor in the first scene, and performing feature extraction to obtain the first facial features of the visitor;
[0171] The acquisition module is further used to determine the clothing information and posture information of the visitor according to the first facial feature by using an image enhancement algorithm to obtain the clothing feature and posture feature;
[0172] A prediction module, configured to predict the next behavior of the visitor in the second scene based on at least one or more of the first facial feature, the clothing feature and the posture feature, and obtain a prediction result;
[0173] An execution module, configured to start a device of the third scene according to the prediction result in the third scene, wherein the device at least includes an elevator;
[0174] The storage module is used to encrypt and store the prediction result and the first facial feature to obtain basic data of the visitor visiting the hotel.
[0175] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.
[0176] In the specific implementation of this application, the personal information, videos and other related data involved, when applied to the specific products or technologies of the embodiments of this application, need to obtain user permission or consent, and the collection, use and processing of the relevant data need to comply with the relevant laws, regulations and standards of the relevant countries and regions.
Claims
1. A hotel visitor detection method based on image enhancement, characterized in that: The visitor is a visitor, and the visitor passes through a first scene, a second scene, and a third scene in the hotel, and the first scene is different from the second scene and the third scene. The method includes: In the first scenario, first facial information of the visitor is obtained, and feature extraction is performed to obtain the first facial features of the visitor; According to the first facial feature, using an image enhancement algorithm, determining the clothing information and posture information of the visitor to obtain clothing features and posture features; In the second scenario, predicting the next behavior of the visitor based on at least one or more of the first facial feature, the clothing feature, and the posture feature to obtain a prediction result; In the third scenario, according to the prediction result, the equipment of the third scenario is started, wherein the equipment at least includes an elevator; The prediction result and the first facial feature are encrypted and stored to obtain basic data of the visitor visiting the hotel; wherein, The step of determining the clothing information and posture information of the visitor by using an image enhancement algorithm according to the first facial feature to obtain the clothing features and posture features comprises: Determine first clothing information and second clothing information of the visitor using an image enhancement algorithm according to the first facial feature, wherein the first clothing information and the second clothing information represent clothing information at a first time and clothing information at a second time corresponding to a preset time period; Extracting features from the first clothing information and the second clothing information respectively to obtain first clothing features and second clothing features; According to the first clothing feature, obtain basic clothing features; Obtaining a supplementary clothing feature by comparing the second clothing feature with the first clothing feature; Combining the clothing supplementary feature with the clothing basic feature to obtain the clothing feature; Determine, based on the first facial feature, multiple postures of the visitor within a preset time period, and obtain posture information of the multiple postures; A convolutional neural network is used to extract features from the posture information of the multiple postures to obtain posture features.
2. The hotel visitor detection method based on image enhancement according to claim 1, characterized in that: In the first scenario, the step of obtaining the first facial information of the visitor and performing feature extraction to obtain the first facial features of the visitor includes: In the first scenario, obtaining first facial information of the visitor; Matching the first facial information with the reservation information of the hotel's booked room to obtain the visitor's check-in room information; Extracting features from the first facial information of the visitor to obtain the first facial features of the visitor; The room information is matched with the first facial feature of the visitor and stored to obtain basic information of the visitor.
3. The hotel visitor detection method based on image enhancement according to claim 1, characterized in that: The step of predicting the next behavior of the visitor in the second scene based on at least one or more of the first facial feature, the clothing feature, and the posture feature to obtain the prediction result includes: Obtain behavioral data of historical visitors and personal information characteristics of such historical visitors; Modeling the behavior data of the historical visitors using a Markov model to obtain a state transition matrix or state transition probability of the historical visitors; Construct a feature vector using the state transition matrix or state transition probability of the historical visitor and the personal information features of the historical visitor to obtain feature training data of the historical visitor; Using the initial decision tree model, training the feature training data to obtain a target decision tree model; In the second scene, the visitor is determined based on at least one or more of the first facial feature, the clothing feature, and the posture feature; The target decision tree model is used to predict the next behavior of the visitor and obtain a prediction result.
4. The hotel visitor detection method based on image enhancement according to claim 3 is characterized in that: In the third scenario, according to the prediction result, the step of starting the device includes: Acquire information of the device in the third scenario; According to the information of the device, matching is performed with the predicted result to obtain the target device; The predicted result is executed using the target device.
5. The hotel visitor detection method based on image enhancement according to claim 4 is characterized in that: The step of encrypting and storing the prediction result and the first facial feature to obtain basic data of the visitor visiting the hotel includes: Acquire execution device information, wherein the execution device information indicates the device actually used by the visitor; Using the execution device information, adjusting the predicted result to obtain an actual result; The actual result and the first facial feature are encrypted and stored to obtain basic data of the visitor's visit to the hotel.
6. The hotel visitor detection method based on image enhancement according to claim 5, characterized in that: The step of encrypting and storing the actual result and the first facial feature to obtain basic data of the visitor visiting the hotel comprises: Performing a hash operation on the first facial feature or the personal information of the visitor using a hash algorithm to obtain a first hash value of the visitor; Using the hash value as a key for the basic data of the visitor accessing the hotel to obtain a first hash code; If the said visitor visits the said hotel again: Acquire the second facial information of the visitor, and perform feature extraction on the second facial information to obtain the second facial features of the visitor; Performing a hash operation on the second facial feature using a hash algorithm to obtain a second hash code of the visitor; Compare and verify the second hash code with the first hash code to obtain a comparison result; If the comparison result is the same: When the basic data of the visitor's visit to the hotel is used as training data for the Markov model and the target decision tree model, the weight of the basic data of the visitor's visit to the hotel is increased.
7. The hotel visitor detection method based on image enhancement according to claim 6 is characterized in that: The step of encrypting and storing the actual result and the first facial feature to obtain basic data of the visitor visiting the hotel also includes: If the said visitor visits the said hotel again: Obtaining the personal information of the visitor, and performing feature extraction on the personal information of the visitor to obtain a second hash code of the visitor; Compare and verify the second hash code with the first hash code to obtain a comparison result; If the comparison result is the same: When the basic data of the visitor's visit to the hotel is used as training data for the Markov model and the target decision tree model, the weight of the basic data of the visitor's visit to the hotel is increased.
8. The hotel visitor detection method based on image enhancement according to claim 7 is characterized in that: The step of encrypting and storing the prediction result and the first facial feature to obtain basic data of the visitor visiting the hotel also includes: Acquire an intermediate server and a central server, wherein the intermediate server stores the first hash code, and the central server stores basic data of the visitor visiting the hotel; Establishing a hash code mapping in the central server, and a unique matching relationship between the hash code mapping and the basic data of the visitor visiting the hotel, to obtain a first mapping hash code, wherein the first mapping hash code has a corresponding relationship with the hash code of the first hash code; If the first hash code sent by the intermediate server to the central server corresponds to the first mapping hash code, the basic data of the visitor visiting the hotel in the central server will be called.
9. A hotel visitor detection system based on image enhancement, characterized in that: The method for detecting a visitor to a hotel based on image enhancement applied to any one of claims 1 to 8, wherein the visitor is a visitor, and the visitor passes through a first scene, a second scene, and a third scene in the hotel, and the first scene is different from the second scene and the third scene, and the system comprises: An acquisition module, used for acquiring the first facial information of the visitor in the first scene, and performing feature extraction to obtain the first facial features of the visitor; The acquisition module is further used to determine the clothing information and posture information of the visitor according to the first facial feature by using an image enhancement algorithm to obtain the clothing feature and posture feature; A prediction module, configured to predict the next behavior of the visitor in the second scene based on at least one or more of the first facial feature, the clothing feature and the posture feature, and obtain a prediction result; An execution module, configured to start a device of the third scene according to the prediction result in the third scene, wherein the device at least includes an elevator; A storage module is used to encrypt and store the prediction result and the first facial feature to obtain basic data of the visitor visiting the hotel; wherein, The step of determining the clothing information and posture information of the visitor by using an image enhancement algorithm according to the first facial feature to obtain the clothing features and posture features comprises: Determine first clothing information and second clothing information of the visitor using an image enhancement algorithm according to the first facial feature, wherein the first clothing information and the second clothing information represent clothing information at a first time and clothing information at a second time corresponding to a preset time period; Extracting features from the first clothing information and the second clothing information respectively to obtain first clothing features and second clothing features; According to the first clothing feature, obtain basic clothing features; Obtaining a supplementary clothing feature by comparing the second clothing feature with the first clothing feature; Combining the clothing supplementary feature with the clothing basic feature to obtain the clothing feature; Determine, based on the first facial feature, multiple postures of the visitor within a preset time period, and obtain posture information of the multiple postures; A convolutional neural network is used to extract features from the posture information of the multiple postures to obtain posture features.
