WO2020134411A1 - Merchandise category recognition method, apparatus, and electronic device - Google Patents

Merchandise category recognition method, apparatus, and electronic device Download PDF

Info

Publication number
WO2020134411A1
WO2020134411A1 PCT/CN2019/112523 CN2019112523W WO2020134411A1 WO 2020134411 A1 WO2020134411 A1 WO 2020134411A1 CN 2019112523 W CN2019112523 W CN 2019112523W WO 2020134411 A1 WO2020134411 A1 WO 2020134411A1
Authority
WO
WIPO (PCT)
Prior art keywords
feature vector
target
library
commodity
reference feature
Prior art date
Application number
PCT/CN2019/112523
Other languages
French (fr)
Chinese (zh)
Inventor
严小乐
朱皓
童俊艳
任烨
Original Assignee
杭州海康威视数字技术股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 杭州海康威视数字技术股份有限公司 filed Critical 杭州海康威视数字技术股份有限公司
Publication of WO2020134411A1 publication Critical patent/WO2020134411A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/50Context or environment of the image
    • G06V20/52Surveillance or monitoring of activities, e.g. for recognising suspicious objects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/22Matching criteria, e.g. proximity measures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • G06F18/2411Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches based on the proximity to a decision surface, e.g. support vector machines
    • GPHYSICS
    • G07CHECKING-DEVICES
    • G07FCOIN-FREED OR LIKE APPARATUS
    • G07F9/00Details other than those peculiar to special kinds or types of apparatus

Definitions

  • the present application relates to the field of data recognition technology, in particular to a method, device and electronic equipment for commodity category recognition.
  • the unmanned vending machine can be an unmanned vending rack or an unmanned vending cabinet.
  • unmanned vending machines can be applied to supermarkets, offices, campuses, cafeterias, shopping malls, etc. Since the unmanned vending machine is not managed by staff, in order to ensure that the products in the unmanned vending machine can be normally and orderly sold, it is necessary to identify the category of the goods in the unmanned vending machine; for example, after adding the goods to the unmanned vending machine , You need to identify the category of the added product.
  • the specific process of product category recognition is to use a sample image containing the product in the unmanned vending machine and the product category of the product in the unmanned vending machine to train a machine learning model, such as a convolutional neural network model, so When it is necessary to identify the product category, the trained machine learning model is used to identify the product category of the product in the unmanned vending machine.
  • a machine learning model such as a convolutional neural network model
  • the purpose of the embodiments of the present application is to provide a method, device and electronic device for commodity category recognition, so as to shorten the time consumed by the new category commodity updating process, and thereby improve the overall efficiency of commodity category recognition.
  • the specific technical solutions are as follows:
  • an embodiment of the present application provides a method for identifying commodity categories, the method including:
  • a preset reference feature vector library determines a first reference feature vector that matches the target feature vector, where the reference feature vector library includes multiple reference feature vectors, and each reference feature vector corresponds to a commodity category;
  • the commodity category corresponding to the first reference feature vector is determined as the commodity category of the target commodity.
  • the method further includes:
  • the reference feature vector library includes multiple feature vector sub-libraries, and the product categories corresponding to any two reference feature vectors in the same feature vector sub-library satisfy a predetermined difference condition, and the two product categories satisfy the predetermined difference
  • the condition is that the similarity between the appearances of the products under the two commodity categories is less than the first similarity
  • the step of determining the first reference feature vector matching the target feature vector from the preset reference feature vector library includes:
  • a first feature vector sub-library is determined from a preset reference feature vector library, where the first feature vector sub-library contains: a reference feature vector corresponding to a commodity category that meets a predetermined matching condition, and the commodity category meets a predetermined
  • the matching condition is: the similarity between the appearance of the commodity under the commodity category and the target commodity is greater than the second similarity;
  • the step of determining the first feature vector sub-library from the preset reference feature vector library includes:
  • the reference appearance data corresponding to each reference feature vector in the feature vector sub-library is determined.
  • the reference appearance data corresponding to each reference feature vector is: the reference feature vector Appearance data of the products under the corresponding product categories;
  • each feature vector sub-library calculates the similarity between the reference appearance data corresponding to each reference feature vector and the appearance data of the target product in the feature vector sub-library, if the calculated similarity includes greater than The similarity of the second similarity determines the feature vector sub-library as the first feature vector sub-library.
  • a plurality of feature vector sub-libraries included in the reference feature vector library correspond to a plurality of unmanned vending machines
  • the step of determining the first feature vector sub-library from the preset reference feature vector library includes:
  • the reference feature vector sub-library corresponding to the unmanned vending machine where the target product is located is determined as the first feature vector sub-library.
  • the step of performing commodity feature recognition on the target image to obtain the target feature vector of the target commodity contained in the target image includes:
  • the convolutional neural network is trained based on a plurality of sample images containing commodities and the commodity category of the commodities contained in each sample image.
  • the step of performing commodity feature recognition on the target image based on the pre-trained convolutional neural network to obtain the target feature vector of the target commodity contained in the target image includes:
  • commodity feature recognition is performed on the target area to obtain the target feature vector of the target commodity contained in the target image.
  • the step of determining the first reference feature vector matching the target feature vector from the preset reference feature vector library includes:
  • the reference feature vector with the largest similarity is determined as the first reference feature vector matching the target feature vector.
  • an embodiment of the present application provides a product category identification device, the device including:
  • the image acquisition module is used to acquire the target image containing the product area in the unmanned vending machine
  • a feature recognition module configured to perform commodity feature recognition on the target image to obtain a target feature vector of the target commodity contained in the target image
  • the feature vector determination module is used to determine a first reference feature vector matching the target feature vector from a preset reference feature vector library, wherein the reference feature vector library includes multiple reference feature vectors, each reference Feature vector corresponds to a commodity category;
  • the commodity category determination module is configured to determine the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity.
  • the device further includes: an update module;
  • the update module is used to obtain an image of a new category product to be uploaded; perform product feature recognition on the image of the new category product to obtain a feature vector of the new category product; and convert the feature vector of the new category product , Added to the reference feature vector library.
  • the reference feature vector library includes multiple feature vector sub-libraries, and the product categories corresponding to any two reference feature vectors in the same feature vector sub-library satisfy a predetermined difference condition, and the two product categories satisfy the predetermined difference
  • the condition is that the similarity between the appearances of the products under the two commodity categories is less than the first similarity
  • the feature vector determination module includes:
  • the feature vector sub-library determination module is used to determine a first feature vector sub-library from a preset reference feature vector library, where the first feature vector sub-library contains: a reference to which the corresponding product category meets a predetermined matching condition Feature vector, the predetermined matching condition that the commodity category meets is: the similarity between the appearance of the commodity under the commodity category and the target commodity is greater than the second similarity;
  • the feature vector sub-library determination module is specifically used for:
  • the reference appearance data corresponding to each reference feature vector in the feature vector sub-library is determined.
  • the reference appearance data corresponding to each reference feature vector is: the reference feature vector Appearance data of the products under the corresponding product categories;
  • each feature vector sub-library calculates the similarity between the reference appearance data corresponding to each reference feature vector and the appearance data of the target product in the feature vector sub-library, if the calculated similarity includes greater than The similarity of the second similarity determines the feature vector sub-library as the first feature vector sub-library.
  • a plurality of feature vector sub-libraries included in the reference feature vector library correspond to a plurality of unmanned vending machines
  • the feature vector sub-library determination module is specifically used for:
  • the reference feature vector sub-library corresponding to the unmanned vending machine where the target product is located is determined as the first feature vector sub-library.
  • the feature recognition module includes:
  • the feature recognition unit is used to perform commodity feature recognition on the target image based on the pre-trained convolutional neural network to obtain the target feature vector of the target commodity contained in the target image;
  • the convolutional neural network is trained based on a plurality of sample images containing commodities and the commodity category of the commodities contained in each sample image.
  • the feature recognition unit is specifically used for:
  • commodity feature recognition is performed on the target area to obtain a target feature vector of the target commodity contained in the target image.
  • the feature vector determination module is specifically used for:
  • the reference feature vector with the largest similarity is determined as the first reference feature vector matching the target feature vector.
  • an embodiment of the present application provides an electronic device, including a processor, a communication interface, a memory, and a communication bus, where the processor, the communication interface, and the memory complete communication with each other through the communication bus;
  • Memory used to store computer programs
  • the processor when used to execute the program stored on the memory, implements the commodity category identification method described in the first aspect.
  • an embodiment of the present application provides a computer-readable storage medium in which a computer program is stored, and when the computer program is executed by a processor, the commodity category recognition described in the first aspect is realized method.
  • the technical solution provided by the embodiment of the present application extracts the target feature vector of the target commodity when identifying the commodity category of the target commodity, and determines the first reference feature vector matching the target feature vector from the preset reference feature vector library, The product category corresponding to the first reference feature vector is determined as the product category of the target product. Since this solution implements commodity category recognition based on a preset reference feature vector library, when a new category product is added to an unmanned vending machine, the feature vector of the new category product can be used to update the reference feature vector library without retraining the machine Learning the model, therefore, this solution can shorten the time spent on the new process of new category of goods, which can improve the overall efficiency of commodity category recognition.
  • FIG. 1 is a flowchart of a method for identifying commodity categories provided by an embodiment of the present application
  • FIG. 2 is a schematic diagram of a product category identification device provided by an embodiment of the present application.
  • FIG. 3 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
  • the embodiments of the present application provide a commodity category recognition method, device, and electronic equipment.
  • the execution subject of a method for identifying a commodity category may be a device for identifying a commodity category, and the apparatus for identifying a commodity category may run in an electronic device, where the electronic device may be
  • the human vending machine may also be a background server or the like that is communicatively connected to the unmanned vending machine.
  • the embodiment of the present application does not limit the electronic device.
  • each unmanned vending machine may be provided with several layers of shelves.
  • An image acquisition device is installed on the top of the shelf, and the image collected by the image acquisition device may contain all the products in the shelf.
  • the reference feature vector library may include feature vectors of various categories of merchandise in each vending machine. Among them, each set of feature vectors in the reference feature vector library corresponds to a commodity category.
  • a method for identifying a commodity category may include the following steps:
  • an unmanned vending machine can be provided with an image collection device, and the image collection device can collect images containing the product area.
  • the image acquisition device acquires the image containing the product area
  • the electronic device as the execution subject can acquire the image containing the product area.
  • the image containing the product area may be referred to as the target image.
  • the electronic device as the execution subject can obtain the target image including the product area in the unmanned vending machine in the following two ways:
  • the first way the electronic device as the execution subject can detect in real time whether the image acquisition device acquires the target image of the commodity area containing the unmanned vending machine, and if it detects that the image acquisition device acquires the target of the commodity area containing the unmanned vending machine For images, the electronic device can acquire the target image containing the product area of the unmanned vending machine from the image acquisition device.
  • the second way After the image acquisition device collects the target image of the product area containing the unmanned vending machine, it can send the target image of the product area containing the unmanned vending machine to the electronic device as the execution subject, so as to execute
  • the electronic device of the main body can acquire the target image of the merchandise area including the unsold shelves.
  • S120 Perform product feature recognition on the target image to obtain a target feature vector of the target product included in the target image.
  • the electronic device as the execution subject After the electronic device as the execution subject obtains the target image, it can perform commodity feature recognition on the target image to obtain the target feature vector of the target commodity contained in the target image.
  • the step of performing commodity feature recognition on the target image to obtain the target feature vector of the target commodity contained in the target image may include:
  • the target image is subjected to commodity feature recognition to obtain the target feature vector of the target commodity contained in the target image;
  • the convolutional neural network is obtained by training based on a plurality of sample images containing commodities and commodity categories of the commodities contained in each sample image.
  • the plurality of sample images containing commodities may be: images collected by image collecting devices provided in each unmanned vending machine.
  • the step of performing commodity feature recognition on the target image based on the pre-trained convolutional neural network to obtain the target feature vector of the target commodity contained in the target image may include:
  • commodity feature recognition is performed on the target area to obtain the target feature vector of the target commodity contained in the target image.
  • the target area included in the target image can be set in advance.
  • the target area included in the target image may also be automatically determined by the image acquisition device, etc.
  • the embodiment of the present application does not limit the specific implementation manner of extracting the target area where the target product included in the target image is located.
  • the target image may be subjected to product feature recognition based on a feature representation method such as a color histogram or a gradient histogram of the target image to obtain a target feature vector of the target product included in the target image.
  • a feature representation method such as a color histogram or a gradient histogram of the target image to obtain a target feature vector of the target product included in the target image.
  • S130 Determine a first reference feature vector that matches the target feature vector from a preset reference feature vector library, where the reference feature vector library includes multiple reference feature vectors, and each reference feature vector corresponds to a commodity category.
  • the first reference feature vector matching the target feature vector can be determined from a preset reference feature vector library. It can be understood that, since the first reference feature vector matches the target feature vector, the product category corresponding to the first reference feature vector also matches the product category corresponding to the target feature vector.
  • the step of determining the first reference feature vector matching the target feature vector from the preset reference feature vector library may include:
  • the reference feature vector with the largest similarity to the target feature vector is determined as the first reference feature vector.
  • the reference feature vector with the highest similarity to the target feature vector can be determined Is the first reference feature vector.
  • S140 Determine the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity.
  • the product category corresponding to the first reference feature vector is the product category corresponding to the target feature vector; and because the target feature vector is the feature vector of the target product Therefore, the product category corresponding to the target feature vector can be determined as the product category of the target product.
  • the target feature vector of the target commodity is extracted, and the first reference matching the target feature vector is determined from the preset reference feature vector library
  • the feature vector determines the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity. Since this solution implements commodity category recognition based on a preset reference feature vector library, when a new category product is added to an unmanned vending machine, the feature vector of the new category product can be used to update the reference feature vector library without retraining the machine Learning the model, therefore, this solution can shorten the time spent on the new process of new category of goods, which can improve the overall efficiency of commodity category recognition.
  • the method for identifying commodity categories provided in the embodiments of the present application may further include:
  • the feature vector of the new category of goods is added to the reference feature vector library.
  • the product category recognition can be implemented for the new category of commodities according to the steps shown in S110-S140.
  • the reference feature vector library may include multiple feature vector sub-libraries, and any two reference feature vectors in the same feature vector sub-library correspond to The product category meets a predetermined difference condition, and the predetermined difference condition satisfied by the two product categories is: the similarity between appearances of the products under the two product categories is less than the first similarity;
  • the step of determining the first reference feature vector matching the target feature vector from the preset reference feature vector library may include the following two steps:
  • Step 1 Determine a first feature vector sub-library from a preset reference feature vector library, where the first feature vector sub-library contains: a reference feature vector corresponding to a product category that meets a predetermined matching condition, the product category meets The predetermined matching condition is: the similarity between the appearance of the commodity corresponding to the commodity category and the target commodity is greater than the second similarity;
  • Step 2 Determine the first reference feature vector matching the target feature vector from the first feature vector sub-library.
  • the confusion analysis method can be human eye observation judgment, merchant presetting, or algorithm analysis, etc.
  • the feature vectors of the above eight products are put into the same feature vector sub-library, and the feature vectors of the above two kinds of products are put into different feature vector sub-libraries.
  • the size of the preset similarity may be set according to actual conditions, and the size of the preset similarity is not specifically limited in the embodiment of the present application.
  • the feature vector sub-library can be associated with the unmanned vending machine, that is, each unmanned vending machine can correspond to a feature vector sub-library, and the feature vector sub-library contains the unmanned vending machine. Feature vectors of all commodities in the cargo plane. In this way, when identifying the product category of the product in the unmanned vending machine, it is possible to directly use the feature vector sub-library corresponding to the unmanned vending machine to perform product category recognition, thereby increasing the speed of product category recognition.
  • step 1 from the preset reference feature vector library, there may be multiple specific implementation manners for determining the first feature vector sub-library.
  • the step of determining the first feature vector sub-library from the preset reference feature vector library may include:
  • each feature vector sub-library in the preset reference feature vector library determines the reference appearance data corresponding to each reference feature vector in the feature vector sub-library, and the reference appearance data corresponding to each reference feature vector is: the reference Appearance data of products under the product category corresponding to the feature vector;
  • each feature vector sub-library calculates the similarity between the reference appearance data corresponding to each reference feature vector in the feature vector sub-library and the appearance data of the target product, if the calculated similarity includes greater than the second similarity Degree of similarity, the feature vector sub-library is determined as the first feature vector sub-library.
  • the size of the second similarity can be set according to actual conditions, which is not specifically limited in the embodiments of the present application. It can be understood that the determined first feature vector sub-library contains the same reference feature vector as the target feature vector.
  • each feature vector sub-library may correspond to a commodity image library.
  • multiple feature vector sub-libraries included in the reference feature vector library may correspond to multiple unmanned vending machines
  • step 1 the step of determining the first feature vector sub-library from the preset reference feature vector library may include:
  • the reference feature vector sub-library corresponding to the unmanned vending machine where the target product is located in the preset reference feature vector library is determined as the first feature vector sub-library.
  • the target product is stored on the unmanned vending machine, so for each unmanned vending machine, when you want to identify the product category of any target product on the unmanned vending machine, you can
  • the feature vector sub-library corresponding to the unmanned vending machine serves as the first feature vector sub-library.
  • the specific implementation manner of the first reference feature vector matching the target feature vector is determined from the first feature vector sub-library, which is determined to match the target feature vector from the preset reference feature vector library in S130
  • the first implementation manner of the first reference feature vector of is the same or similar, and will not be repeated here.
  • an embodiment of the present application provides a product category identification device. As shown in FIG. 2, the device includes:
  • the image acquisition module 210 is used to acquire a target image containing the product area in the unmanned vending machine
  • the feature recognition module 220 is used to perform commodity feature recognition on the target image to obtain a target feature vector of the target commodity contained in the target image;
  • the feature vector determination module 230 is configured to determine a first reference feature vector matching the target feature vector from a preset reference feature vector library, wherein the reference feature vector library includes multiple reference feature vectors, each The reference feature vector corresponds to a commodity category;
  • the commodity category determination module 240 is configured to determine the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity.
  • the device further includes: an update module;
  • the update module is used to obtain an image of a new category product to be uploaded; perform product feature recognition on the image of the new category product to obtain a feature vector of the new category product; and convert the feature vector of the new category product , Added to the reference feature vector library.
  • the target feature vector of the target commodity is extracted, and the first reference matching the target feature vector is determined from the preset reference feature vector library
  • the feature vector determines the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity. Since this solution implements commodity category recognition based on a preset reference feature vector library, when a new category product is added to an unmanned vending machine, the feature vector of the new category product can be used to update the reference feature vector library without retraining the machine Learning the model, therefore, this solution can shorten the time spent on the new process of new category of goods, which can improve the overall efficiency of commodity category recognition.
  • the reference feature vector library includes multiple feature vector sub-libraries, and the product categories corresponding to any two reference feature vectors in the same feature vector sub-library satisfy a predetermined difference condition, and the two product categories satisfy the predetermined difference
  • the condition is that the similarity between the appearances of the products under the two commodity categories is less than the first similarity
  • the feature vector determination module includes:
  • the feature vector sub-library determination module is used to determine a first feature vector sub-library from a preset reference feature vector library, where the first feature vector sub-library contains: a reference to which the corresponding product category meets a predetermined matching condition Feature vector, the predetermined matching condition met by the product category is: the similarity between the appearance of the product under the product category and the target product is greater than the second similarity;
  • the feature vector sub-library determination module is specifically used for:
  • the reference appearance data corresponding to each reference feature vector in the feature vector sub-library is determined.
  • the reference appearance data corresponding to each reference feature vector is: the reference feature vector Appearance data of the products under the corresponding product categories;
  • each feature vector sub-library calculates the similarity between the reference appearance data corresponding to each reference feature vector and the appearance data of the target product in the feature vector sub-library, if the calculated similarity includes greater than the second
  • the similarity of the similarity determines the feature vector sub-library as the first feature vector sub-library.
  • a plurality of feature vector sub-libraries included in the reference feature vector library correspond to a plurality of unmanned vending machines
  • the feature vector sub-library determination module is specifically used for:
  • the reference feature vector sub-library corresponding to the unmanned vending machine where the target product is located is determined as the first feature vector sub-library.
  • the feature recognition module includes:
  • the feature recognition unit is used to perform commodity feature recognition on the target image based on the pre-trained convolutional neural network to obtain the target feature vector of the target commodity contained in the target image;
  • the convolutional neural network is trained based on a plurality of sample images containing commodities and feature vectors of commodities contained in each sample image.
  • the feature recognition unit is specifically used for:
  • commodity feature recognition is performed on the target area to obtain the target feature vector of the target commodity contained in the target image.
  • the feature vector determination module is specifically used for:
  • the reference feature vector with the largest similarity is determined as the first reference feature vector matching the target feature vector.
  • an embodiment of the present application further provides an electronic device, as shown in FIG. 3, including a processor 301, a communication interface 302, a memory 303, and a communication bus 304, where the processor 301, the communication interface 302, and the memory 303 Complete communication with each other through the communication bus 304,
  • Memory 303 used to store computer programs
  • the processor 301 is configured to implement the commodity category identification method described in the first aspect when executing the program stored in the memory 303.
  • the target feature vector of the target commodity is extracted, and the first reference matching the target feature vector is determined from the preset reference feature vector library
  • the feature vector determines the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity. Since this solution implements commodity category recognition based on a preset reference feature vector library, when a new category product is added to an unmanned vending machine, the feature vector of the new category product can be used to update the reference feature vector library without retraining the machine Learning the model, therefore, this solution can shorten the time spent on the new process of new category of goods, which can improve the overall efficiency of commodity category recognition.
  • the communication bus mentioned in the above electronic equipment may be a peripheral component interconnection standard (Peripheral Component Interconnect, PCI) bus or an extended industry standard structure (Extended Industry Standard Architecture, EISA) bus, etc.
  • PCI peripheral component interconnection standard
  • EISA Extended Industry Standard Architecture
  • the communication bus can be divided into an address bus, a data bus, and a control bus. For ease of representation, only a thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.
  • the communication interface is used for communication between the electronic device and other devices.
  • the memory may include random access memory (Random Access Memory, RAM), or non-volatile memory (Non-Volatile Memory, NVM), for example, at least one disk memory.
  • RAM Random Access Memory
  • NVM Non-Volatile Memory
  • the memory may also be at least one storage device located away from the foregoing processor.
  • the aforementioned processor may be a general-purpose processor, including a central processor (Central Processing Unit, CPU), a network processor (Network Processor, NP), etc.; it may also be a digital signal processor (Digital Signal Processing, DSP), dedicated integration Circuit (Application Specific Integrated Circuit, ASIC), field programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components.
  • a central processor Central Processing Unit, CPU
  • NP Network Processor
  • DSP Digital Signal Processing
  • ASIC Application Specific Integrated Circuit
  • FPGA Field-Programmable Gate Array
  • an embodiment of the present application provides a computer-readable storage medium in which a computer program is stored, and when the computer program is executed by a processor, the commodity category recognition described in the first aspect is realized method.
  • the target feature vector of the target commodity is extracted, and the first reference matching the target feature vector is determined from the preset reference feature vector library
  • the feature vector determines the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity. Since this solution implements commodity category recognition based on a preset reference feature vector library, when a new category product is added to an unmanned vending machine, the feature vector of the new category product can be used to update the reference feature vector library without retraining the machine Learning the model, therefore, this solution can shorten the time spent on the new process of new category of goods, which can improve the overall efficiency of commodity category recognition.

Abstract

A merchandise category recognition method, apparatus, and electronic device, the method comprising: acquiring a target image of a merchandise region contained in an unmanned vending machine (S110); performing merchandise feature recognition on the target image to obtain a target feature vector of target merchandise contained in the target image (S120); determining from a preset reference feature vector library a first reference feature vector that matches the target feature vector (S130); and determining a merchandise category corresponding to the first reference feature vector to be the merchandise category of the target merchandise (S140). The described method may shorten the time spent on updating a new category of merchandise, thereby improving the overall efficiency of merchandise category recognition.

Description

一种商品类别识别方法、装置及电子设备Commodity category recognition method, device and electronic equipment
本申请要求于2018年12月29日提交中国专利局、申请号为201811638179.8、发明名称为“一种商品类别识别方法、装置及电子设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application requires the priority of the Chinese patent application submitted to the China Patent Office on December 29, 2018, with the application number 201811638179.8 and the invention titled "A commodity class identification method, device and electronic equipment", the entire contents of which are incorporated by reference In this application.
技术领域Technical field
本申请涉及数据识别技术领域,特别是涉及一种商品类别识别方法、装置及电子设备。The present application relates to the field of data recognition technology, in particular to a method, device and electronic equipment for commodity category recognition.
背景技术Background technique
随着科学技术的发展,无人售货机的应用范围越来越广,其中,该无人售货机可以为无人售货架或无人售货柜。例如,无人售货机可以应用到超市、办公室、校园、食堂、商场等。由于无人售货机没有工作人员的管理,为了确保无人售货机中的商品能够正常有序地销售,需要识别无人售货机中的商品的类别;例如,在无人售货机添加了商品后,需要识别所添加的商品的类别。With the development of science and technology, the application range of unmanned vending machines is getting wider and wider. Among them, the unmanned vending machine can be an unmanned vending rack or an unmanned vending cabinet. For example, unmanned vending machines can be applied to supermarkets, offices, campuses, cafeterias, shopping malls, etc. Since the unmanned vending machine is not managed by staff, in order to ensure that the products in the unmanned vending machine can be normally and orderly sold, it is necessary to identify the category of the goods in the unmanned vending machine; for example, after adding the goods to the unmanned vending machine , You need to identify the category of the added product.
相关技术中,商品类别识别的具体过程为:利用包含无人售货机中的商品的样本图像以及该无人售货机中的商品的商品类别,训练机器学习模型,例如卷积神经网络模型,从而在需要识别商品类别时,利用训练完成的机器学习模型识别该无人售货机中的商品的商品类别。In the related art, the specific process of product category recognition is to use a sample image containing the product in the unmanned vending machine and the product category of the product in the unmanned vending machine to train a machine learning model, such as a convolutional neural network model, so When it is necessary to identify the product category, the trained machine learning model is used to identify the product category of the product in the unmanned vending machine.
由于相关技术中所利用的机器学习模型是基于无人售货机中固定的商品类别所训练的,那么,一旦需要增加新类别商品,为了能够识别新类别商品的商品类别,便需要重新训练机器学习模型,这无疑导致新类别商品的上新过程耗时较长,进而影响商品类别识别的整体效率。Since the machine learning model used in the related art is trained based on the fixed product category in the unmanned vending machine, then, once a new category product needs to be added, in order to be able to identify the product category of the new category product, it is necessary to retrain the machine learning Model, which undoubtedly leads to a longer time for the new process of the new category of goods, which in turn affects the overall efficiency of commodity category recognition.
发明内容Summary of the invention
本申请实施例的目的在于提供一种商品类别识别方法、装置及电子设备,以缩短新类别商品的上新过程所消耗的时间,进而提升商品类别识别的整体效率。具体技术方案如下:The purpose of the embodiments of the present application is to provide a method, device and electronic device for commodity category recognition, so as to shorten the time consumed by the new category commodity updating process, and thereby improve the overall efficiency of commodity category recognition. The specific technical solutions are as follows:
第一方面,本申请实施例提供了一种商品类别识别方法,所述方法包括:In a first aspect, an embodiment of the present application provides a method for identifying commodity categories, the method including:
获取包含无人售货机中的商品区域的目标图像;Get the target image containing the product area in the unmanned vending machine;
对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量;Performing commodity feature recognition on the target image to obtain a target feature vector of the target commodity contained in the target image;
从预设的参考特征向量库中,确定与所述目标特征向量匹配的第一参考特征向量,其中,所述参考特征向量库包含多个参考特征向量,每一参考特征向量对应一个商品类别;From a preset reference feature vector library, determine a first reference feature vector that matches the target feature vector, where the reference feature vector library includes multiple reference feature vectors, and each reference feature vector corresponds to a commodity category;
将所述第一参考特征向量对应的商品类别,确定为所述目标商品的商品类别。The commodity category corresponding to the first reference feature vector is determined as the commodity category of the target commodity.
可选地,所述方法还包括:Optionally, the method further includes:
获得待上新的新类别商品的图像;Obtain images of new and new products to be uploaded;
对所述新类别商品的图像进行商品特征识别,得到所述新类别商品的特征向量;Performing commodity feature recognition on the image of the new category commodity to obtain a feature vector of the new category commodity;
将所述新类别商品的特征向量,增加至所述参考特征向量库中。Add the feature vectors of the new category of commodities to the reference feature vector library.
可选的,所述参考特征向量库包含多个特征向量子库,同一特征向量子库中的任意两个参考特征向量所对应的商品类别满足预定差异条件,该两个商品类别满足的预定差异条件为:该两个商品类别下的商品的外观间相似度小于第一相似度;Optionally, the reference feature vector library includes multiple feature vector sub-libraries, and the product categories corresponding to any two reference feature vectors in the same feature vector sub-library satisfy a predetermined difference condition, and the two product categories satisfy the predetermined difference The condition is that the similarity between the appearances of the products under the two commodity categories is less than the first similarity;
所述从预设的参考特征向量库中,确定与所述目标特征向量匹配的第一参考特征向量的步骤,包括:The step of determining the first reference feature vector matching the target feature vector from the preset reference feature vector library includes:
从预设的参考特征向量库中,确定第一特征向量子库,其中,所述第一特征向量子库中包含:所对应商品类别符合预定匹配条件的参考特征向量,该商品类别符合的预定匹配条件为:该商品类别下的商品与所述目标商品的外观间相似度大于第二相似度;A first feature vector sub-library is determined from a preset reference feature vector library, where the first feature vector sub-library contains: a reference feature vector corresponding to a commodity category that meets a predetermined matching condition, and the commodity category meets a predetermined The matching condition is: the similarity between the appearance of the commodity under the commodity category and the target commodity is greater than the second similarity;
从所述第一特征向量子库中,确定与所述目标特征向量匹配的第一参考特征向量。From the first feature vector sub-library, determine a first reference feature vector that matches the target feature vector.
可选的,所述从预设的参考特征向量库中,确定第一特征向量子库的步 骤,包括:Optionally, the step of determining the first feature vector sub-library from the preset reference feature vector library includes:
针对预设的参考特征向量库中的每一特征向量子库,确定该特征向量子库中各个参考特征向量对应的参考外观数据,每一参考特征向量对应的参考外观数据为:该参考特征向量所对应商品类别下的商品的外观数据;For each feature vector sub-library in the preset reference feature vector library, the reference appearance data corresponding to each reference feature vector in the feature vector sub-library is determined. The reference appearance data corresponding to each reference feature vector is: the reference feature vector Appearance data of the products under the corresponding product categories;
从所述目标图像中获取所述目标商品的外观数据;Obtaining appearance data of the target product from the target image;
针对每一特征向量子库,分别计算该特征向量子库中,每个参考特征向量对应的参考外观数据与所述目标商品的外观数据的相似度,如果所计算得到的相似度中包含有大于第二相似度的相似度,将该特征向量子库确定为第一特征向量子库。For each feature vector sub-library, calculate the similarity between the reference appearance data corresponding to each reference feature vector and the appearance data of the target product in the feature vector sub-library, if the calculated similarity includes greater than The similarity of the second similarity determines the feature vector sub-library as the first feature vector sub-library.
可选的,所述参考特征向量库包含的多个特征向量子库与多个无人售货机一一对应;Optionally, a plurality of feature vector sub-libraries included in the reference feature vector library correspond to a plurality of unmanned vending machines;
所述从预设的参考特征向量库中,确定第一特征向量子库的步骤,包括:The step of determining the first feature vector sub-library from the preset reference feature vector library includes:
将预设的参考特征向量库中,与目标商品所在无人售货机对应的参考特征向量子库确定为第一特征向量子库。In the preset reference feature vector library, the reference feature vector sub-library corresponding to the unmanned vending machine where the target product is located is determined as the first feature vector sub-library.
可选的,所述对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量的步骤,包括:Optionally, the step of performing commodity feature recognition on the target image to obtain the target feature vector of the target commodity contained in the target image includes:
基于预先训练完成的卷积神经网络,对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量;Based on the pre-trained convolutional neural network, perform commodity feature recognition on the target image to obtain the target feature vector of the target commodity contained in the target image;
其中,所述卷积神经网络为基于多个包含商品的样本图像与每个样本图像所包含商品的商品类别所训练得到的。Wherein, the convolutional neural network is trained based on a plurality of sample images containing commodities and the commodity category of the commodities contained in each sample image.
可选的,所述基于预先训练完成的卷积神经网络,对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量的步骤,包括:Optionally, the step of performing commodity feature recognition on the target image based on the pre-trained convolutional neural network to obtain the target feature vector of the target commodity contained in the target image includes:
提取所述目标图像包含的目标商品所在的目标区域;Extract the target area where the target commodity contained in the target image is located;
基于预先训练完成的卷积神经网络,对所述目标区域进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量。Based on the pre-trained convolutional neural network, commodity feature recognition is performed on the target area to obtain the target feature vector of the target commodity contained in the target image.
可选的,所述从预设的参考特征向量库中,确定与所述目标特征向量匹配的第一参考特征向量的步骤,包括:Optionally, the step of determining the first reference feature vector matching the target feature vector from the preset reference feature vector library includes:
分别计算预设的参考特征向量库中,每个参考特征向量与所述目标特征向量的相似度;Calculating the similarity between each reference feature vector and the target feature vector in the preset reference feature vector library separately;
将相似度最大的参考特征向量确定为与所述目标特征向量匹配的第一参考特征向量。The reference feature vector with the largest similarity is determined as the first reference feature vector matching the target feature vector.
第二方面,本申请实施例提供了一种商品类别识别装置,所述装置包括:In a second aspect, an embodiment of the present application provides a product category identification device, the device including:
图像获取模块,用于获取包含无人售货机中的商品区域的目标图像;The image acquisition module is used to acquire the target image containing the product area in the unmanned vending machine;
特征识别模块,用于对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量;A feature recognition module, configured to perform commodity feature recognition on the target image to obtain a target feature vector of the target commodity contained in the target image;
特征向量确定模块,用于从预设的参考特征向量库中,确定与所述目标特征向量匹配的第一参考特征向量,其中,所述参考特征向量库包含多个参考特征向量,每一参考特征向量对应一个商品类别;The feature vector determination module is used to determine a first reference feature vector matching the target feature vector from a preset reference feature vector library, wherein the reference feature vector library includes multiple reference feature vectors, each reference Feature vector corresponds to a commodity category;
商品类别确定模块,用于将所述第一参考特征向量对应的商品类别,确定为所述目标商品的商品类别。The commodity category determination module is configured to determine the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity.
可选地,所述装置还包括:更新模块;Optionally, the device further includes: an update module;
所述更新模块,用于获得待上新的新类别商品的图像;对所述新类别商品的图像进行商品特征识别,得到所述新类别商品的特征向量;将所述新类别商品的特征向量,增加至所述参考特征向量库中。The update module is used to obtain an image of a new category product to be uploaded; perform product feature recognition on the image of the new category product to obtain a feature vector of the new category product; and convert the feature vector of the new category product , Added to the reference feature vector library.
可选的,所述参考特征向量库包含多个特征向量子库,同一特征向量子库中的任意两个参考特征向量所对应的商品类别满足预定差异条件,该两个商品类别满足的预定差异条件为:该两个商品类别下的商品的外观间相似度小于第一相似度;Optionally, the reference feature vector library includes multiple feature vector sub-libraries, and the product categories corresponding to any two reference feature vectors in the same feature vector sub-library satisfy a predetermined difference condition, and the two product categories satisfy the predetermined difference The condition is that the similarity between the appearances of the products under the two commodity categories is less than the first similarity;
所述特征向量确定模块,包括:The feature vector determination module includes:
特征向量子库确定模块,用于从预设的参考特征向量库中,确定第一特征向量子库,其中,所述第一特征向量子库中包含:所对应商品类别符合预 定匹配条件的参考特征向量,该商品类别符合的预定匹配条件为:该商品类别下的的商品与所述目标商品的外观间相似度大于第二相似度;The feature vector sub-library determination module is used to determine a first feature vector sub-library from a preset reference feature vector library, where the first feature vector sub-library contains: a reference to which the corresponding product category meets a predetermined matching condition Feature vector, the predetermined matching condition that the commodity category meets is: the similarity between the appearance of the commodity under the commodity category and the target commodity is greater than the second similarity;
从所述第一特征向量子库中,确定与所述目标特征向量匹配的第一参考特征向量。From the first feature vector sub-library, determine a first reference feature vector that matches the target feature vector.
可选的,所述特征向量子库确定模块,具体用于:Optionally, the feature vector sub-library determination module is specifically used for:
针对预设的参考特征向量库中的每一特征向量子库,确定该特征向量子库中各个参考特征向量对应的参考外观数据,每一参考特征向量对应的参考外观数据为:该参考特征向量所对应商品类别下的商品的外观数据;For each feature vector sub-library in the preset reference feature vector library, the reference appearance data corresponding to each reference feature vector in the feature vector sub-library is determined. The reference appearance data corresponding to each reference feature vector is: the reference feature vector Appearance data of the products under the corresponding product categories;
从所述目标图像中获取所述目标商品的外观数据;Obtaining appearance data of the target product from the target image;
针对每一特征向量子库,分别计算该特征向量子库中,每个参考特征向量对应的参考外观数据与所述目标商品的外观数据的相似度,如果所计算得到的相似度中包含有大于第二相似度的相似度,将该特征向量子库确定为第一特征向量子库。For each feature vector sub-library, calculate the similarity between the reference appearance data corresponding to each reference feature vector and the appearance data of the target product in the feature vector sub-library, if the calculated similarity includes greater than The similarity of the second similarity determines the feature vector sub-library as the first feature vector sub-library.
可选的,所述参考特征向量库包含的多个特征向量子库与多个无人售货机一一对应;Optionally, a plurality of feature vector sub-libraries included in the reference feature vector library correspond to a plurality of unmanned vending machines;
所述特征向量子库确定模块,具体用于:The feature vector sub-library determination module is specifically used for:
将预设的参考特征向量库中,与目标商品所在无人售货机对应的参考特征向量子库确定为第一特征向量子库。In the preset reference feature vector library, the reference feature vector sub-library corresponding to the unmanned vending machine where the target product is located is determined as the first feature vector sub-library.
可选的,所述特征识别模块,包括:Optionally, the feature recognition module includes:
特征识别单元,用于基于预先训练完成的卷积神经网络,对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量;The feature recognition unit is used to perform commodity feature recognition on the target image based on the pre-trained convolutional neural network to obtain the target feature vector of the target commodity contained in the target image;
其中,所述卷积神经网络为基于多个包含商品的样本图像与每个样本图像所包含商品的商品类别所训练得到的。Wherein, the convolutional neural network is trained based on a plurality of sample images containing commodities and the commodity category of the commodities contained in each sample image.
可选的,所述特征识别单元,具体用于:Optionally, the feature recognition unit is specifically used for:
提取所述目标图像包含的目标商品所在的目标区域;Extract the target area where the target commodity contained in the target image is located;
基于预先训练完成的卷积神经网络,对所述目标区域进行商品特征识别, 得到所述目标图像包含的目标商品的目标特征向量。Based on the pre-trained convolutional neural network, commodity feature recognition is performed on the target area to obtain a target feature vector of the target commodity contained in the target image.
可选的,所述特征向量确定模块,具体用于:Optionally, the feature vector determination module is specifically used for:
分别计算参考特征向量库中,每个参考特征向量与所述目标特征向量的相似度;Calculating the similarity between each reference feature vector and the target feature vector in the reference feature vector library;
将相似度最大的参考特征向量确定为与所述目标特征向量匹配的第一参考特征向量。The reference feature vector with the largest similarity is determined as the first reference feature vector matching the target feature vector.
第三方面,本申请实施例提供了一种电子设备,包括处理器、通信接口、存储器和通信总线,其中,处理器,通信接口,存储器通过通信总线完成相互间的通信;In a third aspect, an embodiment of the present application provides an electronic device, including a processor, a communication interface, a memory, and a communication bus, where the processor, the communication interface, and the memory complete communication with each other through the communication bus;
存储器,用于存放计算机程序;Memory, used to store computer programs;
处理器,用于执行存储器上所存放的程序时,实现第一方面所述的商品类别识别方法。The processor, when used to execute the program stored on the memory, implements the commodity category identification method described in the first aspect.
第四方面,本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质内存储有计算机程序,所述计算机程序被处理器执行时实现第一方面所述的商品类别识别方法。According to a fourth aspect, an embodiment of the present application provides a computer-readable storage medium in which a computer program is stored, and when the computer program is executed by a processor, the commodity category recognition described in the first aspect is realized method.
本申请实施例提供的技术方案,在识别目标商品的商品类别时,提取目标商品的目标特征向量,并从预设的参考特征向量库中,确定与目标特征向量匹配的第一参考特征向量,将第一参考特征向量对应的商品类别,确定为目标商品的商品类别。由于本方案基于预设的参考特征向量库实现商品类别识别,故在无人售货机添加新类别商品时,利用新类别商品的特征向量,就可以更新该参考特征向量库,而无需重新训练机器学习模型,因此,通过本方案可以缩短新类别商品的上新过程所消耗的时间,从而可以提升商品类别识别的整体效率。The technical solution provided by the embodiment of the present application extracts the target feature vector of the target commodity when identifying the commodity category of the target commodity, and determines the first reference feature vector matching the target feature vector from the preset reference feature vector library, The product category corresponding to the first reference feature vector is determined as the product category of the target product. Since this solution implements commodity category recognition based on a preset reference feature vector library, when a new category product is added to an unmanned vending machine, the feature vector of the new category product can be used to update the reference feature vector library without retraining the machine Learning the model, therefore, this solution can shorten the time spent on the new process of new category of goods, which can improve the overall efficiency of commodity category recognition.
附图说明BRIEF DESCRIPTION
为了更清楚地说明本申请实施例和现有技术的技术方案,下面对实施例和现有技术中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出 创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly explain the embodiments of the present application and the technical solutions of the prior art, the following briefly introduces the drawings required in the embodiments and the prior art. Obviously, the drawings in the following description are only For some embodiments of the application, for those of ordinary skill in the art, without paying any creative labor, other drawings may be obtained based on these drawings.
图1为本申请实施例所提供的一种商品类别识别方法的流程图;FIG. 1 is a flowchart of a method for identifying commodity categories provided by an embodiment of the present application;
图2为本申请实施例所提供的一种商品类别识别装置的示意图;2 is a schematic diagram of a product category identification device provided by an embodiment of the present application;
图3为本申请实施例所提供的一种电子设备的结构示意图。FIG. 3 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
具体实施方式detailed description
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application will be described clearly and completely in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, but not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by a person of ordinary skill in the art without making creative efforts fall within the protection scope of the present application.
为了缩短新类别商品的上新过程所消耗的时间,进而提升商品类别识别的整体效率,本申请实施例提供了一种商品类别识别方法、装置及电子设备。In order to shorten the time consumed in the process of updating a new category of commodities, and thereby improve the overall efficiency of commodity category recognition, the embodiments of the present application provide a commodity category recognition method, device, and electronic equipment.
需要说明的是,本申请实施例所提供的一种商品类别识别方法的执行主体可以为一种商品类别识别装置,该商品类别识别装置可以运行于电子设备中,其中,该电子设备可以为无人售货机,也可以是与无人售货机通信连接的后台服务器等,本申请实施例对该电子设备不做限定。It should be noted that the execution subject of a method for identifying a commodity category provided in the embodiments of the present application may be a device for identifying a commodity category, and the apparatus for identifying a commodity category may run in an electronic device, where the electronic device may be The human vending machine may also be a background server or the like that is communicatively connected to the unmanned vending machine. The embodiment of the present application does not limit the electronic device.
为了方案描述清楚,首先对本申请实施例提供的技术方案的应用场景进行阐述。在实际应用中,无人售货机可能有多台,且每台无人售货机可能设置有若干层货架,对于任一台无人售货机而言,可以在该台无人售货机的每层货架的顶部安装一图像采集设备,该图像采集设备所采集的图像可以包含该层货架中全部商品。In order to clarify the description of the solution, first, the application scenarios of the technical solution provided by the embodiments of the present application are described. In practical applications, there may be multiple unmanned vending machines, and each unmanned vending machine may be provided with several layers of shelves. For any unmanned vending machine, it can be placed on each floor of the unmanned vending machine An image acquisition device is installed on the top of the shelf, and the image collected by the image acquisition device may contain all the products in the shelf.
由上述描述可知,通过在多个无人售货机中设置多台图像采集设备,可以获取多个无人售货机中所有商品的商品图像,然后识别每张商品图像,得到每张商品图像包含的商品的特征向量,并基于所得到的商品的特征向量建立参考特征向量库。参考特征向量库可以包括各个售货机中的各个类别商品的特征向量。其中,参考特征向量库中的每一组特征向量对应一个商品类别。As can be seen from the above description, by installing multiple image acquisition devices in multiple unmanned vending machines, you can obtain the product images of all the products in multiple unmanned vending machines, and then identify each product image to obtain the content of each product image. Feature vectors of commodities, and establish a reference feature vector library based on the obtained feature vectors of commodities. The reference feature vector library may include feature vectors of various categories of merchandise in each vending machine. Among them, each set of feature vectors in the reference feature vector library corresponds to a commodity category.
第一方面,对本申请实施例所提供的一种商品类别识别方法进行介绍。In the first aspect, an article category identification method provided in an embodiment of the present application is introduced.
如图1所示,本申请实施例所提供的一种商品类别识别方法,可以包括如 下步骤:As shown in FIG. 1, a method for identifying a commodity category provided by an embodiment of the present application may include the following steps:
S110,获取包含无人售货机中的商品区域的目标图像。S110. Acquire a target image containing a product area in the unmanned vending machine.
由上述描述可知,无人售货机中可以设置图像采集设备,图像采集设备可以采集包含商品区域的图像。在图像采集设备采集到包含商品区域的图像后,作为执行主体的电子设备即可以获取包含商品区域的图像,为了方便描述,可以将包含商品区域的图像称为目标图像。As can be seen from the above description, an unmanned vending machine can be provided with an image collection device, and the image collection device can collect images containing the product area. After the image acquisition device acquires the image containing the product area, the electronic device as the execution subject can acquire the image containing the product area. For convenience of description, the image containing the product area may be referred to as the target image.
需要说明的是,作为执行主体的电子设备获取包含无人售货机中的商品区域的目标图像的方式可以有如下两种:It should be noted that the electronic device as the execution subject can obtain the target image including the product area in the unmanned vending machine in the following two ways:
第一种方式:作为执行主体的电子设备可以实时检测图像采集设备是否采集到包含无人售货机的商品区域的目标图像,如果检测到图像采集设备采集到包含无人售货机的商品区域的目标图像,电子设备可以从图像采集设备获取到包含无人售货机的商品区域的目标图像。The first way: the electronic device as the execution subject can detect in real time whether the image acquisition device acquires the target image of the commodity area containing the unmanned vending machine, and if it detects that the image acquisition device acquires the target of the commodity area containing the unmanned vending machine For images, the electronic device can acquire the target image containing the product area of the unmanned vending machine from the image acquisition device.
第二种方式:图像采集设备在采集到包含无人售货机的商品区域的目标图像之后,可以将该包含无人售货机的商品区域的目标图像发送至作为执行主体的电子设备,从而作为执行主体的电子设备可以获取到包含无人售货架的商品区域的目标图像。The second way: After the image acquisition device collects the target image of the product area containing the unmanned vending machine, it can send the target image of the product area containing the unmanned vending machine to the electronic device as the execution subject, so as to execute The electronic device of the main body can acquire the target image of the merchandise area including the unsold shelves.
S120,对目标图像进行商品特征识别,得到目标图像包含的目标商品的目标特征向量。S120: Perform product feature recognition on the target image to obtain a target feature vector of the target product included in the target image.
作为执行主体的电子设备得到目标图像后,可以对目标图像进行商品特征识别,得到目标图像包含的目标商品的目标特征向量。其中,对目标图像进行商品特征识别,得到目标特征向量的方式可以有多种。示例性的,在一种实施方式中,对目标图像进行商品特征识别,得到目标图像包含的目标商品的目标特征向量的步骤,可以包括:After the electronic device as the execution subject obtains the target image, it can perform commodity feature recognition on the target image to obtain the target feature vector of the target commodity contained in the target image. Among them, there are many ways to identify the target image for commodity features and obtain the target feature vector. Exemplarily, in one embodiment, the step of performing commodity feature recognition on the target image to obtain the target feature vector of the target commodity contained in the target image may include:
基于预先训练完成的卷积神经网络,对目标图像进行商品特征识别,得到目标图像包含的目标商品的目标特征向量;Based on the pre-trained convolutional neural network, the target image is subjected to commodity feature recognition to obtain the target feature vector of the target commodity contained in the target image;
其中,卷积神经网络为基于多个包含商品的样本图像与每个样本图像所包含商品的商品类别训练得到的。Among them, the convolutional neural network is obtained by training based on a plurality of sample images containing commodities and commodity categories of the commodities contained in each sample image.
这里,多个包含商品的样本图像可以为:各个无人售货机中设置的图像采集设备所采集的图像。Here, the plurality of sample images containing commodities may be: images collected by image collecting devices provided in each unmanned vending machine.
该实施方式中,基于预先训练完成的卷积神经网络,对目标图像进行商品特征识别,得到目标图像包含的目标商品的目标特征向量的步骤,可以包括:In this embodiment, the step of performing commodity feature recognition on the target image based on the pre-trained convolutional neural network to obtain the target feature vector of the target commodity contained in the target image may include:
提取目标图像包含的目标商品所在的目标区域;Extract the target area where the target product contained in the target image is located;
基于预先训练完成的卷积神经网络,对目标区域进行商品特征识别,得到目标图像包含的目标商品的目标特征向量。Based on the pre-trained convolutional neural network, commodity feature recognition is performed on the target area to obtain the target feature vector of the target commodity contained in the target image.
可以理解的是,图像采集设备所采集的目标图像中,可以有多个目标区域。当需要进行商品特征识别时,可以对目标图像中,目标商品所在的目标区域进行商品特征识别。It can be understood that, in the target image collected by the image collection device, there may be multiple target regions. When product feature recognition is required, product feature recognition can be performed on the target area where the target product is located in the target image.
在实际应用中,目标图像所包含的目标区域可以预先设定。或者,目标图像所包含的目标区域也可以由图像采集设备自动确定等等,本申请实施例对提取目标图像包含的目标商品所在的目标区域的具体实施方式不做限定。In practical applications, the target area included in the target image can be set in advance. Alternatively, the target area included in the target image may also be automatically determined by the image acquisition device, etc. The embodiment of the present application does not limit the specific implementation manner of extracting the target area where the target product included in the target image is located.
在另一种实施方式中,可以基于目标图像的颜色直方图或梯度直方图等特征表示方式,对目标图像进行商品特征识别,得到目标图像包含的目标商品的目标特征向量。In another embodiment, the target image may be subjected to product feature recognition based on a feature representation method such as a color histogram or a gradient histogram of the target image to obtain a target feature vector of the target product included in the target image.
需要说明的是,上述示出的对目标图像进行商品特征识别,得到目标图像包含的目标商品的目标特征向量的具体实施方式,仅仅作为示例,并不应该构成对本申请的限定。It should be noted that the specific implementation manner of performing the product feature recognition on the target image to obtain the target feature vector of the target product contained in the target image as described above is merely an example, and should not constitute a limitation on the present application.
S130,从预设的参考特征向量库中,确定与目标特征向量匹配的第一参考特征向量,其中,参考特征向量库包含多个参考特征向量,每一参考特征向量对应一个商品类别。S130: Determine a first reference feature vector that matches the target feature vector from a preset reference feature vector library, where the reference feature vector library includes multiple reference feature vectors, and each reference feature vector corresponds to a commodity category.
在得到目标特征向量之后,可以从预设的参考特征向量库中,确定与目标特征向量匹配的第一参考特征向量。可以理解的是,由于第一参考特征向量与目标特征向量匹配,因此,第一参考特征向量对应的商品类别与目标特征向量对应的商品类别也匹配。After the target feature vector is obtained, the first reference feature vector matching the target feature vector can be determined from a preset reference feature vector library. It can be understood that, since the first reference feature vector matches the target feature vector, the product category corresponding to the first reference feature vector also matches the product category corresponding to the target feature vector.
在一种实施方式中,从预设的参考特征向量库中,确定与目标特征向量匹配的第一参考特征向量的步骤,可以包括:In one embodiment, the step of determining the first reference feature vector matching the target feature vector from the preset reference feature vector library may include:
计算参考特征向量库中的各个参考特征向量与目标特征向量的相似度;Calculate the similarity between each reference feature vector in the reference feature vector library and the target feature vector;
将与目标特征向量相似度最大的参考特征向量确定为第一参考特征向量。The reference feature vector with the largest similarity to the target feature vector is determined as the first reference feature vector.
本领域技术人员可以理解的是,计算参考特征向量与目标特征向量的相似度的方式有多种,在此不再赘述。Those skilled in the art can understand that there are many ways to calculate the similarity between the reference feature vector and the target feature vector, which will not be repeated here.
对于一个参考特征向量而言,如果该参考特征向量与目标特征向量的相似度较高,说明参考特征向量与目标特征向量越匹配,因此,可以将与目标特征向量相似度最大的参考特征向量确定为第一参考特征向量。For a reference feature vector, if the similarity between the reference feature vector and the target feature vector is high, it means that the reference feature vector and the target feature vector match more closely. Therefore, the reference feature vector with the highest similarity to the target feature vector can be determined Is the first reference feature vector.
S140,将第一参考特征向量对应的商品类别,确定为目标商品的商品类别。S140: Determine the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity.
由于第一参考特征向量为与目标特征向量匹配的参考特征向量,因此,第一参考特征向量对应的商品类别,即为目标特征向量对应的商品类别;又由于目标特征向量是目标商品的特征向量,因此,可以将目标特征向量对应的商品类别确定为目标商品的商品类别。Since the first reference feature vector is the reference feature vector matching the target feature vector, the product category corresponding to the first reference feature vector is the product category corresponding to the target feature vector; and because the target feature vector is the feature vector of the target product Therefore, the product category corresponding to the target feature vector can be determined as the product category of the target product.
可见,通过本发明实施例提供的技术方案,在识别目标商品的商品类别时,提取目标商品的目标特征向量,并从预设的参考特征向量库中,确定与目标特征向量匹配的第一参考特征向量,将第一参考特征向量对应的商品类别,确定为目标商品的商品类别。由于本方案基于预设的参考特征向量库实现商品类别识别,故在无人售货机添加新类别商品时,利用新类别商品的特征向量,就可以更新该参考特征向量库,而无需重新训练机器学习模型,因此,通过本方案可以缩短新类别商品的上新过程所消耗的时间,从而可以提升商品类别识别的整体效率。It can be seen that, through the technical solution provided by the embodiment of the present invention, when identifying the commodity category of the target commodity, the target feature vector of the target commodity is extracted, and the first reference matching the target feature vector is determined from the preset reference feature vector library The feature vector determines the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity. Since this solution implements commodity category recognition based on a preset reference feature vector library, when a new category product is added to an unmanned vending machine, the feature vector of the new category product can be used to update the reference feature vector library without retraining the machine Learning the model, therefore, this solution can shorten the time spent on the new process of new category of goods, which can improve the overall efficiency of commodity category recognition.
在一种实施方式中,本申请实施例提供的商品类别识别方法,还可以包括:In an implementation manner, the method for identifying commodity categories provided in the embodiments of the present application may further include:
获得待上新的新类别商品的图像;Obtain images of new and new products to be uploaded;
对该新类别商品的图像进行商品特征识别,得到该新类别商品的特征向 量;Perform product feature recognition on the image of the new category product to obtain the feature vector of the new category product;
将该新类别商品的特征向量,增加至参考特征向量库中。The feature vector of the new category of goods is added to the reference feature vector library.
可以理解的是,将新类别商品的特征向量,增加至参考特征向量库中之后,就可以按照S110-S140所示的步骤,实现针对该新类别商品进行商品类别识别。It can be understood that after adding the feature vectors of the new category of commodities to the reference feature vector library, the product category recognition can be implemented for the new category of commodities according to the steps shown in S110-S140.
可选地,在一种实施方式中,为了进一步提高商品类别识别的准确度,参考特征向量库可以包含多个特征向量子库,同一特征向量子库中的任意两个参考特征向量所对应的商品类别满足预定差异条件,该两个商品类别满足的预定差异条件为:该两个商品类别下的商品的外观间相似度小于第一相似度;Optionally, in one embodiment, in order to further improve the accuracy of commodity category recognition, the reference feature vector library may include multiple feature vector sub-libraries, and any two reference feature vectors in the same feature vector sub-library correspond to The product category meets a predetermined difference condition, and the predetermined difference condition satisfied by the two product categories is: the similarity between appearances of the products under the two product categories is less than the first similarity;
相应的,从预设的参考特征向量库中,确定与目标特征向量匹配的第一参考特征向量的步骤,可以包括如下两个步骤:Correspondingly, the step of determining the first reference feature vector matching the target feature vector from the preset reference feature vector library may include the following two steps:
步骤1,从预设的参考特征向量库中,确定第一特征向量子库,其中,第一特征向量子库中包含:所对应商品类别符合预定匹配条件的参考特征向量,该商品类别符合的预定匹配条件为:该商品类别所对应的商品与目标商品的外观间相似度大于第二相似度;Step 1: Determine a first feature vector sub-library from a preset reference feature vector library, where the first feature vector sub-library contains: a reference feature vector corresponding to a product category that meets a predetermined matching condition, the product category meets The predetermined matching condition is: the similarity between the appearance of the commodity corresponding to the commodity category and the target commodity is greater than the second similarity;
步骤2,从第一特征向量子库中,确定与目标特征向量匹配的第一参考特征向量。Step 2: Determine the first reference feature vector matching the target feature vector from the first feature vector sub-library.
可以理解的是,不同类别的商品可能存在外观包装相似的情况,对于外观包装相似的商品而言,对应的特征向量的相似度也较高,因此,如果将外观包装相似的商品的特征向量存入到同一参考特征向量库中,在实际识别商品类别时,可能会影响商品类别的识别准确度。因此,为了进一步提高商品类别识别的准确度,可以将彼此之间的外观包装相似度小于预设相似度的商品的特征向量,存入同一个参考特征向量子库中,将外观包装相似度大于预设相似度的商品的特征向量,存入不同的参考特征向量子库中。It can be understood that different types of products may have similar appearance packaging. For products with similar appearance packaging, the similarity of corresponding feature vectors is also high. Therefore, if the feature vectors of products with similar appearance packaging are stored Into the same reference feature vector library, when actually identifying the product category, it may affect the recognition accuracy of the product category. Therefore, in order to further improve the accuracy of product category recognition, the feature vectors of commodities whose appearance packaging similarity is less than the preset similarity can be stored in the same reference feature vector sub-library, and the appearance packaging similarity is greater than Feature vectors of products with preset similarities are stored in different reference feature vector sub-libraries.
举例而言,假设有10种不同类别的商品,其中,有8种不同类别的商品彼此之间的外观包装相似度均小于预设相似度,另有2种商品的外观包装相似度大于预设相似度。这种情况下,可以通过混淆分析方法得出外观包装相似度 较高的这2种商品,其中,该混淆分析方法可以是人眼观察判定、商家预先设定或者算法分析等,本申请实施例对混淆分析方法不作具体限定。然后,将上述8种商品的特征向量放入到同一个特征向量子库中,将上述2种商品的特征向量放入不同的特征向量子库中。这里,预设相似度的大小可以根据实际情况进行设定,本申请实施例对预设相似度的大小不做具体限定。For example, suppose there are 10 different types of products, of which 8 different types of products have similar appearance packaging similarity to each other less than the preset similarity, and 2 other products have similar appearance packaging similarity to the preset Similarity. In this case, these two products with high similarity in appearance and packaging can be obtained through a confusion analysis method, where the confusion analysis method can be human eye observation judgment, merchant presetting, or algorithm analysis, etc. There is no specific limitation on the confusion analysis method. Then, the feature vectors of the above eight products are put into the same feature vector sub-library, and the feature vectors of the above two kinds of products are put into different feature vector sub-libraries. Here, the size of the preset similarity may be set according to actual conditions, and the size of the preset similarity is not specifically limited in the embodiment of the present application.
在实际应用中,可以将特征向量子库与无人售货机进行设备关联,也就是说,每个无人售货机可以对应一个特征向量子库,该特征向量子库中存有该无人售货机中所有商品的的特征向量。这样,在识别无人售货机中的商品的商品类别时,可以直接利用该无人售货机对应的特征向量子库进行商品类别识别,从而提高商品类别识别的速度。In practical applications, the feature vector sub-library can be associated with the unmanned vending machine, that is, each unmanned vending machine can correspond to a feature vector sub-library, and the feature vector sub-library contains the unmanned vending machine. Feature vectors of all commodities in the cargo plane. In this way, when identifying the product category of the product in the unmanned vending machine, it is possible to directly use the feature vector sub-library corresponding to the unmanned vending machine to perform product category recognition, thereby increasing the speed of product category recognition.
在步骤1中,从预设的参考特征向量库中,确定第一特征向量子库的具体实施方式可以存在多种。示例性的,在一种实施方式中,从预设的参考特征向量库中,确定第一特征向量子库的步骤,可以包括:In step 1, from the preset reference feature vector library, there may be multiple specific implementation manners for determining the first feature vector sub-library. Exemplarily, in an embodiment, the step of determining the first feature vector sub-library from the preset reference feature vector library may include:
针对预设的参考特征向量库中的每一特征向量子库,确定该特征向量子库中,每个参考特征向量对应的参考外观数据,每一参考特征向量对应的参考外观数据为:该参考特征向量所对应商品类别下的商品的外观数据;For each feature vector sub-library in the preset reference feature vector library, determine the reference appearance data corresponding to each reference feature vector in the feature vector sub-library, and the reference appearance data corresponding to each reference feature vector is: the reference Appearance data of products under the product category corresponding to the feature vector;
从目标图像中获取目标商品的外观数据;Obtain the appearance data of the target product from the target image;
针对每一特征向量子库,分别计算该特征向量子库中每个参考特征向量对应的参考外观数据与目标商品的外观数据的相似度,如果所计算得到的相似度中包含有大于第二相似度的相似度,将该特征向量子库确定为第一特征向量子库。For each feature vector sub-library, calculate the similarity between the reference appearance data corresponding to each reference feature vector in the feature vector sub-library and the appearance data of the target product, if the calculated similarity includes greater than the second similarity Degree of similarity, the feature vector sub-library is determined as the first feature vector sub-library.
其中,第二相似度的大小可以根据实际情况进行设定,本申请实施例对此不做具体限定。可以理解的是,所确定的第一特征向量子库中,包含有与目标特征向量相同的参考特征向量。The size of the second similarity can be set according to actual conditions, which is not specifically limited in the embodiments of the present application. It can be understood that the determined first feature vector sub-library contains the same reference feature vector as the target feature vector.
可以理解的是,由于特征向量子库中所包含的参考特征向量,均是从包含无人售货机的商品区域的商品图像中提取得到的,因此,可以从商品图像中,获取参考特征向量对应的参考外观数据。其中,每个特征向量子库可以对应一个商品图像库。It can be understood that, since the reference feature vectors included in the feature vector sub-library are all extracted from the product image containing the product area of the unmanned vending machine, the corresponding reference feature vector can be obtained from the product image Reference appearance data. Among them, each feature vector sub-library may correspond to a commodity image library.
在另一种实施方式中,参考特征向量库包含的多个特征向量子库,可以与多个无人售货机一一对应;In another embodiment, multiple feature vector sub-libraries included in the reference feature vector library may correspond to multiple unmanned vending machines;
相应的,步骤1中,从预设的参考特征向量库中,确定第一特征向量子库的步骤,可以包括:Correspondingly, in step 1, the step of determining the first feature vector sub-library from the preset reference feature vector library may include:
将预设的参考特征向量库中,与目标商品所在无人售货机对应的参考特征向量子库,确定为第一特征向量子库。The reference feature vector sub-library corresponding to the unmanned vending machine where the target product is located in the preset reference feature vector library is determined as the first feature vector sub-library.
可以理解的是,目标商品是存放于无人售货机上的,故对于每个无人售货机而言,当要对该无人售货机上的任一目标商品进行商品类别识别时,可以将该无人售货机对应的特征向量子库,作为第一特征向量子库。It is understandable that the target product is stored on the unmanned vending machine, so for each unmanned vending machine, when you want to identify the product category of any target product on the unmanned vending machine, you can The feature vector sub-library corresponding to the unmanned vending machine serves as the first feature vector sub-library.
关于步骤2中,从第一特征向量子库中,确定与目标特征向量匹配的第一参考特征向量的具体实现方式,与S130中从预设的参考特征向量库中,确定与目标特征向量匹配的第一参考特征向量的第一种实现方式相同或相似,此处不再赘述。With regard to step 2, the specific implementation manner of the first reference feature vector matching the target feature vector is determined from the first feature vector sub-library, which is determined to match the target feature vector from the preset reference feature vector library in S130 The first implementation manner of the first reference feature vector of is the same or similar, and will not be repeated here.
第二方面,本申请实施例提供了一种商品类别识别装置,如图2所示,所述装置包括:In a second aspect, an embodiment of the present application provides a product category identification device. As shown in FIG. 2, the device includes:
图像获取模块210,用于获取包含无人售货机中的商品区域的目标图像;The image acquisition module 210 is used to acquire a target image containing the product area in the unmanned vending machine;
特征识别模块220,用于对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量;The feature recognition module 220 is used to perform commodity feature recognition on the target image to obtain a target feature vector of the target commodity contained in the target image;
特征向量确定模块230,用于从预设的参考特征向量库中,确定与所述目标特征向量匹配的第一参考特征向量,其中,所述参考特征向量库包含多个参考特征向量,每一参考特征向量对应一个商品类别;The feature vector determination module 230 is configured to determine a first reference feature vector matching the target feature vector from a preset reference feature vector library, wherein the reference feature vector library includes multiple reference feature vectors, each The reference feature vector corresponds to a commodity category;
商品类别确定模块240,用于将所述第一参考特征向量对应的商品类别,确定为所述目标商品的商品类别。The commodity category determination module 240 is configured to determine the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity.
可选地,所述装置还包括:更新模块;Optionally, the device further includes: an update module;
所述更新模块,用于获得待上新的新类别商品的图像;对所述新类别商 品的图像进行商品特征识别,得到所述新类别商品的特征向量;将所述新类别商品的特征向量,增加至所述参考特征向量库中。The update module is used to obtain an image of a new category product to be uploaded; perform product feature recognition on the image of the new category product to obtain a feature vector of the new category product; and convert the feature vector of the new category product , Added to the reference feature vector library.
可见,通过本发明实施例提供的技术方案,在识别目标商品的商品类别时,提取目标商品的目标特征向量,并从预设的参考特征向量库中,确定与目标特征向量匹配的第一参考特征向量,将第一参考特征向量对应的商品类别,确定为目标商品的商品类别。由于本方案基于预设的参考特征向量库实现商品类别识别,故在无人售货机添加新类别商品时,利用新类别商品的特征向量,就可以更新该参考特征向量库,而无需重新训练机器学习模型,因此,通过本方案可以缩短新类别商品的上新过程所消耗的时间,从而可以提升商品类别识别的整体效率。It can be seen that, through the technical solution provided by the embodiment of the present invention, when identifying the commodity category of the target commodity, the target feature vector of the target commodity is extracted, and the first reference matching the target feature vector is determined from the preset reference feature vector library The feature vector determines the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity. Since this solution implements commodity category recognition based on a preset reference feature vector library, when a new category product is added to an unmanned vending machine, the feature vector of the new category product can be used to update the reference feature vector library without retraining the machine Learning the model, therefore, this solution can shorten the time spent on the new process of new category of goods, which can improve the overall efficiency of commodity category recognition.
可选的,所述参考特征向量库包含多个特征向量子库,同一特征向量子库中的任意两个参考特征向量所对应的商品类别满足预定差异条件,该两个商品类别满足的预定差异条件为:该两个商品类别下的商品的外观间相似度小于第一相似度;Optionally, the reference feature vector library includes multiple feature vector sub-libraries, and the product categories corresponding to any two reference feature vectors in the same feature vector sub-library satisfy a predetermined difference condition, and the two product categories satisfy the predetermined difference The condition is that the similarity between the appearances of the products under the two commodity categories is less than the first similarity;
所述特征向量确定模块,包括:The feature vector determination module includes:
特征向量子库确定模块,用于从预设的参考特征向量库中,确定第一特征向量子库,其中,所述第一特征向量子库中包含:所对应商品类别符合预定匹配条件的参考特征向量,该商品类别符合的预定匹配条件为:该商品类别下的商品与所述目标商品的外观间相似度大于第二相似度;The feature vector sub-library determination module is used to determine a first feature vector sub-library from a preset reference feature vector library, where the first feature vector sub-library contains: a reference to which the corresponding product category meets a predetermined matching condition Feature vector, the predetermined matching condition met by the product category is: the similarity between the appearance of the product under the product category and the target product is greater than the second similarity;
从所述第一特征向量子库中,确定与所述目标特征向量匹配的第一参考特征向量。From the first feature vector sub-library, determine a first reference feature vector that matches the target feature vector.
可选的,所述特征向量子库确定模块,具体用于:Optionally, the feature vector sub-library determination module is specifically used for:
针对预设的参考特征向量库中的每一特征向量子库,确定该特征向量子库中各个参考特征向量对应的参考外观数据,每一参考特征向量对应的参考外观数据为:该参考特征向量所对应商品类别下的商品的外观数据;For each feature vector sub-library in the preset reference feature vector library, the reference appearance data corresponding to each reference feature vector in the feature vector sub-library is determined. The reference appearance data corresponding to each reference feature vector is: the reference feature vector Appearance data of the products under the corresponding product categories;
从所述目标图像中获取所述目标商品的外观数据;Obtaining appearance data of the target product from the target image;
针对每一特征向量子库,分别计算该特征向量子库中,每个参考特征向 量对应的参考外观数据与目标商品的外观数据的相似度,如果所计算得到的相似度中包含有大于第二相似度的相似度,将该特征向量子库确定为第一特征向量子库。For each feature vector sub-library, calculate the similarity between the reference appearance data corresponding to each reference feature vector and the appearance data of the target product in the feature vector sub-library, if the calculated similarity includes greater than the second The similarity of the similarity determines the feature vector sub-library as the first feature vector sub-library.
可选的,所述参考特征向量库包含的多个特征向量子库与多个无人售货机一一对应;Optionally, a plurality of feature vector sub-libraries included in the reference feature vector library correspond to a plurality of unmanned vending machines;
所述特征向量子库确定模块,具体用于:The feature vector sub-library determination module is specifically used for:
将预设的参考特征向量库中,与目标商品所在无人售货机对应的参考特征向量子库确定为第一特征向量子库。In the preset reference feature vector library, the reference feature vector sub-library corresponding to the unmanned vending machine where the target product is located is determined as the first feature vector sub-library.
可选的,所述特征识别模块,包括:Optionally, the feature recognition module includes:
特征识别单元,用于基于预先训练完成的卷积神经网络,对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量;The feature recognition unit is used to perform commodity feature recognition on the target image based on the pre-trained convolutional neural network to obtain the target feature vector of the target commodity contained in the target image;
其中,所述卷积神经网络为基于多个包含商品的样本图像与每个样本图像中包含的商品的特征向量所训练得到的。Wherein, the convolutional neural network is trained based on a plurality of sample images containing commodities and feature vectors of commodities contained in each sample image.
可选的,所述特征识别单元,具体用于:Optionally, the feature recognition unit is specifically used for:
提取所述目标图像包含的目标商品所在的目标区域;Extract the target area where the target commodity contained in the target image is located;
基于预先训练完成的卷积神经网络,对所述目标区域进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量。Based on the pre-trained convolutional neural network, commodity feature recognition is performed on the target area to obtain the target feature vector of the target commodity contained in the target image.
可选的,所述特征向量确定模块,具体用于:Optionally, the feature vector determination module is specifically used for:
分别计算预设的参考特征向量库中,每个参考特征向量与所述目标特征向量的相似度;Calculating the similarity between each reference feature vector and the target feature vector in the preset reference feature vector library separately;
将相似度最大的参考特征向量确定为与所述目标特征向量匹配的第一参考特征向量。The reference feature vector with the largest similarity is determined as the first reference feature vector matching the target feature vector.
第三方面,本申请实施例还提供了一种电子设备,如图3所示,包括处理器301、通信接口302、存储器303和通信总线304,其中,处理器301,通信接口302,存储器303通过通信总线304完成相互间的通信,In a third aspect, an embodiment of the present application further provides an electronic device, as shown in FIG. 3, including a processor 301, a communication interface 302, a memory 303, and a communication bus 304, where the processor 301, the communication interface 302, and the memory 303 Complete communication with each other through the communication bus 304,
存储器303,用于存放计算机程序; Memory 303, used to store computer programs;
处理器301,用于执行存储器303上所存放的程序时,实现第一方面所述的商品类别识别方法。The processor 301 is configured to implement the commodity category identification method described in the first aspect when executing the program stored in the memory 303.
可见,通过本发明实施例提供的技术方案,在识别目标商品的商品类别时,提取目标商品的目标特征向量,并从预设的参考特征向量库中,确定与目标特征向量匹配的第一参考特征向量,将第一参考特征向量对应的商品类别,确定为目标商品的商品类别。由于本方案基于预设的参考特征向量库实现商品类别识别,故在无人售货机添加新类别商品时,利用新类别商品的特征向量,就可以更新该参考特征向量库,而无需重新训练机器学习模型,因此,通过本方案可以缩短新类别商品的上新过程所消耗的时间,从而可以提升商品类别识别的整体效率。It can be seen that, through the technical solution provided by the embodiment of the present invention, when identifying the commodity category of the target commodity, the target feature vector of the target commodity is extracted, and the first reference matching the target feature vector is determined from the preset reference feature vector library The feature vector determines the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity. Since this solution implements commodity category recognition based on a preset reference feature vector library, when a new category product is added to an unmanned vending machine, the feature vector of the new category product can be used to update the reference feature vector library without retraining the machine Learning the model, therefore, this solution can shorten the time spent on the new process of new category of goods, which can improve the overall efficiency of commodity category recognition.
上述电子设备提到的通信总线可以是外设部件互连标准(Peripheral Component Interconnect,PCI)总线或扩展工业标准结构(Extended Industry Standard Architecture,EISA)总线等。该通信总线可以分为地址总线、数据总线、控制总线等。为便于表示,图中仅用一条粗线表示,但并不表示仅有一根总线或一种类型的总线。The communication bus mentioned in the above electronic equipment may be a peripheral component interconnection standard (Peripheral Component Interconnect, PCI) bus or an extended industry standard structure (Extended Industry Standard Architecture, EISA) bus, etc. The communication bus can be divided into an address bus, a data bus, and a control bus. For ease of representation, only a thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.
通信接口用于上述电子设备与其他设备之间的通信。The communication interface is used for communication between the electronic device and other devices.
存储器可以包括随机存取存储器(Random Access Memory,RAM),也可以包括非易失性存储器(Non-Volatile Memory,NVM),例如至少一个磁盘存储器。可选的,存储器还可以是至少一个位于远离前述处理器的存储装置。The memory may include random access memory (Random Access Memory, RAM), or non-volatile memory (Non-Volatile Memory, NVM), for example, at least one disk memory. Optionally, the memory may also be at least one storage device located away from the foregoing processor.
上述的处理器可以是通用处理器,包括中央处理器(Central Processing Unit,CPU)、网络处理器(Network Processor,NP)等;还可以是数字信号处理器(Digital Signal Processing,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件。The aforementioned processor may be a general-purpose processor, including a central processor (Central Processing Unit, CPU), a network processor (Network Processor, NP), etc.; it may also be a digital signal processor (Digital Signal Processing, DSP), dedicated integration Circuit (Application Specific Integrated Circuit, ASIC), field programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components.
第四方面,本申请实施例提供了一种计算机可读存储介质,所述计算机 可读存储介质内存储有计算机程序,所述计算机程序被处理器执行时实现第一方面所述的商品类别识别方法。According to a fourth aspect, an embodiment of the present application provides a computer-readable storage medium in which a computer program is stored, and when the computer program is executed by a processor, the commodity category recognition described in the first aspect is realized method.
可见,通过本发明实施例提供的技术方案,在识别目标商品的商品类别时,提取目标商品的目标特征向量,并从预设的参考特征向量库中,确定与目标特征向量匹配的第一参考特征向量,将第一参考特征向量对应的商品类别,确定为目标商品的商品类别。由于本方案基于预设的参考特征向量库实现商品类别识别,故在无人售货机添加新类别商品时,利用新类别商品的特征向量,就可以更新该参考特征向量库,而无需重新训练机器学习模型,因此,通过本方案可以缩短新类别商品的上新过程所消耗的时间,从而可以提升商品类别识别的整体效率。It can be seen that, through the technical solution provided by the embodiment of the present invention, when identifying the commodity category of the target commodity, the target feature vector of the target commodity is extracted, and the first reference matching the target feature vector is determined from the preset reference feature vector library The feature vector determines the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity. Since this solution implements commodity category recognition based on a preset reference feature vector library, when a new category product is added to an unmanned vending machine, the feature vector of the new category product can be used to update the reference feature vector library without retraining the machine Learning the model, therefore, this solution can shorten the time spent on the new process of new category of goods, which can improve the overall efficiency of commodity category recognition.
在本申请提供的又一实施例中,还提供了一种包含指令的计算机程序产品,当其在计算机上运行时,使得计算机执行上述第一方面所述的商品类别识别方法。In yet another embodiment provided by the present application, there is also provided a computer program product containing instructions, which when run on a computer, causes the computer to execute the commodity category identification method described in the first aspect above.
需要说明的是,在本文中,诸如第一和第二等之类的关系术语仅仅用来将一个实体或者操作与另一个实体或操作区分开来,而不一定要求或者暗示这些实体或操作之间存在任何这种实际的关系或者顺序。而且,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、物品或者设备中还存在另外的相同要素。It should be noted that in this article, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply that these entities or operations There is any such actual relationship or order. Moreover, the terms "include", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device that includes a series of elements includes not only those elements, but also those not explicitly listed Or other elements that are inherent to this process, method, article, or equipment. Without more restrictions, the element defined by the sentence "include one..." does not exclude that there are other identical elements in the process, method, article or equipment that includes the element.
本说明书中的各个实施例均采用相关的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于装置、电子设备以及存储介质实施例而言,由于其基本相似于方法实施例,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。Each embodiment in this specification is described in a related manner. The same or similar parts between the embodiments can be referred to each other. Each embodiment focuses on the differences from other embodiments. In particular, for the embodiments of the device, the electronic device, and the storage medium, since they are basically similar to the method embodiments, the description is relatively simple. For the related parts, refer to the description of the method embodiments.
以上所述仅为本申请的较佳实施例而已,并非用于限定本申请的保护范围。凡在本申请的精神和原则之内所作的任何修改、等同替换、改进等,均包含在本申请的保护范围内。The above are only the preferred embodiments of the present application, and are not intended to limit the protection scope of the present application. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of this application are included in the scope of protection of this application.

Claims (18)

  1. 一种商品类别识别方法,其特征在于,所述方法包括:A commodity category identification method, characterized in that the method includes:
    获取包含无人售货机中的商品区域的目标图像;Get the target image containing the product area in the unmanned vending machine;
    对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量;Performing commodity feature recognition on the target image to obtain a target feature vector of the target commodity contained in the target image;
    从预设的参考特征向量库中,确定与所述目标特征向量匹配的第一参考特征向量,其中,所述参考特征向量库包含多个参考特征向量,每一参考特征向量对应一个商品类别;From a preset reference feature vector library, determine a first reference feature vector that matches the target feature vector, where the reference feature vector library includes multiple reference feature vectors, and each reference feature vector corresponds to a commodity category;
    将所述第一参考特征向量对应的商品类别,确定为所述目标商品的商品类别。The commodity category corresponding to the first reference feature vector is determined as the commodity category of the target commodity.
  2. 根据权利要求1所述的方法,其特征在于,所述方法还包括:The method according to claim 1, wherein the method further comprises:
    获得待上新的新类别商品的图像;Obtain images of new and new products to be uploaded;
    对所述新类别商品的图像进行商品特征识别,得到所述新类别商品的特征向量;Performing commodity feature recognition on the image of the new category commodity to obtain a feature vector of the new category commodity;
    将所述新类别商品的特征向量,增加至所述参考特征向量库中。Add the feature vectors of the new category of commodities to the reference feature vector library.
  3. 根据权利要求1所述的方法,其特征在于,所述参考特征向量库包含多个特征向量子库,同一特征向量子库中的任意两个参考特征向量所对应的商品类别满足预定差异条件,该两个商品类别满足的预定差异条件为:该两个商品类别所对应商品的外观相似度小于第一相似度;The method according to claim 1, wherein the reference feature vector library includes a plurality of feature vector sub-libraries, and the product categories corresponding to any two reference feature vectors in the same feature vector sub-library satisfy a predetermined difference condition, The predetermined difference condition met by the two commodity categories is: the similarity in appearance of the products corresponding to the two commodity categories is less than the first similarity;
    所述从预设的参考特征向量库中,确定与所述目标特征向量匹配的第一参考特征向量的步骤,包括:The step of determining the first reference feature vector matching the target feature vector from the preset reference feature vector library includes:
    从预设的参考特征向量库中,确定第一特征向量子库,其中,所述第一特征向量子库中包含:所对应商品类别符合预定匹配条件的参考特征向量,该商品类别符合的预定匹配条件为:该商品类别所对应的商品与所述目标商品的外观相似度大于第二相似度;A first feature vector sub-library is determined from a preset reference feature vector library, where the first feature vector sub-library contains: a reference feature vector corresponding to a commodity category that meets a predetermined matching condition, and the commodity category meets a predetermined The matching condition is: the appearance similarity between the product corresponding to the product category and the target product is greater than the second similarity;
    从所述第一特征向量子库中,确定与所述目标特征向量匹配的第一参考 特征向量。From the first feature vector sub-library, determine a first reference feature vector that matches the target feature vector.
  4. 根据权利要求3所述的方法,其特征在于,所述从预设的参考特征向量库中,确定第一特征向量子库的步骤,包括:The method according to claim 3, wherein the step of determining a first feature vector sub-library from a preset reference feature vector library includes:
    针对预设的参考特征向量库中的每一特征向量子库,确定该特征向量子库中各个参考特征向量对应的参考外观数据,每一参考特征向量对应的参考外观数据为:该参考特征向量所对应商品类别下的商品的外观数据;For each feature vector sub-library in the preset reference feature vector library, the reference appearance data corresponding to each reference feature vector in the feature vector sub-library is determined. The reference appearance data corresponding to each reference feature vector is: the reference feature vector Appearance data of the products under the corresponding product categories;
    从所述目标图像中获取所述目标商品的外观数据;Obtaining appearance data of the target product from the target image;
    针对每一特征向量子库,分别计算该特征向量子库中,每个参考特征向量对应的参考外观数据与所述目标商品的外观数据的相似度,如果所计算得到的相似度中包含有大于第二相似度的相似度,将该特征向量子库确定为第一特征向量子库。For each feature vector sub-library, calculate the similarity between the reference appearance data corresponding to each reference feature vector and the appearance data of the target product in the feature vector sub-library, if the calculated similarity includes greater than The similarity of the second similarity determines the feature vector sub-library as the first feature vector sub-library.
  5. 根据权利要求3所述的方法,其特征在于,所述参考特征向量库包含的多个特征向量子库与多个无人售货机一一对应;The method according to claim 3, wherein a plurality of feature vector sub-libraries included in the reference feature vector library correspond to a plurality of unmanned vending machines;
    所述从预设的参考特征向量库中,确定第一特征向量子库的步骤,包括:The step of determining the first feature vector sub-library from the preset reference feature vector library includes:
    将预设的参考特征向量库中,与目标商品所在无人售货机对应的参考特征向量子库确定为第一特征向量子库。In the preset reference feature vector library, the reference feature vector sub-library corresponding to the unmanned vending machine where the target product is located is determined as the first feature vector sub-library.
  6. 根据权利要求1至5任一项所述的方法,其特征在于,所述对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量的步骤,包括:The method according to any one of claims 1 to 5, wherein the step of performing commodity feature recognition on the target image to obtain a target feature vector of the target commodity contained in the target image includes:
    基于预先训练完成的卷积神经网络,对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量;Based on the pre-trained convolutional neural network, perform commodity feature recognition on the target image to obtain the target feature vector of the target commodity contained in the target image;
    其中,所述卷积神经网络为基于多个包含商品的样本图像与每个样本图像所包含商品的商品类别所训练得到的。Wherein, the convolutional neural network is trained based on a plurality of sample images containing commodities and the commodity category of the commodities contained in each sample image.
  7. 根据权利要求6所述的方法,其特征在于,所述基于预先训练完成的卷积神经网络,对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量的步骤,包括:The method according to claim 6, wherein the step of performing commodity feature recognition on the target image based on the pre-trained convolutional neural network to obtain the target feature vector of the target commodity contained in the target image ,include:
    提取所述目标图像包含的目标商品所在的目标区域;Extract the target area where the target commodity contained in the target image is located;
    基于预先训练完成的卷积神经网络,对所述目标区域进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量。Based on the pre-trained convolutional neural network, commodity feature recognition is performed on the target area to obtain the target feature vector of the target commodity contained in the target image.
  8. 根据权利要求1所述的方法,其特征在于,所述从预设的参考特征向量库中,确定与所述目标特征向量匹配的第一参考特征向量的步骤,包括:The method according to claim 1, wherein the step of determining a first reference feature vector matching the target feature vector from a preset reference feature vector library includes:
    分别计算预设的参考特征向量库中,每个参考特征向量与所述目标特征向量的相似度;Calculating the similarity between each reference feature vector and the target feature vector in the preset reference feature vector library separately;
    将相似度最大的参考特征向量确定为与所述目标特征向量匹配的第一参考特征向量。The reference feature vector with the largest similarity is determined as the first reference feature vector matching the target feature vector.
  9. 一种商品类别识别装置,其特征在于,所述装置包括:A product category identification device, characterized in that the device includes:
    图像获取模块,用于获取包含无人售货机中的商品区域的目标图像;The image acquisition module is used to acquire the target image containing the product area in the unmanned vending machine;
    特征识别模块,用于对所述目标图像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量;A feature recognition module, configured to perform commodity feature recognition on the target image to obtain a target feature vector of the target commodity contained in the target image;
    特征向量确定模块,用于从预设的参考特征向量库中,确定与所述目标特征向量匹配的第一参考特征向量,其中,所述参考特征向量库包含多个参考特征向量,每一参考特征向量对应一个商品类别;The feature vector determination module is used to determine a first reference feature vector matching the target feature vector from a preset reference feature vector library, wherein the reference feature vector library includes multiple reference feature vectors, each reference Feature vector corresponds to a commodity category;
    商品类别确定模块,用于将所述第一参考特征向量对应的商品类别,确定为所述目标商品的商品类别。The commodity category determination module is configured to determine the commodity category corresponding to the first reference feature vector as the commodity category of the target commodity.
  10. 根据权利要求9所述的装置,其特征在于,所述装置还包括:更新模块;The apparatus according to claim 9, wherein the apparatus further comprises: an update module;
    所述更新模块,用于获得待上新的新类别商品的图像;对所述新类别商品的图像进行商品特征识别,得到所述新类别商品的特征向量;将所述新类别商品的特征向量,增加至所述参考特征向量库中。The update module is used to obtain an image of a new category product to be uploaded; perform product feature recognition on the image of the new category product to obtain a feature vector of the new category product; and convert the feature vector of the new category product , Added to the reference feature vector library.
  11. 根据权利要求9所述的装置,其特征在于,所述参考特征向量库包含多个特征向量子库,同一特征向量子库中的任意两个参考特征向量所对应的商品类别满足预定差异条件,该两个商品类别满足的预定差异条件为:该两 个商品类别所对应商品的外观相似度小于第一相似度;The device according to claim 9, wherein the reference feature vector library includes a plurality of feature vector sub-libraries, and the product categories corresponding to any two reference feature vectors in the same feature vector sub-library satisfy a predetermined difference condition, The predetermined difference condition met by the two commodity categories is: the similarity in appearance of the products corresponding to the two commodity categories is less than the first similarity;
    所述特征向量确定模块,包括:The feature vector determination module includes:
    特征向量子库确定模块,用于从预设的参考特征向量库中,确定第一特征向量子库,其中,所述第一特征向量子库中包含:所对应商品类别符合预定匹配条件的参考特征向量,该商品类别符合的预定匹配条件为:该商品类别所对应的商品与所述目标商品的外观相似度大于第二相似度;The feature vector sub-library determination module is used to determine a first feature vector sub-library from a preset reference feature vector library, where the first feature vector sub-library contains: a reference to which the corresponding product category meets a predetermined matching condition Feature vector, the predetermined matching condition met by the product category is: the similarity in appearance of the product corresponding to the product category and the target product is greater than the second similarity;
    从所述第一特征向量子库中,确定与所述目标特征向量匹配的第一参考特征向量。From the first feature vector sub-library, determine a first reference feature vector that matches the target feature vector.
  12. 根据权利要求11所述的装置,其特征在于,所述特征向量子库确定模块,具体用于:The apparatus according to claim 11, wherein the feature vector sub-library determination module is specifically configured to:
    针对预设的参考特征向量库中的每一特征向量子库,确定该特征向量子库中各个参考特征向量对应的参考外观数据,每一参考特征向量对应的参考外观数据为:该参考特征向量所对应商品类别下的商品的外观数据;For each feature vector sub-library in the preset reference feature vector library, the reference appearance data corresponding to each reference feature vector in the feature vector sub-library is determined. The reference appearance data corresponding to each reference feature vector is: the reference feature vector Appearance data of the products under the corresponding product categories;
    从所述目标图像中获取所述目标商品的外观数据;Obtaining appearance data of the target product from the target image;
    针对每一特征向量子库,分别计算该特征向量子库中,每个参考特征向量对应的参考外观数据与所述目标商品的外观数据的相似度,如果所计算得到的相似度中包含有大于第二相似度的相似度,将该特征向量子库确定为第一特征向量子库。For each feature vector sub-library, calculate the similarity between the reference appearance data corresponding to each reference feature vector and the appearance data of the target product in the feature vector sub-library, if the calculated similarity includes greater than The similarity of the second similarity determines the feature vector sub-library as the first feature vector sub-library.
  13. 根据权利要求11所述的装置,其特征在于,所述参考特征向量库包含的多个特征向量子库与多个无人售货机一一对应;The apparatus according to claim 11, wherein the reference feature vector library includes a plurality of feature vector sub-libraries and one-to-one correspondence with a plurality of unmanned vending machines;
    所述特征向量子库确定模块,具体用于:The feature vector sub-library determination module is specifically used for:
    将预设的参考特征向量库中,与目标商品所在无人售货机对应的参考特征向量子库确定为第一特征向量子库。In the preset reference feature vector library, the reference feature vector sub-library corresponding to the unmanned vending machine where the target product is located is determined as the first feature vector sub-library.
  14. 根据权利要求9至13任一项所述的装置,其特征在于,所述特征识别模块,包括:The device according to any one of claims 9 to 13, wherein the feature recognition module includes:
    特征识别单元,用于基于预先训练完成的卷积神经网络,对所述目标图 像进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量;The feature recognition unit is used to perform commodity feature recognition on the target image based on the pre-trained convolutional neural network to obtain the target feature vector of the target commodity contained in the target image;
    其中,所述卷积神经网络为基于多个包含商品的样本图像与每个样本图像所包含商品的商品类别所训练得到的。Wherein, the convolutional neural network is trained based on a plurality of sample images containing commodities and the commodity category of the commodities contained in each sample image.
  15. 根据权利要求14所述的装置,其特征在于,所述特征识别单元,具体用于:The apparatus according to claim 14, wherein the feature recognition unit is specifically used for:
    提取所述目标图像包含的目标商品所在的目标区域;Extract the target area where the target commodity contained in the target image is located;
    基于预先训练完成的卷积神经网络,对所述目标区域进行商品特征识别,得到所述目标图像包含的目标商品的目标特征向量。Based on the pre-trained convolutional neural network, commodity feature recognition is performed on the target area to obtain the target feature vector of the target commodity contained in the target image.
  16. 根据权利要求9所述的装置,其特征在于,所述特征向量确定模块,具体用于:The apparatus according to claim 9, wherein the feature vector determination module is specifically used for:
    分别计算预设的参考特征向量库中,每个参考特征向量与所述目标特征向量的相似度;Calculating the similarity between each reference feature vector and the target feature vector in the preset reference feature vector library separately;
    将相似度最大的参考特征向量确定为与所述目标特征向量匹配的第一参考特征向量。The reference feature vector with the largest similarity is determined as the first reference feature vector matching the target feature vector.
  17. 一种电子设备,其特征在于,包括处理器、通信接口、存储器和通信总线,其中,处理器,通信接口,存储器通过通信总线完成相互间的通信;An electronic device characterized by comprising a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory complete communication with each other through the communication bus;
    存储器,用于存放计算机程序;Memory, used to store computer programs;
    处理器,用于执行存储器上所存放的程序时,实现权利要求1-8任一所述的方法步骤。The processor, when used to execute the program stored on the memory, implements the method steps of any one of claims 1-8.
  18. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质内存储有计算机程序,所述计算机程序被处理器执行时实现权利要求1-8任一所述的方法步骤。A computer-readable storage medium, characterized in that a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the method steps of any one of claims 1-8 are realized.
PCT/CN2019/112523 2018-12-29 2019-10-22 Merchandise category recognition method, apparatus, and electronic device WO2020134411A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201811638179.8 2018-12-29
CN201811638179.8A CN111382635B (en) 2018-12-29 2018-12-29 Commodity category identification method and device and electronic equipment

Publications (1)

Publication Number Publication Date
WO2020134411A1 true WO2020134411A1 (en) 2020-07-02

Family

ID=71126845

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/112523 WO2020134411A1 (en) 2018-12-29 2019-10-22 Merchandise category recognition method, apparatus, and electronic device

Country Status (2)

Country Link
CN (1) CN111382635B (en)
WO (1) WO2020134411A1 (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113065447A (en) * 2021-03-29 2021-07-02 南京掌控网络科技有限公司 Method and equipment for automatically identifying commodities in image set
CN113111800A (en) * 2021-04-19 2021-07-13 北京每日优鲜电子商务有限公司 Commodity shelf-loading judging method and device for unmanned container and storage medium
CN114140696A (en) * 2022-01-27 2022-03-04 深圳市慧为智能科技股份有限公司 Commodity identification system optimization method, commodity identification system optimization device, commodity identification equipment and storage medium
CN114549938A (en) * 2022-04-25 2022-05-27 广州市玄武无线科技股份有限公司 Model training method, image information management method, image recognition method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105894047A (en) * 2016-06-28 2016-08-24 深圳市唯特视科技有限公司 Human face classification system based on three-dimensional data
CN106886795A (en) * 2017-02-17 2017-06-23 北京维弦科技有限责任公司 Object identification method based on the obvious object in image
CN106960214A (en) * 2017-02-17 2017-07-18 北京维弦科技有限责任公司 Object identification method based on image

Family Cites Families (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8489689B1 (en) * 2006-05-31 2013-07-16 Proofpoint, Inc. Apparatus and method for obfuscation detection within a spam filtering model
JP5385759B2 (en) * 2009-10-30 2014-01-08 キヤノン株式会社 Image processing apparatus and image processing method
CN103559504B (en) * 2013-11-04 2016-08-31 北京京东尚科信息技术有限公司 Image target category identification method and device
CN106255966A (en) * 2014-04-30 2016-12-21 谷歌公司 StoreFront identification is used to identify entity to be investigated
CN106354735A (en) * 2015-07-22 2017-01-25 杭州海康威视数字技术股份有限公司 Image target searching method and device
CN106547744B (en) * 2015-09-16 2020-11-06 杭州海康威视数字技术股份有限公司 Image retrieval method and system
CN106706677B (en) * 2015-11-18 2019-09-03 同方威视技术股份有限公司 Check the method and system of cargo
US9972158B2 (en) * 2016-10-01 2018-05-15 Cantaloupe Systems, Inc. Method and device of automatically determining a planogram in vending
US20180181569A1 (en) * 2016-12-22 2018-06-28 A9.Com, Inc. Visual category representation with diverse ranking
CN107622397A (en) * 2017-08-07 2018-01-23 深圳益强信息科技有限公司 Trade mark monitoring method and system
CN107908685A (en) * 2017-10-31 2018-04-13 西安交通大学 The retrieval of various visual angles commodity image and recognition methods based on transfer learning
CN108764068A (en) * 2018-05-08 2018-11-06 北京大米科技有限公司 A kind of image-recognizing method and device
CN109035579A (en) * 2018-06-29 2018-12-18 深圳和而泰数据资源与云技术有限公司 A kind of commodity recognition method, self-service machine and computer readable storage medium

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105894047A (en) * 2016-06-28 2016-08-24 深圳市唯特视科技有限公司 Human face classification system based on three-dimensional data
CN106886795A (en) * 2017-02-17 2017-06-23 北京维弦科技有限责任公司 Object identification method based on the obvious object in image
CN106960214A (en) * 2017-02-17 2017-07-18 北京维弦科技有限责任公司 Object identification method based on image

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113065447A (en) * 2021-03-29 2021-07-02 南京掌控网络科技有限公司 Method and equipment for automatically identifying commodities in image set
CN113111800A (en) * 2021-04-19 2021-07-13 北京每日优鲜电子商务有限公司 Commodity shelf-loading judging method and device for unmanned container and storage medium
CN114140696A (en) * 2022-01-27 2022-03-04 深圳市慧为智能科技股份有限公司 Commodity identification system optimization method, commodity identification system optimization device, commodity identification equipment and storage medium
CN114549938A (en) * 2022-04-25 2022-05-27 广州市玄武无线科技股份有限公司 Model training method, image information management method, image recognition method and device

Also Published As

Publication number Publication date
CN111382635A (en) 2020-07-07
CN111382635B (en) 2023-10-13

Similar Documents

Publication Publication Date Title
WO2020134411A1 (en) Merchandise category recognition method, apparatus, and electronic device
CN108549870B (en) Method and device for identifying article display
CN110020592B (en) Object detection model training method, device, computer equipment and storage medium
WO2017084408A1 (en) Method and system for checking cargo
WO2022213465A1 (en) Neural network-based image recognition method and apparatus, electronic device, and medium
CN107958230B (en) Facial expression recognition method and device
US20180144216A1 (en) Classification method, classification module and computer program product using the same
CN110287873A (en) Noncooperative target pose measuring method, system and terminal device based on deep neural network
US20230206121A1 (en) Modal information completion method, apparatus, and device
CN111582359A (en) Image identification method and device, electronic equipment and medium
CN109983459A (en) Method and apparatus for identifying the counting of the N-GRAM occurred in corpus
CN111178196B (en) Cell classification method, device and equipment
Shoohi et al. DCGAN for Handling Imbalanced Malaria Dataset based on Over-Sampling Technique and using CNN.
CN114419378B (en) Image classification method and device, electronic equipment and medium
CN106709490B (en) Character recognition method and device
CA3147341A1 (en) Category phrase recognition method, model training method, device and system
JP6904430B2 (en) Information processing equipment, control methods, and programs
CN110069648A (en) A kind of image search method and device
JP2017162098A (en) Learning method, information processing device and learning program
CN112329810B (en) Image recognition model training method and device based on significance detection
CN111222558B (en) Image processing method and storage medium
CN111414930B (en) Deep learning model training method and device, electronic equipment and storage medium
CN112699907A (en) Data fusion method, device and equipment
CN114692778A (en) Multi-modal sample set generation method, training method and device for intelligent inspection
CN111222377B (en) Commodity information determining method and device and electronic equipment

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19906180

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19906180

Country of ref document: EP

Kind code of ref document: A1

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS (EPO FORM 1205A DATED 19.08.2021)

122 Ep: pct application non-entry in european phase

Ref document number: 19906180

Country of ref document: EP

Kind code of ref document: A1