Handheld steel bar counter

Through a handheld steel bar counting device, the steel bar end surface profile is obtained using a linear laser and a binocular camera, and combined with gyroscope data processing, fast and accurate steel bar counting is achieved, solving the problems of low counting efficiency and low accuracy in the prior art.

CN111640086BActive Publication Date: 2025-02-11BEIJING WEIJING INTELLIGENT TECH CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN201910156621.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2019-03-01
Publication Date
2025-02-11
Estimated Expiration
2039-03-01

AI Technical Summary

Technical Problem

In the prior art, the steel bar counting method consumes a long time, has high labor intensity, low efficiency, and has a large counting error under adverse environmental conditions, so it cannot be used stably in large quantities.

Method used

A handheld steel bar counting instrument was designed, using a linear laser emitter and a binocular camera to obtain the contour laser lines of the end face of the steel bar. The three-dimensional data was analyzed through the data processing module, and combined with the motion speed and angle measured by the gyroscope, the number of steel bars was calculated to obtain .

Benefits of technology

It realizes rapid and accurate counting of steel bars, adapts to various lighting environments, and has strong anti-environmental interference, solving the problems of low counting efficiency and low accuracy in the prior art.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN111640086B_ABST
    Figure CN111640086B_ABST
Patent Text Reader

Abstract

The invention discloses a handheld steel bar counter, comprising: a line laser transmitter, a binocular camera, a gyroscope, a data processing module, a display screen, and a manual operation control module, wherein: the line laser transmitter transmits a line laser to project onto a steel bar end face according to a control instruction of the manual operation control module, and obtains a contour laser line of the steel bar end face when the line laser is projected onto the steel bar end face; the binocular camera obtains a left steel bar end face contour image and a right steel bar end face contour image with contour laser lines, wherein parameters of the left camera and the right camera of the binocular camera are the same; the data processing module analyzes and processes the left steel bar end face contour image and the right steel bar end face contour image to obtain three-dimensional data of the steel bar end face contour; the data processing module obtains a steel bar end face contour diagram and steel bar number information according to the three-dimensional data of the steel bar end face contour and a corresponding relationship; and the display screen is used for displaying the steel bar end face contour diagram and steel bar number information.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the technical field of optical detection, and in particular to a handheld steel bar counter. Background Art

[0002] In the existing technical solutions, the steel bars are usually counted manually, and the counting workers mainly use colored pens of different colors to mark multiple times to distinguish the counted and uncounted steel bars.

[0003] The existing manual method is time-consuming, labor-intensive, and inefficient. Moreover, after long-term high-intensity work, the human eye and brain are easily fatigued, and the counting error will be greatly increased.

[0004] Chinese patent document CN201510672905.8 discloses a method for counting the number of steel bars based on computer vision, which obtains the original color image of the cross section of the measured steel bar bundle and converts it into a grayscale image, which is then converted into a binary image after enhancement processing, and then the binary image is used for counting.

[0005] Since the technical solution of CN201510672905.8 directly obtains the original color image of the end face of the steel bar for image processing, it is limited by the technical defects of the image processing technology. In an environment that is too bright or too dark or when the steel bar is corroded, the counting error is large and it cannot be used stably in large quantities. Summary of the invention

[0006] The present invention provides a handheld steel bar counter to overcome at least one problem existing in the prior art.

[0007] To achieve the above object, the present invention provides a handheld steel bar counter, comprising: a line laser transmitter, a binocular camera, a gyroscope, a data processing module, a display screen, and a manual operation control module, wherein:

[0008] The line laser transmitter emits a line laser according to the control instruction of the manual operation control module and projects it onto the end face of the steel bar, and when the line laser is projected onto the end face of the steel bar, a contour laser line of the end face of the steel bar is obtained;

[0009] The binocular camera acquires a left steel bar end face contour image and a right steel bar end face contour image with the contour laser line, wherein the parameters of the left camera and the right camera of the binocular camera are the same;

[0010] The data processing module analyzes and processes the left steel bar end face contour image and the right steel bar end face contour image to obtain three-dimensional steel bar end face contour data;

[0011] The gyroscope measures the current movement speed of the handheld steel bar counter and the angle between the linear laser projection surface and the steel bar end surface;

[0012] The data processing module calculates the corresponding relationship between the contour laser line group projected onto the end face of the steel bar and the movement mode according to the current movement speed of the handheld steel bar counter and the angle between the line laser projection surface and the end face of the steel bar, wherein the movement mode includes the movement speed of the handheld steel bar counter and the angle between the line laser projection surface and the end face of the steel bar; and obtains the steel bar end face contour map and steel bar number information according to the three-dimensional data of the steel bar end face contour and the corresponding relationship;

[0013] The display screen is used to display the steel bar end face profile and steel bar number information.

[0014] Optionally, the data processing module obtains the steel bar end face contour diagram and steel bar number information according to the steel bar end face contour three-dimensional data and the corresponding relationship, including:

[0015] The data processing module quantifies the three-dimensional data and converts it into a grayscale image using a watershed transformation, and determines the center point and number of each steel bar according to the grayscale image.

[0016] Optionally, the data processing module quantifies the three-dimensional data and converts it into a grayscale image using a watershed transform, and determines the center point and number of each steel bar according to the grayscale image, including:

[0017] The data processing module binarizes the obtained three-dimensional data of the complete contour of the steel bar end face according to a preset measurement distance range to obtain a binary image;

[0018] Performing a watershed transform on the binary image to convert the binary image into a grayscale image;

[0019] The grayscale maximum value points in the grayscale image are marked as steel bar center points, and the number of steel bar center points obtained is counted to obtain the number of steel bars.

[0020] Optionally, the data processing module analyzes and processes the left steel bar end face contour image and the right steel bar end face contour image to obtain three-dimensional steel bar end face contour data, including:

[0021] Performing stereoscopic correction on the left steel bar end face contour image and the right steel bar end face contour image, so that the corrected left steel bar end face contour image and the right steel bar end face contour image are aligned;

[0022] Matching the corrected left steel bar end face contour image and the right steel bar end face contour image to obtain a line laser imaging matching point pair;

[0023] The parallax of the left and right images is obtained according to the line laser imaging matching point pair, and the three-dimensional data of the steel bar end face contour is calculated according to the parallax of the left and right images.

[0024] Optionally, the gyroscope calculates the current movement speed of the handheld steel bar counter and the angle between the line laser projection surface and the steel bar end surface, and obtains the corresponding relationship between the contour laser line group projected onto the steel bar end surface and the movement mode, including:

[0025] The gyroscope obtains the speed of the handheld steel bar counter at each moment, the angle between the laser line and the steel bar to be measured, and the movement direction of the handheld steel bar counter, and obtains the movement trajectory of the handheld steel bar counter according to the obtained speed at each moment, the angle between the laser line and the steel bar to be measured, and the movement direction of the handheld steel bar counter;

[0026] The actual position of the laser line during the scanning process is calculated according to the motion trajectory, specifically including: taking the first laser line emitted to the surface of the steel bar as the initial line, and recording the three-dimensional coordinates of each laser point on the initial line; during the scanning process, calculating the time interval between two laser lines according to the timestamps of each laser line and the next laser line acquired by the binocular camera; integrating the speed within the time interval according to the movement speed at each moment recorded by the gyroscope to obtain the distance between two adjacent laser lines; and determining the actual position of the next laser line on the surface of the steel bar according to the initial line and the distance between the two adjacent laser lines.

[0027] Optionally, before the line laser transmitter emits a line laser according to the control instruction of the manual operation control module and projects it onto the end face of the steel bar, the method further includes:

[0028] The left camera and the right camera of the binocular camera are stereo calibrated to obtain the intrinsic parameter matrix A of the binocular camera, the rotation matrix R and the translation vector T between the left camera and the right camera.

[0029] Optionally, the stereo calibration of the left camera and the right camera of the binocular camera to obtain the intrinsic parameter matrix A of the binocular camera, the rotation matrix R and the translation vector T between the left camera and the right camera includes:

[0030] Calibrate the left camera and the right camera of the binocular camera respectively to obtain the intrinsic parameter matrix A of the binocular camera, the rotation matrix R1 of the left camera and the rotation matrix Rr of the right camera, and the translation vector T1 of the left camera and the translation vector Tr of the right camera;

[0031] The rotation matrix R and the translation vector T between the left camera and the right camera are calculated by the following formula:

[0032]

[0033] Optionally, the performing stereoscopic correction on the left steel bar end face contour image and the right steel bar end face contour image comprises:

[0034] Decompose the rotation matrix R into two rotation matrices r1 and r r , where r1 and r r It is obtained by assuming that the left camera and the right camera are each rotated halfway so that the optical axes of the left camera and the right camera are parallel;

[0035] The alignment of the left steel bar end face contour image and the right steel bar end face contour image is achieved by the following formula:

[0036]

[0037] Among them, R rect The rotation matrix to align the rows:

[0038]

[0039] Rotation matrix R rect Starting from the direction of the pole e1, with the origin of the left steel bar end face contour image as the main point, the direction of the translation vector from the left camera to the right camera is the main point direction:

[0040]

[0041] e1 is orthogonal to e2, normalize e1 to the unit vector:

[0042]

[0043] Among them, T x is the horizontal component of the translation vector T in the plane where the binocular camera is located, T y is the vertical component of the translation vector T in the plane where the binocular camera is located;

[0044] e3 is orthogonal to e1 and e2, and e3 is calculated by the following formula:

[0045] e3=e2×e1

[0046] According to the above rotation matrix, the physical meaning is:

[0047]

[0048] Wherein, α represents the angle that the left camera and the right camera need to rotate in their planes to align the rows, 0≤α≤180°; for the left camera, it is rotated α' around the direction of e3, and for the right camera, it is rotated α" around the direction of e3.

[0049] Optionally, the handheld steel bar counter also includes a shell, and the line laser emitter, the binocular camera, the gyroscope, the data processing module and the manual operation control module are arranged inside the shell, the shell is provided with holes for line laser emission and binocular camera to acquire light, and the display screen is arranged at the top of the shell.

[0050] Optionally, the handheld counter has a built-in power supply, and each component is connected via a power line and a data transmission line.

[0051] The above embodiments of this specification achieve the following beneficial effects:

[0052] (1) A moving line laser and a binocular camera are used to obtain the end face profile image of the bundled steel bars, and the number of steel bars is obtained by processing the end face profile image data. Since the line laser can perfectly restore the end face profile image information of the steel bars, and the binocular camera can stably obtain the laser line image, it can adapt to various lighting environments and has strong resistance to environmental interference; by quantifying the three-dimensional data and converting it into a grayscale image using a watershed transform, the center point and number of the steel bars are determined based on the grayscale image, and the number of steel bars can be quickly and accurately analyzed, which solves the problem of time-consuming, low efficiency and low accuracy in counting piles or bundles of steel bars. This is one of the innovative features of the present invention.

[0053] (2) The counter adopts a portable structure design, which is easy to use and can adapt to different usage scenarios.

[0054] (3) There is no need to limit the relative movement between the laser binocular camera and the steel bar to a uniform speed, which makes it easier to use. This is one of the innovative features of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0055] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0056] Figure 1 A schematic diagram of the structure of a handheld steel bar counter according to an embodiment of the present invention;

[0057] Figure 2 A flow chart of scanning and counting steel bars according to one embodiment of this specification is shown;

[0058] Figure 3 A schematic diagram showing the distance between laser lines left on the upper and lower surfaces of an object according to an embodiment of the present specification is shown.

[0059] Description of the reference numerals: 1 - housing; 2 - line laser transmitter; 3 - binocular camera. DETAILED DESCRIPTION

[0060] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0061] Figure 1 The present invention is a schematic diagram of the structure of a handheld steel bar counter according to an embodiment of the present invention; as shown in the figure, the handheld steel bar counter includes: a line laser transmitter 2, a binocular camera 3, a gyroscope, a data processing module, a display screen, and a manual operation control module, wherein:

[0062] The line laser transmitter emits a line laser according to the control instruction of the manual operation control module and projects it onto the end face of the steel bar, and when the line laser is projected onto the end face of the steel bar, a contour laser line of the end face of the steel bar is obtained;

[0063] The binocular camera acquires a left steel bar end face contour image and a right steel bar end face contour image with the contour laser line, wherein the parameters of the left camera and the right camera of the binocular camera are the same;

[0064] The data processing module analyzes and processes the left steel bar end face contour image and the right steel bar end face contour image to obtain three-dimensional steel bar end face contour data;

[0065] The gyroscope measures the current movement speed of the handheld steel bar counter and the angle between the linear laser projection surface and the steel bar end surface;

[0066] The data processing module calculates the corresponding relationship between the contour laser line group projected onto the end face of the steel bar and the movement mode according to the current movement speed of the handheld steel bar counter and the angle between the line laser projection surface and the end face of the steel bar, wherein the movement mode includes the movement speed of the handheld steel bar counter and the angle between the line laser projection surface and the end face of the steel bar; and obtains the steel bar end face contour map and steel bar number information according to the three-dimensional data of the steel bar end face contour and the corresponding relationship;

[0067] The display screen is used to display the steel bar end face profile and steel bar number information.

[0068] The movement mode here refers to the movement mode of the handheld counter during the measurement process, including speed and angle. When scanning the steel bar with a handheld measuring instrument, it is difficult to ensure that the hand is in a uniform speed state, and it is also difficult to ensure that the laser line hits the end face of the steel bar at 90 degrees. Therefore, a gyroscope is used to calculate the angular velocity and linear velocity of the measuring instrument during movement. The requirement for uniform speed during scanning is because when scanning at a uniform speed, the laser line hits the fixed interval of the steel bar end face at a fixed time interval, and has consistent continuity in time. The data obtained by the camera capturing the image for processing is correct; when the scanning speed is non-uniform, the laser line hits the steel bar end face at an unfixed interval, and the camera captures the image for processing and still thinks that the laser line is uniform. At this time, the data obtained is wrong. When the gyroscope is used, the gyroscope can completely record the movement trajectory of the measuring instrument. The movement state of the laser line can be known in real time. When the laser line moves at a non-uniform speed, the time when a certain laser line is left can be calculated based on the speed of movement, thereby ensuring continuity in time. After obtaining the corresponding relationship, the complete contour three-dimensional data of the steel bar end face can be obtained, and then the contour three-dimensional data can be processed.

[0069] In one implementation, the handheld steel bar counter also includes a shell 1, the line laser emitter, the binocular camera, the gyroscope, the data processing module and the manual operation control module are arranged inside the shell, the shell is provided with holes for line laser emission and binocular camera to acquire light, and the display screen is arranged at the top of the shell.

[0070] In one implementation, the handheld counter has a built-in power supply, and each component is connected via a power line and a data transmission line.

[0071] Figure 2 FIG. 1 shows a flow chart of scanning and counting steel bars according to an embodiment of the present specification. Figure 2 Provide a detailed introduction.

[0072] In one implementation, the data processing module obtains the steel bar end face contour diagram and steel bar number information according to the steel bar end face contour three-dimensional data and the corresponding relationship, including:

[0073] The data processing module quantifies the three-dimensional data and converts it into a grayscale image using a watershed transformation, and determines the center point and number of each steel bar according to the grayscale image.

[0074] In one implementation, the data processing module quantifies the three-dimensional data and converts it into a grayscale image using a watershed transform, and determines the center point and number of each steel bar according to the grayscale image, including:

[0075] The data processing module binarizes the obtained three-dimensional data of the complete contour of the steel bar end face according to a preset measurement distance range to obtain a binary image; when binarizing, for example, points falling within the measurement distance range can be set to 1, and points falling outside the measurement distance range can be set to 0, thereby obtaining a binary image;

[0076] Performing a watershed transform on the binary image to convert the binary image into a grayscale image;

[0077] The grayscale maximum value points in the grayscale image are marked as steel bar center points, and the number of steel bar center points obtained is counted to obtain the number of steel bars.

[0078] The quantization in the above embodiment is to convert the specific three-dimensional data into data that is easier to identify. For example, by binarization, the outline of the steel bar can be separated from the background. The specific way to perform binarization in this embodiment is to separate the steel bars and the steel bar gaps according to the distance, for example, 1 is within the distance and 0 is outside the distance. The grayscale maximum value point is found from the converted grayscale image and marked as the steel bar center point; the number of steel bar center points obtained is counted to obtain the number of steel bars.

[0079] Among them, the method of determining the center point of the steel bar is based on the grayscale maximum value. After the aforementioned watershed transformation, a grayscale image is obtained. The grayscale values ​​at different positions in the grayscale image are different. The maximum value of the grayscale value is found, and the maximum value point is the center point of the steel bar.

[0080] In one implementation, the data processing module analyzes and processes the left steel bar end face contour image and the right steel bar end face contour image to obtain three-dimensional steel bar end face contour data, including:

[0081] Performing stereoscopic correction on the left steel bar end face contour image and the right steel bar end face contour image, so that the corrected left steel bar end face contour image and the right steel bar end face contour image are aligned;

[0082] Matching the corrected left steel bar end face contour image and the right steel bar end face contour image to obtain a line laser imaging matching point pair;

[0083] The parallax of the left and right images is obtained according to the line laser imaging matching point pair, and the three-dimensional data of the steel bar end face contour is calculated according to the parallax of the left and right images.

[0084] In one implementation, the gyroscope calculates the current movement speed of the handheld steel bar counter and the angle between the line laser projection surface and the steel bar end surface, and obtains the corresponding relationship between the contour laser line group projected onto the steel bar end surface and the movement mode, including:

[0085] The gyroscope obtains the speed of the handheld steel bar counter at each moment, the angle between the laser line and the steel bar to be measured, and the movement direction of the handheld steel bar counter, and obtains the movement trajectory of the handheld steel bar counter according to the obtained speed at each moment, the angle between the laser line and the steel bar to be measured, and the movement direction of the handheld steel bar counter;

[0086] The actual position of the laser line during the scanning process is calculated according to the motion trajectory, specifically including: taking the first laser line emitted to the surface of the steel bar as the initial line, and recording the three-dimensional coordinates of each laser point on the initial line; during the scanning process, calculating the time interval between two laser lines according to the timestamps of each laser line and the next laser line acquired by the binocular camera; integrating the speed within the time interval according to the movement speed at each moment recorded by the gyroscope to obtain the distance between two adjacent laser lines; and determining the actual position of the next laser line on the surface of the steel bar according to the initial line and the distance between the two adjacent laser lines.

[0087] In one embodiment, the angle between the laser plane and the object to be measured when the laser line hits the surface of the object to be measured at any time during the operation of the handheld steel bar counter is obtained. The actual height of the object to be measured can be calculated based on the angle. The specific contents are as follows:

[0088] like Figure 3 As shown in the figure, when the line laser is directed obliquely at the object to be measured, the distance between the laser lines left on the upper and lower surfaces of the object is not the actual height of the object. After the angle is measured by the gyroscope, the actual depth can be calculated through mathematical operations. Assuming that the distance between the upper and lower surface laser lines is L, the actual height of the object is H, and the angle is θ, then H = L sinθ. Through mathematical operations, the height of the object at the projection of the upper surface laser line can be calculated in real time.

[0089] The speed of the counter is obtained. Based on the obtained speed and the timestamp left when the binocular camera takes the picture, the actual position of each laser line in the direction of movement can be calculated. When the counter does not move at a uniform speed, the laser lines left on the surface of the object are not uniform. If they are arranged in sequence only according to the timestamp, the obtained laser line group does not match the actual object contour. By arranging the laser lines according to the calculated actual position, an accurate object contour laser line group can be obtained, and then an accurate object 3D contour can be obtained.

[0090] The actual position calculation process of the laser line: specify the first laser line on the surface of the object as the initial line, and record the three-dimensional coordinates of each laser point on the laser line. When the counter moves, the binocular camera records the timestamps of the first laser line and the next laser line, and calculates the time interval between the two laser lines. On the other hand, the gyroscope records the movement speed of the counter in real time, and integrates the speed within this time interval to obtain the movement distance, so as to determine the actual position of the next laser line on the surface of the object.

[0091] When the laser line completely sweeps across the object to be measured, the gyroscope has recorded the movement state of the device in real time, that is, the speed of the device, the angle between the device and the object to be measured, and the direction of the counter movement, thereby restoring the movement trajectory of the counter. The above calculation process is used to calculate the three-dimensional data of each laser line, and the combined laser line group can restore the three-dimensional contour of the object to be measured.

[0092] In one implementation, before the line laser transmitter emits the line laser according to the control instruction of the manual operation control module and projects it onto the end face of the steel bar, the method further includes:

[0093] The left camera and the right camera of the binocular camera are stereo calibrated to obtain the intrinsic parameter matrix A of the binocular camera, the rotation matrix R and the translation vector T between the left camera and the right camera.

[0094] In one implementation, the left camera and the right camera of the binocular camera are stereo calibrated to obtain the intrinsic parameter matrix A of the binocular camera, the rotation matrix R and the translation vector T between the left camera and the right camera, including:

[0095] Calibrate the left camera and the right camera of the binocular camera respectively to obtain the intrinsic parameter matrix A of the binocular camera, the rotation matrix R1 of the left camera and the rotation matrix Rr of the right camera, and the translation vector T1 of the left camera and the translation vector Tr of the right camera;

[0096] The rotation matrix R and the translation vector T between the left camera and the right camera are calculated by the following formula:

[0097]

[0098] In one implementation, the stereoscopic correction of the left steel bar end face contour image and the right steel bar end face contour image comprises:

[0099] Decompose the rotation matrix R into two rotation matrices r1 and r r , where r1 and r r It is obtained by assuming that the left camera and the right camera are each rotated halfway so that the optical axes of the left camera and the right camera are parallel;

[0100] The alignment of the left steel bar end face contour image and the right steel bar end face contour image is achieved by the following formula:

[0101]

[0102] Among them, R rect The rotation matrix to align the rows:

[0103]

[0104] Rotation matrix R rect Starting from the direction of the pole e1, with the origin of the left steel bar end face contour image as the main point, the direction of the translation vector from the left camera to the right camera is the main point direction:

[0105]

[0106] e1 is orthogonal to e2, normalize e1 to the unit vector:

[0107]

[0108] Among them, T x is the horizontal component of the translation vector T in the plane where the binocular camera is located, T y is the vertical component of the translation vector T in the plane where the binocular camera is located;

[0109] e3 is orthogonal to e1 and e2, and e3 is calculated by the following formula:

[0110] e3=e2×e1

[0111] According to the above rotation matrix, the physical meaning is:

[0112]

[0113] Wherein, α represents the angle that the left camera and the right camera need to rotate in their planes to align the rows, 0≤α≤180°; for the left camera, it is rotated α' around the direction of e3, and for the right camera, it is rotated α" around the direction of e3.

[0114] In summary, the above embodiments of this specification achieve the following beneficial effects:

[0115] (1) A moving line laser and a binocular camera are used to obtain the end face profile image of the bundled steel bars. The number of steel bars is obtained by processing the end face profile image data. Since the line laser can perfectly restore the end face profile image information of the steel bars, and the binocular camera can stably obtain the laser line image, it can adapt to various lighting environments and has strong resistance to environmental interference. By quantifying the three-dimensional data and converting it into a grayscale image using a watershed transform, the center point and number of the steel bars are determined based on the grayscale image, and the number of steel bars can be quickly and accurately analyzed, solving the problem of time-consuming, low efficiency and low accuracy in counting piles or bundles of steel bars.

[0116] (2) The counter adopts a portable structure design, which is easy to use and can adapt to different usage scenarios.

[0117] (3) There is no need to limit the relative movement between the laser binocular camera and the steel bar to a uniform speed, which makes it easier to use.

[0118] Those skilled in the art can understand that the accompanying drawings are only schematic diagrams of an embodiment, and the modules or processes in the accompanying drawings are not necessarily required to implement the present invention.

[0119] Those skilled in the art can understand that the modules in the device in the embodiment can be distributed in the device in the embodiment according to the description of the embodiment, or can be changed accordingly and located in one or more devices different from the embodiment. The modules in the above embodiment can be combined into one module, or can be further divided into multiple sub-modules.

[0120] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A handheld steel bar counter, characterized in that: include: Line laser transmitter, binocular camera, gyroscope, data processing module, display screen, manual operation control module, including: The line laser transmitter emits a line laser according to the control instruction of the manual operation control module and projects it onto the end face of the steel bar, and when the line laser is projected onto the end face of the steel bar, a contour laser line of the end face of the steel bar is obtained; The binocular camera acquires a left steel bar end face contour image and a right steel bar end face contour image with the contour laser line, wherein the parameters of the left camera and the right camera of the binocular camera are the same; The data processing module analyzes and processes the left steel bar end face contour image and the right steel bar end face contour image to obtain three-dimensional steel bar end face contour data; The gyroscope measures the current movement speed of the handheld steel bar counter and the angle between the linear laser projection surface and the steel bar end surface; The data processing module calculates the corresponding relationship between the contour laser line group projected onto the end face of the steel bar and the movement mode according to the current movement speed of the handheld steel bar counter and the angle between the line laser projection surface and the end face of the steel bar, wherein the movement mode includes the movement speed of the handheld steel bar counter and the angle between the line laser projection surface and the end face of the steel bar; and obtains the steel bar end face contour map and steel bar number information according to the three-dimensional data of the steel bar end face contour and the corresponding relationship; The display screen is used to display the steel bar end face profile and steel bar number information; The data processing module analyzes and processes the left steel bar end face contour image and the right steel bar end face contour image to obtain three-dimensional steel bar end face contour data, including: Performing stereoscopic correction on the left steel bar end face contour image and the right steel bar end face contour image, so that the corrected left steel bar end face contour image and the right steel bar end face contour image are aligned; Matching the corrected left steel bar end face contour image and the right steel bar end face contour image to obtain a line laser imaging matching point pair; Obtaining left and right image parallaxes according to the line laser imaging matching point pairs, and calculating and obtaining three-dimensional data of the steel bar end face contour according to the left and right image parallaxes; The gyroscope calculates the current movement speed of the handheld steel bar counter and the angle between the line laser projection surface and the steel bar end surface, and obtains the corresponding relationship between the contour laser line group projected onto the steel bar end surface and the movement mode, including: The gyroscope obtains the speed of the handheld steel bar counter at each moment, the angle between the laser line and the steel bar to be measured, and the movement direction of the handheld steel bar counter, and obtains the movement trajectory of the handheld steel bar counter according to the obtained speed at each moment, the angle between the laser line and the steel bar to be measured, and the movement direction of the handheld steel bar counter; The actual position of the laser line during the scanning process is calculated according to the motion trajectory, specifically including: taking the first laser line emitted to the steel bar surface as the initial line, and recording the three-dimensional coordinates of each laser point on the initial line; during the scanning process, according to the timestamps of each laser line and the next laser line acquired by the binocular camera, calculating the time interval between the two laser lines; according to the motion speed at each moment recorded by the gyroscope, integrating the speed within the time interval to obtain the distance between two adjacent laser lines; according to the initial line and the distance between the two adjacent laser lines and the angle between the laser line and the steel bar to be measured, calculating the actual position of the next laser line on the steel bar surface, the calculation formula is specifically as follows: H=L sinθ In the above formula, H is the actual height of the next laser line on the steel bar surface, L is the distance between two adjacent laser lines, and θ is the angle between the laser line and the steel bar to be measured.

2. The handheld steel bar counter according to claim 1 is characterized in that: The data processing module obtains the steel bar end face contour diagram and steel bar number information according to the steel bar end face contour three-dimensional data and the corresponding relationship, including: The data processing module quantifies the three-dimensional data and converts it into a grayscale image using a watershed transformation, and determines the center point and number of each steel bar according to the grayscale image.

3. The handheld steel bar counter according to claim 2 is characterized in that: The data processing module quantifies the three-dimensional data and converts it into a grayscale image using a watershed transform, and determines the center point and number of each steel bar according to the grayscale image, including: The data processing module binarizes the obtained three-dimensional data of the complete contour of the steel bar end face according to a preset measurement distance range to obtain a binary image; Performing a watershed transform on the binary image to convert the binary image into a grayscale image; The grayscale maximum value points in the grayscale image are marked as steel bar center points, and the number of steel bar center points obtained is counted to obtain the number of steel bars.

4. The handheld steel bar counter according to any one of claims 1 to 3, characterized in that: Before the line laser transmitter emits the line laser according to the control instruction of the manual operation control module and projects it onto the end face of the steel bar, the method further comprises: The left camera and the right camera of the binocular camera are stereo calibrated to obtain the intrinsic parameter matrix A of the binocular camera, the rotation matrix R and the translation vector T between the left camera and the right camera.

5. The handheld steel bar counter according to any one of claims 1 to 4, characterized in that: The stereo calibration of the left camera and the right camera of the binocular camera to obtain the intrinsic parameter matrix A of the binocular camera, the rotation matrix R between the left camera and the right camera, and the translation vector T include: Calibrate the left camera and the right camera of the binocular camera respectively to obtain the intrinsic parameter matrix A of the binocular camera, the rotation matrix R1 of the left camera and the rotation matrix Rr of the right camera, and the translation vector T1 of the left camera and the translation vector Tr of the right camera; The rotation matrix R and the translation vector T between the left camera and the right camera are calculated by the following formula:

6. The handheld steel bar counter according to claim 5, characterized in that: The stereoscopic correction of the left steel bar end face contour image and the right steel bar end face contour image comprises: Decompose the rotation matrix R into two rotation matrices r1 and r r , where r1 and r r It is obtained by assuming that the left camera and the right camera are each rotated halfway so that the optical axes of the left camera and the right camera are parallel; The alignment of the left steel bar end face contour image and the right steel bar end face contour image is achieved by the following formula: Among them, R rect The rotation matrix to align the rows: Rotation matrix R rect Starting from the direction of the pole e1, with the origin of the left steel bar end face contour image as the main point, the direction of the translation vector from the left camera to the right camera is the main point direction: e1 is orthogonal to e2, normalize e1 to the unit vector: Among them, T x is the horizontal component of the translation vector T in the plane where the binocular camera is located, T y is the vertical component of the translation vector T in the plane where the binocular camera is located; e3 is orthogonal to e1 and e2, and e3 is calculated by the following formula: e3=e2×e1 According to the above rotation matrix, the physical meaning is: Wherein, α represents the angle that the left camera and the right camera need to rotate in their planes to align the rows, 0≤α≤180°; for the left camera, it is rotated α' around the direction of e3, and for the right camera, it is rotated α" around the direction of e3.

7. The handheld steel bar counter according to claim 1, characterized in that: It also includes a shell, the line laser transmitter, the binocular camera, the gyroscope, the data processing module and the manual operation control module are arranged inside the shell, the shell is provided with holes for line laser emission and binocular camera to acquire light, and the display screen is arranged at the top of the shell.

8. The handheld steel bar counter according to claim 1, characterized in that: The handheld counter has a built-in power supply, and each component is connected via a power line and a data transmission line.

Citation Information

Patent Citations

  • Method for counting number of reinforced steel bars based on computer vision

    CN105303233A

  • Linear laser scanning three-dimensional contour measuring method and device

    CN103900489A

  • Visual reversing method based on stereoscopic vision

    CN106183995A

  • Binocular stereo vision three-dimensional measurement method based on line structured light scanning

    CN107907048A