[go: up one dir, main page]

CN115218827B - Method, device, equipment and storage medium for measuring angle between booms - Google Patents

Method, device, equipment and storage medium for measuring angle between booms Download PDF

Info

Publication number
CN115218827B
CN115218827B CN202210625745.1A CN202210625745A CN115218827B CN 115218827 B CN115218827 B CN 115218827B CN 202210625745 A CN202210625745 A CN 202210625745A CN 115218827 B CN115218827 B CN 115218827B
Authority
CN
China
Prior art keywords
image
line segment
arm support
arm
included angle
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.)
Active
Application number
CN202210625745.1A
Other languages
Chinese (zh)
Other versions
CN115218827A (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.)
Sany Automobile Manufacturing Co Ltd
Original Assignee
Sany Automobile Manufacturing 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 Sany Automobile Manufacturing Co Ltd filed Critical Sany Automobile Manufacturing Co Ltd
Priority to CN202210625745.1A priority Critical patent/CN115218827B/en
Publication of CN115218827A publication Critical patent/CN115218827A/en
Application granted granted Critical
Publication of CN115218827B publication Critical patent/CN115218827B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01BMEASURING LENGTH, THICKNESS OR SIMILAR LINEAR DIMENSIONS; MEASURING ANGLES; MEASURING AREAS; MEASURING IRREGULARITIES OF SURFACES OR CONTOURS
    • G01B11/00Measuring arrangements characterised by the use of optical techniques
    • G01B11/26Measuring arrangements characterised by the use of optical techniques for measuring angles or tapers; for testing the alignment of axes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/13Edge detection
    • 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
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Multimedia (AREA)
  • Image Analysis (AREA)

Abstract

本发明提供一种臂架间夹角测量方法、装置、设备和存储介质,包括:通过摄像装置获取实时臂架图像;对所述实时臂架图像进行拟合处理,得到拟合线段集合;从所述拟合线段集合中选取拟合线段,分别计算所述拟合线段与预设的第一区域和第二区域的重合度,并将所述重合度大于阈值对应的拟合线段分别作为第一臂架线段和第二臂架线段;计算所述第二臂架线段与所述第一臂架线段的图像夹角,并根据所述图像夹角和预设的角度映射关系,确定第一臂架和所述第二臂架之间的真实夹角。本发明的技术方案可以降低臂架间夹角测量的成本。

The present invention provides a method, device, equipment and storage medium for measuring the angle between booms, including: acquiring a real-time boom image through a camera device; performing fitting processing on the real-time boom image to obtain a set of fitting line segments; selecting a fitting line segment from the set of fitting line segments, respectively calculating the overlap between the fitting line segment and a preset first area and a preset second area, and using the fitting line segments corresponding to the overlap greater than a threshold as the first boom line segment and the second boom line segment respectively; calculating the image angle between the second boom line segment and the first boom line segment, and determining the real angle between the first boom and the second boom according to the image angle and the preset angle mapping relationship. The technical solution of the present invention can reduce the cost of measuring the angle between booms.

Description

Method, device, equipment and storage medium for measuring included angle between armrests
Technical Field
The present invention relates to the field of computer vision, and in particular, to a method and apparatus for measuring an included angle between arm frames, an electronic device, and a non-transitory computer readable storage medium.
Background
In the use process of engineering machinery such as a concrete pump truck, the expansion angle of the boom in an expansion state needs to be measured, for example, when the boom is controlled to be expanded to a target angle or retracted to an initial state, the current included angle between the boom needs to be acquired in real time.
In the related art, a conventional electrical sensor may be used to measure an included angle between the frames of the construction machine. For example, the inclination angle sensor or the inertial sensor is used for acquiring the horizontal inclination angle of each arm support, so that the included angle between the arm supports is determined.
Disclosure of Invention
The invention provides a method and a device for measuring an included angle between arm frames, electronic equipment and a non-transitory computer readable storage medium, which are used for solving the technical problem of higher cost for measuring the included angle between arm frames in the related technology and reducing the measurement cost on the premise of ensuring the measurement accuracy.
The invention provides a method for measuring an included angle between arm frames, which comprises the following steps:
The method comprises the steps of obtaining real-time arm frame images through a camera device, wherein the arm frames comprise a first arm frame and a second arm frame, the camera device is arranged on the first arm frame and the shooting direction is fixed relative to the first arm frame, fitting the real-time arm frame images to obtain a fitting line segment set, selecting fitting line segments from the fitting line segment set, respectively calculating the coincidence ratio of the fitting line segments to a preset first area and a preset second area, respectively taking the fitting line segments with the coincidence ratio larger than a threshold value as the first arm frame line segments and the second arm frame line segments, determining the first area according to the position of the first arm frame in the real-time arm frame images, determining the second area according to the movement range of the second arm frame in the real-time images, calculating the image included angle of the second arm frame line segments and the first arm frame line segments, and determining the real included angle between the first arm frame and the second arm frame according to the image included angle and a preset angle mapping relation, wherein the angle mapping relation comprises the real included angle between the first arm frame and the second arm frame.
The method for measuring the included angle between the arm frames comprises the steps of obtaining a region anchor point of a first region through a camera device, wherein the first region is a preset frame in a preset second arm frame movement range after a history image is divided into preset frames, the region anchor point is a center point of each preset frame in the first region, and obtaining and determining the first region according to the region anchor point.
According to the method for measuring the included angle between the arm frames, the image included angle between the second arm frame line segment and the first arm frame line segment is calculated, and before the image included angle and a preset angle mapping relation are achieved, the method further comprises the steps of obtaining the historical image and the actual included angle between the first arm frame and the second arm frame when the corresponding second arm frame is in the gesture of the historical image, obtaining the image included angle between the first arm frame and the second arm frame in the historical image according to the historical image, and confirming the angle mapping relation between the actual included angle and the image included angle.
According to the method for measuring the included angle between the arm frames, the image included angle between the second arm frame line segment and the first arm frame line segment is calculated, and the image included angle is calculated according to an inverse trigonometric function algorithm, the first arm frame line segment and the second arm frame line segment.
According to the inter-boom included angle measuring method provided by the invention, before the real-time boom image is fitted, the method further comprises the step of preprocessing the real-time boom image, wherein the preprocessing comprises noise reduction processing operation and/or gray level image generation operation.
According to the method for measuring the included angle between the arm frames, the real-time arm frame images are subjected to fitting processing to obtain a fitting line segment set, the method comprises the steps of performing edge detection processing on the first arm frame images by using an edge detection algorithm to obtain an edge detection result, and converting the edge detection result by using a feature detection algorithm to obtain the fitting line segment set.
According to the method for measuring the included angle between the arm frames, which is provided by the invention, the coincidence degrees of at least two fitting line segments and a preset first area are calculated respectively, and the fitting line segment corresponding to the coincidence degrees larger than a threshold value is used as a second arm frame line segment.
The invention provides an inter-boom included angle measuring device which comprises an image acquisition unit, an image processing unit and a line segment screening unit, wherein the image acquisition unit is used for acquiring real-time boom images through a camera device, the boom comprises a first boom and a second boom, the camera device is arranged on the first boom, the shooting direction of the camera device is fixed relative to the first boom, the image processing unit is used for carrying out fitting processing on the real-time boom images to obtain a fitted line segment set, the line segment screening unit is used for selecting fitted line segments from the fitted line segment set, calculating the coincidence degree of the fitted line segments with a preset first area and a preset second area respectively, the fitted line segments with the coincidence degree larger than a threshold value are used as the first boom line segment and the second boom line segment respectively, the first area is determined according to the position of the first boom in the real-time boom images, the second area is determined according to the movement range of the second boom in the real-time boom images, the included angle acquisition unit is used for calculating the image included angles of the second boom line segments and the first line segments, and the real included angle between the first boom and the second boom is determined according to the image included angle mapping relation between the image included angles and the first included angle mapping relation between the first boom line segments and the real included angles.
The device for measuring the included angle between the arm frames further comprises a region determining unit, wherein the region determining unit is used for obtaining a region anchor point of a first region through the image pick-up device, the first region is a preset frame in a preset second arm frame movement range after the history image is divided into the preset frame, the region anchor point is a center point of each preset frame in the first region, and the first region is obtained and determined according to the region anchor point.
The device for measuring the included angle between the arm frames further comprises an angle mapping table establishing unit, wherein the angle mapping table establishing unit is used for obtaining the historical image and the real included angle between the first arm frame and the second arm frame when the corresponding second arm frame is in the gesture in the historical image, obtaining the image included angle between the first arm frame and the second arm frame in the historical image according to the historical image, and confirming the angle mapping relation between the real included angle and the image included angle.
According to the inter-arm support included angle measuring device provided by the invention, the included angle obtaining unit is further used for calculating the image included angle according to an inverse trigonometric function algorithm, the first arm support line segment and the second arm support line segment.
The device for measuring the included angle between the arm frames further comprises an image preprocessing unit, wherein the image preprocessing unit is used for preprocessing the real-time arm frame image, and the preprocessing comprises noise reduction processing operation and/or gray level image generation operation.
The image processing unit is further used for carrying out edge detection processing on the first arm support image by using an edge detection algorithm to obtain an edge detection result, and converting the edge detection result by using a feature detection algorithm to obtain a fitting line segment set.
According to the inter-arm support included angle measuring device provided by the invention, the line segment screening unit is further used for taking the current fitting line segment as the first arm support line segment and the second arm support line segment if the ratio of the length of the current fitting line segment falling into the first area to the total length of the current fitting line segment is greater than or equal to the threshold value.
The invention also provides a working machine which comprises the device for measuring the included angle between the arm frames.
The invention also provides an electronic device, which comprises a memory, a processor and a computer program stored on the memory and capable of running on the processor, wherein the processor realizes the steps of any one of the methods for measuring the included angle between the arm frames when executing the program.
The invention also provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the inter-boom angle measurement method as described in any of the above.
According to the method, the device, the electronic equipment and the non-transitory computer readable storage medium for measuring the included angle between the arm frames, at least two fitting line segments are obtained through image processing of the first arm frame image shot by the fixedly installed camera device, the second arm frame line segment is obtained by combining with the preset first area, and then the included angle between the two arm frames is obtained according to the first arm frame line segment, the second arm frame line segment and the preset angle mapping table, so that the measurement of the included angle between the arm frames through the computer vision technology is realized, a plurality of electrical sensors are not required to be distributed, and the measurement cost can be reduced while the measurement accuracy is ensured.
Drawings
In order to more clearly illustrate the invention or the technical solutions of the prior art, the following description will briefly explain the drawings used in the embodiments or the description of the prior art, and it is obvious that the drawings in the following description are some embodiments of the invention, and other drawings can be obtained according to the drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic flow chart of a method for measuring an included angle between arm frames according to the present invention;
FIG. 2 is a schematic illustration of a preset sash provided by the present invention;
FIG. 3 is a second flow chart of the method for measuring the included angle between arm frames according to the present invention;
FIG. 4 is a schematic structural diagram of the device for measuring the included angle between arm frames provided by the invention;
fig. 5 is a schematic structural diagram of an electronic device provided by the present invention.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the present invention more apparent, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
The terminology used in the one or more embodiments of the invention is for the purpose of describing particular embodiments only and is not intended to be limiting of the one or more embodiments of the invention. As used in one or more embodiments of the invention and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used in one or more embodiments of the present invention refers to and encompasses any or all possible combinations of one or more of the associated listed items.
It should be understood that, although the terms first, second, etc. may be used in one or more embodiments of the invention to describe various information, these information should not be limited by these terms. These terms are only used to distinguish one type of information from another. For example, a first may also be referred to as a second, and similarly, a second may also be referred to as a first, without departing from the scope of one or more embodiments of the invention. The term "if" as used herein may be interpreted as "at..once" or "when..once" or "in response to a determination", depending on the context.
The following describes example embodiments of the invention in detail with reference to the accompanying drawings.
Fig. 1 is a flowchart of a method for measuring an included angle between arm frames according to an embodiment of the present invention. The method provided by the embodiment of the invention can be executed by any electronic device with computer processing capability, such as a terminal or a server. As shown in fig. 1, the method for measuring the included angle between the arm frames includes:
102, acquiring a real-time arm support image through a camera device, wherein the arm support comprises a first arm support and a second arm support, and the camera device is arranged on the first arm support and the shooting direction is fixed relative to the first arm support.
Specifically, if the first arm support rotates, the camera device rotates along with the first arm support, so that the camera device can shoot the junction area of the first arm support and the second arm support, and the visual angles are the same. In different boom images, the extension direction of the first boom remains unchanged.
And 104, performing fitting processing on the real-time arm support image to obtain a fitting line segment set.
Specifically, the fitting line segment set includes a first boom segment corresponding to a first boom, where the first boom segment is determined based on a length extension direction of the first boom.
The real-time boom image can be processed by an edge detection algorithm and a feature detection algorithm. Edge detection is used to detect areas of the image where some local intensity is strongly varying. Feature detection is a primary operation in image processing that examines each pixel to determine if the pixel represents a feature.
And 106, selecting a fitting line segment from the fitting line segment set, respectively calculating the coincidence ratio of the fitting line segment to a preset first area and a preset second area, and respectively taking the fitting line segment corresponding to the coincidence ratio larger than a threshold value as a first arm frame line segment and a second arm frame line segment, wherein the first area is determined according to the position of the first arm frame in the real-time arm frame image, and the second area is determined according to the movement range of the second arm frame in the real-time arm frame image.
Specifically, the first area is used for filtering and screening the fitting line segment to obtain a second arm support line segment. The central point of each preset sash of the first area can be selected as an area anchor point, and the coverage area of the first area can be determined by calculating according to the coordinates of the area anchor point, so that part of ineffective line segments can be filtered based on the coverage area.
And step 108, calculating an image included angle between the second arm support line segment and the first arm support line segment, and determining a real included angle between the first arm support and the second arm support according to the image included angle and a preset angle mapping relation, wherein the angle mapping relation comprises a mapping relation between the real included angle between the first arm support and the second arm support and the image included angle.
According to the technical scheme provided by the embodiment of the invention, the boom edge fitting line can be obtained based on the boom characteristics extracted by traditional RGB image data under the condition of low cost, the first boom segment and the second boom segment are further obtained through screening according to the preset first area, and the included angle between the booms is obtained by combining the included angle mapping table. The scheme only adopts the classical algorithm of the traditional computer vision, does not need to collect a data set and manually label the data, has extremely low cost and extremely low requirement on calculation resources, and can reduce the cost of angle measurement between the arm frames.
In the embodiment of the present invention, the image capturing device may be an RGB camera, and the resolution thereof needs to be not lower than 480P. The RGB camera is fixed at a pre-selected position by a fixing device such as a bracket, and the position may be a certain position on one of the two arms of the angle to be measured. The image acquired by the image pickup device is transmitted to an electronic device including a processor for processing, and the electronic device may be a general controller of the engineering machine or other embedded electronic devices, and is not limited thereto.
The first area is determined by acquiring an area anchor point of the first area through the image pickup device, wherein the first area is a preset frame in a preset second arm support movement range after a history image is divided into preset frames, the history image is picked up by the image pickup device, the area anchor point is a center point of each preset frame in the first area, and the first area can be acquired and determined according to the area anchor point.
The first area is a boom characteristic area.
In the embodiment of the invention, an angle mapping relation is also required to be obtained in advance, specifically, when the angle mapping relation is obtained, a historical image and a real included angle between the first arm support and the second arm support when the corresponding second arm support is in the gesture in the historical image are required to be obtained, an image included angle between the first arm support and the second arm support in the historical image is obtained according to the historical image, and the angle mapping relation between the real included angle and the image included angle is confirmed.
After the imaging device is fixed at the set mounting position, the shooting direction of the imaging device lens is fixed. When the arm support is in different postures, the camera shooting device shoots to obtain historical arm support images. The actual included angle of the second arm support in different postures can be obtained through manual measurement. According to the historical arm support images of the second arm support in different postures, the image included angles of the second arm support in different postures can be obtained. And obtaining an angle mapping table according to the mapping relation between the real included angle and the image included angle.
As shown in fig. 2, the preset sash in the hatched portion is a first area, and the center point of the preset sash in the first area is an area anchor point. The camera device is mounted on the first arm support 201, and the camera of the camera device faces to the junction of the first arm support 201 and the second arm support 202, and when the first arm support 201 rotates, the camera device can rotate along with the first arm support 201. One end of the second arm support 202 is rotatably connected with the first arm support 201, and the other end of the second arm support 202 is rotatably connected with the third arm support 203. If the included angle between the second arm frame 202 and the third arm frame needs to be measured, the camera device needs to be installed on the second arm frame 202 or the third arm frame, so that the camera device rotates along with the rotation of the arm frame.
Prior to step 104, the real-time boom image is preprocessed, including noise reduction processing operations and/or gray scale image generation operations.
In step 104, edge detection processing may be performed on the first boom image by using a candy Algorithm to obtain an edge detection result, and a Hough transform (Hough Algorithm) Algorithm may be used to convert the edge detection result to obtain a fitted line segment set.
The canny algorithm is one of the most classical and advanced algorithms in the image edge detection algorithm. It can realize non-maximum suppression based on edge gradient direction and hysteresis thresholding of double threshold. The hough transform can be used to identify features found in objects that can identify not only straight lines, but also any shape, such as circles, ovals, etc.
The channel algorithm and the Hough transformation are used for accurately distinguishing the line segments with smaller calculation force so as to find out the contour edge line segments of the first arm support and the second arm support.
In step 106, if the ratio of the length of the current fitting line segment falling into the first region to the total length of the current fitting line segment is greater than or equal to the threshold value, the current fitting line segment is taken as the second arm frame line segment.
Wherein the coordinates of the region anchor point may be used to locate the first region. And screening and filtering the fitting line segments according to the first region, namely screening and filtering the fitting line segments according to the region anchor points.
When screening is carried out, the length of the current fitting line segment falling into the first area, the line segment with the ratio of the total length of the current fitting line segment smaller than the set threshold value is discarded, and the line segment with the ratio larger than or equal to the set threshold value is the second arm frame line segment representing the second arm frame.
In step 108, when calculating the image angle between the second boom segment and the first boom segment, the image angle may be calculated according to the inverse trigonometric function algorithm, the first boom segment and the second boom segment.
In particular, the inverse trigonometric function includes an arctangent function and an arccosine function. Wherein: the arctangent function is calculated as arctan ((k 1-k 2)/(1+k1×k2)), and the arccosine function arccos (x 1×x2/|x1|x2|), where k1 and k2 are the slopes of the two segments, respectively.
And comparing the calculated image included angle with an angle mapping table to obtain the included angle between the first arm support and the second arm support in the real environment corresponding to the current arm support image.
For example, in the real angle mapping table, when the image included angle of the first arm frame and the second arm frame is 45 °, the real included angle of the first arm frame and the second arm frame is 90 °. The mapping can be performed according to the method, and then when the calculated result of the image included angle in the image space is 45 degrees, the final real included angle is 90 degrees.
As shown in fig. 3, in one embodiment of the invention, an RGB camera 301 captures image data to form an RGB data frame 302, and a set of fitted line segments 303 may be obtained by image processing the RGB data frame. The set of fitted line segments is filtered using the pre-selected region anchor points 304 to obtain a set of target line segments 305. The target line segment set 305 includes two line segments, which may represent edges of the first boom and the second boom. The target included angle 307 can be obtained by combining the target line segment set 305 and a pre-established real angle mapping table 306.
By adopting the technical scheme of the embodiment of the invention, the image can be processed at a higher frequency, the angle data between the arms is output, and particularly, the frequency of processing the image can reach 10 frames/second, so that the instantaneous error caused by vibration or other special conditions can be effectively avoided. The error of the angle calculation result in the technical scheme of the embodiment of the invention can be controlled between 1 degree and 2 degrees.
According to the method for measuring the included angle between the arm frames, at least two fitting line segments are obtained through image processing of the first arm frame image shot by the fixedly installed camera device, the second arm frame line segment is obtained by combining the preset first area, and the included angle between the two arm frames is obtained according to the first arm frame line segment, the second arm frame line segment and the preset angle mapping table, so that the measurement of the included angle between the arm frames through a computer vision technology is realized, a plurality of electrical sensors are not required to be distributed, and the measurement cost can be reduced while the measurement accuracy is ensured.
The inter-arm support included angle measuring device provided by the invention is described below, and the inter-arm support included angle measuring device described below and the inter-arm support included angle measuring method described above can be correspondingly referred to each other.
As shown in fig. 4, an apparatus for measuring an included angle between arm frames according to an embodiment of the present invention includes:
The image acquisition unit 402 may be configured to acquire a real-time boom image through a camera device, where the boom includes a first boom and a second boom, and the camera device is installed on the first boom and the shooting direction is fixed relative to the first boom.
The image processing unit 404 may be configured to perform a fitting process on the real-time boom image to obtain a fitting line segment set.
The line segment screening unit 406 may be configured to select a fitting line segment from the fitting line segment set, calculate an overlap ratio between the fitting line segment and a preset first area and a preset second area, and use the fitting line segment corresponding to the overlap ratio greater than a threshold value as a first arm frame line segment and a second arm frame line segment, where the first area is determined according to a position of the first arm frame in the real-time arm frame image, and the second area is determined according to a movement range of the second arm frame in the real-time arm frame image.
The included angle obtaining unit 408 may be configured to calculate an image included angle between the second boom segment and the first boom segment, and determine a real included angle between the first boom and the second boom according to the image included angle and a preset angle mapping relationship, where the angle mapping relationship includes a mapping relationship between the real included angle and the image included angle between the first boom and the second boom.
The device further comprises a region determining unit which can be used for obtaining a region anchor point of a first region through the image pick-up device, wherein the first region is a preset frame in a preset second arm support movement range after the history image is divided into the preset frames, the history image is shot by the image pick-up device, the region anchor point is a center point of each preset frame in the first region, and the first region is determined according to the region anchor point.
In the embodiment of the invention, the device further comprises an angle mapping table establishing unit which can be used for acquiring the historical image and the real included angle between the first arm support and the second arm support when the second arm support is in the gesture in the historical image, acquiring the image included angle between the first arm support and the second arm support in the historical image according to the historical image, and confirming the angle mapping relation between the real included angle and the image included angle.
In the embodiment of the invention, the included angle obtaining unit can also be used for calculating the image included angle according to the inverse trigonometric function algorithm, the first arm frame line segment and the second arm frame line segment.
In the embodiment of the invention, the device further comprises an image preprocessing unit which can be used for preprocessing the real-time arm support image, wherein the preprocessing comprises noise reduction processing operation and/or gray scale image generation operation.
In the embodiment of the invention, the image processing unit can also be used for carrying out edge detection processing on the first arm support image by using an edge detection algorithm to obtain an edge detection result, and converting the edge detection result by adopting a characteristic detection algorithm to obtain a fitting line segment set.
In the embodiment of the invention, the line segment screening unit can be further used for taking the current fitting line segment as the second arm frame line segment if the ratio of the length of the current fitting line segment falling into the first area to the total length of the current fitting line segment is greater than or equal to a threshold value.
Because each functional module of the inter-boom angle measurement device according to the exemplary embodiment of the present invention corresponds to a step of the exemplary embodiment of the inter-boom angle measurement method, for details not disclosed in the embodiment of the device according to the present invention, please refer to the embodiment of the inter-boom angle measurement method according to the present invention.
According to the inter-arm support included angle measuring device provided by the invention, at least two fitting line segments are obtained by carrying out image processing on the first arm support image shot by the fixedly installed camera device, the second arm support line segment is obtained by combining the preset first area, and then the included angle between the two arm supports is obtained according to the first arm support line segment, the second arm support line segment and the preset angle mapping table, so that the inter-arm support included angle is measured by a computer vision technology, a plurality of electrical sensors are not required to be distributed, and the measuring cost can be reduced while the measuring accuracy is ensured.
The embodiment of the invention also provides a working machine, which comprises the device for measuring the included angle between the arm frames.
Fig. 5 illustrates a physical schematic diagram of an electronic device, which may include a processor (processor) 510, a communication interface (Communications Interface) 520, a memory (memory) 530, and a communication bus 550, where the processor 510, the communication interface 520, and the memory 530 perform communication with each other through the communication bus 550, as shown in fig. 5. The processor 510 can call a logic instruction in the memory 530 to execute an inter-boom angle measurement method, wherein the method includes acquiring a real-time boom image through a camera, wherein the boom comprises a first boom and a second boom, the camera is mounted on the first boom and the shooting direction is fixed relative to the first boom, fitting the real-time boom image to obtain a fitting line segment set, selecting a fitting line segment from the fitting line segment set, respectively calculating the coincidence ratio of the fitting line segment and a preset first area and a preset second area, and taking the fitting line segment with the coincidence ratio larger than a threshold value as a first boom line segment and a second boom line segment, respectively, determining the first area according to the position of the first boom in the real-time boom image, determining the second area according to the movement range of the second boom in the real-time image, calculating the image angle between the second boom line segment and the first boom line segment, and determining the real angle between the first boom and the second boom according to the image angle and the preset angle mapping relation, wherein the real angle relation comprises the real angle between the first boom line segment and the real angle.
Further, the logic instructions in the memory 530 described above may be implemented in the form of software functional units and may be stored in a computer-readable storage medium when sold or used as a stand-alone product. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution, in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. The storage medium includes a U disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, an optical disk, or other various media capable of storing program codes.
On the other hand, the invention also provides a computer program product, which comprises a computer program stored on a non-transitory computer readable storage medium, wherein the computer program comprises program instructions, when the program instructions are executed by a computer, the computer can execute the inter-arm included angle measuring method provided by the methods, the method comprises the steps of acquiring a real-time arm frame image through a camera device, wherein the arm frame comprises a first arm frame and a second arm frame, the camera device is arranged on the first arm frame and the shooting direction is fixed relative to the first arm frame, fitting the real-time arm frame image to obtain a fitting line segment set, selecting a fitting line segment from the fitting line segment set, respectively calculating the coincidence degree of the fitting line segment and a preset first arm frame line segment and a preset second arm frame line segment, and taking the fitting line segment corresponding to the coincidence degree larger than a threshold value as the first arm frame line segment and the second arm frame line segment, determining the first area according to the position of the first arm frame in the real-time image, determining the mapping relation between the second arm frame image and the second arm frame image according to the second movement range in the real-time image, and determining the real-time image included angle relation between the second arm frame image and the second arm frame image, and the real-time image included angle relation between the second arm frame image and the first arm frame image included angle relation and the real-time image included angle.
In still another aspect, the present invention further provides a non-transitory computer readable storage medium, on which a computer program is stored, the computer program being implemented when executed by a processor to perform the method for measuring an inter-boom angle provided by the above, where the boom includes a first boom and a second boom, the camera is mounted on the first boom and a shooting direction of the camera is fixed relative to the first boom, the real-time boom image is fitted to obtain a set of fitted line segments, a fitted line segment is selected from the set of fitted line segments, a coincidence ratio of the fitted line segment and a preset first area and a preset second area is calculated, and a fitted line segment with the coincidence ratio greater than a threshold is used as a first boom line segment and a second boom line segment, respectively, where the first area is determined according to a position of the first boom in the real-time image, the second area is determined according to a movement range of the second boom in the real-time image, the second line segment and the first boom image are calculated, and a real angle is mapped according to the preset angle between the first boom image and the first boom image, and the real angle is determined, and the real angle is mapped between the first boom image and the real angle.
The apparatus embodiments described above are merely illustrative, wherein the elements illustrated as separate elements may or may not be physically separate, and the elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over a plurality of network elements. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art will understand and implement the present invention without undue burden.
From the above description of the embodiments, it will be apparent to those skilled in the art that the embodiments may be implemented by means of software plus necessary general hardware platforms, or of course may be implemented by means of hardware. Based on this understanding, the foregoing technical solution may be embodied essentially or in a part contributing to the prior art in the form of a software product, which may be stored in a computer readable storage medium, such as ROM/RAM, a magnetic disk, an optical disk, etc., including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method described in the respective embodiments or some parts of the embodiments.
It should be noted that the above-mentioned embodiments are merely for illustrating the technical solution of the present invention, and not for limiting the same, and although the present invention has been described in detail with reference to the above-mentioned embodiments, it should be understood by those skilled in the art that the technical solution described in the above-mentioned embodiments may be modified or some technical features may be equivalently replaced, and these modifications or substitutions do not make the essence of the corresponding technical solution deviate from the spirit and scope of the technical solution of the embodiments of the present invention.

Claims (11)

1. The method for measuring the included angle between the arm frames is characterized by comprising the following steps of:
Acquiring a real-time arm support image through a camera device, wherein the arm support comprises a first arm support and a second arm support, the camera device is arranged on the first arm support, and the shooting direction of the camera device is fixed relative to the first arm support;
fitting the real-time arm support image to obtain a fitting line segment set;
Selecting a fitting line segment from the fitting line segment set, respectively calculating the coincidence degree of the fitting line segment and a preset first area and a preset second area, and respectively taking the fitting line segment corresponding to the coincidence degree larger than a threshold value as a first arm frame line segment and a second arm frame line segment, wherein the first area is determined according to the position of the first arm frame in the real-time arm frame image, and the second area is determined according to the movement range of the second arm frame in the real-time arm frame image;
Calculating an image included angle between the second arm support line segment and the first arm support line segment, and determining a real included angle between the first arm support and the second arm support according to the image included angle and a preset angle mapping relation, wherein the angle mapping relation comprises a mapping relation between the real included angle between the first arm support and the second arm support and the image included angle.
2. The method of claim 1, wherein the first region is determined by:
Acquiring an area anchor point of a first area through a camera device, wherein the first area is a preset sash in a preset second arm support movement range after dividing a history image into preset sashes, and the area anchor point is a center point of each preset sash in the first area;
and acquiring and determining the first region according to the region anchor point.
3. The method of claim 2, wherein before calculating the image angle between the second boom segment and the first boom segment and according to the image angle and the preset angle mapping relationship, the method further comprises:
acquiring a real included angle between the first arm support and the second arm support when the historical image and the corresponding second arm support are in the gesture in the historical image;
acquiring an image included angle between a first arm support and a second arm support in the historical image according to the historical image;
and confirming the angle mapping relation between the real included angle and the image included angle.
4. The method of claim 3, wherein the obtaining, from the historical image, an image angle between the first boom and the second boom in the historical image includes:
and calculating the image included angle according to an inverse trigonometric function algorithm, the first arm support line segment and the second arm support line segment.
5. The method of claim 1, wherein prior to the fitting the real-time boom image, the method further comprises:
And preprocessing the real-time arm support image, wherein the preprocessing comprises noise reduction processing operation and/or gray scale image generating operation.
6. The method of claim 1, wherein the fitting the real-time boom image to obtain a set of fitted line segments comprises:
Performing edge detection processing on the first arm support image by using an edge detection algorithm to obtain an edge detection result;
and converting the edge detection result by adopting a characteristic detection algorithm to obtain a fitting line segment set.
7. The method of claim 1, wherein the calculating the overlap ratio of the fitting line segment and the preset first area and second area, and the fitting line segment corresponding to the overlap ratio greater than a threshold value is used as a first boom line segment and a second boom line segment, respectively, includes:
And if the ratio of the length of the current fitting line segment falling into the first area to the total length of the current fitting line segment is greater than or equal to the threshold value, taking the current fitting line segment as the first arm frame line segment and the second arm frame line segment.
8. The utility model provides an angle measuring device between cantilever crane which characterized in that includes:
the image acquisition unit is used for acquiring real-time arm support images through the camera device, wherein the arm support comprises a first arm support and a second arm support, the camera device is arranged on the first arm support, and the shooting direction is fixed relative to the first arm support;
The image processing unit is used for carrying out fitting processing on the real-time arm support image to obtain a fitting line segment set;
The line segment screening unit is used for selecting a fitting line segment from the fitting line segment set, calculating the coincidence ratio of the fitting line segment to a preset first region and a preset second region respectively, and taking the fitting line segment corresponding to the coincidence ratio being larger than a threshold value as a first arm frame line segment and a second arm frame line segment respectively, wherein the first region is determined according to the position of the first arm frame in the real-time arm frame image, and the second region is determined according to the movement range of the second arm frame in the real-time arm frame image;
The included angle obtaining unit is used for calculating an image included angle between the second arm support line segment and the first arm support line segment, and determining a real included angle between the first arm support and the second arm support according to the image included angle and a preset angle mapping relation, wherein the angle mapping relation comprises a mapping relation between the real included angle between the first arm support and the second arm support and the image included angle.
9. A working machine comprising the inter-boom angle measuring device according to claim 8.
10. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the steps of the method according to any one of claims 1 to 7 when the program is executed.
11. A non-transitory computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method according to any of claims 1 to 7.
CN202210625745.1A 2022-06-02 2022-06-02 Method, device, equipment and storage medium for measuring angle between booms Active CN115218827B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210625745.1A CN115218827B (en) 2022-06-02 2022-06-02 Method, device, equipment and storage medium for measuring angle between booms

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210625745.1A CN115218827B (en) 2022-06-02 2022-06-02 Method, device, equipment and storage medium for measuring angle between booms

Publications (2)

Publication Number Publication Date
CN115218827A CN115218827A (en) 2022-10-21
CN115218827B true CN115218827B (en) 2025-01-21

Family

ID=83608151

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210625745.1A Active CN115218827B (en) 2022-06-02 2022-06-02 Method, device, equipment and storage medium for measuring angle between booms

Country Status (1)

Country Link
CN (1) CN115218827B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108510469A (en) * 2018-02-08 2018-09-07 郑州瑞富德机电科技有限公司 A kind of bracket detection method and device
CN110706509A (en) * 2019-10-12 2020-01-17 东软睿驰汽车技术(沈阳)有限公司 Parking space and direction angle detection method, device, equipment and medium thereof

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2002003026A1 (en) * 2000-07-04 2002-01-10 Fastcom Technology S.A. System and method for angle measurement
CN105069786B (en) * 2015-07-31 2018-05-08 小米科技有限责任公司 Line detection method and device
CN117470134A (en) * 2018-11-20 2024-01-30 北京图森智途科技有限公司 A method, device and vehicle for measuring the included angle of a trailer

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108510469A (en) * 2018-02-08 2018-09-07 郑州瑞富德机电科技有限公司 A kind of bracket detection method and device
CN110706509A (en) * 2019-10-12 2020-01-17 东软睿驰汽车技术(沈阳)有限公司 Parking space and direction angle detection method, device, equipment and medium thereof

Also Published As

Publication number Publication date
CN115218827A (en) 2022-10-21

Similar Documents

Publication Publication Date Title
WO2016192494A1 (en) Image processing method and device
WO2015196616A1 (en) Image edge detection method, image target recognition method and device
CN114445404A (en) Method and system for automatic identification of structural vibration response based on subpixel edge detection
CN102289803A (en) Image Processing Apparatus, Image Processing Method, and Program
CN111397541A (en) Method, device, terminal and medium for measuring slope angle of soil dump
KR101972582B1 (en) Development for Displacement Measurement System Based on a PTZ Camera and Method thereof
CN112284260A (en) Visual displacement monitoring method, equipment and system
CN112967345A (en) External parameter calibration method, device and system of fisheye camera
CN103400140A (en) Method for processing ice coated on insulator on basis of improved image method
CN110942506A (en) A kind of object surface texture reconstruction method, terminal equipment and system
CN104331907A (en) Method for measuring carrier speed based on ORB (Object Request Broker) character detection
CN116730203A (en) Operation early warning method for tower crane
CN115218827B (en) Method, device, equipment and storage medium for measuring angle between booms
CN113034526B (en) Grabbing method, grabbing device and robot
CN116430069A (en) Machine vision fluid flow velocity measuring method, device, computer equipment and storage medium
CN117392243B (en) Encoder installation position detection method and system based on image processing
CN115564728B (en) Image corner detection method, device, equipment and application
JP2006041939A (en) Monitor device and monitor program
CN118501894A (en) Image scale factor estimation method, device, electronic device and storage medium
CN106846418A (en) A kind of electrical verification hanging ground-wire Robot visual location system
JP2006065472A (en) Three-dimensional model generating device and method
JP6800938B2 (en) Image processing equipment, image processing methods and programs
CN113240739B (en) Pose detection method and device for excavator and accessory and storage medium
CN117649409B (en) Automatic limiting system, method, device and medium for sliding table based on machine vision
CN117281540B (en) Respiratory signal acquisition method, device, equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant