WO2022222822A1 - Method and device for identifying and positioning abelmoschus manihot on basis of cameras placed in non-parallel manner - Google Patents

Method and device for identifying and positioning abelmoschus manihot on basis of cameras placed in non-parallel manner Download PDF

Info

Publication number
WO2022222822A1
WO2022222822A1 PCT/CN2022/086576 CN2022086576W WO2022222822A1 WO 2022222822 A1 WO2022222822 A1 WO 2022222822A1 CN 2022086576 W CN2022086576 W CN 2022086576W WO 2022222822 A1 WO2022222822 A1 WO 2022222822A1
Authority
WO
WIPO (PCT)
Prior art keywords
cameras
flower
rotating platform
edge
pixel
Prior art date
Application number
PCT/CN2022/086576
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 WO2022222822A1 publication Critical patent/WO2022222822A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/40Extraction of image or video features
    • G06V10/56Extraction of image or video features relating to colour
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/60Analysis of geometric attributes
    • G06T7/62Analysis of geometric attributes of area, perimeter, diameter or volume
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/10Image acquisition
    • G06V10/12Details of acquisition arrangements; Constructional details thereof
    • G06V10/14Optical characteristics of the device performing the acquisition or on the illumination arrangements
    • G06V10/147Details of sensors, e.g. sensor lenses
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/40Extraction of image or video features
    • G06V10/44Local feature extraction by analysis of parts of the pattern, e.g. by detecting edges, contours, loops, corners, strokes or intersections; Connectivity analysis, e.g. of connected components

Definitions

  • the invention provides a low-cost target identification method and equipment for hollyhocks based on orthogonally placed cameras, belonging to the field of agriculture.
  • Yellow Hollyhock [Abelmoschus manihot (L.) Medic.] is an annual or perennial erect herb of the Malvaceae family. Due to various factors such as blind excavation and deterioration of the ecological environment, the wild resources of hollyhocks in my country were on the verge of extinction in the 1980s. At present, the artificial cultivation of hollyhock is mainly distributed in Jiangsu, Anhui, Shandong, Hainan, Guangxi and other regions. The whole body of yellow hollyhock is a treasure.
  • the leaves, tender pods and flowers of yellow hollyhock are rich in various vitamins and nutrients such as iron, calcium, crude protein, etc., which can prevent hardening of arteries, hair loss, prolong puberty, and enhance visceral function.
  • the seed oil yield is 25% to 32%, and the extracted oil is clear and light yellow with strong antioxidant properties. It is a new type of edible oil crop. As a medicinal material, hollyhocks have been included in the "Chinese Pharmacopoeia".
  • Patent CN 103279762 B provides a natural environment. A method for judging common growth patterns of fruits.
  • Patent CN 101828469 B provides a binocular visual information acquisition device for a cucumber picking robot, which uses two cameras placed in parallel to perform binocular recognition, and obtains two sets of images with similar contents but with slight differences in shooting angles.
  • target position information including depth information (ie, the distance information of the target from the position of the camera).
  • depth information ie, the distance information of the target from the position of the camera.
  • the depth information of the target can only be obtained through coordinate transformation through the pixel difference of the obtained image.
  • this solution requires high processing power of the computer and is susceptible to interference.
  • the problem is that the hardware cost increases, which is not conducive to low-cost large-scale promotion.
  • Patent CN111723863A discloses a method, device, computer equipment and storage medium for identifying and obtaining the position of fruit tree flowers.
  • the method inputs the partial image of the flower cluster into the flower detection model to obtain the flower types and types of all flowers in the partial image of the flower cluster.
  • the flower detection model is trained according to the flower cluster local sample image and the flower position label and flower type label in the flower cluster local sample image. This method is used to automatically identify the type and position of flowers in fruit trees to guide the robot's subsequent flower thinning operations.
  • the present invention provides a low-cost target recognition device and target recognition method based on non-parallel placement cameras, using the device and method to form a hardware solution at the lowest cost possible, while achieving detection High-precision localization of targets such as hollyhock flowers.
  • the present invention first provides a method for identifying and locating the maturity of the hollyhock flower based on non-parallel placement of cameras, comprising the following steps:
  • Step S10 two non-parallel cameras shoot plants from different directions, extract all pixel points with yellow color image peak characteristics in the picture, and form a color block to be determined, and the colors in the two cameras reach the set threshold.
  • the color blocks are marked as flowers;
  • Step S20 After binarizing each image marked as a flower, edge extraction is performed, and after obtaining a closed edge, the area of the closed figure enclosed by the edge is calculated, and a closed figure with a suitable area is selected and its respective geometric center points are obtained. coordinates, and then calculate the variance of the distance from each pixel on the edge of the closed graph to its geometric center point;
  • step S30 Determine the shape of the flower according to the variance. If the variance meets the set value, mark it as a mature flower and go to step S40; if the variance does not meet the set value, adjust the angles of the two non-parallel cameras to shoot from other different directions. For the plant, repeat the operations of step S10 and subsequent steps until the camera rotates once, and after one rotation, the flower shape is still not successfully determined to meet the standard, so the subsequent operations on the flower are abandoned;
  • the non-parallel placement is that the angle between the two cameras is greater than 15 degrees, more preferably greater than 45 degrees, and even more preferably orthogonal.
  • one of the two cameras is preferably located above the detected hollyhock plant.
  • the method for determining that the yellow color reaches the threshold is: extracting the information of the red channel and the green channel of each pixel of the color camera, and when the values output by the two channels are greater than the respective set thresholds at the same time, determine the Pixels are yellow.
  • the edge extraction method is as follows: the pixels marked in the step S10 are set to black, and the unmarked pixels are set to white. When there are 8 pixels around a black pixel When a white pixel or a black pixel is at the edge of the image, the black pixel is marked as an edge. When the above operations are performed on each pixel of the image, a closed figure surrounded by several closed edges will be obtained.
  • the closed graphics with a suitable screening area are closed graphics whose area is greater than or equal to a preset threshold after excluding closed graphics with too small area and closed graphics at the edge of the image.
  • step S30 when the shape of the flower is determined according to the variance, if the variance is small, it means that the flower is close to a circle, and the flower shape seen from this angle is qualified and can be picked; if the variance is large, it means that the shape does not meet the standard. , there will be the following situations: a. The flowers are not fully blooming, growing in strips, and can not meet the picking standards, you can give up picking; b. The shooting angle is wrong, it is horn-shaped, and the picking angle is not reached, you can further rotate the camera to shoot Handling; c. The working environment is complex, and several flowers grow together, which is inconvenient to carry out the positioning and picking operation.
  • the X-Y plane refers to a plane parallel to the ground
  • the Z axis refers to an axis orthogonal to the X-Y plane
  • Another aspect of the present invention provides a method for identifying and locating the color and shape of a target based on non-parallel cameras, comprising the following steps:
  • step S1 the two cameras placed in non-parallel photograph the detected objects from different directions, and the pixel positions of the color image in the picture with the target peak characteristic are extracted to form the color blocks to be determined. Color blocks are marked as preliminary targets;
  • Step S2 After binarizing the image of each marked preliminary target, perform edge extraction, after obtaining a closed edge, calculate the area of the closed figure enclosed by the edge, select a closed figure with a suitable area, and obtain its respective geometry. The coordinates of the center point, and then calculate the variance of the distance from each pixel point on the edge of the closed graph to its geometric center point;
  • Step S3 determine whether the shape of the preliminary target meets the standard according to the size of the variance. If the variance meets the set value, mark it as the target and go to step S40; if the variance does not meet the set value, adjust the angles of the two non-parallel cameras. Shoot the detected object from other different directions, and repeat the operations of step S10 and the subsequent steps until the camera rotates once, and after one rotation, if it is still not successfully determined as the target object, then give up the follow-up operation on the detected object;
  • Step S4 using the X-Y plane position and the X-Z plane position provided by the two cameras to jointly analyze the position of the target.
  • the non-parallel placement is that the angle between the two cameras is greater than 15 degrees, more preferably greater than 45 degrees, and even more preferably orthogonal.
  • one of the two cameras is preferably located above the detected object.
  • the method for judging that the selected color reaches the threshold is: extracting the information of two specified color channels of each pixel of the color camera, when the output values of the two channels are greater than the respective set thresholds at the same time , determine that the pixel is the selected color.
  • the detection object and the target object have different colors, especially contrasting colors, such as red and green, yellow and green, white and other colors, etc., preferably the target object is located in the detection object.
  • the detection object be a cone or a cone-shaped upper tip and a lower large;
  • the preferred detection object is a plant strain, more preferably a Malvaceae plant strain, especially a hollyhock plant strain;
  • the target object is further preferably a brocade
  • the plant flower or fruit of the family Auraceae is more preferably a hollyhock flower.
  • the edge extraction method is: set the marked pixels in step S1 as black, and set the unmarked pixels as white, when there are 8 pixels around a black pixel
  • the black pixel is marked as an edge.
  • the closed graphics with suitable screening area are closed graphics whose area is greater than or equal to the preset threshold after eliminating closed graphics with too small area and closed graphics at the edge of the image.
  • the X-Y plane refers to a plane parallel to the ground
  • the Z axis refers to an axis orthogonal to the X-Y plane
  • the position of the target object and the camera can be positioned by analyzing the position.
  • Another aspect of the present invention provides a target object recognition and positioning device based on non-parallel placement cameras, comprising a frame (1) fixed on a mobile carrier and a rotating platform (2); on the rotating platform (2) Two non-parallel cameras are fixed; the frame (1) and the rotating platform (2) are connected by a motor assembly (5) with a position encoder, and the rotating platform (2) can be mounted on the frame (1) turn up.
  • the non-parallel placement is that the angle between the two cameras is greater than 15 degrees, more preferably greater than 45 degrees, and even more preferably orthogonal.
  • the rotating platform (2) is a gantry-type bracket or an inverted L-shape.
  • a Y-axis camera (3) and a Z-axis camera (4) are respectively fixed on two sides of the L-shaped rotating platform (2); with position coding
  • the motor assembly (5) of the machine is fixed on the inner side of the top edge of the frame (1). 2) Turn.
  • the invention also provides a device for detecting the maturity and positioning of hollyhocks based on non-parallel cameras, comprising a frame (1) fixed on a mobile carrier and a rotating platform (2); Two non-parallel cameras are fixed; the frame (1) and the rotating platform (2) are connected by a motor assembly (5) with a position encoder, and the rotating platform (2) can be mounted on the frame (1) turn up.
  • the non-parallel placement is such that the angle between the two cameras is greater than 15 degrees, more preferably greater than 45 degrees, and even more preferably orthogonal.
  • the rotating platform (2) is a gantry-type bracket or an inverted L-shape.
  • a Y-axis camera (3) and a Z-axis camera (4) are respectively fixed on two sides of the L-shaped rotating platform (2); with position coding
  • the motor assembly (5) of the machine is fixed on the inner side of the top edge of the frame (1). 2) Turn.
  • the device provided by the present invention uses the non-parallel cameras to capture the image of the target object, calculates the three-dimensional coordinates of the target object through the two-dimensional spatial coordinates of the target object obtained by each of the two cameras, and uses the shape and color information of the target itself. As a basis for whether it needs to be processed, such as picking flowers.
  • the method provided by the invention can obtain the result by judging the pixel threshold value of the color image, extracting the edge after binarization, and calculating the variance of the target image, and the required calculation amount is extremely low, and even a low-resolution color camera can be combined with a single-chip microcomputer to obtain a result. Achieving the identification of targets such as hollyhock flowers greatly reduces the difficulty of program development and the cost of practical application.
  • the method provided by the invention can solve the problem of maturity detection and positioning of the flower position when automatically picking the flowers of hollyhock.
  • the spatial position and picking angle of the flowers of the hollyhock that can be picked are determined, and the flowers are provided to the picking machine.
  • the arm guides it to carry out automatic picking, which involves the field of agricultural robots and the field of image recognition, especially a method for judging the pre-picking maturity and spatial positioning of fruits and vegetables or economically valuable crop flowers through image recognition.
  • the application scenarios are not limited to this.
  • FIG. 1 is a schematic structural diagram of a low-cost target recognition device based on orthogonally placed cameras according to the present invention.
  • the X-Y plane refers to a plane parallel to the ground
  • the Z axis refers to an axis orthogonal to the X-Y plane.
  • a low-cost target recognition device based on orthogonally placed cameras includes a frame (1) fixed on a mobile carrier and a rotating platform (2); the rotating platform (2) is fixed with non-parallel placed Two cameras; the frame (1) and the rotating platform (2) are connected by a motor assembly (5) with a position encoder, and the rotating platform (2) can be rotated on the frame (1).
  • the low-cost target recognition device of the present invention based on the orthogonal placement of cameras is described below with a more specific example:
  • the frame (1) fixed on the mobile carrier (such as a crawler trolley) is connected to the L-shaped rotating platform (2) through the motor assembly (5), so that the rotating platform (2) can be wound around the motor assembly (5) the shaft rotates.
  • the Z-axis camera (4) is fixed on the inner side of the top edge of the rotating platform 2, and its shooting screen is parallel to the ground, and provides image information in the X-Y plane direction.
  • the Y-axis camera (3) is fixed on the inner side of the side of the rotating platform (2), and its shooting screen is perpendicular to the ground, providing image information in the direction of the X-Z plane.
  • the flowers of the hollyhock plant with picking value are yellow, which is significantly different from the green of the plant itself, and distributed in the outer part of the plant, it is not easy to be blocked by the branches and leaves of the plant, which provides an advantageous condition for the implementation of the present invention.
  • the motor assembly (2) fixed on the frame (1) is almost directly above the plants.
  • the Z-axis camera (4) shoots from the top to the bottom, and the Y-axis camera (3) shoots from the side, and extracts all the pixel points with the peak characteristic of the yellow RGB image in the picture to form the color block to be discriminated.
  • the motor assembly (5) drives the rotating platform (2) fixedly connected with the Z-axis camera (4) and the Y-axis camera (3) to rotate, so that the Y-axis camera (3) can monitor the flowers on the hollyhock plants from multiple angles. images are collected.
  • the color blocks whose color reaches the threshold are marked as flowers.
  • the edge is extracted, and the coordinates of the geometric center point of the edge are obtained.
  • the variance of the distance from each point of the edge to the geometric center point (which can be understood as the radius) is made. If the flower is more like a circle, the variance is small, which means that the flower pattern seen at this angle is qualified and can be picked. If the variance is large, it means:
  • the shooting angle is wrong, it is horn-shaped, and the picking angle is not reached. It is necessary to wait for the rotating platform to rotate to a suitable angle for identification and then pick it by the manipulator fixed on the rotating platform.
  • the three X-Y-Z coordinates of the current position of the flower that is judged to be able to be picked can be jointly solved by the X-Y plane position and the X-Z plane position provided by the two cameras.
  • the rotation of the rotating platform (2) is temporarily stopped, and the manipulator fixedly connected to it will pick flowers according to the X-Y-Z coordinates provided above.
  • the rotating platform (2) is the rotating platform of the gantry type support, and the top edge and bottom of the rotating platform (2) are respectively fixed to the Y-axis camera (3), and the inner wall of one side is fixed.
  • the motor assembly (5) with the position encoder is fixed on the inside of the top edge of the frame (1), and the rotating shaft of the motor assembly (5) is connected to the outside of the top edge of the rotating platform (2) for Drive the rotating platform (2) to rotate.

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Multimedia (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Health & Medical Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • Vascular Medicine (AREA)
  • Geometry (AREA)
  • Length Measuring Devices By Optical Means (AREA)
  • Image Analysis (AREA)

Abstract

Provided in the present invention is a method for identifying the maturity of Abelmoschus manihot and positioning Abelmoschus manihot on the basis of cameras placed in a non-parallel manner. The method comprises the following steps: two cameras placed in a non-parallel manner capturing a plant from different directions, and marking, as flowers, color blocks in the two cameras, the colors of the color blocks both reaching a preset threshold value; binarizing each image that is marked as a flower, and then performing edge extraction, and then calculating the variance of the distance from each pixel point of a sideline of a closed graph to the geometric center point of the closed graph; determining the shape of the flower according to the magnitude of the variance; and parsing the position of a mature flower. Further provided in the present invention is a device for identifying the maturity of Abelmoschus manihot and positioning and detecting Abelmoschus manihot on the basis of cameras placed in a non-parallel manner. By means of the method and the device of the present invention, cameras placed in a non-parallel manner are used to collect an image of a target crop, and the three-dimensional coordinates of a flower are resolved according to the spatial coordinates, which are respectively obtained by two cameras, of the flower in two dimensions. In addition, the morphology and color information of the flower itself are used as the basis for determining whether the flower needs to be treated.

Description

一种基于非平行放置摄像头的黄蜀葵花识别及定位方法和设备A method and device for identifying and locating hollyhocks based on non-parallel cameras 技术领域technical field
本发明提供了一种基于正交放置摄像头的黄蜀葵花低成本目标识别方法和设备,属于农业领域。The invention provides a low-cost target identification method and equipment for hollyhocks based on orthogonally placed cameras, belonging to the field of agriculture.
背景技术Background technique
黄蜀葵[Abelmoschus manihot(L.)Medic.]系锦葵科秋葵属一年生或多年生直立草本植物。由于盲目采挖及生态环境恶化等多方面的因素,我国黄蜀葵野生资源在上世纪80年代已濒临灭绝。目前,黄蜀葵的人工栽培主要分布在江苏、安徽、山东、海南、广西等地区。黄蜀葵全身都是宝,黄蜀葵的叶、嫩荚、花富含多种维生素及铁、钙、粗蛋白质等营养物质,具有防止血管硬化、毛发脱落、延长青春期、增强内脏功能等作用;黄蜀葵的种籽出油率25%~32%,榨出的油清亮浅黄,有很强的抗氧化性,是新型的食用油料作物;黄蜀葵花作为药材,已被收载入《中国药典》中。Yellow Hollyhock [Abelmoschus manihot (L.) Medic.] is an annual or perennial erect herb of the Malvaceae family. Due to various factors such as blind excavation and deterioration of the ecological environment, the wild resources of hollyhocks in my country were on the verge of extinction in the 1980s. At present, the artificial cultivation of hollyhock is mainly distributed in Jiangsu, Anhui, Shandong, Hainan, Guangxi and other regions. The whole body of yellow hollyhock is a treasure. The leaves, tender pods and flowers of yellow hollyhock are rich in various vitamins and nutrients such as iron, calcium, crude protein, etc., which can prevent hardening of arteries, hair loss, prolong puberty, and enhance visceral function. The seed oil yield is 25% to 32%, and the extracted oil is clear and light yellow with strong antioxidant properties. It is a new type of edible oil crop. As a medicinal material, hollyhocks have been included in the "Chinese Pharmacopoeia".
随着农业化大规模种植和工业化进程的推进,传统的采用人工采摘技术以远远不能满足现代农业的需求,机器人技术已开始运用于农业领域。然而,目前采收机器人主要应用于苹果、橘子等目标清晰的农作物上,这些作物为了保证运输后不损坏,采摘时往往不需要成熟时才采摘,例如专利CN 103279762 B提供了一种自然环境下果实常见生长形态判定方法,专利CN 101828469 B提供了黄瓜采摘机器人双目视觉信息获取装置,其采用平行放置的两个摄像头进行双目识别,在获得两组内容类似但是存在微小拍摄角度差异的图像后,对得到图像进行复杂处理,获得包括深度信息(即目标距离摄像头位置的远近信息)在内的目标位置信息。采用平行放置摄像头进行双目识别时,由于只能通过获得的图像的像素点差异在处理后进行坐标变换以获得目标的深度信息,为了达到较高的定位精度,需要提高摄像图像的分辨率并进行多次定位,这种方案对计算机的处理能力要求较高,且易受到干扰。带来的问题是硬件成本的提高,不利于低成本大规模推广。With the advancement of large-scale agricultural planting and industrialization, the traditional manual picking technology is far from meeting the needs of modern agriculture. Robot technology has begun to be used in the agricultural field. However, at present, harvesting robots are mainly used on crops with clear goals such as apples and oranges. In order to ensure that these crops are not damaged after transportation, they often do not need to be picked when they are mature. For example, the patent CN 103279762 B provides a natural environment. A method for judging common growth patterns of fruits. Patent CN 101828469 B provides a binocular visual information acquisition device for a cucumber picking robot, which uses two cameras placed in parallel to perform binocular recognition, and obtains two sets of images with similar contents but with slight differences in shooting angles. Then, complex processing is performed on the obtained image to obtain target position information including depth information (ie, the distance information of the target from the position of the camera). When using parallel cameras for binocular recognition, the depth information of the target can only be obtained through coordinate transformation through the pixel difference of the obtained image. In order to achieve higher positioning accuracy, it is necessary to improve the resolution of the camera image and Perform multiple positioning, this solution requires high processing power of the computer and is susceptible to interference. The problem is that the hardware cost increases, which is not conducive to low-cost large-scale promotion.
对于花朵来说,特别是作为药物的黄蜀葵花来说,成熟度会影响到其活性成分黄酮的含量,因此,采用机器人采摘黄蜀葵花时,其成熟度的判断尤为重要。专利CN111723863A公开了一种果树花朵的识别及位置获取方法、装置、计算机设备及存储介质,该方法将花簇的局部图像输入到花朵检测模型中得到花簇的局部图像中所有花朵 的花朵类型及对应的花朵位置,花朵检测模型是根据花簇局部样本图像和花簇局部样本图像中的花朵位置标注、花朵类型标注训练得到的。该方法用于自动识别果树中花朵的类型及位置,以指导机器人后续的疏花操作,涉及人工智能方向,需要前期采集大量图像进行模型训练,应用时对硬件要求较高。该方法采用AI识别的方式只能解决花朵的识别,但是对空间定位比较困难,且训练模型和执行识别对硬件需求较高,并且需要事先准备好大量训练数据。For flowers, especially for hollyhocks, which are used as medicines, the maturity will affect the content of flavonoids, the active ingredient. Therefore, when picking hollyhocks by robots, it is particularly important to judge their maturity. Patent CN111723863A discloses a method, device, computer equipment and storage medium for identifying and obtaining the position of fruit tree flowers. The method inputs the partial image of the flower cluster into the flower detection model to obtain the flower types and types of all flowers in the partial image of the flower cluster. Corresponding flower positions, the flower detection model is trained according to the flower cluster local sample image and the flower position label and flower type label in the flower cluster local sample image. This method is used to automatically identify the type and position of flowers in fruit trees to guide the robot's subsequent flower thinning operations. It involves artificial intelligence and requires a large number of images to be collected in the early stage for model training. The application requires high hardware. This method can only solve the recognition of flowers by using AI recognition, but it is difficult to locate the space, and the training model and the execution of recognition have high hardware requirements, and a large amount of training data needs to be prepared in advance.
此外,现有技术中还有采用单摄像头加距离传感器的方式,属于非常早期的设想,距离传感器极易受到干扰从而丢失距离信息,并不能解决实际问题。In addition, there is also a method of using a single camera and a distance sensor in the prior art, which is a very early idea. The distance sensor is easily interfered and thus loses distance information, which cannot solve practical problems.
发明内容SUMMARY OF THE INVENTION
为了解决现有技术的缺陷,本发明提供了一种基于非平行放置摄像头的低成本目标识别设备和目标识别方法,利用该设备和方法以尽可能低廉的成本构成硬件解决方案,同时达到被检测目标如黄蜀葵花朵的高精度定位。In order to solve the defects of the prior art, the present invention provides a low-cost target recognition device and target recognition method based on non-parallel placement cameras, using the device and method to form a hardware solution at the lowest cost possible, while achieving detection High-precision localization of targets such as hollyhock flowers.
本发明首先提供一种基于非平行放置摄像头的黄蜀葵花的成熟度识别及定位方法,包括以下步骤:The present invention first provides a method for identifying and locating the maturity of the hollyhock flower based on non-parallel placement of cameras, comprising the following steps:
步骤S10,非平行放置的两个摄像头从不同方向拍摄植株,提取画面中所有具有黄色的彩色图像峰值特征的像素点位,组成待判别的色块,对两个摄像头中颜色均达到所设阈值的色块标记为花朵;Step S10, two non-parallel cameras shoot plants from different directions, extract all pixel points with yellow color image peak characteristics in the picture, and form a color block to be determined, and the colors in the two cameras reach the set threshold. The color blocks are marked as flowers;
步骤S20,对每一个被标记为花朵的图像二值化后进行边沿提取,得到闭合的边线后,计算边线围成的封闭图形面积,选择面积合适的封闭图形并分别求出其各自几何中心点的坐标,再对封闭图形边线每个像素点到其几何中心点的距离求方差;Step S20: After binarizing each image marked as a flower, edge extraction is performed, and after obtaining a closed edge, the area of the closed figure enclosed by the edge is calculated, and a closed figure with a suitable area is selected and its respective geometric center points are obtained. coordinates, and then calculate the variance of the distance from each pixel on the edge of the closed graph to its geometric center point;
S30、根据方差大小判定花朵形状,对于方差符合设置值的,标记为成熟花朵并转入步骤S40;对于方差不符合设置值的,可调整非平行放置的两个摄像头的角度从其他不同方向拍摄植株,重复执行步骤S10及之后的操作直至摄像头旋转一周,旋转一周后,仍未成功判定花朵形状达标,从而放弃对该花朵进行后续操作;S30. Determine the shape of the flower according to the variance. If the variance meets the set value, mark it as a mature flower and go to step S40; if the variance does not meet the set value, adjust the angles of the two non-parallel cameras to shoot from other different directions. For the plant, repeat the operations of step S10 and subsequent steps until the camera rotates once, and after one rotation, the flower shape is still not successfully determined to meet the standard, so the subsequent operations on the flower are abandoned;
S40、利用两个摄像头提供的X-Y平面位置以及X-Z平面位置共同解析出成熟花朵的位置。S40, using the X-Y plane position and the X-Z plane position provided by the two cameras to jointly analyze the position of the mature flower.
优选地,所述步骤S10中,所述的非平行放置的为两个摄像头夹角大于15度,进一步优选为大于45度,更进一步优选为正交放置。其中,两个摄像头中的一个优选为位于被检测的黄蜀葵植株上方。Preferably, in the step S10, the non-parallel placement is that the angle between the two cameras is greater than 15 degrees, more preferably greater than 45 degrees, and even more preferably orthogonal. Wherein, one of the two cameras is preferably located above the detected hollyhock plant.
优选地,所述步骤S10中,黄色颜色达到阈值的判定方法为:提取彩色摄像头每个像素点红色通道和绿色通道的信息,当两个通道输出的值同时大于各自设定阈值时,判定该像素点为黄色。Preferably, in the step S10, the method for determining that the yellow color reaches the threshold is: extracting the information of the red channel and the green channel of each pixel of the color camera, and when the values output by the two channels are greater than the respective set thresholds at the same time, determine the Pixels are yellow.
优选地,所述步骤S20中,边沿提取方法为:将步骤S10中被标记的像素点设为黑色,将未被标记的像素点设为白色,当一个黑色像素点周围8个像素点中有一个白色像素点或该黑色像素点处在图像边沿时,则该黑色像素点被标记为边线,当对图像每一个像素点执行以上操作后,会得到若干封闭边线围成的封闭图形。Preferably, in the step S20, the edge extraction method is as follows: the pixels marked in the step S10 are set to black, and the unmarked pixels are set to white. When there are 8 pixels around a black pixel When a white pixel or a black pixel is at the edge of the image, the black pixel is marked as an edge. When the above operations are performed on each pixel of the image, a closed figure surrounded by several closed edges will be obtained.
所述步骤S20中,所述筛选面积合适的封闭图形为剔除了面积过小的封闭图形和处在图像边沿的封闭图形之后,面积大于或等于预设阈值的封闭图形。In the step S20, the closed graphics with a suitable screening area are closed graphics whose area is greater than or equal to a preset threshold after excluding closed graphics with too small area and closed graphics at the edge of the image.
所述步骤S30中,根据方差大小判定花朵形状时,如方差较小,则表示花接近圆形,从这个角度看到的花型是合格可以采摘的;如方差较大,则表示形状不达标,会有如下几种情况:a.花没有完全盛开,成长条状,达不到采摘标准,可以放弃采摘;b.拍摄角度不对,成喇叭状,没有达到采摘角度,可以进一步旋转摄像头进行拍摄处理;c.工作环境复杂,若干朵花朵生长在一起,不便于执行定位采摘操作。In the step S30, when the shape of the flower is determined according to the variance, if the variance is small, it means that the flower is close to a circle, and the flower shape seen from this angle is qualified and can be picked; if the variance is large, it means that the shape does not meet the standard. , there will be the following situations: a. The flowers are not fully blooming, growing in strips, and can not meet the picking standards, you can give up picking; b. The shooting angle is wrong, it is horn-shaped, and the picking angle is not reached, you can further rotate the camera to shoot Handling; c. The working environment is complex, and several flowers grow together, which is inconvenient to carry out the positioning and picking operation.
所述步骤S40中,X-Y平面指的是与地面平行的平面,Z轴指的是与X-Y平面正交的轴,通过解析出该位置实现对成熟花朵的定位。In the step S40, the X-Y plane refers to a plane parallel to the ground, the Z axis refers to an axis orthogonal to the X-Y plane, and the positioning of the mature flower is realized by analyzing the position.
本发明另一个方面提供一种基于非平行放置摄像头的目标物的颜色与形状的识别及定位方法,包括以下步骤:Another aspect of the present invention provides a method for identifying and locating the color and shape of a target based on non-parallel cameras, comprising the following steps:
步骤S1,非平行放置的两个摄像头从不同方向拍摄检测物,提取画面中的彩色图像具有目标峰值特征的像素点位,组成待判别的色块,对两个摄像头中颜色达到所设阈值的色块标记为初步目标;In step S1, the two cameras placed in non-parallel photograph the detected objects from different directions, and the pixel positions of the color image in the picture with the target peak characteristic are extracted to form the color blocks to be determined. Color blocks are marked as preliminary targets;
步骤S2,对每一个被标记出的初步目标的图像二值化后进行边沿提取,得到闭合的边线后,计算边线围成的封闭图形面积,选择面积合适的封闭图形并分别求出其各自几何中心点的坐标,再对封闭图形边线每个像素点到其几何中心点的距离求方差;Step S2: After binarizing the image of each marked preliminary target, perform edge extraction, after obtaining a closed edge, calculate the area of the closed figure enclosed by the edge, select a closed figure with a suitable area, and obtain its respective geometry. The coordinates of the center point, and then calculate the variance of the distance from each pixel point on the edge of the closed graph to its geometric center point;
步骤S3,根据方差大小判定初步目标的形状是否达标,对于方差符合设置值的,标记为目标物并转入步骤S40;对于方差不符合设置值的,可调整非平行放置的两个摄像头的角度从其他不同方向拍检测物,重复执行步骤S10及之后的操作直至摄像头旋转一周,旋转一周后,如仍未能成功判定为目标物,则放弃对该检测物进行后续操作;Step S3, determine whether the shape of the preliminary target meets the standard according to the size of the variance. If the variance meets the set value, mark it as the target and go to step S40; if the variance does not meet the set value, adjust the angles of the two non-parallel cameras. Shoot the detected object from other different directions, and repeat the operations of step S10 and the subsequent steps until the camera rotates once, and after one rotation, if it is still not successfully determined as the target object, then give up the follow-up operation on the detected object;
步骤S4,利用两个摄像头提供的X-Y平面位置以及X-Z平面位置共同解析出目标 物的位置。Step S4, using the X-Y plane position and the X-Z plane position provided by the two cameras to jointly analyze the position of the target.
优选地,所述步骤S1中,所述的非平行放置的为两个摄像头夹角大于15度,进一步优选为大于45度,更进一步优选为正交放置。其中,两个摄像头中的一个优选为位于被检测的检测物的上方。Preferably, in the step S1, the non-parallel placement is that the angle between the two cameras is greater than 15 degrees, more preferably greater than 45 degrees, and even more preferably orthogonal. Wherein, one of the two cameras is preferably located above the detected object.
优选地,所述步骤S1中,选定颜色达到阈值的判定方法为:提取彩色摄像头每个像素点的两种指定的颜色通道的信息,当两个通道输出的值同时大于各自设定阈值时,判定该像素点为选定颜色。Preferably, in the step S1, the method for judging that the selected color reaches the threshold is: extracting the information of two specified color channels of each pixel of the color camera, when the output values of the two channels are greater than the respective set thresholds at the same time , determine that the pixel is the selected color.
优选地,所述步骤S1中,所述的检测物与目标物具有不同颜色,特别是对比鲜明的颜色,例如红与绿、黄与绿、白色与其他颜色等,优选目标物位于检测物的外侧,进一步优选检测物为锥形或整体上类似锥形的上尖下大;优选检测物为植物株,进一步优选为锦葵科植物株特别是黄蜀葵植物株;所述目标物进一步优选为锦葵科的植物花或果实,进一步优选为黄蜀葵花。Preferably, in the step S1, the detection object and the target object have different colors, especially contrasting colors, such as red and green, yellow and green, white and other colors, etc., preferably the target object is located in the detection object. On the outside, it is further preferred that the detection object be a cone or a cone-shaped upper tip and a lower large; the preferred detection object is a plant strain, more preferably a Malvaceae plant strain, especially a hollyhock plant strain; the target object is further preferably a brocade The plant flower or fruit of the family Auraceae is more preferably a hollyhock flower.
优选地,所述步骤S2中,边沿提取方法为:将步骤S1中被标记的像素点设为黑色,将未被标记的像素点设为白色,当一个黑色像素点周围8个像素点中有一个白色像素点或该黑色像素点处在图像边沿时,则该黑色像素点被标记为边线,当对图像每一个像素点执行以上操作后,会得到若干封闭边线围成的封闭图形。Preferably, in the step S2, the edge extraction method is: set the marked pixels in step S1 as black, and set the unmarked pixels as white, when there are 8 pixels around a black pixel When a white pixel or a black pixel is at the edge of the image, the black pixel is marked as an edge. When the above operations are performed on each pixel of the image, a closed figure surrounded by several closed edges will be obtained.
所述步骤S2中,所述筛选面积合适的封闭图形为剔除了面积过小的封闭图形和处在图像边沿的封闭图形之后,面积大于或等于预设阈值的封闭图形。In the step S2, the closed graphics with suitable screening area are closed graphics whose area is greater than or equal to the preset threshold after eliminating closed graphics with too small area and closed graphics at the edge of the image.
所述步骤S3中,X-Y平面指的是与地面平行的平面,Z轴指的是与X-Y平面正交的轴,通过解析出该位置实现对目标物与摄像头位置的定位。In the step S3, the X-Y plane refers to a plane parallel to the ground, the Z axis refers to an axis orthogonal to the X-Y plane, and the position of the target object and the camera can be positioned by analyzing the position.
本发明再一方面提供了一种基于非平行放置摄像头的目标物识别及定位设备,包括固定在移动载具上的机架(1)、转动平台(2);所述转动平台(2)上固定有非平行放置的两个摄像头;所述机架(1)、转动平台(2)通过带位置编码器的电机总成(5)连接,且转动平台(2)可在机架(1)上转动。Another aspect of the present invention provides a target object recognition and positioning device based on non-parallel placement cameras, comprising a frame (1) fixed on a mobile carrier and a rotating platform (2); on the rotating platform (2) Two non-parallel cameras are fixed; the frame (1) and the rotating platform (2) are connected by a motor assembly (5) with a position encoder, and the rotating platform (2) can be mounted on the frame (1) turn up.
优选地,所述目标物识别及定位设备中,所述的非平行放置为两个摄像头夹角大于15度,进一步优选为大于45度,更进一步优选为正交放置。Preferably, in the target object recognition and positioning device, the non-parallel placement is that the angle between the two cameras is greater than 15 degrees, more preferably greater than 45 degrees, and even more preferably orthogonal.
优选地,所述目标物识别及定位设备中,所述转动平台(2)为龙门式支架或倒置的L形。当所述转动平台(2)为倒置的L形时,所述L形的转动平台(2)的两个边上分别固定有Y轴摄像头(3)和Z轴摄像头(4);带位置编码器的电机总成(5)固定于 机架(1)顶边内侧,电机总成(5)的转轴与倒置的L形的转动平台(2)顶边外侧的连接,用于驱动转动平台(2)转动。Preferably, in the target object identification and positioning device, the rotating platform (2) is a gantry-type bracket or an inverted L-shape. When the rotating platform (2) is in an inverted L shape, a Y-axis camera (3) and a Z-axis camera (4) are respectively fixed on two sides of the L-shaped rotating platform (2); with position coding The motor assembly (5) of the machine is fixed on the inner side of the top edge of the frame (1). 2) Turn.
本发明还提供了一种基于非平行放置摄像头的黄蜀葵花成熟度及定位检测设备,包括固定在移动载具上的机架(1)、转动平台(2);所述转动平台(2)上固定有非平行放置的两个摄像头;所述机架(1)、转动平台(2)通过带位置编码器的电机总成(5)连接,且转动平台(2)可在机架(1)上转动。The invention also provides a device for detecting the maturity and positioning of hollyhocks based on non-parallel cameras, comprising a frame (1) fixed on a mobile carrier and a rotating platform (2); Two non-parallel cameras are fixed; the frame (1) and the rotating platform (2) are connected by a motor assembly (5) with a position encoder, and the rotating platform (2) can be mounted on the frame (1) turn up.
优选地,所述黄蜀葵花成熟度及定位检测设备中,所述非平行放置为两个摄像头夹角大于15度,进一步优选为大于45度,更进一步优选为正交放置。Preferably, in the hollyhock flower maturity and positioning detection device, the non-parallel placement is such that the angle between the two cameras is greater than 15 degrees, more preferably greater than 45 degrees, and even more preferably orthogonal.
优选地,所述黄蜀葵花成熟度及定位检测设备中,所述转动平台(2)为龙门式支架或倒置的L形。当所述转动平台(2)为倒置的L形时,所述L形的转动平台(2)的两个边上分别固定有Y轴摄像头(3)和Z轴摄像头(4);带位置编码器的电机总成(5)固定于机架(1)顶边内侧,电机总成(5)的转轴与倒置的L形的转动平台(2)顶边外侧的连接,用于驱动转动平台(2)转动。Preferably, in the hollyhock flower maturity and positioning detection equipment, the rotating platform (2) is a gantry-type bracket or an inverted L-shape. When the rotating platform (2) is in an inverted L shape, a Y-axis camera (3) and a Z-axis camera (4) are respectively fixed on two sides of the L-shaped rotating platform (2); with position coding The motor assembly (5) of the machine is fixed on the inner side of the top edge of the frame (1). 2) Turn.
本发明提供的设备利用非平行放置的摄像头对目标物的图像采集,通过两个摄像头各获得的两个维度的目标物空间坐标,解算出其三维坐标,同时利用该目标本身的形态、颜色信息作为其是否需要进行处理如对鲜花进行采摘的依据。The device provided by the present invention uses the non-parallel cameras to capture the image of the target object, calculates the three-dimensional coordinates of the target object through the two-dimensional spatial coordinates of the target object obtained by each of the two cameras, and uses the shape and color information of the target itself. As a basis for whether it needs to be processed, such as picking flowers.
本发明提供的方法对目标图像进行彩色图像像素阈值判断、二值化后边沿提取、方差计算即可得到结果,所需要的运算量极低,甚至可以将低分辨率彩色摄像头配合单片机进行组合从而实现目标物如黄蜀葵花的识别,极大的降低了方案开发难度以及实际应用成本。The method provided by the invention can obtain the result by judging the pixel threshold value of the color image, extracting the edge after binarization, and calculating the variance of the target image, and the required calculation amount is extremely low, and even a low-resolution color camera can be combined with a single-chip microcomputer to obtain a result. Achieving the identification of targets such as hollyhock flowers greatly reduces the difficulty of program development and the cost of practical application.
本发明提供的方法是可以解决自动化采摘黄蜀葵花朵时花朵位置的成熟度检测和定位问题,通过对植株上花朵进行一定的筛选,确定可以采摘的黄蜀葵花朵空间位置和采摘角度,并提供给采摘机械臂指引其进行自动化采摘,涉及农业机器人领域以及图像识别领域,特别是涉及一种通过图像识别进行果蔬或有经济价值的农作物花朵的采摘前成熟度的判定和空间定位的方法,但所取得成果的应用场景不限制于此。The method provided by the invention can solve the problem of maturity detection and positioning of the flower position when automatically picking the flowers of hollyhock. By screening the flowers on the plant to a certain extent, the spatial position and picking angle of the flowers of the hollyhock that can be picked are determined, and the flowers are provided to the picking machine. The arm guides it to carry out automatic picking, which involves the field of agricultural robots and the field of image recognition, especially a method for judging the pre-picking maturity and spatial positioning of fruits and vegetables or economically valuable crop flowers through image recognition. The application scenarios are not limited to this.
附图说明Description of drawings
图1为本发明基于正交放置摄像头的低成本目标识别设备的结构示意图。FIG. 1 is a schematic structural diagram of a low-cost target recognition device based on orthogonally placed cameras according to the present invention.
具体实施方式Detailed ways
下面对本发明作出进一步说明,本发明中,X-Y平面指的是与地面平行的平面,Z 轴指的是与X-Y平面正交的轴。The present invention will be further described below. In the present invention, the X-Y plane refers to a plane parallel to the ground, and the Z axis refers to an axis orthogonal to the X-Y plane.
实施例1Example 1
基于正交放置摄像头的低成本目标识别设备,见图1,包括固定在移动载具上的机架(1)、转动平台(2);所述转动平台(2)上固定有非平行放置的两个摄像头;所述机架(1)、转动平台(2)通过带位置编码器的电机总成(5)连接,且转动平台(2)可在机架(1)上转动。A low-cost target recognition device based on orthogonally placed cameras, as shown in Figure 1, includes a frame (1) fixed on a mobile carrier and a rotating platform (2); the rotating platform (2) is fixed with non-parallel placed Two cameras; the frame (1) and the rotating platform (2) are connected by a motor assembly (5) with a position encoder, and the rotating platform (2) can be rotated on the frame (1).
下面以一个更具体的实例来说明本发明基于正交放置摄像头的低成本目标识别设备:The low-cost target recognition device of the present invention based on the orthogonal placement of cameras is described below with a more specific example:
见图1,固定于移动载具(例如履带小车)上的机架(1),通过电机总成(5)连接L形状的转动平台(2),使得转动平台(2)可以绕电机总成(5)的轴转动。Z轴摄像头(4)固定在转动平台2的顶边内侧,其拍摄画面与地面平行,提供X-Y平面方向的图像信息。Y轴摄像头(3)固定在转动平台(2)的侧边内侧,其拍摄画面与地面垂直,提供X-Z平面方向的图像信息。See Figure 1, the frame (1) fixed on the mobile carrier (such as a crawler trolley) is connected to the L-shaped rotating platform (2) through the motor assembly (5), so that the rotating platform (2) can be wound around the motor assembly (5) the shaft rotates. The Z-axis camera (4) is fixed on the inner side of the top edge of the rotating platform 2, and its shooting screen is parallel to the ground, and provides image information in the X-Y plane direction. The Y-axis camera (3) is fixed on the inner side of the side of the rotating platform (2), and its shooting screen is perpendicular to the ground, providing image information in the direction of the X-Z plane.
由于黄蜀葵植株具有采摘价值的花朵呈现黄色,与植株本身绿色有着显著的颜色上的区别,且分布在植株外侧部分,不易被植株枝叶遮挡,这为本发明的实施提供了优势条件。Since the flowers of the hollyhock plant with picking value are yellow, which is significantly different from the green of the plant itself, and distributed in the outer part of the plant, it is not easy to be blocked by the branches and leaves of the plant, which provides an advantageous condition for the implementation of the present invention.
采摘机器人载具按设计路线在植株旁停靠后,固定在机架(1)上的电机总成(2)几乎位于植株正上方。此时Z轴摄像头(4)从顶部向下方拍摄、Y轴摄像头(3)从侧面拍摄,提取画面中所有具有黄色RGB图像峰值特征的像素点位,组成待判别的色块。After the picking robot carrier stops beside the plants according to the designed route, the motor assembly (2) fixed on the frame (1) is almost directly above the plants. At this time, the Z-axis camera (4) shoots from the top to the bottom, and the Y-axis camera (3) shoots from the side, and extracts all the pixel points with the peak characteristic of the yellow RGB image in the picture to form the color block to be discriminated.
之后电机总成(5)带动固连着Z轴摄像头(4)和Y轴摄像头(3)的转动平台(2)进行旋转,使得Y轴摄像头(3)可以从多个角度对黄蜀葵植株上花朵的图像进行采集。Afterwards, the motor assembly (5) drives the rotating platform (2) fixedly connected with the Z-axis camera (4) and the Y-axis camera (3) to rotate, so that the Y-axis camera (3) can monitor the flowers on the hollyhock plants from multiple angles. images are collected.
转动的过程中,对颜色达到阈值的色块标记为花朵。同时对每一个被标记出的花朵图像二值化后进行边沿提取,求出边线几何中心点坐标。之后对边线每个点到几何中心点的距离(可以理解为半径)做方差,如果花更像圆形,则方差较小,意味着在这个角度看到的花型是合格的可以采摘的。如果方差较大,那么意味着:During the rotation, the color blocks whose color reaches the threshold are marked as flowers. At the same time, after binarizing each marked flower image, the edge is extracted, and the coordinates of the geometric center point of the edge are obtained. Afterwards, the variance of the distance from each point of the edge to the geometric center point (which can be understood as the radius) is made. If the flower is more like a circle, the variance is small, which means that the flower pattern seen at this angle is qualified and can be picked. If the variance is large, it means:
a.花没有完全盛开,成长条状,达不到采摘标准;a. The flowers are not in full bloom, grow in strips, and fail to meet the picking standards;
b.此时拍摄角度不对,成喇叭状,没有达到采摘角度,需等待转动平台转动至合适角度识别通过后再由固定在转动平台上的机械手进行采摘。b. At this time, the shooting angle is wrong, it is horn-shaped, and the picking angle is not reached. It is necessary to wait for the rotating platform to rotate to a suitable angle for identification and then pick it by the manipulator fixed on the rotating platform.
通过上述步骤,被判断为可以采摘的花朵在转动平台当前位置的三个X-Y-Z坐标可 由两个摄像头提供的X-Y平面位置以及X-Z平面位置共同解出。此时转动平台(2)暂时停止转动,由固连在其上的机械手根据上述提供的X-Y-Z坐标进行花朵的采摘。Through the above steps, the three X-Y-Z coordinates of the current position of the flower that is judged to be able to be picked can be jointly solved by the X-Y plane position and the X-Z plane position provided by the two cameras. At this time, the rotation of the rotating platform (2) is temporarily stopped, and the manipulator fixedly connected to it will pick flowers according to the X-Y-Z coordinates provided above.
实施例2Example 2
与实施例1基本相同,不同之处仅在于:转动平台(2)为龙门式支架的转动平台,转动平台(2)的顶边底部分别固定Y轴摄像头(3)、一个侧边的内壁固定Z轴摄像头(4);带位置编码器的电机总成(5)固定于机架(1)顶边内侧,电机总成(5)的转轴与转动平台(2)顶边外侧连接,用于驱动转动平台(2)转动。Basically the same as Embodiment 1, the difference is only that: the rotating platform (2) is the rotating platform of the gantry type support, and the top edge and bottom of the rotating platform (2) are respectively fixed to the Y-axis camera (3), and the inner wall of one side is fixed. Z-axis camera (4); the motor assembly (5) with the position encoder is fixed on the inside of the top edge of the frame (1), and the rotating shaft of the motor assembly (5) is connected to the outside of the top edge of the rotating platform (2) for Drive the rotating platform (2) to rotate.
以上所述实施例仅表达了本发明的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对发明专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本发明构思的前提下,还可以做出若干变形和改进,这些都属于本发明的保护范围。因此,本发明专利的保护范围应以所附权利要求为准。The above-mentioned embodiments only represent several embodiments of the present invention, and the descriptions thereof are specific and detailed, but should not be construed as a limitation on the scope of the invention patent. It should be pointed out that for those of ordinary skill in the art, without departing from the concept of the present invention, several modifications and improvements can also be made, which all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be subject to the appended claims.

Claims (12)

  1. 一种基于非平行放置摄像头的黄蜀葵花的成熟度识别及定位方法,其特征在于:包括以下步骤:A kind of maturity identification and positioning method based on the hollyhock flower of non-parallel placement camera, it is characterized in that: comprise the following steps:
    S10、非平行放置的两个摄像头从不同方向拍摄植株,提取画面中所有具有黄色的彩色图像峰值特征的像素点位,组成待判别的色块,对两个摄像头中颜色均达到所设阈值的色块标记为花朵;S10. Two non-parallel cameras shoot plants from different directions, extract all pixel positions with the peak characteristic of the yellow color image in the picture, and form a color block to be discriminated. Color blocks are marked as flowers;
    S20、对每一个被标记为花朵的图像二值化后进行边沿提取,得到闭合的边线后,计算边线围成的封闭图形面积,选择面积合适的封闭图形并分别求出其各自几何中心点的坐标,再对封闭图形边线每个像素点到其几何中心点的距离求方差;S20. After binarizing each image marked as a flower, perform edge extraction, and after obtaining a closed edge, calculate the area of the closed figure enclosed by the edge, select a closed figure with a suitable area, and obtain the distance between its respective geometric center points. coordinates, and then calculate the variance of the distance from each pixel point on the edge of the closed graph to its geometric center point;
    S30、根据方差大小判定花朵形状,对于方差符合设置值的,标记为成熟花朵并转入步骤S40;对于方差不符合设置值的,可调整非平行放置的两个摄像头的角度从其他不同方向拍摄植株,重复执行步骤S10及之后的操作直至摄像头旋转一周;S30. Determine the shape of the flower according to the variance. If the variance meets the set value, mark it as a mature flower and go to step S40; if the variance does not meet the set value, adjust the angles of the two non-parallel cameras to shoot from other different directions. Plants, repeat the operations of step S10 and subsequent steps until the camera rotates once;
    S40、利用两个摄像头提供的X-Y平面位置以及X-Z平面位置共同解析出成熟花朵的位置。S40, using the X-Y plane position and the X-Z plane position provided by the two cameras to jointly analyze the position of the mature flower.
  2. 根据权利要求1所述的方法,其特征在于:所述步骤S10中,黄色颜色达到阈值的判定方法为:提取彩色摄像头每个像素点红色通道和绿色通道的信息,当两个通道输出的值同时大于各自设定阈值时,判定该像素点为黄色。The method according to claim 1, wherein: in the step S10, the method for determining that the yellow color reaches the threshold value is: extracting the information of the red channel and the green channel of each pixel point of the color camera, and when the values output by the two channels are When it is greater than the respective set thresholds at the same time, it is determined that the pixel is yellow.
  3. 根据权利要求1所述的方法,其特征在于:所述步骤S20中,边沿提取方法为:将步骤S10中被标记的像素点设为黑色,将未被标记的像素点设为白色,当一个黑色像素点周围8个像素点中有一个白色像素点或该黑色像素点处在图像边沿时,则该黑色像素点被标记为边线,当对图像每一个像素点执行以上操作后,会得到若干封闭边线围成的封闭图形。The method according to claim 1, wherein: in the step S20, the edge extraction method is: set the pixel points marked in the step S10 as black, set the unmarked pixels as white, when one When there is a white pixel in the 8 pixels around the black pixel or the black pixel is at the edge of the image, the black pixel is marked as an edge. When the above operations are performed on each pixel of the image, a number of A closed figure enclosed by closed edges.
  4. 根据权利要求1所述的方法,其特征在于:所述的两个摄像头中的一个位于被检测的黄蜀葵植株上方。The method according to claim 1, wherein one of the two cameras is located above the detected hollyhock plant.
  5. 一种基于非平行放置摄像头的目标物的颜色与形状的识别及定位方法,其特征在于:包括以下步骤:A method for identifying and locating the color and shape of a target based on a non-parallel camera, comprising the following steps:
    S1、非平行放置的两个摄像头从不同方向拍摄检测物,提取画面中的彩色图像具有目标峰值特征的像素点位,组成待判别的色块,对两个摄像头中颜色达到所设阈值的色块标记为初步目标;S1. Two non-parallel cameras shoot the detection object from different directions, extract the pixel points of the color image in the picture with the target peak characteristic, and form the color block to be judged. Blocks are marked as preliminary goals;
    S2、对每一个被标记出的初步目标的图像二值化后进行边沿提取,得到闭合的边线 后,计算边线围成的封闭图形面积,选择面积合适的封闭图形并分别求出其各自几何中心点的坐标,再对封闭图形边线每个像素点到其几何中心点的距离求方差;S2. Perform edge extraction after binarizing the image of each marked preliminary target. After obtaining a closed edge, calculate the area of the closed figure enclosed by the edge, select a closed figure with a suitable area, and obtain its respective geometric center. The coordinates of the point, and then calculate the variance of the distance from each pixel point on the edge of the closed graph to its geometric center point;
    S3、根据方差大小判定初步目标的形状是否达标,对于方差符合设置值的,标记为目标物并转入步骤S40;对于方差不符合设置值的,可调整非平行放置的两个摄像头的角度从其他不同方向拍摄检测物,重复执行步骤S10及之后的操作直至摄像头旋转一周;S3. Determine whether the shape of the preliminary target meets the standard according to the size of the variance. If the variance meets the set value, mark it as the target and go to step S40; Shoot the detected object in other different directions, and repeat step S10 and subsequent operations until the camera rotates once;
    S4、利用两个摄像头提供的X-Y平面位置以及X-Z平面位置共同解析出目标物的位置。S4, using the X-Y plane position and the X-Z plane position provided by the two cameras to jointly analyze the position of the target.
  6. 一种基于非平行放置摄像头的目标物识别及定位设备,其特征在于:包括固定在移动载具上的机架(1)、转动平台(2);所述转动平台(2)上固定有非平行放置的两个摄像头;所述机架(1)、转动平台(2)通过带位置编码器的电机总成(5)连接,且转动平台(2)可在机架(1)上转动。A target object recognition and positioning device based on non-parallel placement cameras, characterized in that it comprises a frame (1) fixed on a mobile carrier, and a rotating platform (2); Two cameras placed in parallel; the frame (1) and the rotating platform (2) are connected by a motor assembly (5) with a position encoder, and the rotating platform (2) can be rotated on the frame (1).
  7. 根据权利要求6所述的设备,其特征在于:所述所述转动平台(2)为倒置的L形,所述L形的转动平台(2)的两个边上分别固定有Y轴摄像头(3)和Z轴摄像头(4);带位置编码器的电机总成(5)固定于机架(1)顶边内侧,电机总成(5)的转轴与倒置的L形的转动平台(2)顶边外侧的连接,用于驱动转动平台(2)转动。The device according to claim 6, characterized in that: the rotating platform (2) is an inverted L-shape, and a Y-axis camera ( 3) and the Z-axis camera (4); the motor assembly (5) with the position encoder is fixed on the inner side of the top edge of the frame (1), and the rotating shaft of the motor assembly (5) is connected to the inverted L-shaped rotating platform (2). ) on the outside of the top edge to drive the rotating platform (2) to rotate.
  8. 一种基于非平行放置摄像头的黄蜀葵花成熟度及定位检测设备,其特征在于:包括固定在移动载具上的机架(1)、转动平台(2);所述转动平台(2)上固定有非平行放置的两个摄像头;所述机架(1)、转动平台(2)通过带位置编码器的电机总成(5)连接,且转动平台(2)可在机架(1)上转动。A kind of hollyhock flower maturity and positioning detection equipment based on non-parallel placement camera, it is characterized in that: comprising a frame (1) fixed on a mobile carrier, a rotating platform (2); the rotating platform (2) is fixed on the There are two non-parallel cameras; the frame (1) and the rotating platform (2) are connected by a motor assembly (5) with a position encoder, and the rotating platform (2) can be mounted on the frame (1) turn.
  9. 根据权利要求8所述的设备,其特征在于:所述转动平台(2)为倒置的L形;所述L形的转动平台(2)的两个边上分别固定有Y轴摄像头(3)和Z轴摄像头(4);带位置编码器的电机总成(5)固定于机架(1)顶边内侧,电机总成(5)的转轴与倒置的L形的转动平台(2)顶边外侧的连接,用于驱动转动平台(2)转动。The device according to claim 8, characterized in that: the rotating platform (2) is an upside-down L-shaped; Y-axis cameras (3) are respectively fixed on two sides of the L-shaped rotating platform (2). and the Z-axis camera (4); the motor assembly (5) with the position encoder is fixed on the inner side of the top edge of the frame (1), and the rotating shaft of the motor assembly (5) is connected to the top of the inverted L-shaped rotating platform (2). The connection on the outside of the side is used to drive the rotating platform (2) to rotate.
  10. 权利要求1-9所述的非平行放置为两个摄像头夹角大于15度,进一步优选为大于45度,更进一步优选为正交放置。The non-parallel placement described in claims 1-9 is that the angle between the two cameras is greater than 15 degrees, more preferably greater than 45 degrees, and even more preferably orthogonal.
  11. 根据权利要求5所述的方法、权利要求6所述的设备,其特征在于:所述的检测物与目标物具有不同颜色,优选目标物位于检测物的外侧,进一步优选检测物为锥形或整体上呈现类锥形;优选检测物为植物株,进一步优选为锦葵科植物株特别是黄 蜀葵植物株;所述目标物进一步优选为锦葵科的植物花或果实,进一步优选为黄蜀葵花。The method according to claim 5 and the device according to claim 6, wherein the detection object and the target object have different colors, preferably the target object is located outside the detection object, and further preferably the detection object is a cone or The overall appearance is like a cone; the detection object is preferably a plant strain, more preferably a Malvaceae plant strain, especially a hollyhock plant strain; the target object is further preferably a Malvaceae plant flower or fruit, more preferably a hollyhock flower.
  12. 根据权利要求6或7所述的设备,其特征在于:所述转动平台(2)为龙门式支架或倒置的L形。The device according to claim 6 or 7, characterized in that: the rotating platform (2) is a gantry-type bracket or an inverted L-shape.
PCT/CN2022/086576 2021-04-21 2022-04-13 Method and device for identifying and positioning abelmoschus manihot on basis of cameras placed in non-parallel manner WO2022222822A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202110428210.0 2021-04-21
CN202110428210.0A CN112949660A (en) 2021-04-21 2021-04-21 Abelmoschus manihot flower recognition and positioning method and device based on non-parallel cameras

Publications (1)

Publication Number Publication Date
WO2022222822A1 true WO2022222822A1 (en) 2022-10-27

Family

ID=76233101

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/086576 WO2022222822A1 (en) 2021-04-21 2022-04-13 Method and device for identifying and positioning abelmoschus manihot on basis of cameras placed in non-parallel manner

Country Status (2)

Country Link
CN (1) CN112949660A (en)
WO (1) WO2022222822A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116616045A (en) * 2023-06-07 2023-08-22 山东农业工程学院 Picking method and picking system based on plant growth

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112949660A (en) * 2021-04-21 2021-06-11 桑一男 Abelmoschus manihot flower recognition and positioning method and device based on non-parallel cameras

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111723863A (en) * 2020-06-19 2020-09-29 中国农业科学院农业信息研究所 Fruit tree flower identification and position acquisition method and device, computer equipment and storage medium
CN111753577A (en) * 2019-03-28 2020-10-09 天津工业大学 Apple identification and positioning method in automatic picking robot
CN111758424A (en) * 2020-06-22 2020-10-13 华中农业大学 Automatic device of pinching of field cotton
US20210065350A1 (en) * 2019-09-04 2021-03-04 Triple Win Technology(Shenzhen) Co.Ltd. Computing device and non-transitory storage medium implementing target object identification method
CN112949660A (en) * 2021-04-21 2021-06-11 桑一男 Abelmoschus manihot flower recognition and positioning method and device based on non-parallel cameras

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111753577A (en) * 2019-03-28 2020-10-09 天津工业大学 Apple identification and positioning method in automatic picking robot
US20210065350A1 (en) * 2019-09-04 2021-03-04 Triple Win Technology(Shenzhen) Co.Ltd. Computing device and non-transitory storage medium implementing target object identification method
CN111723863A (en) * 2020-06-19 2020-09-29 中国农业科学院农业信息研究所 Fruit tree flower identification and position acquisition method and device, computer equipment and storage medium
CN111758424A (en) * 2020-06-22 2020-10-13 华中农业大学 Automatic device of pinching of field cotton
CN112949660A (en) * 2021-04-21 2021-06-11 桑一男 Abelmoschus manihot flower recognition and positioning method and device based on non-parallel cameras

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116616045A (en) * 2023-06-07 2023-08-22 山东农业工程学院 Picking method and picking system based on plant growth
CN116616045B (en) * 2023-06-07 2023-11-24 山东农业工程学院 Picking method and picking system based on plant growth

Also Published As

Publication number Publication date
CN112949660A (en) 2021-06-11

Similar Documents

Publication Publication Date Title
WO2022222822A1 (en) Method and device for identifying and positioning abelmoschus manihot on basis of cameras placed in non-parallel manner
Malik et al. Mature tomato fruit detection algorithm based on improved HSV and watershed algorithm
Longsheng et al. Kiwifruit recognition at nighttime using artificial lighting based on machine vision
CN201600330U (en) System for recognizing and locating mature pineapples
Oppenheim et al. Detecting tomato flowers in greenhouses using computer vision
CN114260895B (en) Method and system for determining grabbing obstacle avoidance direction of mechanical arm of picking robot
CN105719282B (en) A kind of orchard mcintosh image fruit branches and leaves area obtaining method
CN105631884A (en) Crops spike number field active measurement device and method
Rahul et al. Image processing based automatic plant disease detection and stem cutting robot
CN105850376A (en) Electronic and automatic pomegranate picking method
Ji et al. Research on key technology of truss tomato harvesting robot in greenhouse
CN115316129A (en) Self-adaptive bionic picking device based on binocular vision recognition and cluster fruit picking method
JP2007200309A (en) Position specification method and apparatus for plant target part, and working robot using the same apparatus
CN105230375A (en) Intelligent management system for yellow peach orchard
Jin et al. Far-near combined positioning of picking-point based on depth data features for horizontal-trellis cultivated grape
CN115937314B (en) Method for detecting growth posture of oil tea fruits
CN109886062A (en) A kind of camellia oleifera fruit flower identification positioning system
CN114937078A (en) Automatic weeding method, device and storage medium
Fujinaga Cutting point detection for strawberry fruit harvesting and truss pruning by agricultural robot
Zhang et al. Height information acquisition method of seedling with machine vision
CN114600641A (en) Strawberry picking machine based on image recognition technology and picking method thereof
Yihang et al. Automatic recognition of rape seeding emergence stage based on computer vision technology
Tarry et al. An integrated bud detection and localization system for application in greenhouse automation
Abhijith et al. Farm-copter: Computer vision based precision agriculture
Bhusal et al. Trellis wire detection for obstacle avoidance in apple orchards

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: 22790930

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: 22790930

Country of ref document: EP

Kind code of ref document: A1