Equipment movement detection method, related device, equipment and storage medium
Through image acquisition and scene recognition model identification, the problem of inaccurate GPS positioning is solved, and the accuracy and service quality of mobile detection are improved.
Patent Information
- Application Number
- CN202310731368.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-06-19
- Publication Date
- 2024-12-20
AI Technical Summary
The existing technology has inaccurate GPS positioning in scenarios such as high-rise buildings or valleys, resulting in large errors in the mobile detection results of interactive equipment and no effective solution is available.
The image acquisition device is used to acquire the image to be recognized, and the scene recognition model trained based on N sample images is recognized, to determine the movement of the interactive device, and trigger the corresponding prompt operation.
Improve the accuracy of device movement detection, avoid errors caused by inaccurate positioning, and ensure service quality and user experience.
Smart Images

Figure CN119169494A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a method for detecting device movement, related apparatus, equipment and storage medium. Background Art
[0002] With the continuous development of Internet technology, mobile payment is becoming more and more widely used. However, the mobility of interactive devices has always been a difficult problem. On the one hand, the location information of interactive devices needs to be filed, so the interactive devices cannot be moved at will. On the other hand, after the interactive devices move, it will cause difficulties in the management of quality services. How to effectively solve the mobility problem of interactive devices has become an important issue.
[0003] At present, in the related technology, the geographical location information of the interactive device can be obtained based on the global positioning system (GPS), so as to determine whether the interactive device moves. If it is detected that the interactive device moves, a further processing strategy is adopted.
[0004] However, the inventors have found that the current solution has at least the following problems: the GPS positioning results are not accurate in some scenarios (e.g., high-rise buildings or valleys, etc.), resulting in large errors in the mobile detection results of the interactive device. No effective solution has been proposed yet for the above problems. Summary of the invention
[0005] The embodiments of the present application provide a method for detecting device movement, related apparatus, equipment, and storage medium, which can avoid inaccurate device positioning in certain scenarios, thereby improving the accuracy of movement detection results.
[0006] In view of this, the present application provides, on one hand, a method for detecting movement of a device, comprising:
[0007] Invoke an image acquisition device of a target interactive device to acquire an image to be recognized, wherein the image to be recognized is an image acquired at a target time;
[0008] The image to be identified is identified by a scene recognition model to obtain a scene recognition result of the image to be identified, wherein the scene recognition model is obtained by training based on N sample images, the N sample images are acquired by an image acquisition device of the target interactive device before the target time, and N is an integer greater than 1;
[0009] According to the scene recognition result of the image to be recognized, the movement detection result of the target interactive device is determined, wherein the movement detection result is used to indicate the movement of the target interactive device, and when the movement detection result indicates that the target interactive device has moved, a prompt operation is triggered.
[0010] Another aspect of the present application provides a device movement detection apparatus, comprising:
[0011] An acquisition module, used to call an image acquisition device of a target interactive device to acquire an image to be recognized, wherein the image to be recognized is an image acquired at a target time;
[0012] A recognition module, used to recognize the image to be recognized by using a scene recognition model to obtain a scene recognition result of the image to be recognized, wherein the scene recognition model is obtained by training based on N sample images, the N sample images are acquired by an image acquisition device of a target interactive device before a target time, and N is an integer greater than 1;
[0013] The detection module is used to determine the movement detection result of the target interactive device according to the scene recognition result of the image to be identified, wherein the movement detection result is used to indicate the movement of the target interactive device, and trigger a prompt operation when the movement detection result indicates that the target interactive device has moved.
[0014] In one possible design, in another implementation of another aspect of the embodiment of the present application, the device movement detection apparatus further includes a training module;
[0015] The acquisition module is further used to recognize the image to be recognized by using the scene recognition model, and before obtaining the scene recognition result of the image to be recognized, call the image acquisition device of the target interactive device to obtain N sample images;
[0016] The acquisition module is further used to acquire a scene label corresponding to each sample image in the N sample images, wherein the scene label is an initial scene label or a non-initial scene label;
[0017] The acquisition module is also used to acquire the scene prediction result corresponding to each sample image through the scene recognition model to be trained based on the N sample images;
[0018] The training module is used to use the scene label corresponding to each sample image and the scene prediction result to update the model parameters of the scene recognition model to be trained until the model training conditions are met to obtain the scene recognition model, wherein the scene recognition model is used to recognize the images collected by the target interactive device.
[0019] In one possible design, in another implementation of another aspect of the embodiment of the present application, the device movement detection apparatus further includes a sending module;
[0020] The acquisition module is further used to recognize the image to be recognized by using the scene recognition model, and before obtaining the scene recognition result of the image to be recognized, call the image acquisition device of the target interactive device to obtain N sample images;
[0021] A sending module, used for sending N sample images to a server;
[0022] The server is used to obtain a scene label corresponding to each sample image in the N sample images, where the scene label is an initial scene label or a non-initial scene label;
[0023] The server is used to obtain the scene prediction result corresponding to each sample image through the scene recognition model to be trained based on the N sample images;
[0024] The server is used to use the scene label and scene prediction result corresponding to each sample image to update the model parameters of the scene recognition model to be trained until the model training conditions are met to obtain the scene recognition model. The scene recognition model is used to recognize the images collected by the target interactive device.
[0025] In one possible design, in another implementation of another aspect of the embodiment of the present application,
[0026] An acquisition module, specifically used to acquire a standard sample image from N sample images, wherein the standard sample image is the first frame image collected from the N sample images;
[0027] Determine the scene label corresponding to the standard sample image as the initial scene label;
[0028] Extract feature points from each of the N sample images to obtain a set of feature points corresponding to each sample image;
[0029] Compare the feature point set corresponding to each sample image in the (N-1) sample images with the feature point set corresponding to the standard sample image, wherein the (N-1) sample images are the sample images remaining after removing the standard sample image from the N sample images;
[0030] If the feature point offset between the feature point set corresponding to the sample image and the feature point set corresponding to the standard sample image is greater than the offset threshold, the scene label corresponding to the sample image is determined as a non-initial scene label;
[0031] If the feature point offset between the feature point set corresponding to the sample image and the feature point set corresponding to the standard sample image is less than or equal to the offset threshold, the scene label corresponding to the sample image is determined as the initial scene label.
[0032] In one possible design, in another implementation of another aspect of the embodiment of the present application,
[0033] An acquisition module, specifically used to display N sample images;
[0034] In response to the labeling operation for each sample image, a scene label corresponding to each sample image is obtained.
[0035] In one possible design, in another implementation of another aspect of the embodiment of the present application,
[0036] The acquisition module is further used to acquire M sample images when the scene labels corresponding to the N sample images are all initial scene labels, wherein the scene label of each sample image in the M sample images is a non-initial scene label, the M sample images are images collected by other interactive devices, or the M sample images are pre-constructed images, and M is an integer greater than 1;
[0037] An acquisition module, specifically used to acquire a scene prediction result corresponding to each sample image in the (N+M) sample images through a scene recognition model to be trained based on the N sample images and the M sample images;
[0038] The training module is specifically used to use the scene label corresponding to each sample image in the (N+M) sample images and the scene prediction result to update the model parameters of the scene recognition model to be trained until the model training conditions are met to obtain the scene recognition model.
[0039] In one possible design, in another implementation of another aspect of the embodiment of the present application, the scene prediction result is a scene prediction probability distribution;
[0040] The acquisition module is specifically used to obtain the scene prediction probability distribution corresponding to each sample image through the scene recognition model to be trained based on N sample images, wherein the scene prediction probability distribution includes the probability that the sample image belongs to the initial scene label and the probability of the non-initial scene label.
[0041] In one possible design, in another implementation of another aspect of the embodiment of the present application,
[0042] An acquisition module is specifically used to identify the image to be identified through a scene recognition model to obtain a scene probability distribution of the image to be identified, wherein the scene probability distribution includes a probability that the image to be identified belongs to an initial scene label and a probability that the image to be identified belongs to a non-initial scene label;
[0043] According to the scene probability distribution of the image to be recognized, the scene recognition result of the image to be recognized is determined.
[0044] In one possible design, in another implementation of another aspect of the embodiment of the present application, the scene prediction result is a scene prediction score;
[0045] The acquisition module is specifically used to obtain the scene prediction score corresponding to each sample image through the scene recognition model to be trained based on N sample images, wherein the scene prediction score represents the probability that the sample image belongs to the initial scene label.
[0046] In one possible design, in another implementation of another aspect of the embodiment of the present application,
[0047] An acquisition module is specifically used to identify the image to be identified through a scene recognition model to obtain a scene score of the image to be identified, wherein the scene score represents the probability that the image to be identified belongs to the initial scene label;
[0048] According to the scene score of the image to be identified, a scene identification result of the image to be identified is determined.
[0049] In one possible design, in another implementation of another aspect of the embodiment of the present application, the device movement detection apparatus further includes a determination module and an execution module;
[0050] a determination module, configured to call the image acquisition device of the target interactive device, and before acquiring the image to be identified, determine the longitude change value and the latitude change value according to the first position information of the target interactive device and the initial position information of the target interactive device, wherein the first position information is acquired according to a global positioning system GPS chip built into the target interactive device;
[0051] The determination module is further configured to determine that the target interactive device has moved if the longitude change value or the latitude change value is greater than or equal to the change threshold;
[0052] The execution module is used to execute the step of calling the image acquisition device of the target interactive device to obtain the image to be identified if the longitude change value or the latitude change value is less than the change threshold.
[0053] In one possible design, in another implementation of another aspect of the embodiment of the present application,
[0054] The determination module is further used to call the image acquisition device of the target interactive device, and before acquiring the image to be identified, determine the longitude change value and the latitude change value according to the second position information of the target interactive device and the initial position information of the target interactive device, wherein the second position information is obtained by connecting the target interactive device to the base station;
[0055] The determination module is further configured to determine that the target interactive device has moved if the longitude change value or the latitude change value is greater than or equal to the change threshold;
[0056] The execution module is also used to execute the step of calling the image acquisition device of the target interactive device to obtain the image to be identified if the longitude change value or the latitude change value is less than the change threshold.
[0057] In one possible design, in another implementation of another aspect of the embodiment of the present application,
[0058] The determination module is further used to call the image acquisition device of the target interactive device, and before acquiring the image to be identified, when the third position information of the target interactive device is acquired, determine the longitude change value and the latitude change value according to the third position information and the initial position information of the target interactive device, wherein the third position information is acquired by connecting the target interactive device to a mobile hotspot;
[0059] The determination module is further configured to determine that the target interactive device has moved if the longitude change value or the latitude change value is greater than or equal to the change threshold;
[0060] The execution module is also used to execute the step of calling the image acquisition device of the target interactive device to obtain the image to be identified if the longitude change value or the latitude change value is less than the change threshold.
[0061] In one possible design, in another implementation of another aspect of the embodiment of the present application,
[0062] The determination module is further used to call the image acquisition device of the target interactive device, and before acquiring the image to be identified, when the fourth position information of the target interactive device is acquired, determine the longitude change value and the latitude change value according to the fourth position information and the initial position information of the target interactive device, wherein the fourth position information is acquired by connecting the target interactive device to the Bluetooth device;
[0063] The determination module is further configured to determine that the target interactive device has moved if the longitude change value or the latitude change value is greater than or equal to the change threshold;
[0064] The execution module is also used to execute the step of calling the image acquisition device of the target interactive device to obtain the image to be identified if the longitude change value or the latitude change value is less than the change threshold.
[0065] In one possible design, in another implementation of another aspect of the embodiment of the present application,
[0066] The detection module is specifically used to obtain the acceleration value of the target interactive device through the acceleration sensor built into the target interactive device when the scene recognition result of the image to be recognized indicates that the target interactive device is in the initial scene;
[0067] If the acceleration value is greater than or equal to the acceleration threshold, it is determined that the target interactive device has moved;
[0068] If the acceleration value is less than the acceleration threshold, it is determined that the target interactive device has not moved.
[0069] In one possible design, in another implementation of another aspect of the embodiment of the present application,
[0070] a detection module, specifically configured to obtain, when a scene recognition result of the image to be recognized indicates that the target interaction device is in an initial scene, a signal strength between the target interaction device and T wireless devices at a first moment, wherein T is an integer greater than or equal to 3;
[0071] According to the signal strength between the target interactive device and the T wireless devices, a target space model is constructed, wherein the target space model includes a position point corresponding to the target interactive device and a position point corresponding to each of the T wireless devices;
[0072] The movement detection result of the target interactive device is determined according to the target space model and the initial space model, wherein the initial space model is constructed based on the signal strength between the target interactive device and T wireless devices for a second moment, and the second moment occurs before the first moment.
[0073] Another aspect of the present application provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor implements the above-mentioned methods when executing the computer program.
[0074] Another aspect of the present application provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the above-mentioned methods are implemented.
[0075] Another aspect of the present application provides a computer program product, including a computer program, which implements the above-mentioned methods when executed by a processor.
[0076] It can be seen from the above technical solutions that the embodiments of the present application have the following advantages:
[0077] In an embodiment of the present application, a method for detecting device movement is provided. First, an image acquisition device of a target interactive device is called to obtain an image to be identified. Then, the image to be identified is identified by a scene recognition model to obtain a scene recognition result of the image to be identified. Finally, the target interactive device can determine the movement detection result of the target interactive device according to the scene recognition result of the image to be identified. Based on this, when the movement detection result indicates that the target interactive device has moved, a prompt operation is triggered. In the above manner, the image acquisition device of the interactive device is used to collect images of the surrounding scene, and then the scene recognition is performed on the collected image based on the image recognition technology, so that it is possible to finely judge whether the interactive device has moved. In this way, the situation of inaccurate device positioning in certain scenarios is avoided, thereby improving the accuracy of the movement detection result. Based on this, by detecting the movement of the interactive device, the abnormal situation of the device can be discovered in time, thereby improving the service quality. And the movement detection of the interactive device is automatically performed, thereby avoiding the tediousness and inaccuracy of manual inspection and improving the management efficiency. In addition, by detecting the movement of the interactive device, transaction failure or delay caused by the movement of the device can be avoided, thereby improving the user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0078] Figure 1 A schematic diagram of an implementation environment of the device movement detection method in an embodiment of the present application;
[0079] Figure 2 This is another schematic diagram of an implementation environment of the device movement detection method in an embodiment of the present application;
[0080] Figure 3 A schematic diagram of a flow chart of a device movement detection method in an embodiment of the present application;
[0081] Figure 4 A schematic diagram of a top view of a target interaction device in an embodiment of the present application;
[0082] Figure 5 A schematic diagram of automatically labeling a sample image in an embodiment of the present application;
[0083] Figure 6 A schematic diagram of manually annotating a sample image in an embodiment of the present application;
[0084] Figure 7 A schematic diagram of a network structure of a scene recognition model in an embodiment of the present application;
[0085] Figure 8 A schematic diagram of an initial space model and a target space model in an embodiment of the present application;
[0086] Fig. 9 A schematic diagram of a device movement detection device in an embodiment of the present application;
[0087] Fig.10 It is a structural diagram of a terminal in an embodiment of the present application. DETAILED DESCRIPTION
[0088] The embodiments of the present application provide a method for detecting device movement, related apparatus, equipment, and storage medium, which can avoid inaccurate device positioning in certain scenarios, thereby improving the accuracy of movement detection results.
[0089] The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein, for example. In addition, the terms "including" and "corresponding to" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0090] With the widespread use of mobile payment, the mobility of interactive devices has a great impact on filing and management. How to effectively detect the mobility of interactive devices has become an important issue.
[0091] In an embodiment of the present application, a method for detecting device movement is provided, which uses the geographical location of the interactive device to roughly determine whether the location of the interactive device has moved. In the case where the geographical location information does not change much, the image of the surrounding scene is collected by the camera, and the surrounding scene is recognized by using image recognition technology to finely determine whether the interactive device has moved. If the location of the interactive device is detected to have moved, a corresponding prompt or alarm can be issued. In this way, the mobility problem of the interactive device can be effectively solved and the quality of payment services can be improved.
[0092] A device movement detection method is provided for this application, which includes at least one of the following scenarios when applied.
[0093] (1) Public equipment used in the payment field;
[0094] The interactive device involved in the present application may specifically be a palm scanning device or a face scanning device, wherein both the palm scanning device and the face scanning device have built-in color cameras, and the palm scanning device and the face scanning device have communication functions.
[0095] Based on this, first, positioning is achieved using the communication function of the interactive device. For example, GPS positioning is performed using the positioning chip built into the interactive device; for another example, after the interactive device establishes a Bluetooth connection with the terminal, positioning is performed using Bluetooth technology; for another example, after the interactive device is connected to the Internet, positioning is performed using network address information. In this way, the geographic location information of the interactive device is obtained. Then, when the geographic location information does not change much, the built-in color camera is called to take photos or videos of the surrounding scenes, and the image recognition technology is used to identify the scenes in the photos or videos to determine whether the interactive device has moved. If it is detected that the location of the interactive device has moved, a corresponding prompt or alarm is given.
[0096] It can be seen that through the above method, the movement problem of interactive equipment can be discovered in time and measures can be taken to improve the quality of payment services.
[0097] (2) Public equipment used in exhibition halls;
[0098] The interactive device involved in the present application may specifically be an exhibition object placed in a public exhibition area, wherein the interactive device is externally connected to a color camera and a positioning chip is provided on the interactive device.
[0099] Based on this, first, the positioning chip of the interactive device is used for GPS positioning, thereby obtaining the geographical location information of the interactive device. Then, if the geographical location information does not change much, an external color camera is called to take photos or videos of the surrounding scenes, and the scene in the photo or video is identified using image recognition technology to determine whether the interactive device has moved. If the location of the interactive device is detected to have moved, a corresponding prompt or alarm is issued.
[0100] It can be seen that through the above method, the movement problem of interactive equipment can be discovered in time and measures can be taken, thereby preventing the exhibition objects from being moved at will to a certain extent.
[0101] It should be noted that the above application scenarios are only examples, and the device movement detection method provided in this embodiment can also be applied to other scenarios, which are not limited here.
[0102] The method provided in this application can be applied to Figure 1 The implementation environment shown includes a target interaction device 110. The target interaction device 110 involved in the present application includes but is not limited to a face-scanning device, a palm-scanning device, and the like.
[0103] Combination Figure 1In the implementation environment shown, in step A1, the target interaction device 110 calls the image acquisition device to shoot the image to be identified from the external environment. In step A2, the target interaction device 110 calls the scene recognition model to identify the image to be identified, thereby obtaining a scene recognition result. In step A3, a corresponding motion detection result is generated according to the scene recognition result. In step A4, the target interaction device 110 triggers a prompt operation when it is determined that motion has occurred based on the motion detection result.
[0104] The method provided in this application can also be applied to Figure 2 The implementation environment shown in the figure includes a target interactive device 110 and a server 120, and the target interactive device 110 and the server 120 can communicate with each other through a communication network 130. The communication network 130 uses standard communication technology and / or protocols, usually the Internet, but can also be any network, including but not limited to Bluetooth, local area network (LAN), metropolitan area network (MAN), wide area network (WAN), mobile, dedicated network or any combination of virtual private networks. In some embodiments, customized or dedicated data communication technology can be used to replace or supplement the above data communication technology.
[0105] The server 120 involved in the present application can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence (AI) platforms.
[0106] It should be noted that Figure 2 The environment shown is described by taking the configuration of the scene recognition model deployed on the server 120 as an example. In some embodiments, the configuration of the scene recognition model can also be deployed on the target interaction device 110. In some embodiments, part of the configuration of the scene recognition model is deployed on the target interaction device 110, and part of the configuration is deployed on the server 120.
[0107] Combination Figure 2In the implementation environment shown, in step B1, the target interaction device 110 calls the image acquisition device to capture the image to be identified from the external environment. In step B2, the target interaction device 110 sends the image to be identified to the server 120 through the communication network 130. In step B3, the server 120 calls the scene recognition model to identify the image to be identified, thereby obtaining a scene recognition result. In step B4, the server 120 generates a corresponding motion detection result based on the scene recognition result. In step B5, the target interaction device sends the motion detection result to the target interaction device 110 through the communication network 130. In step B6, the target interaction device 110 triggers a prompt operation when it is determined that movement has occurred based on the motion detection result.
[0108] Combined with the above introduction, the following will introduce the device movement detection method in this application, please refer to Figure 3 In the embodiment of the present application, the device movement detection method can be completed independently by the target interactive device, or can be completed by the target interactive device in cooperation with the server. The method of the present application includes:
[0109] 210. Calling an image acquisition device of a target interactive device to acquire an image to be recognized, wherein the image to be recognized is an image acquired at a target time;
[0110] In one or more embodiments, the target interactive device has a built-in image acquisition device (e.g., a color camera), or the target interactive device has an external image acquisition device. Based on this, the target interactive device calls the image acquisition device to capture an image or video, and uses the image captured at the target time as the image to be recognized. Among them, the "target interactive device" in this application refers to a certain "interactive device".
[0111] It should be noted that the target time can be the current time or a certain time point. For example, if an image is collected every hour, the target time is the hour closest to the current time.
[0112] Specifically, for ease of understanding, see Figure 4 , Figure 4 This is a schematic diagram of a top view of the target interaction device in the embodiment of the present application. As shown in the figure, the target interaction device is a palm-swiping device as an example, where C1 is used to indicate an image acquisition device. It can be understood that in actual applications, the palm-swiping device can also perform identity authentication and payment authorization by scanning the texture and pattern of the user's palm.
[0113] 220. Recognize the image to be recognized by using a scene recognition model to obtain a scene recognition result of the image to be recognized, wherein the scene recognition model is obtained by training based on N sample images, the N sample images are acquired by an image acquisition device of a target interactive device before a target time, and N is an integer greater than 1;
[0114] In one or more embodiments, the image to be recognized is used as the input of the scene recognition model, and the scene recognition model outputs the scene recognition result, wherein the scene recognition result may be "belonging to the same scene" or "belonging to different scenes".
[0115] Specifically, the scene recognition model has a one-to-one correspondence with the target interactive device, that is, the image acquisition device of the target interactive device needs to capture the environment image as a sample image in advance (that is, before the target moment), and the scene recognition model is trained using N sample images. Therefore, different scene recognition models will be trained based on different interactive devices. For ease of understanding, please refer to Table 1, which is an illustration of the relationship between the scene recognition model and the interactive object.
[0116] Table 1
[0117] Scene Recognition Model Interactive devices Scene Recognition Model A Interactive device A Scene Recognition Model B Interactive device B Scene Recognition Model C Interactive Device C Scene Recognition Model D Interactive Device D
[0118] Among them, assuming that the target interactive device is "interactive device A", then the scene recognition model it uses should be "scene recognition model A".
[0119] 230. Determine a movement detection result of the target interactive device according to the scene recognition result of the image to be recognized, wherein the movement detection result is used to indicate the movement of the target interactive device, and trigger a prompt operation when the movement detection result indicates that the target interactive device has moved.
[0120] In one or more embodiments, if the scene recognition result is "belonging to the same scene", the movement detection result of the target interactive device is determined to be "no movement", that is, the movement detection result indicates that the target interactive device has not moved at the target time. If the scene recognition result is "belonging to a different scene", the movement detection result of the target interactive device is determined to be "moved", that is, the movement detection result indicates that the target interactive device has moved at the target time.
[0121] Specifically, when the motion detection result indicates that the target interactive device has moved, a prompt operation needs to be triggered. Exemplarily, the prompt operation can be to send a text message or email to relevant personnel. Exemplarily, the prompt operation can also be to display an alarm message on the interface of the target interactive device. In addition, when the target interactive device is detected to have moved, the latest geographic location information of the target interactive device needs to be recorded for continued management and positioning.
[0122] In an embodiment of the present application, a method for detecting the movement of a device is provided. In the above manner, the image acquisition device of the interactive device is used to acquire images of the surrounding scene, and then the scene recognition is performed on the acquired image based on the image recognition technology, so that it is possible to finely judge whether the interactive device has moved. In this way, inaccurate device positioning in certain scenarios is avoided, thereby improving the accuracy of the movement detection results. Based on this, by detecting the movement of the interactive device, abnormal conditions of the device can be discovered in time, thereby improving the service quality. In addition, the movement detection of the interactive device is performed automatically, thereby avoiding the tediousness and inaccuracy of manual inspections and improving management efficiency. In addition, by detecting the movement of the interactive device, transaction failures or delays caused by device movement can be avoided, thereby improving the user experience.
[0123] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, before the scene recognition result of the image to be recognized is obtained by recognizing the image to be recognized through the scene recognition model, the following may also be included:
[0124] Calling the image acquisition device of the target interactive device to obtain N sample images;
[0125] Obtaining a scene label corresponding to each sample image in the N sample images, wherein the scene label is an initial scene label or a non-initial scene label;
[0126] Based on N sample images, the scene prediction result corresponding to each sample image is obtained through the scene recognition model to be trained;
[0127] The scene label corresponding to each sample image and the scene prediction result are used to update the model parameters of the scene recognition model to be trained until the model training conditions are met to obtain the scene recognition model, wherein the scene recognition model is used to recognize images collected by the target interactive device.
[0128] In one or more embodiments, a method for training a scene recognition model is introduced. As can be seen from the aforementioned embodiments, the target interaction device takes photos or videos of the surrounding scene by calling the image acquisition device, thereby obtaining N sample images. Based on this, the target interaction device can also use the collected N sample images to perform model training locally. Among them, the target interaction device can use an open source machine learning framework (TensorFlow) when training.
[0129] Specifically, after the target interactive device is deployed in the offline environment, a scene image can be taken as a sample image by using an image acquisition device every X minutes (for example, 5 minutes) until N sample images (for example, 1000 sample images) are obtained. In one implementation, a portion of the sample images (for example, 800 sample images) can be used as a training set, and the remaining sample images (for example, 200 sample images) can be used as a test set. In another implementation, all sample images (for example, 1000 sample images) can be used as a training set.
[0130] Each sample image among the N sample images needs to be labeled. If the sample image belongs to the image of the native scene, it can be labeled as "1", that is, it indicates that the sample image corresponds to the initial scene label. The native scene refers to the initial scene when the target interactive device is deployed offline. If the non-sample image belongs to the image of the native scene, it can be labeled as "0", that is, it indicates that the sample image corresponds to the non-initial scene label. The non-native scene refers to the non-initial scene when the target interactive device is deployed offline (for example, the scene corresponding to the target interactive device after it has been moved).
[0131] After the model is built, the target interactive device uses N sample images as the input of the scene recognition model to be trained, and outputs the scene prediction results corresponding to each sample image through the scene recognition model to be trained. Based on this, the matching (fit) method in TensorFlow's open source artificial neural network library (tf.keras) can be used for model training. Thus, the scene label corresponding to each sample image is used as the "true value", and the scene prediction result is used as the "prediction value", and the model parameters of the scene recognition model to be trained are optimized using the loss function. It is understandable that the present application can select different optimization algorithms, such as stochastic gradient descent (SGD) or adaptive momentum (Adam) optimization algorithm. By adjusting the parameters of the model until the model training conditions are met, a scene recognition model is obtained. Thus, the scene recognition model can be stored in the target interactive device.
[0132] It should be noted that, in one case, the exhaustion criterion can be used as the basis for determining whether the model training conditions are met, for example, a threshold of the number of iterations is set, and when the number of iterations reaches the threshold of the number of iterations, it means that the model training conditions have been met. In another case, the observation criterion can be used as the basis for determining whether the model training conditions are met, for example, when the loss value has converged, it means that the model training conditions have been met.
[0133] After the scene recognition model is trained, one implementation method is to directly put the scene recognition model online. Another implementation method is to evaluate the scene recognition model using a test set or a validation set to determine the accuracy and generalization ability of the scene recognition model. Among them, the validation set is a portion of sample images randomly selected from N sample images. Specifically, the evaluate method in tf.keras can be used to evaluate the model, and the evaluation indicators include but are not limited to accuracy, precision, recall, F1 value, etc.
[0134] Secondly, in an embodiment of the present application, a method for training a scene recognition model is provided. Through the above method, the target interactive device can be trained locally based on the collected sample images to obtain a scene recognition model suitable for the target interactive device. As a result, the target interactive device can perform scene recognition by calling the scene recognition model stored locally, thereby saving data transmission time and improving scene recognition efficiency.
[0135] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, before the scene recognition result of the image to be recognized is obtained by recognizing the image to be recognized through the scene recognition model, the following may also be included:
[0136] Calling the image acquisition device of the target interactive device to obtain N sample images;
[0137] Send N sample images to the server;
[0138] The server is used to obtain a scene label corresponding to each sample image in the N sample images, where the scene label is an initial scene label or a non-initial scene label;
[0139] The server is used to obtain the scene prediction result corresponding to each sample image through the scene recognition model to be trained based on the N sample images;
[0140] The server is used to use the scene label and scene prediction result corresponding to each sample image to update the model parameters of the scene recognition model to be trained until the model training conditions are met to obtain the scene recognition model. The scene recognition model is used to recognize the images collected by the target interactive device.
[0141] In one or more embodiments, another method of training a scene recognition model is introduced. As can be seen from the above embodiments, the target interactive device takes photos or videos of the surrounding scene by calling the image acquisition device, thereby obtaining N sample images. Then, the N sample images are uploaded to the server, and the server uses the N sample images to train the model. Among them, the server can use an open source machine learning framework (TensorFlow) for server training.
[0142] Specifically, after the target interactive device is deployed in an offline environment, a scene image can be taken as a sample image by using an image acquisition device every X minutes (for example, 5 minutes). In one implementation, the target interactive device sends a sample image to the server each time it obtains a sample image. In another implementation, after the target interactive device obtains N sample images (for example, 1000 sample images), it continuously sends N sample images to the server.
[0143] It should be noted that the server stores the sample images uploaded by each interactive device separately. Based on this, after the server obtains N sample images for the target interactive device, it can perform model training. Among them, a part of the sample images (for example, 800 sample images) can be used as a training set, and the remaining sample images (for example, 200 sample images) can be used as a test set. In addition, some sample images (for example, 100 sample images) of other interactive devices can also be used as a test set to improve the accuracy of model training.
[0144] The server needs to label each sample image among the N sample images. If the sample image belongs to the local scene, it can be labeled as "1", that is, it means that the sample image corresponds to the initial scene label. If the non-sample image belongs to the local scene, it can be labeled as "0", that is, it means that the sample image corresponds to the non-initial scene label. In addition, sample images from other interactive devices are also labeled as "0".
[0145] After the model is built, the server uses N sample images as the input of the scene recognition model to be trained, and outputs the scene prediction results corresponding to each sample image through the scene recognition model to be trained. Based on this, the matching fit method in tf.keras can be used for model training. Thus, the scene label corresponding to each sample image is used as the "true value", and the scene prediction result is used as the "prediction value", and the model parameters of the scene recognition model to be trained are optimized using the loss function. It can be understood that different optimization algorithms can be selected in the present application, such as SGD or Adam optimization algorithms. By adjusting the parameters of the model until the model training conditions are met, a scene recognition model is obtained. Thus, the scene recognition model corresponding to the target interactive device can be stored in the server, and the server can also store scene recognition models corresponding to other interactive devices.
[0146] It should be noted that the exhaustion criterion or the observation criterion can be used as the basis for determining whether the model training conditions are met. In addition, after the scene recognition model is trained, one implementation method is to directly put the scene recognition model online. Another implementation method is to use a test set or a validation set to evaluate the scene recognition model, which will not be described here.
[0147] Secondly, in an embodiment of the present application, another method for training a scene recognition model is provided. Through the above method, the server can be trained based on the sample images collected by the target interactive device to obtain a scene recognition model suitable for the target interactive device. Thus, the server can perform scene recognition on the image uploaded by the target interactive device by calling the scene recognition model. Since there is no need to store the scene recognition model on the interactive device side, not only the storage resources of the interactive device can be saved, but also the data processing cost of the interactive device can be saved.
[0148] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, obtaining the scene label corresponding to each sample image in the N sample images may specifically include:
[0149] Obtaining a standard sample image from the N sample images, wherein the standard sample image is the first frame image collected from the N sample images;
[0150] Determine the scene label corresponding to the standard sample image as the initial scene label;
[0151] Extract feature points from each of the N sample images to obtain a set of feature points corresponding to each sample image;
[0152] Compare the feature point set corresponding to each sample image in the (N-1) sample images with the feature point set corresponding to the standard sample image, wherein the (N-1) sample images are the sample images remaining after removing the standard sample image from the N sample images;
[0153] If the feature point offset between the feature point set corresponding to the sample image and the feature point set corresponding to the standard sample image is greater than the offset threshold, the scene label corresponding to the sample image is determined as a non-initial scene label;
[0154] If the feature point offset between the feature point set corresponding to the sample image and the feature point set corresponding to the standard sample image is less than or equal to the offset threshold, the scene label corresponding to the sample image is determined as the initial scene label.
[0155] In one or more embodiments, a method for obtaining a scene label is introduced. As can be seen from the foregoing embodiments, N sample images need to be labeled separately, for example, sample images belonging to a native scene are set to "1", that is, the initial scene label, and sample images belonging to a non-native scene are set to "0", that is, the non-initial scene label.
[0156] Specifically, the N sample images are collected in chronological order, so the earliest collected sample image (i.e., the first frame image) can be used as the standard sample image, and the label of the standard sample image can be used as the initial scene label and set to "1". Based on this, the feature points in each sample image can be extracted respectively to obtain the feature point set corresponding to each sample image.
[0157] For ease of introduction, see Figure 5 , Figure 5 This is a schematic diagram of automatically labeling a sample image in an embodiment of the present application. Assume Figure 5 The figure (A) shows a standard sample image, wherein D11 is used to indicate the first feature point in the standard sample image, D12 is used to indicate the second feature point in the standard sample image, D13 is used to indicate the third feature point in the standard sample image, and D14 is used to indicate the fourth feature point in the standard sample image. Figure 5 The figure (B) shows a sample image, in which D21 is used to indicate the first feature point in the sample image, D22 is used to indicate the second feature point in the sample image, D23 is used to indicate the third feature point in the sample image, and D24 is used to indicate the fourth feature point in the sample image.
[0158] The first feature point indicated by D11 is matched with the first feature point indicated by D21, and the offset between the two first feature points is calculated, thereby obtaining "Offset 1". The second feature point indicated by D12 is matched with the second feature point indicated by D22, and the offset between the two second feature points is calculated, thereby obtaining "Offset 2". The second feature point indicated by D13 is matched with the third feature point indicated by D23, and the offset between the two third feature points is calculated, thereby obtaining "Offset 3". The fourth feature point indicated by D14 is matched with the fourth feature point indicated by D24, and the offset between the two fourth feature points is calculated, thereby obtaining "Offset 4".
[0159] Based on this, the average of "Offset 1", "Offset 2", "Offset 3" and "Offset 4" is calculated to obtain the feature point offset between the sample image and the standard sample image. If the feature point offset is greater than the offset threshold, it means that the sample image has a large offset compared to the standard sample image. Therefore, the scene label corresponding to the sample image is determined as a non-initial scene label. If the feature point offset is less than or equal to the offset threshold, the scene label corresponding to the sample image is determined as the initial scene label.
[0160] Again, in the embodiment of the present application, a method for obtaining scene labels is provided. Through the above method, for the N sample images collected, after marking the first frame image, the user can automatically complete the image annotation by matching feature points, thereby improving the annotation efficiency.
[0161] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, obtaining the scene label corresponding to each sample image in the N sample images may specifically include:
[0162] Display N sample images;
[0163] In response to the labeling operation for each sample image, a scene label corresponding to each sample image is obtained.
[0164] In one or more embodiments, another method of obtaining a scene label is introduced. As can be seen from the foregoing embodiments, it is necessary to label the N sample images separately, for example, setting the sample images belonging to the native scene to "1", that is, the initial scene label, and setting the sample images belonging to the non-native scene to "0", that is, the non-initial scene label.
[0165] Specifically, the N sample images are collected in chronological order. Therefore, the earliest collected sample image (i.e., the first frame image) can be used as the standard sample image, and the label of the standard sample image can be used as the initial scene label and set to "1". For ease of understanding, please refer to Figure 6 , Figure 6 FIG. 1 is a schematic diagram of manually annotating a sample image in an embodiment of the present application. Figure 6 As shown in Figure (A), assuming that a sample image belongs to an image of the local scene, the first annotation control indicated by E1 can be clicked, thereby triggering a annotation operation in response to the sample image, that is, obtaining the scene label corresponding to the sample image as the "initial scene label", and the initial scene label can be set to "1".
[0166] like Figure 6 As shown in Figure (B), assuming that a sample image belongs to a non-native scene, the second annotation control indicated by E2 can be clicked to trigger an annotation operation in response to the sample image, that is, the scene label corresponding to the sample image is obtained as a "non-initial scene label", and the non-initial scene label can be set to "0".
[0167] Again, in the embodiment of the present application, another method for obtaining scene labels is provided. In the above method, for the N sample images collected, the user can label each sample image separately, thereby obtaining higher quality data.
[0168] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, another optional embodiment provided by the embodiment of the present application may further include:
[0169] In the case where the scene labels corresponding to the N sample images are all initial scene labels, M sample images are obtained, wherein the scene label of each sample image in the M sample images is a non-initial scene label, the M sample images are images collected by other interactive devices, or the M sample images are pre-constructed images, and M is an integer greater than 1;
[0170] Based on N sample images, the scene prediction result corresponding to each sample image is obtained through the scene recognition model to be trained, which may specifically include:
[0171] Based on the N sample images and the M sample images, a scene prediction result corresponding to each sample image in the (N+M) sample images is obtained through the scene recognition model to be trained;
[0172] The scene label and the scene prediction result corresponding to each sample image are used to update the model parameters of the scene recognition model to be trained until the model training conditions are met to obtain the scene recognition model, which may specifically include:
[0173] The scene label corresponding to each sample image in the (N+M) sample images and the scene prediction result are used to update the model parameters of the scene recognition model to be trained until the model training conditions are met, thereby obtaining a scene recognition model.
[0174] In one or more embodiments, a method of introducing negative sample images for model training is introduced. It can be seen from the aforementioned embodiments that the N sample images acquired by the target interactive device through the image acquisition device may all belong to the local scene. Based on this, in order to improve the generalization ability of the model, M sample images belonging to non-local scenes can also be introduced for training together. The following will introduce two methods of introducing M sample images with examples.
[0175] Method 1: Use pre-built sample images;
[0176] Some images are added in advance as M sample images. The M sample images can be images crawled from web pages, or images taken by staff, or images extracted from search libraries. These M sample images are all marked with non-initial scene labels.
[0177] For example, if the model training is performed on the target interactive device side, in one case, the M sample images can be stored in the target interactive device. In another case, the M sample images can be stored in the server, and the target interactive device requests the server to send the M sample images. If the model training is performed on the server side, the M sample images are directly stored in the server.
[0178] Method 2: Sample images collected using other interactive devices;
[0179] For the target interaction device, one or more sample images collected by other interactions may be used as M sample images, wherein the M sample images are all marked as non-initial scene labels.
[0180] For example, if the model training is performed on the target interactive device side, the target interactive device requests the server to send M sample images, that is, the server can separately store sample images from different interactive devices. If the model training is performed on the server side, the M sample images are directly stored in the server.
[0181] Specifically, after obtaining N sample images and M sample images, the scene recognition model can be trained. It should be noted that the network structure of the scene recognition model can adopt convolutional neural networks (CNN), or visual geometry group network (VGG), or residual network (ResNet), or initial network (Inception), or a custom network structure. The following is an example of the model structure of the scene recognition model using CNN built with tf.keras as an example.
[0182] When building a model, you need to define the model's input layer, convolution layer, pooling layer, and fully connected layer. You can use techniques such as dropout and batch normalization to prevent overfitting.
[0183] For easier understanding, see Figure 7 , Figure 7 A network structure diagram of the scene recognition model in the embodiment of the present application, as shown in the figure, the core of the CNN model is the convolution layer and the downsampling layer (i.e., the pooling layer). The convolution layer extracts the features of the image through the convolution operation, and the downsampling layer reduces the dimension of the features through the downsampling operation, thereby reducing the amount of calculation and the amount of parameters. After the convolution layer and the downsampling layer, a fully connected layer and an activation function are usually added to perform tasks such as classification tasks or regression. For image recognition tasks, the CNN model usually adopts a structure of multi-layer convolution layers and downsampling layers to extract the multi-level features of the image.
[0184] During the training process, the CNN model updates the model parameters through the back propagation algorithm to minimize the loss function. For example, (N+M) sample images are used as the input of the scene recognition model to be trained, and the scene prediction result corresponding to each sample image is output through the scene recognition model to be trained. Then, the model parameters of the scene recognition model to be trained are updated using the loss value between the scene label corresponding to each sample image and the scene prediction result. During the testing process, the CNN model predicts through the forward propagation algorithm and outputs the category or probability distribution of the image.
[0185] The convolution layer enhances the input signal and reduces the noise through convolution operation. The input of the convolution layer is connected to the receptive field of the upper layer to extract features and obtain the positional relationship with other features. The feature calculation method of the convolution layer output is:
[0186]
[0187] Among them, “*” represents the convolution operation. Represents the output of the j-th neuron in the l-th layer after convolution operation. Represents the output of the i-th neuron in the (l-1)-th layer, that is, the input data of the l-th layer. Represents the filter parameters of the i-th and j-th neurons in layer l. represents the bias value of the jth neuron. f(·) represents a nonlinear activation function, such as the sigmoid function, the hyperbolic tangent function (tanh) function, and the rectified linear unit function. The ReLU function trains the CNN model quickly and with higher accuracy.
[0188] The downsampling layer is also called the pooling layer. There is a downsampling layer after each convolution layer in the CNN model. Because the amount of feature data obtained by the convolution layer is too large, if it is directly used for training, it will increase the complexity of the network model. Therefore, the dimension of the feature can be reduced by pooling the local features. At the same time, pooling can improve the overfitting problem of the convolutional neural network to a certain extent. After two feature extractions, the network can have a strong tolerance for input distortion.
[0189] Again, in an embodiment of the present application, a method of introducing negative sample images for model training is provided. Through the above method, if the collected sample images are all positive samples (i.e., image samples with scene labels that are initial scene labels), the accuracy and generalization ability of the model can be improved by introducing negative samples (i.e., image samples with scene labels that are not initial scene labels), thereby obtaining better model performance.
[0190] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, the scene prediction result is a scene prediction probability distribution;
[0191] Based on N sample images, the scene prediction result corresponding to each sample image is obtained through the scene recognition model to be trained, which may specifically include:
[0192] Based on N sample images, the scene prediction probability distribution corresponding to each sample image is obtained through the scene recognition model to be trained, wherein the scene prediction probability distribution includes the probability that the sample image belongs to the initial scene label and the probability of the non-initial scene label.
[0193] In one or more embodiments, a method for implementing model training based on a classification task is introduced. It can be seen from the aforementioned embodiments that during the model training process, the scene recognition model to be trained can output the scene prediction probability distribution corresponding to each sample image. It can be understood that, in another case, the scene recognition model to be trained can also output the scene prediction probability value corresponding to each sample image. Exemplarily, when the scene prediction probability value is "1", it means that the sample image is predicted to be an initial scene label. When the scene prediction probability value is "0", it means that the sample image is predicted to be a non-initial scene label.
[0194] Specifically, assume that the scene prediction probability distribution is expressed as (a, b), where a represents the probability that the sample image belongs to the initial scene label, b represents the probability that the sample image belongs to the non-initial scene label, and a+b=1. Based on this, the following loss function can be used to calculate the loss value:
[0195]
[0196] Where L1 represents the loss value. N represents the total number of sample images. i represents the i-th sample image. M represents the total number of label categories. c represents the label of the c-th category. y ic represents the scene label of the i-th sample image, for example, the initial scene label is 1 and the non-initial scene label is 0. ic It represents the probability that the i-th sample image is predicted to be the c-th category label. For example, the probability that the i-th sample image is predicted to be the initial scene label is 0.8, and the probability that it is predicted to be the non-initial scene label is 0.2.
[0197] Again, in the embodiment of the present application, a method for implementing model training based on classification tasks is provided. Through the above method, the scene prediction result is defined as the scene prediction probability distribution, that is, the prediction of discrete values can be achieved based on the scene prediction probability distribution. Therefore, by using the scene prediction probability distribution and scene labels corresponding to the sample images, the model parameters can be optimized to improve the accuracy of the model for scene classification.
[0198] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, the scene recognition result of the image to be recognized is obtained by recognizing the image to be recognized through the scene recognition model, which may specifically include:
[0199] The image to be identified is identified by a scene recognition model to obtain a scene probability distribution of the image to be identified, wherein the scene probability distribution includes the probability that the image to be identified belongs to an initial scene label and the probability that the image to be identified belongs to a non-initial scene label;
[0200] According to the scene probability distribution of the image to be recognized, the scene recognition result of the image to be recognized is determined.
[0201] In one or more embodiments, a method for predicting scene recognition results based on a classification task is introduced. It can be seen from the aforementioned embodiments that during the model application process, the scene recognition model can output the scene probability distribution corresponding to each sample image. The scene probability distribution is expressed as (a, b), where a represents the probability that the image to be recognized belongs to the initial scene label, b represents the probability that the image to be recognized belongs to the non-initial scene label, and a+b=1.
[0202] Specifically, the image to be identified is used as the input of the scene recognition model, and the scene recognition model outputs the scene probability distribution. Assuming that the scene probability distribution is (0.8, 0.2), it means that the probability that the image to be identified belongs to the initial scene label is 0.8, and the probability that the image to be identified belongs to the non-initial scene label is 0.2. Therefore, the category label with the highest probability can be selected as the label of the image to be identified. For example, if the label of the image to be identified is "initial scene label", the scene recognition result of the image to be identified is "belonging to the same scene". For another example, if the label of the image to be identified is "non-initial scene label", the scene recognition result of the image to be identified is "belonging to different scenes".
[0203] Furthermore, in an embodiment of the present application, a method for predicting scene recognition results based on a classification task is provided. Through the above method, the scene recognition result is defined as a scene probability distribution, that is, the prediction of discrete values can be achieved based on the scene probability distribution, so that the scene recognition result of the image to be recognized can be directly determined.
[0204] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, the scene prediction result is a scene prediction score;
[0205] Based on N sample images, the scene prediction result corresponding to each sample image is obtained through the scene recognition model to be trained, which may specifically include:
[0206] Based on N sample images, the scene prediction score corresponding to each sample image is obtained through the scene recognition model to be trained, wherein the scene prediction score represents the probability that the sample image belongs to the initial scene label.
[0207] In one or more embodiments, a method for implementing model training based on regression tasks is introduced. As can be seen from the above embodiments, during the model training process, the scene recognition model to be trained can output the scene prediction score corresponding to each sample image.
[0208] Specifically, the scene prediction score is represented as x, where x represents the probability that the sample image belongs to the initial scene label, and the value range of x is greater than or equal to 0 and less than or equal to 1. Based on this, the following loss function can be used to calculate the loss value:
[0209]
[0210] Where L2 represents the loss value. N represents the total number of sample images. i represents the i-th sample image. y i represents the true probability that the i-th sample image belongs to the initial scene label. Assuming that the i-th sample image belongs to the initial scene label, then y i is 1, assuming that the i-th sample image belongs to a non-initial scene label, then y i is 0. f(x i ) represents the probability that the i-th sample image is predicted to be the initial scene label.
[0211] Again, in the embodiment of the present application, a method for implementing model training based on regression tasks is provided. Through the above method, the scene prediction result is defined as a scene prediction score, that is, the prediction of continuous values can be achieved based on the scene prediction score. Therefore, the scene prediction score and scene label corresponding to the sample image can be used to optimize the model parameters and improve the accuracy of the model for scene recognition.
[0212] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, the scene recognition result of the image to be recognized is obtained by recognizing the image to be recognized through the scene recognition model, which may specifically include:
[0213] The image to be identified is identified by the scene recognition model to obtain a scene score of the image to be identified, wherein the scene score represents the probability that the image to be identified belongs to the initial scene label;
[0214] According to the scene score of the image to be identified, a scene identification result of the image to be identified is determined.
[0215] In one or more embodiments, a method for predicting scene recognition results based on a regression task is introduced. As can be seen from the aforementioned embodiments, during the model application process, the scene recognition model can output a scene score corresponding to each sample image. The scene score is represented as x, where x represents the probability that the image to be recognized belongs to the initial scene label, and the value range of x is greater than or equal to 0 and less than or equal to 1.
[0216] Specifically, the image to be identified is used as the input of the scene recognition model, and the scene recognition model outputs the scene score. Assuming that the scene score is 0.8, it means that the probability that the image to be identified belongs to the initial scene label is 0.8. If the scene score is greater than or equal to the score threshold (for example, 0.7), the label of the image to be identified is determined to be the "initial scene label", that is, the scene recognition result of the image to be identified is "belonging to the same scene". If the scene score is less than the score threshold (for example, 0.7), the label of the image to be identified is determined to be the "non-initial scene label", that is, the scene recognition result of the image to be identified is "belonging to a different scene".
[0217] Furthermore, in an embodiment of the present application, a method for predicting scene recognition results based on a regression task is provided. Through the above method, the scene recognition result is defined as a scene score, that is, the prediction of continuous values can be achieved based on the scene score, so that the scene recognition result of the image to be recognized can be directly determined.
[0218] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, before calling the image acquisition device of the target interactive device to obtain the image to be recognized, the following may also be included:
[0219] When the first location information of the target interactive device is obtained, determining the longitude change value and the latitude change value according to the first location information and the initial location information of the target interactive device, wherein the first location information is obtained according to a global positioning system GPS chip built into the target interactive device;
[0220] If the longitude change value or the latitude change value is greater than or equal to the change threshold, it is determined that the target interactive device has moved;
[0221] If the longitude change value or the latitude change value is less than the change threshold, the step of calling the image acquisition device of the target interactive device to obtain the image to be identified is executed.
[0222] In one or more embodiments, a method for detecting geographic location based on GPS positioning technology is introduced. As can be seen from the aforementioned embodiments, a GPS chip can be built into the target interactive device, so that the geographic location information (i.e., including longitude information and latitude information) of the target interactive device can be obtained through satellite signals, thereby determining whether the target interactive device is moving.
[0223] Specifically, when the target interactive device is deployed in an offline environment, the initial location information can be determined through the GPS chip, that is, the initial longitude information and the initial latitude information are obtained. The latest location information of the target interactive device is obtained through the GPS chip at intervals (for example, 5 minutes), that is, the first location information of the target interactive device is obtained. Based on this, the longitude information in the first location information is subtracted from the longitude information in the initial location information, and the absolute value of the difference is used as the longitude change value. The latitude information in the first location information is subtracted from the latitude information in the initial location information, and the absolute value of the difference is used as the latitude change value.
[0224] If the longitude change value or the latitude change value is greater than or equal to the change threshold, it is considered that the target interactive device has moved, and thus a prompt operation is triggered.
[0225] If the longitude change value or the latitude change value is less than the change threshold, it is necessary to use image recognition technology to continue to determine whether the target interactive device has moved.
[0226] Secondly, in the embodiment of the present application, a method for detecting geographic location based on GPS positioning technology is provided. Through the above method, it is possible to obtain highly accurate geographic location information, thereby using a method combining geographic location detection and scene recognition to more accurately determine whether the interactive device has moved.
[0227] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, before calling the image acquisition device of the target interactive device to obtain the image to be recognized, the following may also be included:
[0228] When the second location information of the target interactive device is obtained, determining the longitude change value and the latitude change value according to the second location information and the initial location information of the target interactive device, wherein the second location information is obtained by connecting the target interactive device to the base station;
[0229] If the longitude change value or the latitude change value is greater than or equal to the change threshold, it is determined that the target interactive device has moved;
[0230] If the longitude change value or the latitude change value is less than the change threshold, the step of calling the image acquisition device of the target interactive device to obtain the image to be identified is executed.
[0231] In one or more embodiments, a method for detecting geographic location based on base station positioning technology is provided. As can be seen from the above embodiments, if the geographic location information cannot be obtained using a GPS chip, the geographic location information (i.e., including longitude information and latitude information) of the target interactive device can also be obtained through base station positioning technology, thereby determining whether the target interactive device is moving.
[0232] Specifically, when the target interactive device is deployed in an offline environment, the initial location information can be determined by connecting to the base station, that is, the initial longitude information and initial latitude information are obtained. The latest location information of the target interactive device is obtained at intervals (for example, 5 minutes), that is, the second location information of the target interactive device is obtained.
[0233] It is understandable that there are many ways to obtain the second location information using the base station. For example, the geographic location information of the base station is queried through the base station identifier to which the target interactive device is connected, and then the geographic location information is used as the second location information of the target interactive device. For another example, if the target interactive device can only search for one base station, the second location information of the target interactive device can be approximately calculated based on the angle of arrival (AoA), time of arrival (ToA) and signal strength of the signal. For another example, when the target interactive device can be connected to three base stations, the distance from the base station to the target interactive device is calculated by the arrival time of the signal, and then the second location information of the target interactive device is calculated using geometric knowledge. In addition, other methods can be used to estimate the second location information of the target interactive device. This is only for illustration and should not be understood as a limitation on the present application.
[0234] Based on this, the longitude information in the second location information is subtracted from the longitude information in the initial location information, and the absolute value of the difference is used as the longitude change value. The latitude information in the second location information is subtracted from the latitude information in the initial location information, and the absolute value of the difference is used as the latitude change value.
[0235] If the longitude change value or the latitude change value is greater than or equal to the change threshold, it is considered that the target interactive device has moved, and thus a prompt operation is triggered.
[0236] If the longitude change value or the latitude change value is less than the change threshold, it is necessary to use image recognition technology to continue to determine whether the target interactive device has moved.
[0237] Secondly, in the embodiment of the present application, a method for detecting geographic location based on base station positioning technology is provided. Through the above method, the geographic location information of the interactive device can be obtained by using the base station transmission signal. On the one hand, it can be used both indoors and outdoors, and the positioning success rate is high. On the other hand, it is more convenient and the required cost is lower.
[0238] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, before calling the image acquisition device of the target interactive device to obtain the image to be recognized, the following may also be included:
[0239] When the third location information of the target interactive device is obtained, determining the longitude change value and the latitude change value according to the third location information and the initial location information of the target interactive device, wherein the third location information is obtained by connecting the target interactive device to a mobile hotspot;
[0240] If the longitude change value or the latitude change value is greater than or equal to the change threshold, it is determined that the target interactive device has moved;
[0241] If the longitude change value or the latitude change value is less than the change threshold, the step of calling the image acquisition device of the target interactive device to obtain the image to be identified is executed.
[0242] In one or more embodiments, a method for detecting geographic location based on wireless fidelity (WiFi) positioning technology is introduced. As can be seen from the above embodiments, if the geographic location information cannot be obtained through base station positioning technology, the geographic location information (i.e., including longitude information and latitude information) of the target interactive device can also be obtained based on WiFi positioning technology to determine whether the target interactive device is moving.
[0243] Specifically, when the target interactive device is deployed in an offline environment, the initial location information can be determined by connecting to the WiFi, that is, the initial longitude information and initial latitude information can be obtained. The latest location information of the target interactive device can be obtained at intervals (for example, 5 minutes), that is, the third location information of the target interactive device can be obtained.
[0244] It is understandable that the method of obtaining the third location information using WiFi can be to scan the WiFi hardware address (media access control address, MAC) near the target interactive device for positioning, and the target interactive device uploads the WiFi MAC address to the server. The server analyzes the geographical location information corresponding to the MAC address, that is, obtains the third location information of the target interactive device.
[0245] Based on this, the longitude information in the third position information is subtracted from the longitude information in the initial position information, and the absolute value of the difference is used as the longitude change value. The latitude information in the third position information is subtracted from the latitude information in the initial position information, and the absolute value of the difference is used as the latitude change value.
[0246] If the longitude change value or the latitude change value is greater than or equal to the change threshold, it is considered that the target interactive device has moved, and thus a prompt operation is triggered.
[0247] If the longitude change value or the latitude change value is less than the change threshold, it is necessary to use image recognition technology to continue to determine whether the target interactive device has moved.
[0248] Secondly, in the embodiment of the present application, a method for detecting geographic location based on WiFi positioning technology is provided. Through the above method, positioning using WiFi can obtain high-precision geographic location information, and no additional hardware equipment is required, so the cost is low and easy to deploy. In addition, WiFi positioning can also be used in combination with other positioning technologies, such as GPS or Bluetooth, so as to improve the accuracy and reliability of positioning.
[0249] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, before calling the image acquisition device of the target interactive device to obtain the image to be recognized, the following may also be included:
[0250] When the fourth location information of the target interactive device is obtained, determining the longitude change value and the latitude change value according to the fourth location information and the initial location information of the target interactive device, wherein the fourth location information is obtained by connecting the target interactive device to the Bluetooth device;
[0251] If the longitude change value or the latitude change value is greater than or equal to the change threshold, it is determined that the target interactive device has moved;
[0252] If the longitude change value or the latitude change value is less than the change threshold, the step of calling the image acquisition device of the target interactive device to obtain the image to be identified is executed.
[0253] In one or more embodiments, a method for detecting geographic location based on Bluetooth positioning technology is introduced. As can be seen from the above embodiments, if the geographic location information cannot be obtained through WiFi positioning technology, the geographic location information (i.e., including longitude information and latitude information) of the target interactive device can also be obtained based on Bluetooth positioning technology to determine whether the target interactive device is moving.
[0254] Specifically, when the target interactive device is deployed in an offline environment, the initial location information can be determined by the connected Bluetooth device, that is, the initial longitude information and initial latitude information are obtained. The latest location information of the target interactive device is obtained at intervals (for example, 5 minutes), that is, the third location information of the target interactive device is obtained.
[0255] It is understandable that the method of obtaining the third location information using a Bluetooth device may be to first arrange a certain number of Bluetooth devices indoors, and the location coordinates of these Bluetooth devices are known. Then, the distance is estimated by measuring the signal strength. Among them, when a Bluetooth device is broadcasting, the farther the signal receiving end is from the transmitting end, the weaker the received signal strength indication (RSSI) field strength value; the closer the receiving end is to the transmitting end, the stronger the received RSSI field strength value.
[0256] Based on this, the longitude information in the fourth position information is subtracted from the longitude information in the initial position information, and the absolute value of the difference is used as the longitude change value. The latitude information in the fourth position information is subtracted from the latitude information in the initial position information, and the absolute value of the difference is used as the latitude change value.
[0257] If the longitude change value or the latitude change value is greater than or equal to the change threshold, it is considered that the target interactive device has moved, and thus a prompt operation is triggered.
[0258] If the longitude change value or the latitude change value is less than the change threshold, it is necessary to use image recognition technology to continue to determine whether the target interactive device has moved.
[0259] Secondly, in the embodiment of the present application, a method for detecting geographic location based on WiFi positioning technology is provided. Through the above method, positioning using WiFi can obtain high-precision geographic location information, and no additional hardware equipment is required, so the cost is low and easy to deploy. In addition, WiFi positioning can also be used in combination with other positioning technologies, such as GPS or Bluetooth, so as to improve the accuracy and reliability of positioning.
[0260] Secondly, in the embodiment of the present application, a method for detecting geographic location based on Bluetooth positioning technology is provided. Through the above method, positioning using Bluetooth can be used in environments such as indoors or high-rise buildings, and has high accuracy and reliability.
[0261] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, determining the movement detection result of the target interactive device according to the scene recognition result of the image to be recognized may specifically include:
[0262] When the scene recognition result of the image to be recognized indicates that the target interactive device is in the initial scene, acquiring an acceleration value of the target interactive device through an acceleration sensor built into the target interactive device;
[0263] If the acceleration value is greater than or equal to the acceleration threshold, it is determined that the target interactive device has moved;
[0264] If the acceleration value is less than the acceleration threshold, it is determined that the target interactive device has not moved.
[0265] In one or more embodiments, a method for detecting the movement of a device based on an acceleration sensor is introduced. It can be seen from the aforementioned embodiments that if the scene recognition result is "belonging to different scenes", it means that the target interaction device is not in the initial scene, and thus, it can be determined that the target interaction device has moved. If the scene recognition result is "belonging to the same scene", it means that the target interaction device is in the initial scene. Based on this, the movement of the target interaction device can be further judged in combination with the acceleration value of the target interaction device.
[0266] Specifically, an acceleration sensor is built into the target interactive device. Among them, the acceleration sensor is a sensor that can measure acceleration. It is usually composed of a mass block, a damper, an elastic element, a sensitive element, and an adaptive circuit. During the acceleration process, the acceleration sensor measures the inertial force on the mass block and uses Newton's second law to obtain the acceleration value. If the acceleration value is greater than or equal to the acceleration threshold, it is considered that the target interactive device has moved, so the prompt operation is triggered. If the longitude change value is less than the acceleration threshold, it is considered that the target interactive device has not moved.
[0267] Secondly, in the embodiment of the present application, a method for detecting the movement of a device based on an acceleration sensor is provided. Through the above method, if the scene recognition result indicates that the target interactive device is in the initial scene, the acceleration value of the target interactive device can also be used to continue to judge its movement, thereby further improving the accuracy of the movement detection result.
[0268] Optionally, in the above Figure 3 On the basis of the corresponding embodiments, in another optional embodiment provided by the embodiment of the present application, determining the movement detection result of the target interactive device according to the scene recognition result of the image to be recognized may specifically include:
[0269] When the scene recognition result of the image to be recognized indicates that the target interaction device is in the initial scene, obtaining the signal strength between the target interaction device and T wireless devices at the first moment, where T is an integer greater than or equal to 3;
[0270] According to the signal strength between the target interactive device and the T wireless devices, a target space model is constructed, wherein the target space model includes a position point corresponding to the target interactive device and a position point corresponding to each of the T wireless devices;
[0271] The movement detection result of the target interactive device is determined according to the target space model and the initial space model, wherein the initial space model is constructed based on the signal strength between the target interactive device and T wireless devices for a second moment, and the second moment occurs before the first moment.
[0272] In one or more embodiments, a method for detecting device movement based on radio signal strength is introduced. As can be seen from the aforementioned embodiments, if the scene recognition result is "belonging to different scenes", it means that the target interaction device is not in the initial scene, and thus, it can be determined that the target interaction device has moved. If the scene recognition result is "belonging to the same scene", it means that the target interaction device is in the initial scene. Based on this, the movement of the target interaction device can be further judged in combination with the change in signal strength between the target interaction device and the surrounding wireless devices.
[0273] It should be noted that the surrounding wireless devices include but are not limited to cash registers, point of sale (POS) terminals, etc., which are not limited here.
[0274] Specifically, for ease of understanding, see Figure 8 , Figure 8 is a schematic diagram of the initial space model and the target space model in the embodiment of the present application, such as Figure 8 As shown in Figure (A), take T wireless devices as 3 wireless devices as an example. When the target interaction device is deployed in an offline environment, an initial spatial model corresponding to the second moment (i.e., the initial moment) is constructed according to the signal strength between the target interaction device and the three wireless devices. F1 is used to indicate the spatial position of the target interaction device in the initial spatial model. F2 is used to indicate the spatial position of the first wireless device in the initial spatial model. F3 is used to indicate the spatial position of the second wireless device in the initial spatial model. F4 is used to indicate the spatial position of the third wireless device in the initial spatial model.
[0275] The signal strength between the target interactive device and the three wireless devices may be acquired at regular intervals (eg, 5 minutes), and a target space model corresponding to the first moment (ie, current moment) may be constructed based on the signal strength between the target interactive device and the three wireless devices.
[0276] like Figure 8As shown in Figure (B), F5 is used to indicate the spatial position of the target interactive device in the target space model. F6 is used to indicate the spatial position of the first wireless device in the target space model. F7 is used to indicate the spatial position of the second wireless device in the target space model. F8 is used to indicate the spatial position of the third wireless device in the target space model. It can be seen that compared with the initial space model, the target space model can detect that the distance between the target interactive device and one or more of the wireless devices has changed when the positions of the other three wireless devices have not changed. Therefore, it is considered that the target interactive device has moved.
[0277] Secondly, in the embodiment of the present application, a method for detecting device movement based on radio signal strength is provided. In the above method, if the scene recognition result indicates that the target interactive device is in the initial scene, the movement of the target interactive device can also be determined by detecting the change in signal strength between the target interactive device and surrounding wireless devices.
[0278] The following is a detailed description of the device movement detection device in this application. Fig. 9 , Fig. 9 This is a schematic diagram of an embodiment of a device movement detection device in an embodiment of the present application. The device movement detection device 30 includes:
[0279] An acquisition module 310 is used to call an image acquisition device of a target interactive device to acquire an image to be recognized, wherein the image to be recognized is an image acquired at a target time;
[0280] The recognition module 320 is used to recognize the image to be recognized by using a scene recognition model to obtain a scene recognition result of the image to be recognized, wherein the scene recognition model is obtained by training based on N sample images, and the N sample images are acquired by the image acquisition device of the target interactive device before the target time, and N is an integer greater than 1;
[0281] The detection module 330 is used to determine the movement detection result of the target interactive device according to the scene recognition result of the image to be identified, wherein the movement detection result is used to indicate the movement of the target interactive device, and trigger a prompt operation when the movement detection result indicates that the target interactive device has moved.
[0282] In an embodiment of the present application, a motion detection device is provided. The above-mentioned device uses the image acquisition device of the interactive device to capture images of the surrounding scene, and then performs scene recognition on the captured image based on the image recognition technology, so that it can be finely judged whether the interactive device has moved. In this way, inaccurate device positioning in certain scenarios is avoided, thereby improving the accuracy of the motion detection results. Based on this, by detecting the movement of the interactive device, abnormal conditions of the device can be discovered in time, thereby improving the service quality. And the movement detection of the interactive device is automatically performed, avoiding the tediousness and inaccuracy of manual inspections and improving management efficiency. In addition, by detecting the movement of the interactive device, transaction failures or delays caused by device movement can be avoided, thereby improving the user experience.
[0283] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application, the device movement detection device further includes a training module 340;
[0284] The acquisition module 310 is further used to recognize the image to be recognized by using the scene recognition model, and before obtaining the scene recognition result of the image to be recognized, call the image acquisition device of the target interactive device to obtain N sample images;
[0285] The acquisition module 310 is further used to acquire a scene label corresponding to each sample image in the N sample images, wherein the scene label is an initial scene label or a non-initial scene label;
[0286] The acquisition module 310 is further used to acquire the scene prediction result corresponding to each sample image through the scene recognition model to be trained based on the N sample images;
[0287] The training module 340 is used to use the scene label and scene prediction result corresponding to each sample image to update the model parameters of the scene recognition model to be trained until the model training conditions are met to obtain the scene recognition model, wherein the scene recognition model is used to recognize images collected by the target interactive device.
[0288] In an embodiment of the present application, a motion detection device is provided. With the above device, the target interactive device can be trained locally based on the collected sample images to obtain a scene recognition model suitable for the target interactive device. As a result, the target interactive device can perform scene recognition by calling the scene recognition model stored locally, thereby saving data transmission time and improving scene recognition efficiency.
[0289] Optionally, in the above Fig. 9On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application, the device movement detection device further includes a sending module 350;
[0290] The acquisition module 310 is further used to recognize the image to be recognized by using the scene recognition model, and before obtaining the scene recognition result of the image to be recognized, call the image acquisition device of the target interactive device to obtain N sample images;
[0291] A sending module 350, configured to send N sample images to a server;
[0292] The server is used to obtain a scene label corresponding to each sample image in the N sample images, where the scene label is an initial scene label or a non-initial scene label;
[0293] The server is used to obtain the scene prediction result corresponding to each sample image through the scene recognition model to be trained based on the N sample images;
[0294] The server is used to use the scene label and scene prediction result corresponding to each sample image to update the model parameters of the scene recognition model to be trained until the model training conditions are met to obtain the scene recognition model. The scene recognition model is used to recognize the images collected by the target interactive device.
[0295] In an embodiment of the present application, a motion detection device is provided. Using the above device, the server can be trained based on the sample images collected by the target interactive device to obtain a scene recognition model suitable for the target interactive device. Thus, the server can perform scene recognition on the image uploaded by the target interactive device by calling the scene recognition model. Since there is no need to store the scene recognition model on the interactive device side, not only the storage resources of the interactive device can be saved, but also the data processing cost of the interactive device can be saved.
[0296] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application,
[0297] The acquisition module 310 is specifically used to acquire a standard sample image from the N sample images, wherein the standard sample image is the first frame image collected from the N sample images;
[0298] Determine the scene label corresponding to the standard sample image as the initial scene label;
[0299] Extract feature points from each of the N sample images to obtain a set of feature points corresponding to each sample image;
[0300] Compare the feature point set corresponding to each sample image in the (N-1) sample images with the feature point set corresponding to the standard sample image, wherein the (N-1) sample images are the sample images remaining after removing the standard sample image from the N sample images;
[0301] If the feature point offset between the feature point set corresponding to the sample image and the feature point set corresponding to the standard sample image is greater than the offset threshold, the scene label corresponding to the sample image is determined as a non-initial scene label;
[0302] If the feature point offset between the feature point set corresponding to the sample image and the feature point set corresponding to the standard sample image is less than or equal to the offset threshold, the scene label corresponding to the sample image is determined as the initial scene label.
[0303] In an embodiment of the present application, a motion detection device is provided. With the above device, for the N sample images collected, after marking the first frame of the image, the user can automatically complete the image annotation by matching feature points, thereby improving the annotation efficiency.
[0304] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application,
[0305] An acquisition module 310 is specifically used to display N sample images;
[0306] In response to the labeling operation for each sample image, a scene label corresponding to each sample image is obtained.
[0307] In an embodiment of the present application, a motion detection device is provided. With the above device, for N sample images collected, the user can mark each sample image separately, thereby obtaining higher quality data.
[0308] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application,
[0309] The acquisition module 310 is further configured to acquire M sample images when the scene labels corresponding to the N sample images are all initial scene labels, wherein the scene label of each sample image in the M sample images is a non-initial scene label, the M sample images are images collected by other interactive devices, or the M sample images are pre-constructed images, and M is an integer greater than 1;
[0310] The acquisition module 310 is specifically used to acquire the scene prediction result corresponding to each sample image in the (N+M) sample images through the scene recognition model to be trained based on the N sample images and the M sample images;
[0311] The training module 340 is specifically used to use the scene label corresponding to each sample image in the (N+M) sample images and the scene prediction result to update the model parameters of the scene recognition model to be trained until the model training conditions are met to obtain the scene recognition model.
[0312] In an embodiment of the present application, a motion detection device is provided. Using the above device, if the sample images collected are all positive samples (i.e., image samples whose scene labels are initial scene labels), the accuracy and generalization ability of the model can be improved by introducing negative samples (i.e., image samples whose scene labels are non-initial scene labels), thereby obtaining better model performance.
[0313] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application, the scene prediction result is a scene prediction probability distribution;
[0314] The acquisition module 310 is specifically used to obtain the scene prediction probability distribution corresponding to each sample image based on N sample images through the scene recognition model to be trained, wherein the scene prediction probability distribution includes the probability that the sample image belongs to the initial scene label and the probability of the non-initial scene label.
[0315] In an embodiment of the present application, a motion detection device is provided. Using the above device, the scene prediction result is defined as the scene prediction probability distribution, that is, the prediction of discrete values can be achieved based on the scene prediction probability distribution. Therefore, by using the scene prediction probability distribution and scene label corresponding to the sample image, the model parameters can be optimized to improve the accuracy of the model for scene classification.
[0316] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application,
[0317] The acquisition module 310 is specifically used to identify the image to be identified by using the scene recognition model to obtain the scene probability distribution of the image to be identified, wherein the scene probability distribution includes the probability that the image to be identified belongs to the initial scene label and the probability that it belongs to the non-initial scene label;
[0318] According to the scene probability distribution of the image to be recognized, the scene recognition result of the image to be recognized is determined.
[0319] In an embodiment of the present application, a motion detection device is provided. Using the above device, the scene recognition result is defined as a scene probability distribution, that is, the discrete value can be predicted based on the scene probability distribution, so that the scene recognition result of the image to be recognized can be directly determined.
[0320] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection apparatus 30 provided in the embodiment of the present application, the scene prediction result is a scene prediction score;
[0321] The acquisition module 310 is specifically used to acquire the scene prediction score corresponding to each sample image through the scene recognition model to be trained based on N sample images, wherein the scene prediction score represents the probability that the sample image belongs to the initial scene label.
[0322] In an embodiment of the present application, a motion detection device is provided. Using the above device, the scene prediction result is defined as a scene prediction score, that is, the prediction of continuous values can be achieved based on the scene prediction score. Therefore, the scene prediction score and scene label corresponding to the sample image can be used to optimize the model parameters and improve the accuracy of the model for scene recognition.
[0323] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application,
[0324] The acquisition module 310 is specifically configured to recognize the image to be recognized by using a scene recognition model to obtain a scene score of the image to be recognized, wherein the scene score represents the probability that the image to be recognized belongs to the initial scene label;
[0325] According to the scene score of the image to be identified, a scene identification result of the image to be identified is determined.
[0326] In an embodiment of the present application, a motion detection device is provided. Using the above device, the scene recognition result is defined as a scene score, that is, the continuous value can be predicted based on the scene score, so that the scene recognition result of the image to be recognized can be directly determined.
[0327] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application, the device movement detection device further includes a determination module 360 and an execution module 370;
[0328] The determination module 360 is used to call the image acquisition device of the target interactive device to determine the longitude change value and the latitude change value according to the first position information of the target interactive device and the initial position information of the target interactive device before acquiring the image to be identified, wherein the first position information is acquired according to the global positioning system GPS chip built into the target interactive device;
[0329] The determination module 360 is further configured to determine that the target interactive device has moved if the longitude change value or the latitude change value is greater than or equal to the change threshold;
[0330] The execution module 370 is used to execute the step of calling the image acquisition device of the target interactive device to obtain the image to be identified if the longitude change value or the latitude change value is less than the change threshold.
[0331] In an embodiment of the present application, a motion detection device is provided. By using the above device, it is possible to obtain high-precision geographic location information, thereby using a method combining geographic location detection and scene recognition to more accurately determine whether an interactive device has moved.
[0332] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application,
[0333] The determination module 360 is further configured to call the image acquisition device of the target interactive device, and before acquiring the image to be identified, determine the longitude change value and the latitude change value according to the second position information of the target interactive device and the initial position information of the target interactive device when the second position information of the target interactive device is acquired, wherein the second position information is acquired by connecting the target interactive device to the base station;
[0334] The determination module 360 is further configured to determine that the target interactive device has moved if the longitude change value or the latitude change value is greater than or equal to the change threshold;
[0335] The execution module 370 is further configured to execute the step of calling the image acquisition device of the target interactive device to obtain the image to be identified if the longitude change value or the latitude change value is less than the change threshold.
[0336] In the embodiment of the present application, a mobile detection device is provided. With the above device, the geographical location information of the interactive device can be obtained by using the base station transmitting signal. On the one hand, it can be used both indoors and outdoors, and the positioning success rate is high. On the other hand, it is more convenient and the required cost is low.
[0337] Optionally, in the above Fig. 9On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application,
[0338] The determination module 360 is further used to call the image acquisition device of the target interactive device, and before acquiring the image to be identified, when the third position information of the target interactive device is acquired, determine the longitude change value and the latitude change value according to the third position information and the initial position information of the target interactive device, wherein the third position information is acquired by connecting the target interactive device to a mobile hotspot;
[0339] The determination module 360 is further configured to determine that the target interactive device has moved if the longitude change value or the latitude change value is greater than or equal to the change threshold;
[0340] The execution module 370 is further configured to execute the step of calling the image acquisition device of the target interactive device to obtain the image to be identified if the longitude change value or the latitude change value is less than the change threshold.
[0341] In the embodiment of the present application, a mobile detection device is provided. With the above device, positioning using WiFi can obtain high-precision geographic location information, and no additional hardware equipment is required, so the cost is low and easy to deploy. In addition, WiFi positioning can also be used in combination with other positioning technologies, such as GPS or Bluetooth, to improve the accuracy and reliability of positioning.
[0342] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application,
[0343] The determination module 360 is further used to call the image acquisition device of the target interactive device, and before acquiring the image to be identified, when the fourth position information of the target interactive device is acquired, determine the longitude change value and the latitude change value according to the fourth position information and the initial position information of the target interactive device, wherein the fourth position information is acquired by connecting the target interactive device to the Bluetooth device;
[0344] The determination module 360 is further configured to determine that the target interactive device has moved if the longitude change value or the latitude change value is greater than or equal to the change threshold;
[0345] The execution module 370 is further configured to execute the step of calling the image acquisition device of the target interactive device to obtain the image to be identified if the longitude change value or the latitude change value is less than the change threshold.
[0346] In the embodiment of the present application, a mobile detection device is provided. With the above device, positioning using Bluetooth can be used indoors or in high-rise buildings, and has high accuracy and reliability.
[0347] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application,
[0348] The detection module 330 is specifically configured to obtain an acceleration value of the target interactive device through an acceleration sensor built into the target interactive device when the scene recognition result of the image to be recognized indicates that the target interactive device is in the initial scene;
[0349] If the acceleration value is greater than or equal to the acceleration threshold, it is determined that the target interactive device has moved;
[0350] If the acceleration value is less than the acceleration threshold, it is determined that the target interactive device has not moved.
[0351] In an embodiment of the present application, a motion detection device is provided. With the above device, if the scene recognition result indicates that the target interactive device is in the initial scene, the acceleration value of the target interactive device can be used to further determine its movement, thereby further improving the accuracy of the motion detection result.
[0352] Optionally, in the above Fig. 9 On the basis of the corresponding embodiment, in another embodiment of the device movement detection device 30 provided in the embodiment of the present application,
[0353] The detection module 330 is specifically configured to obtain the signal strength between the target interaction device and T wireless devices at a first moment when the scene recognition result of the image to be recognized indicates that the target interaction device is in the initial scene, where T is an integer greater than or equal to 3;
[0354] According to the signal strength between the target interactive device and the T wireless devices, a target space model is constructed, wherein the target space model includes a position point corresponding to the target interactive device and a position point corresponding to each of the T wireless devices;
[0355] The movement detection result of the target interactive device is determined according to the target space model and the initial space model, wherein the initial space model is constructed based on the signal strength between the target interactive device and T wireless devices for a second moment, and the second moment occurs before the first moment.
[0356] In an embodiment of the present application, a motion detection device is provided. With the above device, if the scene recognition result indicates that the target interactive device is in the initial scene, the movement of the target interactive device can also be determined by detecting the change in signal strength between the target interactive device and surrounding wireless devices.
[0357] The present application also provides a terminal, such as Fig.10 For the sake of convenience, only the parts related to the embodiments of the present application are shown. For specific technical details not disclosed, please refer to the method part of the embodiments of the present application. In the embodiments of the present application, the terminal is taken as an interactive device (for example, a palm scanning device or a face scanning device, etc.) as an example for explanation:
[0358] Fig.10 FIG. 1 is a block diagram showing a partial structure of an interactive device related to a terminal provided in an embodiment of the present application. Fig.10 The interactive device includes: a radio frequency (RF) circuit 410, a memory 420, an input unit 430, a display unit 440, a sensor 450, an audio circuit 460, a WiFi module 470, a processor 480, and a power supply 490. Those skilled in the art will appreciate that Fig.10 The interactive device structure shown in the figure does not constitute a limitation on the interactive device, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.
[0359] Combine the following Fig.10 The following is a detailed introduction to the components of the interactive device:
[0360] The RF circuit 410 can be used for receiving and sending signals during the process of sending and receiving information or making calls. In particular, after receiving the downlink information of the base station, it is sent to the processor 480 for processing; in addition, the designed uplink data is sent to the base station. Generally, the RF circuit 410 includes but is not limited to an antenna, at least one amplifier, a transceiver, a coupler, a low noise amplifier (LNA), a duplexer, etc. In addition, the RF circuit 410 can also communicate with the network and other devices through wireless communication. The above-mentioned wireless communication can use any communication standard or protocol, including but not limited to the global system of mobile communication (GSM), general packet radio service (GPRS), code division multiple access (CDMA), wideband code division multiple access (WCDMA), long term evolution (LTE), email, short messaging service (SMS), etc.
[0361] The memory 420 can be used to store software programs and modules. The processor 480 executes various functional applications and data processing of the interactive device by running the software programs and modules stored in the memory 420. The memory 420 can mainly include a program storage area and a data storage area, wherein the program storage area can store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area can store data created according to the use of the interactive device (such as audio data, a phone book, etc.), etc. In addition, the memory 420 can include a high-speed random access memory, and can also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.
[0362] The input unit 430 can be used to receive input digital or character information, and to generate key signal input related to the user settings and function control of the interactive device. Specifically, the input unit 430 may include a touch panel 431 and other input devices 432. The touch panel 431, also known as a touch screen, can collect the user's touch operation on or near it (such as the user's operation on the touch panel 431 or near the touch panel 431 using any suitable object or accessory such as a finger, stylus, etc.), and drive the corresponding connection device according to a pre-set program. Optionally, the touch panel 431 may include two parts: a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch orientation, detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into contact coordinates, and then sends it to the processor 480, and can receive and execute commands sent by the processor 480. In addition, the touch panel 431 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic waves. In addition to the touch panel 431, the input unit 430 may further include other input devices 432. Specifically, the other input devices 432 may include but are not limited to one or more of a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a mouse, a joystick, etc.
[0363] The display unit 440 can be used to display information input by the user or information provided to the user and various menus of the interactive device. The display unit 440 may include a display panel 441. Optionally, the display panel 441 may be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), etc. Further, the touch panel 431 may cover the display panel 441. When the touch panel 431 detects a touch operation on or near it, it is transmitted to the processor 480 to determine the type of touch event. Subsequently, the processor 480 provides a corresponding visual output on the display panel 441 according to the type of touch event. Although in Fig.10 In the embodiment, the touch panel 431 and the display panel 441 are used as two independent components to implement the input and output functions of the interactive device, but in some embodiments, the touch panel 431 and the display panel 441 can be integrated to implement the input and output functions of the interactive device.
[0364] The interactive device may also include at least one sensor 450, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor and a proximity sensor, wherein the ambient light sensor may adjust the brightness of the display panel 441 according to the brightness of the ambient light, and the proximity sensor may turn off the display panel 441 and / or the backlight when the interactive device is moved to the ear. As a type of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in all directions (generally three axes), and can detect the magnitude and direction of gravity when stationary. It can be used for applications that identify the posture of the interactive device (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer, tapping), etc.; as for other sensors that can be configured in the interactive device, such as gyroscopes, barometers, hygrometers, thermometers, infrared sensors, etc., they will not be repeated here.
[0365] The audio circuit 460, the speaker 461, and the microphone 462 can provide an audio interface between the user and the interactive device. The audio circuit 460 can transmit the received audio data to the speaker 461 after converting the received audio data into an electrical signal, which is converted into a sound signal for output; on the other hand, the microphone 462 converts the collected sound signal into an electrical signal, which is received by the audio circuit 460 and converted into audio data, and then the audio data is output to the processor 480 for processing, and then sent to another interactive device through the RF circuit 410, or the audio data is output to the memory 420 for further processing.
[0366] WiFi is a short-range wireless transmission technology. The interactive device can help users send and receive emails, browse web pages, and access streaming media through the WiFi module 470. It provides users with wireless broadband Internet access. Fig.10 A WiFi module 470 is shown, but it is understandable that it is not a necessary component of the interactive device and can be omitted as needed without changing the essence of the invention.
[0367] The processor 480 is the control center of the interactive device. It uses various interfaces and lines to connect various parts of the entire interactive device. It executes various functions of the interactive device and processes data by running or executing software programs and / or modules stored in the memory 420, and calling data stored in the memory 420. Optionally, the processor 480 may include one or more processing units; optionally, the processor 480 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface, and application programs, and the modem processor mainly processes wireless communications. It is understandable that the above-mentioned modem processor may not be integrated into the processor 480.
[0368] The interactive device also includes a power supply 490 (such as a battery) for supplying power to each component. Optionally, the power supply can be logically connected to the processor 480 through a power management system, thereby implementing functions such as charging, discharging, and power consumption management through the power management system.
[0369] Although not shown, the mobile phone may also include a camera, a Bluetooth module, etc., which will not be described in detail here.
[0370] The steps performed by the terminal in the above embodiment can be based on the Fig.10 The terminal structure shown.
[0371] A computer device is also provided in an embodiment of the present application, including a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the steps of the methods described in the above embodiments are implemented.
[0372] A computer-readable storage medium is also provided in an embodiment of the present application, on which a computer program is stored. When the computer program is executed by a processor, the steps of the methods described in the above embodiments are implemented.
[0373] A computer program product is also provided in an embodiment of the present application, including a computer program, which, when executed by a processor, implements the steps of the methods described in the above embodiments.
[0374] It is understandable that in the specific implementation of this application, user information, biometric information and other related data are involved. When the above embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of relevant data need to comply with relevant laws, regulations and standards of relevant countries and regions.
[0375] 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.
[0376] In the several embodiments provided in the present application, it should be understood that the disclosed systems, 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 an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0377] 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.
[0378] 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. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0379] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a server or terminal device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store computer programs.
[0380] As described above, the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application 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 make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A method for detecting device movement, characterized in that: include: Invoke an image acquisition device of a target interactive device to acquire an image to be recognized, wherein the image to be recognized is an image acquired at a target time; Recognize the image to be recognized by a scene recognition model to obtain a scene recognition result of the image to be recognized, wherein the scene recognition model is obtained by training based on N sample images, and the N sample images are acquired by the image acquisition device of the target interaction device before the target time, and N is an integer greater than 1; Based on the scene recognition result of the image to be recognized, the movement detection result of the target interaction device is determined, wherein the movement detection result is used to indicate the movement of the target interaction device, and when the movement detection result indicates that the target interaction device has moved, a prompt operation is triggered.
2. The detection method according to claim 1, characterized in that Before the scene recognition model is used to recognize the image to be recognized and a scene recognition result of the image to be recognized is obtained, the method further includes: Invoking the image acquisition device of the target interactive device to obtain the N sample images; Obtaining a scene label corresponding to each sample image in the N sample images, wherein the scene label is an initial scene label or a non-initial scene label; Based on the N sample images, obtaining a scene prediction result corresponding to each sample image through a scene recognition model to be trained; The model parameters of the scene recognition model to be trained are updated using the scene label and scene prediction result corresponding to each sample image until the model training conditions are met, thereby obtaining the scene recognition model, wherein the scene recognition model is used to recognize the images collected by the target interaction device.
3. The detection method according to claim 1, characterized in that: Before the scene recognition model is used to recognize the image to be recognized and a scene recognition result of the image to be recognized is obtained, the method further includes: Invoking the image acquisition device of the target interactive device to obtain the N sample images; Sending the N sample images to a server; The server is used to obtain a scene label corresponding to each sample image in the N sample images, and the scene label is an initial scene label or a non-initial scene label; The server is used to obtain a scene prediction result corresponding to each sample image through a scene recognition model to be trained based on the N sample images; The server is used to use the scene label and scene prediction result corresponding to each sample image to update the model parameters of the scene recognition model to be trained until the model training conditions are met, thereby obtaining the scene recognition model, which is used to recognize the images collected by the target interactive device.
4. The detection method according to claim 2 or 3, characterized in that: The obtaining of the scene label corresponding to each sample image in the N sample images includes: Acquire a standard sample image from the N sample images, wherein the standard sample image is a first frame image captured from the N sample images; Determining the scene label corresponding to the standard sample image as the initial scene label; Extracting feature points from each of the N sample images to obtain a set of feature points corresponding to each sample image; Comparing feature points of a feature point set corresponding to each sample image in the (N-1) sample images with a feature point set corresponding to the standard sample image, wherein the (N-1) sample images are sample images remaining after removing the standard sample image from the N sample images; If the feature point offset between the feature point set corresponding to the sample image and the feature point set corresponding to the standard sample image is greater than the offset threshold, the scene label corresponding to the sample image is determined as the non-initial scene label; If the feature point offset between the feature point set corresponding to the sample image and the feature point set corresponding to the standard sample image is less than or equal to the offset threshold, the scene label corresponding to the sample image is determined as the initial scene label.
5. The detection method according to claim 2 or 3, characterized in that: The obtaining of the scene label corresponding to each sample image in the N sample images includes: Display the N sample images; In response to the labeling operation for each sample image, a scene label corresponding to each sample image is obtained.
6. The detection method according to claim 2 or 3, characterized in that: The method further comprises: In the case where the scene labels corresponding to the N sample images are all the initial scene labels, M sample images are obtained, wherein the scene label of each sample image in the M sample images is the non-initial scene label, the M sample images are images collected by other interactive devices, or the M sample images are pre-constructed images, and M is an integer greater than 1; The step of obtaining a scene prediction result corresponding to each sample image by using a scene recognition model to be trained based on the N sample images includes: Based on the N sample images and the M sample images, obtaining a scene prediction result corresponding to each sample image in the (N+M) sample images through the scene recognition model to be trained; The method of updating the model parameters of the scene recognition model to be trained by using the scene label and the scene prediction result corresponding to each sample image until the model training conditions are met to obtain the scene recognition model comprises: The scene label corresponding to each sample image in the (N+M) sample images and the scene prediction result are used to update the model parameters of the scene recognition model to be trained until the model training conditions are met, thereby obtaining the scene recognition model.
7. The detection method according to claim 2 or 3, characterized in that: The scenario prediction result is a scenario prediction probability distribution; The step of obtaining a scene prediction result corresponding to each sample image by using a scene recognition model to be trained based on the N sample images includes: Based on the N sample images, the scene prediction probability distribution corresponding to each sample image is obtained through the scene recognition model to be trained, wherein the scene prediction probability distribution includes the probability that the sample image belongs to the initial scene label and the probability of the non-initial scene label.
8. The detection method according to claim 7, characterized in that: The step of identifying the image to be identified by using a scene recognition model to obtain a scene recognition result of the image to be identified includes: Recognize the image to be recognized by the scene recognition model to obtain a scene probability distribution of the image to be recognized, wherein the scene probability distribution includes a probability that the image to be recognized belongs to the initial scene label and a probability that the image to be recognized belongs to the non-initial scene label; A scene recognition result of the image to be recognized is determined according to the scene probability distribution of the image to be recognized.
9. The detection method according to claim 2 or 3, characterized in that: The scenario prediction result is a scenario prediction score; The step of obtaining a scene prediction result corresponding to each sample image by using a scene recognition model to be trained based on the N sample images includes: Based on the N sample images, a scene prediction score corresponding to each sample image is obtained through the scene recognition model to be trained, wherein the scene prediction score represents the probability that the sample image belongs to the initial scene label.
10. The detection method according to claim 9, characterized in that: The step of identifying the image to be identified by using a scene recognition model to obtain a scene recognition result of the image to be identified includes: Recognize the image to be recognized by using the scene recognition model to obtain a scene score of the image to be recognized, wherein the scene score represents the probability that the image to be recognized belongs to the initial scene label; A scene recognition result of the image to be recognized is determined according to the scene score of the image to be recognized.
11. The detection method according to claim 1, characterized in that: Before calling the image acquisition device of the target interactive device to obtain the image to be recognized, the method further includes: In the case of acquiring the first location information of the target interactive device, determining the longitude change value and the latitude change value according to the first location information and the initial location information of the target interactive device, wherein the first location information is acquired according to a global positioning system GPS chip built into the target interactive device; If the longitude change value or the latitude change value is greater than or equal to the change threshold, it is determined that the target interactive device has moved; If the longitude change value or the latitude change value is smaller than the change threshold, the step of calling the image acquisition device of the target interactive device to acquire the image to be identified is executed.
12. The detection method according to claim 1, characterized in that: Before calling the image acquisition device of the target interactive device to obtain the image to be recognized, the method further includes: In the case of acquiring the second location information of the target interaction device, determining the longitude change value and the latitude change value according to the second location information and the initial location information of the target interaction device, wherein the second location information is acquired by connecting the target interaction device to a base station; If the longitude change value or the latitude change value is greater than or equal to the change threshold, it is determined that the target interactive device has moved; If the longitude change value or the latitude change value is smaller than the change threshold, the step of calling the image acquisition device of the target interactive device to acquire the image to be identified is executed.
13. The detection method according to claim 1, characterized in that: Before calling the image acquisition device of the target interactive device to obtain the image to be recognized, the method further includes: In the case of obtaining the third location information of the target interactive device, determining the longitude change value and the latitude change value according to the third location information and the initial location information of the target interactive device, wherein the third location information is obtained by connecting the target interactive device to a mobile hotspot; If the longitude change value or the latitude change value is greater than or equal to the change threshold, it is determined that the target interactive device has moved; If the longitude change value or the latitude change value is smaller than the change threshold, the step of calling the image acquisition device of the target interactive device to acquire the image to be identified is executed.
14. The detection method according to claim 1, characterized in that: Before calling the image acquisition device of the target interactive device to obtain the image to be recognized, the method further includes: In the case of acquiring the fourth location information of the target interactive device, determining the longitude change value and the latitude change value according to the fourth location information and the initial location information of the target interactive device, wherein the fourth location information is acquired by connecting the target interactive device to a Bluetooth device; If the longitude change value or the latitude change value is greater than or equal to the change threshold, it is determined that the target interactive device has moved; If the longitude change value or the latitude change value is smaller than the change threshold, the step of calling the image acquisition device of the target interactive device to acquire the image to be identified is executed.
15. The detection method according to claim 1, characterized in that: The step of determining the movement detection result of the target interactive device according to the scene recognition result of the image to be recognized includes: When the scene recognition result of the image to be recognized indicates that the target interaction device is in the initial scene, acquiring an acceleration value of the target interaction device through an acceleration sensor built into the target interaction device; If the acceleration value is greater than or equal to the acceleration threshold, it is determined that the target interactive device has moved; If the acceleration value is less than the acceleration threshold, it is determined that the target interaction device has not moved.
16. The detection method according to claim 1, characterized in that: The step of determining the movement detection result of the target interactive device according to the scene recognition result of the image to be recognized includes: When the scene recognition result of the image to be recognized indicates that the target interaction device is in an initial scene, obtaining a signal strength between the target interaction device and T wireless devices at a first moment, wherein T is an integer greater than or equal to 3; Constructing a target space model according to the signal strength between the target interaction device and the T wireless devices, wherein the target space model includes a position point corresponding to the target interaction device and a position point corresponding to each of the T wireless devices; The motion detection result of the target interactive device is determined according to the target space model and the initial space model, wherein the initial space model is constructed based on the signal strength between the target interactive device and T wireless devices for a second moment, and the second moment occurs before the first moment.
17. A device for detecting movement of equipment, characterized in that: include: An acquisition module, used for calling an image acquisition device of a target interactive device to acquire an image to be recognized, wherein the image to be recognized is an image acquired at a target time; a recognition module, configured to recognize the image to be recognized by using a scene recognition model to obtain a scene recognition result of the image to be recognized, wherein the scene recognition model is obtained by training based on N sample images, the N sample images are acquired by the image acquisition device of the target interaction device before the target time, and N is an integer greater than 1; A detection module is used to determine a movement detection result of the target interaction device based on a scene recognition result of the image to be identified, wherein the movement detection result is used to indicate the movement of the target interaction device, and trigger a prompt operation when the movement detection result indicates that the target interaction device has moved.
18. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the detection method according to any one of claims 1 to 16 are implemented.
19. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the detection method according to any one of claims 1 to 16 are implemented.
20. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the detection method according to any one of claims 1 to 16 are implemented.
