Movatterモバイル変換


[0]ホーム

URL:


CN112085063A - A target identification method, device, terminal device and storage medium - Google Patents

A target identification method, device, terminal device and storage medium
Download PDF

Info

Publication number
CN112085063A
CN112085063ACN202010797205.2ACN202010797205ACN112085063ACN 112085063 ACN112085063 ACN 112085063ACN 202010797205 ACN202010797205 ACN 202010797205ACN 112085063 ACN112085063 ACN 112085063A
Authority
CN
China
Prior art keywords
target object
target
classification label
neural network
network model
Prior art date
Legal status (The legal status 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 status listed.)
Granted
Application number
CN202010797205.2A
Other languages
Chinese (zh)
Other versions
CN112085063B (en
Inventor
李扬
程骏
庞建新
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Youbixuan Intelligent Robot Co ltd
Original Assignee
Shenzhen Ubtech Technology Co ltd
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 Shenzhen Ubtech Technology Co ltdfiledCriticalShenzhen Ubtech Technology Co ltd
Priority to CN202010797205.2ApriorityCriticalpatent/CN112085063B/en
Publication of CN112085063ApublicationCriticalpatent/CN112085063A/en
Application grantedgrantedCritical
Publication of CN112085063BpublicationCriticalpatent/CN112085063B/en
Activelegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Images

Classifications

Landscapes

Abstract

Translated fromChinese

本申请适用于机器视觉技术领域,提供了一种目标识别方法、装置、终端设备及存储介质,其中,方法包括:通过第一神经网络模型对目标图像进行检测,获得所述目标图像中的目标物体和所述目标物体的第一分类标签;通过第二神经网络模型对所述目标物体进行分类,获得所述目标物体的第二分类标签;根据所述第一分类标签和所述第二分类标签,确定所述目标物体的类别。本申请实施例由于第一个神经网络模型可以检测目标物体并对目标物体从第一分类标签进行分类,第二神经网络模型只需对目标物体从第二分类标签进行分类,平衡了第一神经网络模型和第二神经网络模型的分类负担,从而提高了对目标的识别效率。

Figure 202010797205

The present application is applicable to the field of machine vision technology, and provides a target recognition method, device, terminal device and storage medium, wherein the method includes: detecting a target image by using a first neural network model, and obtaining the target in the target image. object and the first classification label of the target object; classify the target object through the second neural network model to obtain the second classification label of the target object; according to the first classification label and the second classification label to determine the category of the target object. In the embodiment of the present application, since the first neural network model can detect the target object and classify the target object from the first classification label, the second neural network model only needs to classify the target object from the second classification label, which balances the first neural network. The classification burden of the network model and the second neural network model, thereby improving the recognition efficiency of the target.

Figure 202010797205

Description

Translated fromChinese
一种目标识别方法、装置、终端设备及存储介质A target identification method, device, terminal device and storage medium

技术领域technical field

本申请属于机器视觉技术领域,尤其涉及一种目标识别方法、装置、终端设备及存储介质。The present application belongs to the technical field of machine vision, and in particular, relates to a target recognition method, device, terminal device and storage medium.

背景技术Background technique

随着机器视觉技术的发展,基于机器视觉的目标识别技术(例如车型识别、垃圾类型识别等等)也得到了越来越广泛的关注,目标识别是从图像或视频中检测出目标,并对目标进行分类,以确定目标属于何种类型。With the development of machine vision technology, target recognition technology based on machine vision (such as vehicle type recognition, garbage type recognition, etc.) has also received more and more extensive attention. Targets are classified to determine what type the target is.

深度学习为机器视觉中的一个新的领域,近年来基于深度学习的目标识别技术,由于其精度较高,得到了比较广泛的应用,然而目前基于深度学习的目标识别技术主要是先检测目标,检测到图像中的目标后再用分类器去对目标进行分类。当需要分类的类别太多时,分类器负荷过大,从而导致识别效率低。Deep learning is a new field in machine vision. In recent years, the target recognition technology based on deep learning has been widely used due to its high accuracy. However, the current target recognition technology based on deep learning mainly detects the target first. After detecting the target in the image, the classifier is used to classify the target. When there are too many categories to be classified, the classifier is overloaded, resulting in low recognition efficiency.

发明内容SUMMARY OF THE INVENTION

本申请实施例提供了一种目标识别方法、装置、终端设备及存储介质,旨在解决现有对目标识别的效率不高的问题。The embodiments of the present application provide a target recognition method, apparatus, terminal device and storage medium, which aim to solve the problem of low efficiency of target recognition in the prior art.

第一方面,本申请实施例提供了一种目标识别方法,包括:In a first aspect, an embodiment of the present application provides a target recognition method, including:

通过第一神经网络模型对目标图像进行检测,获得所述目标图像中的目标物体和所述目标物体的第一分类标签;Detecting the target image by using the first neural network model to obtain the target object in the target image and the first classification label of the target object;

通过第二神经网络模型对所述目标物体进行分类,获得所述目标物体的第二分类标签;Classify the target object by using the second neural network model to obtain a second classification label of the target object;

根据所述第一分类标签和所述第二分类标签,确定所述目标物体的类别。The category of the target object is determined according to the first classification label and the second classification label.

第二方面,本申请实施例提供了一种目标识别装置,包括:In a second aspect, an embodiment of the present application provides a target identification device, including:

第一获得模块,用于通过第一神经网络模型对目标图像进行检测,获得所述目标图像中的目标物体和所述目标物体的第一分类标签;a first obtaining module, configured to detect a target image through a first neural network model, and obtain a target object in the target image and a first classification label of the target object;

第二获得模块,用于通过第二神经网络模型对所述目标物体进行分类,获得所述目标物体的第二分类标签;a second obtaining module, configured to classify the target object through a second neural network model to obtain a second classification label of the target object;

确定模块,用于根据所述第一分类标签和所述第二分类标签,确定所述目标物体的类别。A determination module, configured to determine the category of the target object according to the first classification label and the second classification label.

第三方面,本申请实施例提供了一种终端设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现上述目标识别方法的步骤。In a third aspect, an embodiment of the present application provides a terminal device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, when the processor executes the computer program Steps to implement the above object recognition method.

第四方面,本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,上述计算机程序被处理器执行时实现上述目标识别方法的步骤。In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the steps of the above target identification method are implemented.

第五方面,本申请实施例提供了一种计算机程序产品,当计算机程序产品在电子设备上运行时,使得电子设备执行上述现上述目标识别方法的步骤。In a fifth aspect, an embodiment of the present application provides a computer program product, which, when the computer program product runs on an electronic device, causes the electronic device to execute the steps of the above-mentioned target identification method.

本申请实施例与现有技术相比存在的有益效果是:本申请实施例通过第一神经网络模型对目标图像进行检测,获得所述目标图像中的目标物体和所述目标物体的第一分类标签;通过第二神经网络模型对所述目标物体进行分类,获得所述目标物体的第二分类标签;根据所述第一分类标签和所述第二分类标签,确定所述目标物体的类别。由于第一个神经网络模型可以检测目标物体并对目标物体从第一分类标签进行分类,第二神经网络模型只需对目标物体从第二分类标签进行分类,平衡了第一神经网络模型和第二神经网络模型的分类负担,从而提高了对目标的识别效率。Compared with the prior art, the embodiment of the present application has the following beneficial effects: the embodiment of the present application detects the target image through the first neural network model, and obtains the target object in the target image and the first classification of the target object label; classify the target object through a second neural network model to obtain a second classification label of the target object; determine the category of the target object according to the first classification label and the second classification label. Since the first neural network model can detect the target object and classify the target object from the first classification label, the second neural network model only needs to classify the target object from the second classification label, which balances the first neural network model and the third classification label. The classification burden of the second neural network model, thereby improving the recognition efficiency of the target.

附图说明Description of drawings

为了更清楚地说明本申请实施例中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to illustrate the technical solutions in the embodiments of the present application more clearly, the following briefly introduces the accompanying drawings that need to be used in the description of the embodiments or the prior art. Obviously, the drawings in the following description are only for the present application. In some embodiments, for those of ordinary skill in the art, other drawings can also be obtained according to these drawings without any creative effort.

图1是本申请一实施例提供的目标识别方法的流程示意图;1 is a schematic flowchart of a target recognition method provided by an embodiment of the present application;

图2是本申请一实施例提供的步骤S103的一个具体流程示意图;FIG. 2 is a specific flowchart of step S103 provided by an embodiment of the present application;

图3是本申请一实施例提供的一具体应用场景中预先构建矩阵的示意图;3 is a schematic diagram of a pre-built matrix in a specific application scenario provided by an embodiment of the present application;

图4是本申请一实施例提供的一具体应用场景中输出结果的示意图;4 is a schematic diagram of an output result in a specific application scenario provided by an embodiment of the present application;

图5是本申请另一实施例提供的目标识别装置的结构示意图;5 is a schematic structural diagram of a target identification device provided by another embodiment of the present application;

图6是本申请又一实施例提供的终端设备的结构示意图。FIG. 6 is a schematic structural diagram of a terminal device provided by another embodiment of the present application.

具体实施方式Detailed ways

以下描述中,为了说明而不是为了限定,提出了诸如特定系统结构、技术之类的具体细节,以便透彻理解本申请实施例。然而,本领域的技术人员应当清楚,在没有这些具体细节的其它实施例中也可以实现本申请。在其它情况中,省略对众所周知的系统、装置、电路以及方法的详细说明,以免不必要的细节妨碍本申请的描述。In the following description, for the purpose of illustration rather than limitation, specific details such as a specific system structure and technology are set forth in order to provide a thorough understanding of the embodiments of the present application. However, it will be apparent to those skilled in the art that the present application may be practiced in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.

应当理解,当在本申请说明书和所附权利要求书中使用时,术语“包括”指示所描述特征、整体、步骤、操作、元素和/或组件的存在,但并不排除一个或多个其它特征、整体、步骤、操作、元素、组件和/或其集合的存在或添加。It is to be understood that, when used in this specification and the appended claims, the term "comprising" indicates the presence of the described feature, integer, step, operation, element and/or component, but does not exclude one or more other The presence or addition of features, integers, steps, operations, elements, components and/or sets thereof.

还应当理解,在本申请说明书和所附权利要求书中使用的术语“和/或”是指相关联列出的项中的一个或多个的任何组合以及所有可能组合,并且包括这些组合。It will also be understood that, as used in this specification and the appended claims, the term "and/or" refers to and including any and all possible combinations of one or more of the associated listed items.

如在本申请说明书和所附权利要求书中所使用的那样,术语“如果”可以依据上下文被解释为“当...时”或“一旦”或“响应于确定”或“响应于检测到”。类似地,短语“如果确定”或“如果检测到[所描述条件或事件]”可以依据上下文被解释为意指“一旦确定”或“响应于确定”或“一旦检测到[所描述条件或事件]”或“响应于检测到[所描述条件或事件]”。As used in the specification of this application and the appended claims, the term "if" may be contextually interpreted as "when" or "once" or "in response to determining" or "in response to detecting ". Similarly, the phrases "if it is determined" or "if the [described condition or event] is detected" may be interpreted, depending on the context, to mean "once it is determined" or "in response to the determination" or "once the [described condition or event] is detected. ]" or "in response to detection of the [described condition or event]".

另外,在本申请说明书和所附权利要求书的描述中,术语“第一”、“第二”、“第三”等仅用于区分描述,而不能理解为指示或暗示相对重要性。In addition, in the description of the specification of the present application and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the description, and should not be construed as indicating or implying relative importance.

在本申请说明书中描述的参考“一个实施例”或“一些实施例”等意味着在本申请的一个或多个实施例中包括结合该实施例描述的特定特征、结构或特点。由此,在本说明书中的不同之处出现的语句“在一个实施例中”、“在一些实施例中”、“在其他一些实施例中”、“在另外一些实施例中”等不是必然都参考相同的实施例,而是意味着“一个或多个但不是所有的实施例”,除非是以其他方式另外特别强调。术语“包括”、“包含”、“具有”及它们的变形都意味着“包括但不限于”,除非是以其他方式另外特别强调。References in this specification to "one embodiment" or "some embodiments" and the like mean that a particular feature, structure or characteristic described in connection with the embodiment is included in one or more embodiments of the present application. Thus, appearances of the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in other embodiments," etc. in various places in this specification are not necessarily All refer to the same embodiment, but mean "one or more but not all embodiments" unless specifically emphasized otherwise. The terms "including", "including", "having" and their variants mean "including but not limited to" unless specifically emphasized otherwise.

本申请实施例提供的目标识别方法,可以应用于机器人、手机、平板电脑、可穿戴设备、车载设备、增强现实(augmented reality,AR)/虚拟现实(virtual reality,VR)设备、笔记本电脑、超级移动个人计算机(ultra-mobile personal computer,UMPC)、上网本、个人数字助理(personal digital assistant,PDA)等终端设备上,本申请实施例对终端设备的具体类型不作任何限制。The target recognition method provided in the embodiments of the present application can be applied to robots, mobile phones, tablet computers, wearable devices, vehicle-mounted devices, augmented reality (AR)/virtual reality (VR) devices, notebook computers, super On terminal devices such as a mobile personal computer (ultra-mobile personal computer, UMPC), a netbook, a personal digital assistant (personal digital assistant, PDA), the embodiments of the present application do not limit the specific type of the terminal device.

为了说明本申请所述的技术方案,下面通过以下实施例来进行说明。In order to illustrate the technical solutions described in this application, the following examples are used to illustrate.

实施例一Example 1

请参阅图1,本申请实施例提供的一种目标识别方法,包括:Referring to FIG. 1, a target recognition method provided by an embodiment of the present application includes:

步骤S101,通过第一神经网络模型对目标图像进行检测,获得所述目标图像中的目标物体和所述目标物体的第一分类标签。Step S101: Detect a target image through a first neural network model to obtain a target object in the target image and a first classification label of the target object.

具体的,上述第一神经网络模型为预先构建并已经训练完成的神经网络模型,用于检测所述目标图像中是否存在所述目标物体,当检测到存在所述目标物体时输出所述目标物体的第一分类标签。Specifically, the above-mentioned first neural network model is a pre-built and trained neural network model, which is used to detect whether the target object exists in the target image, and output the target object when the target object is detected. The first category label of .

在一个具体应用场景中,如所述目标物体可以是车辆,第一分类标签包括车辆的尺寸,所述车辆尺寸可包括多种属性尺寸,如大型尺寸车辆、中型尺寸车辆及小型尺寸车辆。上述第一神经网络模型在检测目标图像中存在车辆时输出车辆的属性尺寸。在实际应用中,上述第一分类标签可以是其他一种或多种指示目标物体特征的分类标签,如需要检测的目标物体是车辆时,上述第一分类标签可以是车辆的品牌,上述应用场景只是举例,如还可以应用于垃圾识别,人脸识别等等,对此不做限定。In a specific application scenario, for example, the target object may be a vehicle, and the first classification label includes the size of the vehicle, and the vehicle size may include various attribute sizes, such as a large-sized vehicle, a medium-sized vehicle, and a small-sized vehicle. The above-mentioned first neural network model outputs the attribute size of the vehicle when detecting the existence of the vehicle in the target image. In practical applications, the first classification label may be one or more other classification labels indicating the characteristics of the target object. For example, when the target object to be detected is a vehicle, the first classification label may be the brand of the vehicle. The above application scenario It is just an example, for example, it can also be applied to garbage recognition, face recognition, etc., which is not limited.

所述第一神经网络模型可以是预先通过轻量级网络模型构建的神经网络模型,根据需要识别的目标物体准备大量的包含所述目标物体的图像,如需要识别的目标物体是车辆时,准备包括各种类型车辆的图片,并对每个图片进行第一分类标签标注。将准备大量的包含所述目标物体的图像对第一神经网络模型进行训练,直至第一神经网络模型的预设损失函数收敛为止,判定第一神经网络模型为已经训练好的神经网络模型。第一神经网络模型的预设的损失函数可以是交叉熵损失函数或者均方误差损失函数等类型的损失函数。The first neural network model may be a neural network model constructed in advance through a lightweight network model. Prepare a large number of images containing the target object according to the target object to be recognized. For example, when the target object to be recognized is a vehicle, prepare Include pictures of various types of vehicles, and label each picture with the first classification label. A large number of images containing the target object are prepared to train the first neural network model until the preset loss function of the first neural network model converges, and the first neural network model is determined to be a trained neural network model. The preset loss function of the first neural network model may be a loss function of a type such as a cross entropy loss function or a mean square error loss function.

在一个实施例中,所述通过第一神经网络模型对目标图像进行检测,获得所述目标图像中的目标物体和所述目标物体的第一分类标签,包括:通过第一神经网络模型对目标图像进行检测,在检测到所述目标图像中的目标物体时,获得所述目标物体在所述目标图像中的坐标和所述目标物体的第一分类标签。具体可以是在检测到目标物体时,输出目标物体的在图像中的位置信息和所述目标物体的第一分类标签。In one embodiment, the detecting the target image by using the first neural network model to obtain the target object in the target image and the first classification label of the target object includes: using the first neural network model to detect the target The image is detected, and when the target object in the target image is detected, the coordinates of the target object in the target image and the first classification label of the target object are obtained. Specifically, when the target object is detected, the position information of the target object in the image and the first classification label of the target object are output.

步骤S102,通过第二神经网络模型对所述目标物体进行分类,获得所述目标物体的第二分类标签。Step S102: Classify the target object through a second neural network model to obtain a second classification label of the target object.

具体的,上述第二神经网络模型为预先构建并已经训练完成的神经网络模型,用于对第一神经网络模型检测的所述目标物体进行分类,第二神经网络模型输出结果为所述目标物体的第二分类标签。Specifically, the above-mentioned second neural network model is a pre-built and trained neural network model, which is used to classify the target object detected by the first neural network model, and the output result of the second neural network model is the target object The second category label of .

在一个具体应用场景中,如所述目标物体可以为车辆,上述第一分类标签包括车辆的尺寸,上述第二分类标签包括车辆的车型,车型包括多种属性的车型,如轿车,客车和货车等等。上述第二神经网络模型用于输出车辆车型的属性。在实际应用中,上述第二分类标签可以是其他一种或多种指示目标物体特征的分类标签,上述第一分类标签与第二分类标签是从目标物体的不同特征维度进行分类的标签,上述应用场景和第一分类标签与第二分类标签两个特征维度只是举例,对此不做限定,如应用场景还可以是应用于垃圾识别,人脸识别等等应用场景。In a specific application scenario, for example, the target object may be a vehicle, the first classification label includes the size of the vehicle, the second classification label includes the model of the vehicle, and the model includes models with various attributes, such as sedans, passenger cars and trucks and many more. The above-mentioned second neural network model is used to output the attributes of the vehicle type. In practical applications, the second classification label may be one or more other classification labels indicating the characteristics of the target object, and the first classification label and the second classification label are labels classified from different feature dimensions of the target object. The application scenario and the two feature dimensions of the first classification label and the second classification label are just examples, which are not limited. For example, the application scenario may also be applied to application scenarios such as garbage recognition and face recognition.

所述第二神经网络模式可以是预先通过轻量级网络模型构建的神经网络模型,根据需要识别的目标物体准备大量的目标物体图像,如需要识别的目标物体是车辆时,准备各种类型车辆的图片,并对每个图片进行第二分类标签标注。将准备大量的目标物体图像对第二神经网络模型进行训练,直至第二神经网络模型的预设损失函数收敛为止,判定第二神经网络模型为已经训练好的神经网络模型。第二神经网络模型的预设的损失函数可以是交叉熵损失函数或者均方误差损失函数等类型的损失函数。The second neural network mode can be a neural network model constructed in advance through a lightweight network model, and a large number of target object images are prepared according to the target object to be recognized. For example, when the target object to be recognized is a vehicle, various types of vehicles are prepared. pictures, and label each picture with a second classification label. A large number of target object images are prepared to train the second neural network model until the preset loss function of the second neural network model converges, and the second neural network model is determined to be a trained neural network model. The preset loss function of the second neural network model may be a loss function of a type such as a cross entropy loss function or a mean square error loss function.

在一个实施例中,所述通过第二神经网络模型对所述目标物体进行分类,获得所述目标物体的第二分类标签之前,包括:根据所述目标物体在所述目标图像中的坐标,提取所述目标物体。具体的,在通过第一神经网络模型确定目标物体在目标图像中的位置时,根据在目标图像中的位置提取出目标物体,将提取的目标物体输入至第二神经网络模型,因此第二神经网络模型只需要对目标物体进行分类不需要检测,可以提高分类效率。In one embodiment, before obtaining the second classification label of the target object by classifying the target object by using the second neural network model, the method includes: according to the coordinates of the target object in the target image, Extract the target object. Specifically, when the position of the target object in the target image is determined by the first neural network model, the target object is extracted according to the position in the target image, and the extracted target object is input into the second neural network model, so the second neural network The network model only needs to classify the target object without detection, which can improve the classification efficiency.

在一个实施例中,所述根据所述目标物体在所述目标图像中的坐标,提取所述目标物体,包括:根据所述目标物体在所述目标图像中的坐标,确定对应的矩形框;根据所述矩形框在所述目标图像中的坐标,提取所述目标物体。在具体应用中,由于神经网络输入的图片一般是形状规则的图片,因此先根据所述目标物体在所述目标图像中的坐标,在所述目标图像中绘制出包括所述目标物体的矩形框;具体可以是与目标物体在目标图像中最上位置像素点的坐标间隔第一预设像素个数的距离确定矩形框的上边,与目标物体在目标图像中最下位置像素点的坐标间隔第二预设像素个数的距离确定矩形框的下边,与目标物体在目标图像中最左位置像素点的坐标间隔第三预设像素个数的距离确定矩形框的左边,与目标物体在目标图像中最右位置像素点的坐标间隔第四预设像素个数的距离确定矩形框的右边,确定矩形框之后,再根据所述矩形框在所述目标图像中的坐标,对所述目标图像进行剪裁,以提取规则的目标物体的图像。In one embodiment, the extracting the target object according to the coordinates of the target object in the target image includes: determining a corresponding rectangular frame according to the coordinates of the target object in the target image; The target object is extracted according to the coordinates of the rectangular frame in the target image. In a specific application, since the image input by the neural network is generally a regular-shaped image, a rectangular frame including the target object is first drawn in the target image according to the coordinates of the target object in the target image. Specifically, it can be determined by the distance between the coordinates of the pixel at the uppermost position of the target object in the target image and the first preset number of pixels, and the distance between the coordinates of the pixel at the lowermost position of the target object in the target image and the distance between the pixels at the lowermost position in the target image. The distance of the preset number of pixels determines the lower edge of the rectangular frame, and the distance from the third preset number of pixels to the coordinates of the pixel point at the leftmost position of the target object in the target image determines the left side of the rectangular frame, and the distance between the target object and the target object in the target image The distance between the coordinates of the pixel point at the rightmost position and the fourth preset number of pixels determines the right side of the rectangular frame. After the rectangular frame is determined, the target image is trimmed according to the coordinates of the rectangular frame in the target image. , to extract regular images of target objects.

步骤S103,根据所述第一分类标签和所述第二分类标签,确定所述目标物体的类别。Step S103: Determine the category of the target object according to the first classification label and the second classification label.

具体的,根据第一分类标签和第二分类标签确定目标物体的类别,如上述通过第一神经网络确定目标物体的第一分类标签为大型尺寸车辆,上述第二神经网络确定目标物体的第二分类标签为客车,则确定目标物体的类别为大型尺寸车辆的客车。如上述通过第一神经网络确定目标物体的第一分类标签为小型尺寸车辆,上述第二神经网络确定目标物体的第二分类标签为客车,则确定目标物体的类别为小型尺寸车辆的客车。Specifically, the category of the target object is determined according to the first classification label and the second classification label. As described above, the first classification label of the target object is determined by the first neural network as a large-size vehicle, and the second neural network is used to determine the second classification of the target object. If the classification label is a passenger car, the category of the target object is determined to be a passenger car of a large-sized vehicle. If the first classification label of the target object is determined by the first neural network as a small-sized vehicle, and the second classification label of the target object is determined by the second neural network as a passenger car, the category of the target object is determined to be a passenger car of a small-sized vehicle.

在一个实施例中,在将目标图像输入至第一神经网络模型进行目标检测之前,包括:构建包含M×M个元素的矩阵;其中,M≥2且为整数;在所述矩阵的每个元素中存储一类物体的类别信息;建立所述矩阵的第i列中的各个元素与第i属性的第一分类标签之间的关联关系并存储;其中,1≤i≤M且i为整数;建立所述矩阵的第i行中的各个元素与第i属性的第二分类标签之间的关联关系并存储。其中,第i列为矩阵中的任一列,第i行为矩阵中的任一行。In one embodiment, before the target image is input into the first neural network model for target detection, the method includes: constructing a matrix including M×M elements; wherein, M≥2 and an integer; in each of the matrix The category information of a class of objects is stored in the element; the association relationship between each element in the i-th column of the matrix and the first classification label of the i-th attribute is established and stored; wherein, 1≤i≤M and i is an integer ; Establish and store the association relationship between each element in the ith row of the matrix and the second classification label of the ith attribute. Among them, the i-th column is any column in the matrix, and the i-th row is any row in the matrix.

在实际应用中,第一分类标签与第二分类标签是目标物体两个维度的不同特征,根据两个维度的不同特征可能不能直接得出目标物体的类别,当需要分类N个类别(N等于M×M),可预先建立一个M×M个元素的矩阵,在所述矩阵的每个元素中存储一类物体的类别信息;矩阵的同一列中的各个元素对应同一种第一分类标签,不同列元素对应不同的第一分类标签;矩阵的同一行中的各个元素对应同一种第二分类标签,不同行元素对应不同的第二分类标签。In practical applications, the first classification label and the second classification label are different features of the two dimensions of the target object. According to the different features of the two dimensions, the class of the target object may not be directly obtained. When it is necessary to classify N classes (N equal to M×M), a matrix of M×M elements can be established in advance, and the category information of a class of objects is stored in each element of the matrix; each element in the same column of the matrix corresponds to the same first classification label, Different column elements correspond to different first classification labels; each element in the same row of the matrix corresponds to the same second classification label, and different row elements correspond to different second classification labels.

在一个实施例中,如图3所示,上述步骤S103具体包括步骤S1031至步骤S1034:In one embodiment, as shown in FIG. 3 , the above step S103 specifically includes steps S1031 to S1034:

步骤S1031,根据所述第一分类标签,确定所述目标物体在所述矩阵中的列坐标;Step S1031, determining the column coordinates of the target object in the matrix according to the first classification label;

具体的,由于矩阵中不同列元素对应不同的第一分类标签,根据第一神经网络输出的第一分类标签,可以确定目标物体属于矩阵中的哪一列。Specifically, since elements in different columns in the matrix correspond to different first classification labels, which column in the matrix the target object belongs to can be determined according to the first classification labels output by the first neural network.

步骤S1032,根据所述第二分类标签,确定所述目标物体在所述矩阵中的行坐标;Step S1032, determining the row coordinates of the target object in the matrix according to the second classification label;

具体的,由于矩阵中不同行元素对应不同的第二分类标签,根据第二神经网络输出的第二分类标签,确定目标物体属于矩阵中的哪一行。Specifically, since different row elements in the matrix correspond to different second classification labels, it is determined which row in the matrix the target object belongs to according to the second classification label output by the second neural network.

步骤S1033,根据所述行坐标和所述列坐标,确定所述目标物体在所述矩阵中的坐标;Step S1033, determining the coordinates of the target object in the matrix according to the row coordinates and the column coordinates;

具体的,根据得到目标物体所属于的行坐标和列坐标,可以确定目标物体在矩阵中的坐标位置。Specifically, according to the obtained row coordinates and column coordinates to which the target object belongs, the coordinate position of the target object in the matrix can be determined.

步骤S1034,根据所述目标物体在所述矩阵中的坐标,确定所述目标物体的类别。Step S1034: Determine the category of the target object according to the coordinates of the target object in the matrix.

具体的,目标物体在矩阵中的坐标位置,获取与该坐标位置对应存储物体的类别信息。Specifically, for the coordinate position of the target object in the matrix, the category information of the stored object corresponding to the coordinate position is obtained.

为更好的理解本申请实施例,请参阅图3,为一具体应用场景中一个矩阵示意图,例如M×M个元素的矩阵为一个3×3的矩阵,每个元素存储了对应的类别信息。矩阵的同一列中的各个元素对应同一种第一分类标签(如第一列的所有元素对应小型尺寸车辆,第二列的所有元素对应中型尺寸车辆),不同列的元素对应不同的第一分类标签,矩阵的同一行中的各个元素对应同一种第二分类标签(如第一行的所有元素对应货车,第二行的所有元素对应客车),不同行的元素对应不同的第二分类标签。当根据第一神经网络输出的第一分类标签是小型尺寸车辆时,确定目标物体属于矩阵中列坐标为第一列,当第二神经网络输出的第二分类标签是桥车,确定目标物体属于矩阵中行坐标为第三行,根据列坐标和行坐标可以确定目标物体属于矩阵中的第三行第一列,根据第三行第一列中存储的类别信息(小型轿车),可确定目标物体类别为小型轿车。因此在需要分类N个类别(N等于M×M)时,每个神经网络模型只需分类M个类别,M小于N,特别在分类较多时M远小于N,神经网络的分类类别越少对分类的效果会越好,因此可提高目标的识别效率。当需要分的N个类别不是一个完全平方数时,建立的矩阵中某个或多个元素可以不存储目标物体的类别信息,那么当识别到物体属于未存储目标物体的类别信息的矩阵中的坐标时,输出结果为识别错误。此处仅是为了帮助理解进行举例,具体根据实际应用进行分类,此处不做限定。To better understand the embodiments of the present application, please refer to FIG. 3 , which is a schematic diagram of a matrix in a specific application scenario. For example, a matrix with M×M elements is a 3×3 matrix, and each element stores corresponding category information. . Each element in the same column of the matrix corresponds to the same first category label (for example, all elements in the first column correspond to small-sized vehicles, and all elements in the second column correspond to medium-sized vehicles), and elements in different columns correspond to different first categories Label, each element in the same row of the matrix corresponds to the same second classification label (for example, all elements in the first row correspond to trucks, and all elements in the second row correspond to passenger cars), and elements in different rows correspond to different second classification labels. When the first classification label output by the first neural network is a small-sized vehicle, it is determined that the target object belongs to the first column in the matrix, and when the second classification label output by the second neural network is a bridge vehicle, it is determined that the target object belongs to The row coordinate in the matrix is the third row. According to the column coordinates and row coordinates, it can be determined that the target object belongs to the third row and the first column of the matrix. According to the category information (small car) stored in the third row and the first column, the target object can be determined. The category is small car. Therefore, when N categories need to be classified (N is equal to M×M), each neural network model only needs to classify M categories, and M is smaller than N, especially when there are many classifications, M is much smaller than N, and the fewer the classification categories of the neural network, the less right The classification effect will be better, so the recognition efficiency of the target can be improved. When the N categories to be divided are not a perfect square number, one or more elements in the established matrix may not store the category information of the target object, then when it is identified that the object belongs to the matrix that does not store the category information of the target object When the coordinates are set, the output result is a recognition error. The examples here are only for helping understanding, and are specifically classified according to practical applications, which are not limited here.

在一个实施例中,在根据所述第一分类标签和所述第二分类标签,确定所述目标物体的类别之后,包括:在所述目标图像中以预设方式显示所述矩形框以及所述目标物体的类别信息。如可以是以预设颜色显示所述矩形框并在距离矩形宽预设距离的位置显示所述目标物体的类别信息。在一种应用场景中,如图4所示,为一个应用场景中输出结果示意图,所述目标图像中包括目标车辆,并输出目标车辆的矩形框以及目标车辆的类别信息为小型轿车。In one embodiment, after determining the category of the target object according to the first classification label and the second classification label, the method includes: displaying the rectangular frame and all the objects in the target image in a preset manner. Describe the category information of the target object. For example, the rectangular frame may be displayed in a preset color and the category information of the target object may be displayed at a position with a preset distance from the rectangle. In an application scenario, as shown in FIG. 4 , which is a schematic diagram of the output result in an application scenario, the target image includes a target vehicle, and the rectangular frame of the target vehicle and the category information of the target vehicle are output as a small car.

本申请实施例由第一个神经网络模型可以检测目标物体并对目标物体从第一分类标签进行分类,第二神经网络模型只需对目标物体从第二分类标签进行分类,平衡了第一神经网络模型和第二神经网络模型的分类负担,从而提高了对目标的识别效率。In the embodiment of the present application, the first neural network model can detect the target object and classify the target object from the first classification label, and the second neural network model only needs to classify the target object from the second classification label, which balances the first neural network. The classification burden of the network model and the second neural network model, thereby improving the recognition efficiency of the target.

对应于上文实施例所述的目标识别方法,图5示出了本申请实施例提供的目标识别装置的结构框图,为了便于说明,仅示出了与本申请实施例相关的部分。参照图5,目标识别装置500包括:Corresponding to the target recognition method described in the above embodiment, FIG. 5 shows a structural block diagram of the target recognition apparatus provided by the embodiment of the present application. For convenience of description, only the part related to the embodiment of the present application is shown. 5, thetarget identification device 500 includes:

第一获得模块501,用于通过第一神经网络模型对目标图像进行检测,获得所述目标图像中的目标物体和所述目标物体的第一分类标签;The first obtainingmodule 501 is used to detect the target image through the first neural network model, and obtain the target object in the target image and the first classification label of the target object;

第二获得模块502,用于通过第二神经网络模型对所述目标物体进行分类,获得所述目标物体的第二分类标签;A second obtainingmodule 502, configured to classify the target object through a second neural network model, and obtain a second classification label of the target object;

确定模块503,用于根据所述第一分类标签和所述第二分类标签,确定所述目标物体的类别。The determiningmodule 503 is configured to determine the category of the target object according to the first classification label and the second classification label.

在一个实施例中,所述目标识别装置还包括:In one embodiment, the target identification device further includes:

构建模块,用于构建包含M×M个元素的矩阵;其中,M≥2且为整数;A building block for building a matrix containing M×M elements; where M≥2 and an integer;

存储模块,用于在所述矩阵的每个元素中存储一类物体的类别信息;a storage module for storing category information of a class of objects in each element of the matrix;

第一建立模块,用于建立所述矩阵的第i列中的各个元素与第i属性的第一分类标签之间的关联关系并存储;其中,1≤i≤M且i为整数;The first establishment module is used to establish and store the association relationship between each element in the ith column of the matrix and the first classification label of the ith attribute; wherein, 1≤i≤M and i is an integer;

第二建立模块,用于建立所述矩阵的第i行中的各个元素与第i属性的第二分类标签之间的关联关系并存储。The second establishing module is configured to establish and store the association relationship between each element in the ith row of the matrix and the second classification label of the ith attribute.

在一个实施例中,所述确定模块503包括:In one embodiment, the determiningmodule 503 includes:

第一确定单元,用于根据所述第一分类标签,确定所述目标物体在所述矩阵中的列坐标;a first determining unit, configured to determine the column coordinates of the target object in the matrix according to the first classification label;

第二确定单元,用于根据所述第二分类标签,确定所述目标物体在所述矩阵中的行坐标;a second determining unit, configured to determine the row coordinates of the target object in the matrix according to the second classification label;

第三确定单元,用于根据所述行坐标和所述列坐标,确定所述目标物体在所述矩阵中的坐标;a third determining unit, configured to determine the coordinates of the target object in the matrix according to the row coordinates and the column coordinates;

第四确定单元,用于根据所述目标物体在所述矩阵中的坐标,确定所述目标物体的类别。The fourth determining unit is configured to determine the category of the target object according to the coordinates of the target object in the matrix.

在一个实施例中,第一获得模块具体用于:In one embodiment, the first obtaining module is specifically used for:

通过第一神经网络模型对目标图像进行检测,在检测到所述目标图像中的目标物体时,获得所述目标物体在所述目标图像中的坐标和所述目标物体的第一分类标签。The target image is detected by the first neural network model, and when the target object in the target image is detected, the coordinates of the target object in the target image and the first classification label of the target object are obtained.

在一个实施例中,所述目标识别装置还包括:In one embodiment, the target identification device further includes:

目标提取模块,用于在所述第二获得模块触发之前,根据所述目标物体在所述目标图像中的坐标,根据所述目标物体在所述目标图像中的坐标,提取所述目标物体。A target extraction module, configured to extract the target object according to the coordinates of the target object in the target image and according to the coordinates of the target object in the target image before the second obtaining module is triggered.

在一个实施例中,所述目标提取模块具体用于:根据所述目标物体在所述目标图像中的坐标,确定对应的矩形框;根据所述矩形框在所述目标图像中的坐标,提取所述目标物体。In one embodiment, the target extraction module is specifically configured to: determine the corresponding rectangular frame according to the coordinates of the target object in the target image; extract the corresponding rectangular frame according to the coordinates of the rectangular frame in the target image the target object.

在一个实施例中,所述目标识别装置还包括:In one embodiment, the target identification device further includes:

显示模块,用于在所述目标图像中以预设方式显示所述矩形框以及所述目标物体的类别信息。A display module, configured to display the rectangular frame and the category information of the target object in a preset manner in the target image.

由于第一个神经网络模型可以检测目标物体并对目标物体从第一分类标签进行分类,第二神经网络模型只需对目标物体从第二分类标签进行分类,平衡了第一神经网络模型和第二神经网络模型的分类负担,从而提高了对目标的识别效率。Since the first neural network model can detect the target object and classify the target object from the first classification label, the second neural network model only needs to classify the target object from the second classification label, which balances the first neural network model and the third classification label. The classification burden of the second neural network model, thereby improving the recognition efficiency of the target.

如图6所示,本发明的一个实施例还提供一种终端设备600包括:处理器601,存储器602以及存储在所述存储器602中并可在所述处理器601上运行的计算机程序603,例如目标识别程序。所述处理器601执行所述计算机程序603时实现上述各个目标识别方法实施例中的步骤。所述处理器601执行所述计算机程序603时实现上述各装置实施例中各模块的功能,例如图6所示模块601至603的功能。As shown in FIG. 6, an embodiment of the present invention further provides aterminal device 600 including: aprocessor 601, amemory 602, and acomputer program 603 stored in thememory 602 and running on theprocessor 601, such as object recognition programs. When theprocessor 601 executes thecomputer program 603, the steps in each of the above-mentioned embodiments of the target identification method are implemented. When theprocessor 601 executes thecomputer program 603, the functions of the modules in the above-mentioned device embodiments are implemented, for example, the functions of themodules 601 to 603 shown in FIG. 6 .

示例性的,所述计算机程序603可以被分割成一个或多个模块,所述一个或者多个模块被存储在所述存储器602中,并由所述处理器601执行,以完成本发明。所述一个或多个模块可以是能够完成特定功能的一系列计算机程序指令段,该指令段用于描述所述计算机程序603在所述终端设备600中的执行过程。例如,所述计算机程序603可以被分割成第一获得模块,第二获得模块和确定模块,各模块具体功能在上述实施例中已有描述,此处不再赘述。Exemplarily, thecomputer program 603 may be divided into one or more modules, and the one or more modules are stored in thememory 602 and executed by theprocessor 601 to complete the present invention. The one or more modules may be a series of computer program instruction segments capable of accomplishing specific functions, and the instruction segments are used to describe the execution process of thecomputer program 603 in theterminal device 600 . For example, thecomputer program 603 may be divided into a first obtaining module, a second obtaining module and a determining module, and the specific functions of each module have been described in the above embodiments, and will not be repeated here.

所述终端设备600可以是机器人,移动终端设备桌上型计算机、笔记本及掌上电脑等计算设备。所述终端设备可包括,但不仅限于,处理器601,存储器602。本领域技术人员可以理解,图6仅仅是终端设备600的示例,并不构成对终端设备600的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件,例如所述终端设备还可以包括输入输出设备、网络接入设备、总线等。Theterminal device 600 may be a computing device such as a robot, a mobile terminal device, a desktop computer, a notebook, and a palmtop computer. The terminal device may include, but is not limited to, theprocessor 601 and thememory 602 . Those skilled in the art can understand that FIG. 6 is only an example of theterminal device 600, and does not constitute a limitation on theterminal device 600, and may include more or less components than the one shown, or combine some components, or different components For example, the terminal device may further include an input and output device, a network access device, a bus, and the like.

所称处理器601可以是中央处理单元(Central Processing Unit,CPU),还可以是其他通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。The so-calledprocessor 601 may be a central processing unit (Central Processing Unit, CPU), and may also be other general-purpose processors, digital signal processors (Digital Signal Processors, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), Field-Programmable Gate Array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.

所述存储器602可以是所述终端设备600的内部存储单元,例如终端设备600的硬盘或内存。所述存储器602也可以是所述终端设备600的外部存储设备,例如所述终端设备600上配备的插接式硬盘,智能存储卡(Smart Media Card,SMC),安全数字(SecureDigital,SD)卡,闪存卡(Flash Card)等。进一步地,所述存储器602还可以既包括所述终端设备600的内部存储单元也包括外部存储设备。所述存储器602用于存储所述计算机程序以及所述终端设备所需的其他程序和数据。所述存储器602还可以用于暂时地存储已经输出或者将要输出的数据。Thememory 602 may be an internal storage unit of theterminal device 600 , such as a hard disk or a memory of theterminal device 600 . Thememory 602 may also be an external storage device of theterminal device 600, for example, a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card equipped on theterminal device 600 , Flash Card (Flash Card) and so on. Further, thememory 602 may also include both an internal storage unit of theterminal device 600 and an external storage device. Thememory 602 is used to store the computer program and other programs and data required by the terminal device. Thememory 602 may also be used to temporarily store data that has been output or will be output.

所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,仅以上述各功能单元、模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元、模块完成,即将所述装置的内部结构划分成不同的功能单元或模块,以完成以上描述的全部或者部分功能。实施例中的各功能单元、模块可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中,上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。另外,各功能单元、模块的具体名称也只是为了便于相互区分,并不用于限制本申请的保护范围。上述系统中单元、模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that, for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example. Module completion, that is, dividing the internal structure of the device into different functional units or modules to complete all or part of the functions described above. Each functional unit and module in the embodiment may be integrated in one processing unit, or each unit may exist physically alone, or two or more units may be integrated in one unit, and the above-mentioned integrated units may adopt hardware. It can also be realized in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing from each other, and are not used to limit the protection scope of the present application. For the specific working process of the units and modules in the above-mentioned system, reference may be made to the corresponding process in the foregoing method embodiments, which will not be repeated here.

在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述或记载的部分,可以参见其它实施例的相关描述。In the foregoing embodiments, the description of each embodiment has its own emphasis. For parts that are not described or described in detail in a certain embodiment, reference may be made to the relevant descriptions of other embodiments.

本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本发明的范围。Those of ordinary skill in the art can realize that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Skilled artisans may implement the described functionality using different methods for each particular application, but such implementations should not be considered beyond the scope of the present invention.

在本发明所提供的实施例中,应该理解到,所揭露的装置/终端设备和方法,可以通过其它的方式实现。例如,以上所描述的装置/终端设备实施例仅仅是示意性的,例如,所述模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通讯连接可以是通过一些接口,装置或单元的间接耦合或通讯连接,可以是电性,机械或其它的形式。In the embodiments provided by the present invention, it should be understood that the disclosed apparatus/terminal device and method may be implemented in other manners. For example, the apparatus/terminal device embodiments described above are only illustrative. For example, the division of the modules or units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units. Or components may be combined or may be integrated into another system, or some features may be omitted, or not implemented. On the other hand, the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.

所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.

另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit. The above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.

所述集成的模块如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本发明实现上述实施例方法中的全部或部分流程,也可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一计算机可读存储介质中,该计算机程序在被处理器执行时,可实现上述各个方法实施例的步骤。其中,所述计算机程序包括计算机程序代码,所述计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。所述计算机可读介质可以包括:能够携带所述计算机程序代码的任何实体或装置、记录介质、U盘、移动硬盘、磁碟、光盘、计算机存储器、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,RandomAccess Memory)、电载波信号、电信信号以及软件分发介质等。需要说明的是,所述计算机可读介质包含的内容可以根据司法管辖区内立法和专利实践的要求进行适当的增减,例如在某些司法管辖区,根据立法和专利实践,计算机可读介质不包括电载波信号和电信信号。The integrated modules, if implemented in the form of software functional units and sold or used as independent products, may be stored in a computer-readable storage medium. Based on this understanding, the present invention can implement all or part of the processes in the methods of the above embodiments, and can also be completed by instructing relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer When the program is executed by the processor, the steps of the foregoing method embodiments can be implemented. Wherein, the computer program includes computer program code, and the computer program code may be in the form of source code, object code, executable file or some intermediate form, and the like. The computer-readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a U disk, a removable hard disk, a magnetic disk, an optical disk, a computer memory, a read-only memory (ROM, Read-Only Memory) , Random Access Memory (RAM, RandomAccess Memory), electric carrier signal, telecommunication signal and software distribution medium, etc. It should be noted that the content contained in the computer-readable media may be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction, for example, in some jurisdictions, according to legislation and patent practice, the computer-readable media Electric carrier signals and telecommunication signals are not included.

以上所述实施例仅用以说明本发明的技术方案,而非对其限制;尽管参照前述实施例对本发明进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本发明各实施例技术方案的精神和范围,均应包含在本发明的保护范围之内。The above-mentioned embodiments are only used to illustrate the technical solutions of the present invention, but not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: it can still be used for the foregoing implementations. The technical solutions described in the examples are modified, or some technical features thereof are equivalently replaced; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should be included in the within the protection scope of the present invention.

Claims (10)

Translated fromChinese
1.一种目标识别方法,其特征在于,包括:1. a target recognition method, is characterized in that, comprises:通过第一神经网络模型对目标图像进行检测,获得所述目标图像中的目标物体和所述目标物体的第一分类标签;Detecting the target image by using the first neural network model to obtain the target object in the target image and the first classification label of the target object;通过第二神经网络模型对所述目标物体进行分类,获得所述目标物体的第二分类标签;Classify the target object by using the second neural network model to obtain a second classification label of the target object;根据所述第一分类标签和所述第二分类标签,确定所述目标物体的类别。The category of the target object is determined according to the first classification label and the second classification label.2.根据权利要求1所述的目标识别方法,其特征在于,在将目标图像输入至第一神经网络模型进行目标检测之前,包括:2. The target recognition method according to claim 1, wherein before the target image is input to the first neural network model for target detection, the method comprises:构建包含M×M个元素的矩阵;其中,M≥2且为整数;Build a matrix containing M × M elements; where M ≥ 2 and an integer;在所述矩阵的每个元素中存储一类物体的类别信息;storing class information of a class of objects in each element of the matrix;建立所述矩阵的第i列中的各个元素与第i属性的第一分类标签之间的关联关系并存储;其中,1≤i≤M且i为整数;establishing and storing the association relationship between each element in the i-th column of the matrix and the first classification label of the i-th attribute; wherein, 1≤i≤M and i is an integer;建立所述矩阵的第i行中的各个元素与第i属性的第二分类标签之间的关联关系并存储。The association relationship between each element in the ith row of the matrix and the second classification label of the ith attribute is established and stored.3.根据权利要求2所述的目标识别方法,其特征在于,根据所述第一分类标签和所述第二分类标签,确定所述目标物体的类别,包括:3. The target recognition method according to claim 2, wherein determining the category of the target object according to the first classification label and the second classification label, comprising:根据所述第一分类标签,确定所述目标物体在所述矩阵中的列坐标;According to the first classification label, determine the column coordinates of the target object in the matrix;根据所述第二分类标签,确定所述目标物体在所述矩阵中的行坐标;According to the second classification label, determine the row coordinates of the target object in the matrix;根据所述行坐标和所述列坐标,确定所述目标物体在所述矩阵中的坐标;Determine the coordinates of the target object in the matrix according to the row coordinates and the column coordinates;根据所述目标物体在所述矩阵中的坐标,确定所述目标物体的类别。The category of the target object is determined according to the coordinates of the target object in the matrix.4.根据权利要求1至3任一项所述的目标识别方法,其特征在于,所述通过第一神经网络模型对目标图像进行检测,获得所述目标图像中的目标物体和所述目标物体的第一分类标签,包括:4. The target recognition method according to any one of claims 1 to 3, wherein the target image is detected by the first neural network model, and the target object and the target object in the target image are obtained. The first category labels of , including:通过第一神经网络模型对目标图像进行检测,在检测到所述目标图像中的目标物体时,获得所述目标物体在所述目标图像中的坐标和所述目标物体的第一分类标签。The target image is detected by the first neural network model, and when the target object in the target image is detected, the coordinates of the target object in the target image and the first classification label of the target object are obtained.5.根据权利要求4所述的目标识别方法,其特征在于,所述通过第二神经网络模型对所述目标物体进行分类,获得所述目标物体的第二分类标签之前,包括:5 . The target recognition method according to claim 4 , wherein the method for classifying the target object through the second neural network model and before obtaining the second classification label of the target object, comprising: 5 .根据所述目标物体在所述目标图像中的坐标,提取所述目标物体。The target object is extracted according to the coordinates of the target object in the target image.6.根据权利要求5所述的目标识别方法,其特征在于,所述根据所述目标物体在所述目标图像中的坐标,提取所述目标物体,包括:6. The target recognition method according to claim 5, wherein the extracting the target object according to the coordinates of the target object in the target image comprises:根据所述目标物体在所述目标图像中的坐标,确定对应的矩形框;Determine the corresponding rectangular frame according to the coordinates of the target object in the target image;根据所述矩形框在所述目标图像中的坐标,提取所述目标物体。The target object is extracted according to the coordinates of the rectangular frame in the target image.7.根据权利要求6所述的目标识别方法,其特征在于,在根据所述第一分类标签和所述第二分类标签,确定所述目标物体的类别之后,包括:7. The target recognition method according to claim 6, wherein after determining the category of the target object according to the first classification label and the second classification label, the method comprises:在所述目标图像中以预设方式显示所述矩形框以及所述目标物体的类别信息。The rectangular frame and the category information of the target object are displayed in a preset manner in the target image.8.一种目标识别装置,其特征在于,包括:8. A target identification device, characterized in that, comprising:第一获得模块,用于通过第一神经网络模型对目标图像进行检测,获得所述目标图像中的目标物体和所述目标物体的第一分类标签;a first obtaining module, configured to detect a target image through a first neural network model, and obtain a target object in the target image and a first classification label of the target object;第二获得模块,用于通过第二神经网络模型对所述目标物体进行分类,获得所述目标物体的第二分类标签;a second obtaining module, configured to classify the target object through a second neural network model to obtain a second classification label of the target object;确定模块,用于根据所述第一分类标签和所述第二分类标签,确定所述目标物体的类别。A determination module, configured to determine the category of the target object according to the first classification label and the second classification label.9.一种终端设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,其特征在于,所述处理器执行所述计算机程序时实现如权利要求1至7任一项所述的方法。9. A terminal device, comprising a memory, a processor and a computer program stored in the memory and running on the processor, wherein the processor implements the computer program as claimed in the claims when executing the computer program The method of any one of 1 to 7.10.一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现如权利要求1至7任一项所述的方法。10 . A computer-readable storage medium storing a computer program, wherein the computer program implements the method according to any one of claims 1 to 7 when the computer program is executed by a processor. 11 .
CN202010797205.2A2020-08-102020-08-10Target identification method, device, terminal equipment and storage mediumActiveCN112085063B (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN202010797205.2ACN112085063B (en)2020-08-102020-08-10Target identification method, device, terminal equipment and storage medium

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN202010797205.2ACN112085063B (en)2020-08-102020-08-10Target identification method, device, terminal equipment and storage medium

Publications (2)

Publication NumberPublication Date
CN112085063Atrue CN112085063A (en)2020-12-15
CN112085063B CN112085063B (en)2023-10-13

Family

ID=73736046

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN202010797205.2AActiveCN112085063B (en)2020-08-102020-08-10Target identification method, device, terminal equipment and storage medium

Country Status (1)

CountryLink
CN (1)CN112085063B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN113657329A (en)*2021-08-242021-11-16西安天和防务技术股份有限公司Target classification identification method and device and terminal equipment
CN116858831A (en)*2023-07-032023-10-10广东省农业科学院农业经济与信息研究所Lucid ganoderma detection and identification method and device

Citations (8)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN106875424A (en)*2017-01-162017-06-20西北工业大学A kind of urban environment driving vehicle Activity recognition method based on machine vision
CN108776819A (en)*2018-06-052018-11-09Oppo广东移动通信有限公司Target identification method, mobile terminal and computer readable storage medium
CN109344884A (en)*2018-09-142019-02-15腾讯科技(深圳)有限公司 Media information classification method, method and device for training picture classification model
CN109766822A (en)*2019-01-072019-05-17山东大学 Gesture recognition method and system based on neural network
CN110427802A (en)*2019-06-182019-11-08平安科技(深圳)有限公司AU detection method, device, electronic equipment and storage medium
WO2020119527A1 (en)*2018-12-112020-06-18中国科学院深圳先进技术研究院Human action recognition method and apparatus, and terminal device and storage medium
CN111310775A (en)*2018-12-112020-06-19Tcl集团股份有限公司Data training method and device, terminal equipment and computer readable storage medium
CN111399638A (en)*2020-02-292020-07-10浙江工业大学Blind computer and intelligent mobile phone auxiliary control method adapted to same

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN106875424A (en)*2017-01-162017-06-20西北工业大学A kind of urban environment driving vehicle Activity recognition method based on machine vision
CN108776819A (en)*2018-06-052018-11-09Oppo广东移动通信有限公司Target identification method, mobile terminal and computer readable storage medium
CN109344884A (en)*2018-09-142019-02-15腾讯科技(深圳)有限公司 Media information classification method, method and device for training picture classification model
WO2020119527A1 (en)*2018-12-112020-06-18中国科学院深圳先进技术研究院Human action recognition method and apparatus, and terminal device and storage medium
CN111310775A (en)*2018-12-112020-06-19Tcl集团股份有限公司Data training method and device, terminal equipment and computer readable storage medium
CN109766822A (en)*2019-01-072019-05-17山东大学 Gesture recognition method and system based on neural network
CN110427802A (en)*2019-06-182019-11-08平安科技(深圳)有限公司AU detection method, device, electronic equipment and storage medium
CN111399638A (en)*2020-02-292020-07-10浙江工业大学Blind computer and intelligent mobile phone auxiliary control method adapted to same

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
李良福 等: "基于深度学习的桥梁裂缝检测算法研究", 《自动化学报》, vol. 45, no. 9, pages 1727 - 1742*

Cited By (2)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN113657329A (en)*2021-08-242021-11-16西安天和防务技术股份有限公司Target classification identification method and device and terminal equipment
CN116858831A (en)*2023-07-032023-10-10广东省农业科学院农业经济与信息研究所Lucid ganoderma detection and identification method and device

Also Published As

Publication numberPublication date
CN112085063B (en)2023-10-13

Similar Documents

PublicationPublication DateTitle
EP3564854B1 (en)Facial expression recognition method, apparatus, electronic device, and storage medium
CN111860398B (en) Remote sensing image target detection method, system and terminal device
CN110197146B (en)Face image analysis method based on deep learning, electronic device and storage medium
CN112084856A (en)Face posture detection method and device, terminal equipment and storage medium
CN112997190B (en) License plate recognition method, device and electronic equipment
WO2018205467A1 (en)Automobile damage part recognition method, system and electronic device and storage medium
CN111080660A (en)Image segmentation method and device, terminal equipment and storage medium
CN111191582A (en)Three-dimensional target detection method, detection device, terminal device and computer-readable storage medium
WO2022082999A1 (en)Object recognition method and apparatus, and terminal device and storage medium
CN112488054B (en) A face recognition method, device, terminal equipment and storage medium
CN112085701A (en)Face ambiguity detection method and device, terminal equipment and storage medium
CN110852311A (en)Three-dimensional human hand key point positioning method and device
CN111476225B (en)In-vehicle human face identification method, device, equipment and medium based on artificial intelligence
CN113139490B (en)Image feature matching method and device, computer equipment and storage medium
CN112037256A (en)Target tracking method and device, terminal equipment and computer readable storage medium
CN114926540A (en)Lane line calibration method and device, terminal equipment and readable storage medium
CN113378837A (en)License plate shielding identification method and device, electronic equipment and storage medium
CN112085063A (en) A target identification method, device, terminal device and storage medium
CN115512105A (en)Anti-attack sample generation method and device and terminal equipment
WO2023109086A1 (en)Character recognition method, apparatus and device, and storage medium
CN113705643A (en)Target detection method and device and electronic equipment
CN117710765A (en) Target recognition method, device, electronic equipment and computer-readable storage medium
CN111309850A (en) A data feature extraction method, device, terminal device and medium
US20230386244A1 (en)Person re-identification method, computer-readable storage medium, and terminal device
CN112967187B (en)Method and apparatus for target detection

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination
GR01Patent grant
GR01Patent grant
TR01Transfer of patent right

Effective date of registration:20231210

Address after:Room 601, 6th Floor, Building 13, No. 3 Jinghai Fifth Road, Beijing Economic and Technological Development Zone (Tongzhou), Tongzhou District, Beijing, 100176

Patentee after:Beijing Youbixuan Intelligent Robot Co.,Ltd.

Address before:518000 16th and 22nd Floors, C1 Building, Nanshan Zhiyuan, 1001 Xueyuan Avenue, Nanshan District, Shenzhen City, Guangdong Province

Patentee before:Shenzhen UBTECH Technology Co.,Ltd.

TR01Transfer of patent right

[8]ページ先頭

©2009-2025 Movatter.jp