Food material identification method and device, refrigeration equipment, server and readable storage medium

By obtaining video streaming data and network information in the smart refrigerator, judging the network status and identifying ingredients, it solves the problem of ingredient management in the smart refrigerator in the offline state, and realizes automatic ingredient identification and accurate information acquisition in any network environment. Improved user experience.

CN118865191APending Publication Date: 2024-10-29HEFEI MIDEA REFRIGERATOR CO LTD +2
View PDF 9 Cites 0 Cited by

Patent Information

Application Number
CN202310485036.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-04-27
Publication Date
2024-10-29

AI Technical Summary

Technical Problem

In the solution of food management in smart refrigerators based on visual sensors, food identification and management cannot be realized offline, and it is difficult to obtain accurate and comprehensive food information only by image recognition, resulting in poor user experience.

Method used

By obtaining the video stream data and networking information of the refrigeration equipment, it is determined whether the equipment is connected to the Internet. If it is not connected to the Internet, it will be identified locally. If it is connected, it will be sent to the server for identification. It can realize automatic food identification in any network environment, and obtain accurate and accurate information through the video stream data. Comprehensive ingredient information.

Benefits of technology

It realizes automatic and non-perceptual ingredient recognition in any network environment, improves user experience and ensures the accuracy and comprehensiveness of ingredient information.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118865191A_ABST
    Figure CN118865191A_ABST
Patent Text Reader

Abstract

The invention discloses a food material identification method and device, refrigeration equipment, a server and a readable storage medium, and the method comprises the steps: obtaining video stream data of a process that a food material enters and exits from the refrigeration equipment and first networking information of the refrigeration equipment; according to the first networking information, whether the refrigeration equipment is networked or not is judged; if not, identifying the video stream data to obtain first food material information of the food material; and if the network is connected, sending the video stream data to a server, so that the server identifies the video stream data to obtain second food material information of the food materials. Therefore, according to the networking condition of the refrigeration equipment, local or remote food material identification on the collected video stream data can be started, automatic food material identification without perception of a user in any network environment is realized, and relatively accurate and comprehensive food material information can be obtained by performing food material identification based on the video stream data, so that the user experience is improved. And thus, the user experience is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of smart home technology, and in particular to a food identification method, device, refrigeration equipment, server and readable storage medium. Background Art

[0002] At present, the food management technologies of smart refrigerators mainly include RFID (Radio Frequency Identification), vision, APP (Application), voice and other methods. Among them, the RFID method requires the use of additional food clips / stickers, and the APP and voice methods require the user's active input, which is time-consuming, and users often forget to delete relevant information when taking out the food. Compared with the above technologies, the solution based on visual sensors (such as cameras) can obtain images in the refrigerator in real time, and through image processing, it can achieve seamless food input and deletion, and the user does not need to actively operate, which has a better experience.

[0003] When managing food ingredients based on visual sensors, the refrigerator can collect pictures locally and the remote server can perform picture recognition. However, this method has certain requirements for the network. When the refrigerator is offline, the food ingredients cannot be recognized and managed. Moreover, if only pictures are recognized, relatively accurate and comprehensive food ingredient information may not be obtained, resulting in a poor user experience. Summary of the invention

[0004] The present invention aims to solve at least one of the technical problems in the related art to a certain extent. To this end, the first purpose of the present invention is to propose a food identification method, which can start local or remote food identification of the collected video stream data according to the networking status of the refrigeration equipment, realize automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0005] The second objective of the present invention is to provide another food identification method.

[0006] The third objective of the present invention is to provide a food identification device.

[0007] A fourth objective of the present invention is to provide another food identification device.

[0008] A fifth object of the present invention is to provide a refrigeration device.

[0009] A sixth objective of the present invention is to provide a server.

[0010] A seventh object of the present invention is to provide a computer-readable storage medium.

[0011] To achieve the above-mentioned purpose, the first aspect of the embodiment of the present invention proposes a food identification method, which is applied to refrigeration equipment. The method includes: obtaining video stream data of the process of food entering and exiting the refrigeration equipment and the first networking information of the refrigeration equipment; judging whether the refrigeration equipment is connected to the network based on the first networking information; if not connected to the network, identifying the video stream data to obtain the first food information of the food; if connected to the network, sending the video stream data to the server so that the server can identify the video stream data and obtain the second food information of the food.

[0012] According to the food identification method of the embodiment of the present invention, the video stream data of the food entering and exiting the refrigeration device and the first networking information of the refrigeration device are obtained through the refrigeration device; according to the first networking information, it is determined whether the refrigeration device is connected to the network; if it is not connected to the network, the video stream data is identified to obtain the first food information of the food; if it is connected to the network, the video stream data is sent to the server so that the server can identify the video stream data and obtain the second food information of the food. Therefore, according to the networking status of the refrigeration device, local or remote food identification of the collected video stream data can be started, realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0013] According to one embodiment of the present invention, after obtaining the first ingredient information of the ingredient, the method also includes: obtaining the second networking information of the refrigeration device after a preset time; if it is determined according to the second networking information that the refrigeration device is connected to the network, the first ingredient information is sent to the server so that the server synchronizes the ingredient information according to the first ingredient information.

[0014] According to one embodiment of the present invention, video stream data is identified to obtain first ingredient information of an ingredient, including: determining a first recognition model, wherein the first recognition model is obtained based on a training sample labeled with ingredient information corresponding to a plurality of sample images; and using the first recognition model, the video stream data is identified to obtain first ingredient information of the ingredient.

[0015] To achieve the above-mentioned purpose, the second aspect of the present invention proposes a method for identifying ingredients, which is applied to a server. The method includes: when a first preset condition is met, receiving video stream data of the process of ingredients entering and leaving the refrigeration equipment sent by the refrigeration equipment, wherein the first preset condition is to determine that the refrigeration equipment is connected to the network based on the first networking information of the refrigeration equipment; identifying the video stream data to obtain the second ingredient information of the ingredients.

[0016] According to the food identification method of an embodiment of the present invention, the server receives the video stream data of the food entering and exiting the refrigeration device sent by the refrigeration device when the first preset condition is met, wherein the first preset condition is to determine that the refrigeration device is connected to the network according to the first networking information of the refrigeration device; identify the video stream data to obtain the second food information of the food. Therefore, according to the networking status of the refrigeration device, local or remote food identification of the collected video stream data can be started, realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0017] According to one embodiment of the present invention, video stream data is identified to obtain second ingredient information of an ingredient, including: parsing the video stream data to obtain M images, where M is an integer greater than 2; filtering the M images to determine N key frame images with the largest changes among the M images, where M is greater than N and N is an integer; extracting feature data of each key frame image, and obtaining the second ingredient information of the ingredient based on the feature data of each key frame image.

[0018] According to an embodiment of the present invention, M images are filtered to determine N key frame images with the largest changes among the M images, including: subtracting every two adjacent images and taking the first N images with the largest differences as the N key frame images.

[0019] According to one embodiment of the present invention, the method also includes: when a second preset condition is met, receiving first ingredient information sent by the refrigeration device, wherein the first ingredient information is obtained by the refrigeration device identifying video stream data when it is determined that the refrigeration device is not connected to the network based on the first networking information, and the second preset condition is to determine that the refrigeration device is connected to the network based on the second networking information of the refrigeration device after a preset time; and synchronizing the ingredient information of the ingredient based on the first ingredient information.

[0020] According to one embodiment of the present invention, identifying video stream data to obtain second ingredient information of an ingredient includes: obtaining a second recognition model, wherein the second recognition model is obtained based on a training sample annotated with ingredient information corresponding to a plurality of sample images; and identifying the video stream data through the second recognition model to obtain the second ingredient information of the ingredient.

[0021] To achieve the above-mentioned purpose, the third aspect of the present invention proposes an ingredient identification device, which includes: an acquisition module, used to acquire video stream data of the process of ingredients entering and exiting a refrigeration device and first networking information of the refrigeration device; a judgment module, used to judge whether the refrigeration device is connected to the network based on the first networking information; a determination module, used to identify the video stream data if it is not connected to the network, and obtain the first ingredient information of the ingredients; and a sending module, used to send the video stream data to a server if it is connected to the network, so that the server can identify the video stream data and obtain the second ingredient information of the ingredients.

[0022] According to the food identification device of the embodiment of the present invention, the acquisition module is used to obtain the video stream data of the food entering and exiting the refrigeration device and the first networking information of the refrigeration device; the judgment module is used to determine whether the refrigeration device is connected to the network according to the first networking information; the determination module is used to identify the video stream data if it is not connected to the network to obtain the first food information of the food; the sending module is used to send the video stream data to the server if it is connected to the network so that the server can identify the video stream data and obtain the second food information of the food. Therefore, according to the networking status of the refrigeration device, local or remote food identification of the collected video stream data can be started, thereby realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0023] To achieve the above-mentioned purpose, the fourth aspect of the present invention proposes a food identification device, which includes: a receiving module, which is used to receive video stream data of the process of food entering and leaving the refrigeration equipment sent by the refrigeration equipment when a first preset condition is met, wherein the first preset condition is to determine that the refrigeration equipment is connected to the network based on the first networking information of the refrigeration equipment; an identification module, which is used to identify the video stream data and obtain the second food information of the food.

[0024] According to the food identification device of the embodiment of the present invention, the receiving module receives the video stream data of the food entering and exiting the refrigeration device sent by the refrigeration device when the first preset condition is met, wherein the first preset condition is to determine that the refrigeration device is connected to the network according to the first networking information of the refrigeration device; and to identify the video stream data through the identification module to obtain the second food information of the food. Therefore, according to the networking status of the refrigeration device, local or remote food identification of the collected video stream data can be started, realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0025] To achieve the above-mentioned purpose, a fifth embodiment of the present invention proposes a refrigeration device, comprising: a memory for storing programs; and a processor for implementing the food identification method of the first embodiment by executing the programs stored in the memory.

[0026] In the above refrigeration equipment, by obtaining the video stream data of the process of food entering and leaving the refrigeration equipment and the first networking information of the refrigeration equipment; judging whether the refrigeration equipment is connected to the network according to the first networking information; if not, identifying the video stream data to obtain the first food information of the food; if connected to the network, sending the video stream data to the server so that the server can identify the video stream data and obtain the second food information of the food. Therefore, according to the networking status of the refrigeration equipment, local or remote food identification of the collected video stream data can be started, realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0027] To achieve the above-mentioned purpose, a sixth aspect of the present invention proposes a server, comprising: a memory for storing programs; and a processor for implementing the food identification method of the second aspect of the embodiment by executing the programs stored in the memory.

[0028] In the above server, when the first preset condition is met, the video stream data of the food entering and leaving the refrigeration device is received, wherein the first preset condition is to determine that the refrigeration device is connected to the network according to the first networking information of the refrigeration device; identify the video stream data to obtain the second food information of the food. Therefore, according to the networking status of the refrigeration device, local or remote food identification of the collected video stream data can be started, realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0029] To achieve the above objectives, a seventh aspect of the present invention provides a computer-readable storage medium having a program stored thereon, and the program can be executed by a processor to implement the food identification method of the first and second aspects.

[0030] In the above-mentioned computer-readable storage medium, by obtaining the video stream data of the process of food entering and exiting the refrigeration equipment and the first networking information of the refrigeration equipment; judging whether the refrigeration equipment is connected to the network according to the first networking information; if not, identifying the video stream data to obtain the first food information of the food; if connected to the network, sending the video stream data to the server so that the server can identify the video stream data and obtain the second food information of the food. Therefore, according to the networking status of the refrigeration equipment, local or remote food identification of the collected video stream data can be started, realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0031] Additional aspects and advantages of the present invention will be given in part in the following description and in part will be obvious from the following description, or will be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] Figure 1 A structural schematic diagram of a food identification system provided by an embodiment of the present invention;

[0033] Figure 2 A schematic diagram of a flow chart of a first embodiment of a food identification method provided by an embodiment of the present invention;

[0034] Figure 3 A schematic diagram of a flow chart of a second embodiment of a food identification method provided by an embodiment of the present invention;

[0035] Figure 4 A schematic diagram of a flow chart of a third embodiment of a food identification method provided by an embodiment of the present invention;

[0036] Figure 5 A schematic diagram of the structure of a food identification device provided by an embodiment of the present invention;

[0037] Figure 6 A schematic diagram of the structure of another food identification device provided by an embodiment of the present invention;

[0038] Figure 7 A schematic diagram of the structure of a refrigeration device provided by an embodiment of the present invention;

[0039] Figure 8 A schematic diagram of the structure of a server provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0040] Embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present invention, and should not be construed as limiting the present invention.

[0041] The following describes the food identification method, device, refrigeration equipment, server and readable storage medium proposed in the embodiments of the present invention with reference to the accompanying drawings.

[0042] In this application, reference is made to Figure 1 As shown, Figure 1 This is a structural schematic diagram of a food identification system provided in an embodiment of the present invention. The system 1 includes a refrigeration device 10 and a server 20.

[0043] Specifically, it can be done by Figure 1 The refrigeration device 10 shown implements the food thawing method provided in the following embodiment 1. Figure 2 This is a flow chart of a first embodiment of a method for identifying food provided by an embodiment of the present invention. The method for identifying food provided by this embodiment may include the following steps:

[0044] S201, obtaining video stream data of a process of food entering and exiting a refrigeration device and first networking information of the refrigeration device.

[0045] Specifically, the refrigeration device may be a refrigerator, a freezer, a fresh-keeping cabinet, etc. The embodiment of the present invention may be described by taking the refrigeration device being a refrigerator as an example.

[0046] Specifically, the video stream data of the process of food entering and leaving the refrigeration device can be collected by an image acquisition device installed inside the refrigeration device. In specific implementation, the image acquisition device can be installed on the top of the refrigeration device, for example, it can be installed in the area near the door body of the top of the refrigeration device, or it can be installed in other locations where the process of food entering and leaving the refrigeration device can be captured, and the embodiment of the present invention does not limit this.

[0047] Specifically, the image acquisition device can be a visual sensor such as an RGB color camera, a black and white camera, a 3D camera, a hyperspectral camera, etc.

[0048] Specifically, after the user opens the refrigeration device (such as detecting the user's door opening signal), the image acquisition device disposed inside the refrigeration device can be controlled to collect video stream data of the process of food entering and exiting the refrigeration device, and after the user closes the refrigeration device (such as detecting the user's door closing signal), the image acquisition device can be controlled to stop shooting. Alternatively, when it is detected that the opening angle of the refrigeration device door is greater than a preset angle, the image acquisition device disposed inside the refrigeration device can be controlled to collect video stream data of the process of food entering and exiting the refrigeration device; when it is detected that the opening angle of the refrigeration device door is less than or equal to the preset angle, the image acquisition device disposed inside the refrigeration device can be controlled to stop shooting.

[0049] Specifically, the first networking information of the refrigeration device is the current networking information of the refrigeration device. In specific implementation, the first networking information of the refrigeration device can be obtained by detecting whether a WiFi (Wireless Fidelity) module provided in the refrigeration device is connected to a network hotspot.

[0050] S202: Determine whether the refrigeration equipment is connected to the network based on the first networking information.

[0051] If not, execute S203; if so, execute S204.

[0052] Specifically, the networking field information of the refrigeration device can be obtained. If the networking field is "0", it indicates that the refrigeration device is currently offline (not connected to the network). If the networking field is "1", it indicates that the refrigeration device is currently connected to the network.

[0053] S203: Identify the video stream data to obtain first ingredient information of the ingredient.

[0054] Specifically, the video stream data can be identified by a processor disposed in the refrigeration device to obtain the first food information of the food. In specific implementation, the first food information may include information such as the category, quantity, name, and in / out status of the food, wherein the in / out status information may be "food is put into the refrigeration device" or "food is taken out of the refrigeration device". For example, if the in / out status information is "1", it indicates that the food is put into the refrigeration device, and if the in / out status information is "0", it indicates that the food is taken out of the refrigeration device.

[0055] S204: Send the video stream data to the server so that the server can identify the video stream data and obtain the second ingredient information of the ingredient.

[0056] Specifically, if it is determined that the refrigeration equipment is currently connected to the network, the video stream data can be sent to the server for identification. In specific implementation, the collected video stream data can be preprocessed and compressed, and the compressed video stream data can be sent to the server frame by frame. If the transmission fails, it can be retransmitted. The compression method can use an encoding method such as H.265 or H.264.

[0057] Specifically, if it is determined that the refrigeration equipment is currently connected to the network, then after detecting the user's door closing signal, all collected video stream data can be sent to the server for identification, or the collected video stream data can be sent to the server for identification at a preset frame rate while being collected.

[0058] Specifically, the second ingredient information of the ingredient may also include information such as the category, quantity, name, and entry and exit status of the ingredient.

[0059] The food identification method provided by the embodiment of the present invention obtains the video stream data of the food entering and exiting the refrigeration device and the first networking information of the refrigeration device; according to the first networking information, it is determined whether the refrigeration device is connected to the network; if it is not connected to the network, the video stream data is identified to obtain the first food information of the food; if it is connected to the network, the video stream data is sent to the server so that the server can identify the video stream data and obtain the second food information of the food. Therefore, according to the networking status of the refrigeration device, local or remote food identification of the collected video stream data can be started, realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0060] In some embodiments, after obtaining the first ingredient information of the ingredient, the above-mentioned ingredient identification method may also include: obtaining the second networking information of the refrigeration device after a preset time; if it is determined according to the second networking information that the refrigeration device is connected to the network, the first ingredient information is sent to the server so that the server synchronizes the ingredient information according to the first ingredient information.

[0061] Specifically, when the refrigeration device is currently not connected to the Internet, the refrigeration device identifies the video stream data to obtain the first ingredient information of the ingredient. If after a preset time, it is determined that the refrigeration device is connected to the Internet based on the second networking information, then the first ingredient information obtained after the refrigeration device identifies it can be synchronized to the server to ensure that the ingredient data on the local refrigeration device side is consistent with the ingredient data on the remote server side.

[0062] Specifically, the first food information obtained after the refrigeration device identifies the food can be stored in a local offline database. When it is determined that the refrigeration device has been connected to the network after a preset time, the refrigeration device can actively initiate data synchronization. For example, the refrigeration device can synchronize the food data generated during the offline period to the remote server by calling the synchronization data interface of the server, so that the local data is consistent with the cloud data.

[0063] In the embodiment of the present invention, by acquiring the second networking information of the refrigeration device after a preset time; if it is determined that the refrigeration device is connected to the network according to the second networking information, the first food information is sent to the server so that the server synchronizes the food information according to the first food information. In this way, the local data can be kept consistent with the cloud data.

[0064] In some embodiments, video stream data is identified to obtain first ingredient information of an ingredient, including: determining a first recognition model, wherein the first recognition model is obtained based on a training sample labeled with ingredient information corresponding to a plurality of sample images; and the video stream data is identified through the first recognition model to obtain first ingredient information of the ingredient.

[0065] Specifically, the first recognition model may include an access action recognition model. For example, the access action recognition model may be a VLAD (Vector of Locally Aggregated Descriptors), NetVLAD, RNN (Recurrent Neural Network), 3D convolution, TSN (Time-Sensitive Network), dual-stream method, and other models. The input of the above model may be video stream data, and the output may be the judgment result of the food storage and removal action.

[0066] Specifically, the first recognition model may also include an ingredient detection model. For example, the ingredient detection model may be Yolo (You Only Look Once), Faster RCNN (Region-based Convolutional Neural Networks), SPPNet (Spatial Pyramid Pooling in Deep Convolutional Networks), and other models. The input of the above model may be video stream data, and the output may be information such as ingredient type and quantity.

[0067] Specifically, the first recognition model may also include a storage and access action recognition model and a food detection model. The storage and access action recognition model is used to obtain the judgment results of food storage and retrieval actions, and the food detection model is used to obtain information such as food type and quantity.

[0068] Specifically, a lightweight first recognition model can be deployed on the refrigeration equipment side to facilitate the refrigeration equipment to quickly recognize food information.

[0069] Specifically, the refrigeration equipment can obtain the first recognition model through OTA (Over the Air Technology) upgrade. In specific implementation, the remote server can send the first recognition model to the refrigeration equipment through three steps: collection and annotation of training data, model fine-tuning and publishing. For example, collect historical videos received by the server and labels predicted by the first recognition model, manually review and modify these labels, and use the modified labels and the corresponding original videos as training sets; use the old model parameters as a benchmark, and use the above training set to fine-tune the first recognition model until the first recognition model converges; publish the newly trained first recognition model to the local refrigeration equipment through OTA.

[0070] In an embodiment of the present invention, a first recognition model is determined, wherein the first recognition model is obtained based on a training sample annotated with food information corresponding to a plurality of sample images; the video stream data is recognized by the first recognition model to obtain first food information of the food. Thus, the first food information of the food can be quickly obtained by the first recognition model deployed locally, thereby improving the user experience.

[0071] Specifically, it can be done by Figure 1 The server 20 shown implements the food thawing method provided in the following second embodiment. Figure 3 This is a flow chart of a second embodiment of a method for identifying food materials provided by an embodiment of the present invention. The method for identifying food materials provided by this embodiment may include the following steps:

[0072] S301, when a first preset condition is met, receiving video stream data of a process of food entering and exiting the refrigeration device sent by the refrigeration device, wherein the first preset condition is determining that the refrigeration device is connected to the network based on first networking information of the refrigeration device.

[0073] Specifically, the server can receive the video stream data of the food entering and leaving the refrigeration device only when it is determined that the refrigeration device is connected to the network. In specific implementation, the server can start the monitoring service, and after monitoring the sending request from the refrigeration device side, open the port for receiving the video stream data.

[0074] Specifically, after receiving the video stream data sent by the refrigeration equipment, the server may write the video stream data into the server disk for subsequent recognition.

[0075] S302, identifying the video stream data, and obtaining second ingredient information of the ingredient.

[0076] Specifically, if compressed video stream data is received, the server decompresses the compressed video stream data, wherein the decompression process refers to restoring the compressed video stream data to the original video.

[0077] The food identification method provided by the embodiment of the present invention receives the video stream data of the food entering and exiting the refrigeration device sent by the refrigeration device when the first preset condition is met, wherein the first preset condition is to determine that the refrigeration device is connected to the network according to the first networking information of the refrigeration device; identify the video stream data to obtain the second food information of the food. Therefore, according to the networking status of the refrigeration device, local or remote food identification of the collected video stream data can be started, thereby realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0078] In some embodiments, the above-mentioned identification of video stream data to obtain the second ingredient information of the food may include: parsing the video stream data to obtain M images, where M is an integer greater than 2; filtering the M images to determine N key frame images with the largest changes among the M images, where M is greater than N and N is an integer; extracting feature data of each key frame image, and obtaining the second ingredient information of the food based on the feature data of each key frame image.

[0079] Specifically, M images can be captured from the video according to preset rules. For example, the preset rules may be to capture each frame of the video, or to capture 1 image from the video every 5 frames, or to capture 15 images from the video per second, etc. The embodiment of the present invention does not impose any limitation on this.

[0080] Specifically, N images with the largest changes from the beginning to the end of the M images can be used as key frames, and feature data of each key frame can be extracted by a preset feature extraction method, and the second ingredient information of the ingredient can be obtained based on the feature data of each key frame. The feature data can be the RGB information tensor of each key frame (the coordinate information and color information of each pixel in each key frame).

[0081] In an embodiment of the present invention, M images are obtained by parsing video stream data, where M is an integer greater than 2; the M images are filtered to determine the N key frame images with the largest changes among the M images, where M is greater than N and N is an integer; the feature data of each key frame image is extracted, and the second food information of the food is obtained according to the feature data of each key frame image. Therefore, since the key frame with the largest change before and after in the video can maximize the representation of the change of the food in the video, the more accurate second food information can be obtained through the feature data of the key frame, thereby reducing the amount of calculation while improving the accuracy of food recognition and improving the user experience.

[0082] In some embodiments, filtering the M images to determine the N key frame images with the largest changes in the M images may include: subtracting every two adjacent images and taking the first N images with the largest differences as the N key frame images.

[0083] For example, by using preset rules to capture 100 images from a video, the first image can be subtracted from the second image, the second image can be subtracted from the third image, and so on, the 99th image can be subtracted from the 100th image to obtain 99 difference values, and the top 20 images with the largest difference values ​​can be determined as the key frame images with the largest changes.

[0084] In the embodiment of the present invention, by subtracting each two adjacent images and taking the first N images with the largest difference as N key frame images, the key frame image with the largest change can be obtained, and based on the key frame image with the largest change, more accurate second food information can be obtained, thereby improving the accuracy of food recognition and improving the user experience.

[0085] In some embodiments, the above-mentioned food identification method may also include: when a second preset condition is met, receiving first food information sent by the refrigeration device, wherein the first food information is obtained by the refrigeration device identifying the video stream data when it is determined that the refrigeration device is not connected to the network according to the first networking information, and the second preset condition is to determine that the refrigeration device is connected to the network according to the second networking information of the refrigeration device after a preset time; according to the first food information, synchronize the food information of the food.

[0086] Specifically, when the refrigeration device is currently not connected to the Internet, the refrigeration device identifies the video stream data to obtain the first ingredient information of the ingredient. If after a preset time, it is determined that the refrigeration device is connected to the Internet based on the second networking information, then the first ingredient information obtained after the refrigeration device identifies it can be synchronized to the server to ensure that the ingredient data on the local refrigeration device side is consistent with the ingredient data on the remote server side.

[0087] In an embodiment of the present invention, by receiving the first food information sent by the refrigeration device when the second preset condition is met, wherein the first food information is obtained by the refrigeration device identifying the video stream data when the refrigeration device determines that the refrigeration device is not connected to the network according to the first networking information, and the second preset condition is to determine that the refrigeration device is connected to the network according to the second networking information of the refrigeration device after a preset time; and synchronizing the food information of the food according to the first food information. In this way, the local data can be kept consistent with the cloud data.

[0088] In some embodiments, the above-mentioned identification of video stream data to obtain the second ingredient information of the food may include: obtaining a second recognition model, wherein the second recognition model is obtained based on a training sample labeled with the ingredient information corresponding to a plurality of sample images; and identifying the video stream data through the second recognition model to obtain the second ingredient information of the food.

[0089] Specifically, the second recognition model may include an access action recognition model. For example, the access action recognition model may be a VLAD, NetVLAD, RNN, 3D convolution, TSN, dual stream method, etc. The input of the above model may be video stream data, and the output may be the determination result of the food storage and removal action.

[0090] Specifically, the second recognition model may also include an ingredient detection model. For example, the ingredient detection model may be a Yolo, Faster RCNN, SPPNet, or other model. The input of the above model may be video stream data, and the output may be information such as ingredient type and quantity.

[0091] Specifically, the second recognition model may also include a storage and access action recognition model and a food detection model. The storage and access action recognition model is used to obtain the judgment results of food storage and retrieval actions, and the food detection model is used to obtain information such as food type and quantity.

[0092] Specifically, a more powerful second recognition model can be deployed on the server side to facilitate the server to accurately identify food information.

[0093] Specifically, the remote server can obtain the second recognition model through two steps: collecting and labeling training data and fine-tuning the model. For example, the historical videos received by the server and the labels predicted by the second recognition model are collected, and these labels are manually reviewed and modified, and the modified labels and the corresponding original videos are used as training sets; the old model parameters are used as a benchmark, and the second recognition model is fine-tuned using the above training set until the second recognition model converges, thereby obtaining a newly trained second recognition model.

[0094] In the embodiment of the present invention, by obtaining a second recognition model, wherein the second recognition model is obtained based on a training sample annotated with food information corresponding to a plurality of sample images; the second recognition model is used to recognize the video stream data to obtain the second food information of the food. Thus, more accurate second food information of the food can be obtained through the second recognition model deployed on the remote server, thereby improving the user experience.

[0095] As a specific example, Figure 4 A flowchart of a third embodiment of a food identification method provided by an embodiment of the present invention is shown as follows: Figure 4 As shown, the food identification method provided in this embodiment may include the following steps:

[0096] S401, obtaining video stream data of the process of food entering and leaving the refrigerator.

[0097] S402, determining whether the refrigerator is currently connected to the Internet.

[0098] If not, execute S403; if so, execute S404.

[0099] S403, the refrigerator identifies the video stream data through the first recognition model, obtains first ingredient information of the ingredient, and stores the first ingredient information in a local offline database.

[0100] The first ingredient information of the ingredient may include the category, quantity and access action information of the ingredient.

[0101] S404, the refrigerator pre-processes and compresses the video stream data, and sends the processed video stream data to the remote server.

[0102] S405, the remote server receives the video stream data sent by the refrigerator, and writes the video stream data into the server disk.

[0103] S406, the remote server performs standardization processing on the video stream data, wherein the standardization processing includes decompression, key frame extraction and feature extraction.

[0104] Among them, decompression refers to restoring the compressed video to the original video, key frame extraction refers to taking the N images with the largest changes in the video as key frames, and feature extraction refers to obtaining the RGB information tensor of each key frame.

[0105] S407, merging the key frames and inputting them into a second recognition model to obtain second ingredient information of the ingredient, and storing the second ingredient information in a database on the server side.

[0106] The second ingredient information of the ingredient may include the category, quantity and access action information of the ingredient.

[0107] In an embodiment of the present invention, local or remote food identification of the collected video stream data can be initiated according to the networking status of the refrigerator, thereby realizing automatic and user-imperceptible food identification in any network environment. Moreover, food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0108] Figure 5 Schematic diagram of the structure of a food identification device provided by an embodiment of the present invention. Figure 5 As shown, the first food identification device 50 may be arranged in a refrigeration device, and the first food identification device 50 may include: an acquisition module 510 , a judgment module 520 , a determination module 530 and a sending module 540 .

[0109] Among them, the above-mentioned acquisition module 510 can be used to obtain video stream data of the process of food entering and exiting the refrigeration equipment and the first networking information of the refrigeration equipment; the above-mentioned judgment module 520 can be used to judge whether the refrigeration equipment is connected to the network based on the first networking information; the above-mentioned determination module 530 can be used to identify the video stream data if it is not connected to the network, and obtain the first food information of the food; the above-mentioned sending module 540 can be used to send the video stream data to the server if it is connected to the network, so that the server can identify the video stream data and obtain the second food information of the food.

[0110] The food identification device provided by the embodiment of the present invention obtains the video stream data of the food entering and exiting the refrigeration device and the first networking information of the refrigeration device through the acquisition module; determines whether the refrigeration device is connected to the network according to the first networking information through the judgment module; identifies the video stream data through the determination module to obtain the first food information of the food if it is not connected to the network; and sends the video stream data to the server through the sending module if it is connected to the network, so that the server can identify the video stream data and obtain the second food information of the food. Therefore, according to the networking status of the refrigeration device, local or remote food identification of the collected video stream data can be started, thereby realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0111] According to one embodiment of the present invention, the above-mentioned acquisition module 510 can also be used to: obtain the second networking information of the refrigeration equipment after a preset time; the above-mentioned sending module 540 can also be used to: if it is determined according to the second networking information that the refrigeration equipment is connected to the network, then the first ingredient information is sent to the server, so that the server can synchronize the ingredient information according to the first ingredient information.

[0112] According to one embodiment of the present invention, the above-mentioned determination module 530 can be specifically used to: determine a first recognition model, wherein the first recognition model is obtained based on a training sample that is labeled with food information corresponding to multiple sample images; through the first recognition model, the video stream data is recognized to obtain the first ingredient information of the food.

[0113] Figure 6 A schematic diagram of another food identification device provided by an embodiment of the present invention. Figure 6 As shown, the second food identification device 60 may be arranged in a server, and the second food identification device 60 may include: a receiving module 610 and an identification module 620 .

[0114] Among them, the above-mentioned receiving module 610 can be used to receive video stream data of the process of food entering and leaving the refrigeration equipment sent by the refrigeration equipment when the first preset condition is met, wherein the first preset condition is to determine that the refrigeration equipment is connected to the network based on the first networking information of the refrigeration equipment; the above-mentioned identification module 620 can be used to identify the video stream data and obtain the second food information of the food.

[0115] The food identification device provided by the embodiment of the present invention receives the video stream data of the food entering and exiting the refrigeration device sent by the refrigeration device through the receiving module when the first preset condition is met, wherein the first preset condition is to determine that the refrigeration device is connected to the network according to the first networking information of the refrigeration device; and to identify the video stream data through the identification module to obtain the second food information of the food. Therefore, according to the networking status of the refrigeration device, local or remote food identification of the collected video stream data can be started, realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0116] According to one embodiment of the present invention, the above-mentioned recognition module 620 can be specifically used to: parse video stream data to obtain M images, where M is an integer greater than 2; filter the M images to determine N key frame images with the largest changes among the M images, where M is greater than N and N is an integer; extract feature data of each key frame image, and obtain the second ingredient information of the ingredient based on the feature data of each key frame image.

[0117] According to an embodiment of the present invention, the identification module 620 may be specifically used to: perform a difference operation on every two adjacent images, and use the first N images with the largest difference as N key frame images.

[0118] According to one embodiment of the present invention, the above-mentioned receiving module 610 can also be used to: receive the first ingredient information sent by the refrigeration device when the second preset condition is met, wherein the first ingredient information is obtained by the refrigeration device identifying the video stream data when it is determined that the refrigeration device is not connected to the network according to the first networking information, and the second preset condition is to determine that the refrigeration device is connected to the network according to the second networking information of the refrigeration device after a preset time; the above-mentioned identification module 620 can also be used to synchronize the ingredient information of the ingredient according to the first ingredient information.

[0119] According to one embodiment of the present invention, the above-mentioned recognition module 620 can be specifically used to: obtain a second recognition model, wherein the second recognition model is obtained based on a training sample that is labeled with food information corresponding to multiple sample images; through the second recognition model, the video stream data is recognized to obtain the second ingredient information of the food.

[0120] In addition, corresponding to the food identification method provided in the above embodiment, the embodiment of the present invention also provides a refrigeration device, such as Figure 7 As shown, the refrigeration device 70 may include: a memory 710, a processor 720, and a program stored in the memory 710 and executable on the processor 720. When the processor 720 executes the program, all steps of the food identification method with the refrigeration device as the execution subject provided in the embodiment of the present invention are implemented.

[0121] In the above refrigeration equipment, by obtaining the video stream data of the process of food entering and leaving the refrigeration equipment and the first networking information of the refrigeration equipment; judging whether the refrigeration equipment is connected to the network according to the first networking information; if not, identifying the video stream data to obtain the first food information of the food; if connected to the network, sending the video stream data to the server so that the server can identify the video stream data and obtain the second food information of the food. Therefore, according to the networking status of the refrigeration equipment, local or remote food identification of the collected video stream data can be started, realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0122] In addition, corresponding to the food identification method provided in the above embodiment, the embodiment of the present invention also provides a server, such as Figure 8 As shown, the server 80 may include: a memory 810, a processor 820, and a program stored in the memory 810 and executable on the processor 820. When the processor 820 executes the program, all steps of the food identification method with the server as the execution subject provided in the embodiment of the present invention are implemented.

[0123] In the above server, when the first preset condition is met, the video stream data of the food entering and leaving the refrigeration device is received, wherein the first preset condition is to determine that the refrigeration device is connected to the network according to the first networking information of the refrigeration device; identify the video stream data to obtain the second food information of the food. Therefore, according to the networking status of the refrigeration device, local or remote food identification of the collected video stream data can be started, realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0124] In addition, corresponding to the food identification method provided in the above embodiment, the embodiment of the present invention further provides a computer-readable storage medium, on which a program is stored, and when the program is executed by a processor, all the steps of the food identification method of the embodiment of the present invention are implemented.

[0125] In the above-mentioned computer-readable storage medium, by obtaining the video stream data of the process of food entering and exiting the refrigeration equipment and the first networking information of the refrigeration equipment; judging whether the refrigeration equipment is connected to the network according to the first networking information; if not, identifying the video stream data to obtain the first food information of the food; if connected to the network, sending the video stream data to the server so that the server can identify the video stream data and obtain the second food information of the food. Therefore, according to the networking status of the refrigeration equipment, local or remote food identification of the collected video stream data can be started, realizing automatic and user-imperceptible food identification in any network environment, and food identification based on video stream data can obtain relatively accurate and comprehensive food information, thereby improving the user experience.

[0126] It should be noted that the logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be specifically implemented in any computer-readable medium for use by an instruction execution system, device or apparatus (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or apparatus and execute instructions), or in combination with these instruction execution systems, devices or apparatuses. For the purposes of this specification, "computer-readable medium" can be any device that can contain, store, communicate, propagate or transmit a program for use by an instruction execution system, device or apparatus, or in combination with these instruction execution systems, devices or apparatuses. More specific examples of computer-readable media (a non-exhaustive list) include the following: an electrical connection portion with one or more wirings (electronic device), a portable computer disk box (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable and programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disk read-only memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium and then editing, interpreting or processing in other suitable ways if necessary, and then stored in a computer memory.

[0127] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, a plurality of steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.

[0128] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.

[0129] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In the description of the present invention, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.

[0130] In the present invention, unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", "fixed" and the like should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements, unless otherwise clearly defined. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.

[0131] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and vary the above embodiments within the scope of the present invention.

Claims

1. A food identification method, characterized in that: Applied to refrigeration equipment, the method comprises: Acquire video stream data of a process of food entering and exiting the refrigeration device and first networking information of the refrigeration device; determining, according to the first networking information, whether the refrigeration equipment is connected to the network; If the network is not connected, the video stream data is identified to obtain first food information of the food; If the network is connected, the video stream data is sent to the server so that the server can identify the video stream data and obtain the second ingredient information of the ingredient.

2. The method according to claim 1, characterized in that: After obtaining the first ingredient information of the ingredient, the method further includes: Acquire second networking information of the refrigeration equipment after a preset time; If it is determined according to the second networking information that the refrigeration device has been connected to the network, the first food information is sent to the server so that the server synchronizes the food information according to the first food information.

3. The method according to claim 1 or 2, characterized in that: The step of identifying the video stream data to obtain first food information of the food includes: Determining a first recognition model, wherein the first recognition model is obtained based on a training sample annotated with food information corresponding to a plurality of sample images; The video stream data is identified through the first recognition model to obtain first ingredient information of the ingredient.

4. A food identification method, characterized in that: Applied to a server, the method comprises: When a first preset condition is met, receiving video stream data of a process of food entering and leaving the refrigeration device sent by the refrigeration device, wherein the first preset condition is determining that the refrigeration device has been connected to the network according to first networking information of the refrigeration device; The video stream data is identified to obtain second ingredient information of the ingredient.

5. The method according to claim 4, characterized in that The identifying the video stream data to obtain second food information of the food includes: Parsing the video stream data to obtain M images, where M is an integer greater than 2; Filtering the M images, determining the N key frame images with the largest changes among the M images, where M is greater than N and N is an integer; Feature data of each of the key frame images is extracted, and second ingredient information of the ingredient is obtained according to the feature data of each of the key frame images.

6. The method according to claim 5, characterized in that The filtering of the M images to determine the N key frame images with the largest changes among the M images includes: Difference is calculated for every two adjacent images, and the first N images with the largest difference are used as N key frame images.

7. The method according to any one of claims 4 to 6, characterized in that: The method further comprises: When a second preset condition is met, first food information sent by the refrigeration device is received, wherein the first food information is obtained by the refrigeration device identifying the video stream data when the refrigeration device is determined to be not connected to the network according to the first networking information, and the second preset condition is to determine that the refrigeration device is connected to the network according to the second networking information of the refrigeration device after a preset time; Synchronize the ingredient information of the ingredient according to the first ingredient information.

8. The method according to claim 4, characterized in that The identifying the video stream data to obtain second food information of the food includes: Obtaining a second recognition model, wherein the second recognition model is obtained based on a training sample annotated with food information corresponding to a plurality of sample images; The video stream data is identified by the second identification model to obtain second ingredient information of the ingredient.

9. A food identification device, characterized in that: The device comprises: An acquisition module, used for acquiring video stream data of a process of food entering and exiting a refrigeration device and first networking information of the refrigeration device; A judging module, configured to judge whether the refrigeration device is connected to the network according to the first networking information; a determination module, configured to identify the video stream data and obtain first ingredient information of the ingredient if the network is not connected; The sending module is used to send the video stream data to the server if the server is connected to the network, so that the server can identify the video stream data and obtain the second ingredient information of the ingredient.

10. A food identification device, characterized in that: The device comprises: A receiving module, configured to receive video stream data of a process of food entering and leaving the refrigeration device sent by the refrigeration device when a first preset condition is met, wherein the first preset condition is that the refrigeration device is determined to be connected to the network according to first networking information of the refrigeration device; The identification module is used to identify the video stream data and obtain the second ingredient information of the ingredient.

11. A refrigeration device, characterized in that: include: A memory, a processor, and a program stored in the memory and executable on the processor, wherein when the processor executes the program, the method according to any one of claims 1 to 3 is implemented.

12. A server, characterized in that: include: A memory, a processor, and a program stored in the memory and executable on the processor, wherein when the processor executes the program, the method according to any one of claims 4 to 8 is implemented.

13. A computer-readable storage medium, characterized in that: A program is stored thereon, and when the program is executed by a processor, the method according to any one of claims 1 to 8 is implemented.

Citation Information

Patent Citations

  • Food material recognition system and method, food material model training method, refrigerator and server

    CN107798277A

  • Intelligent refrigerator and food material input method

    CN111462190A

  • Cabinet food identification system and identification method

    CN111950414A

  • Offline task processing method and device, computer equipment and storage medium

    CN112667976A

  • Food material identification method and device and equipment

    CN113468936A