Road marking method based on visual standard sample points
By marking marking samples on the road, combining wheel odometer and IMU data, using camera image processing and HSV color space analysis, adjusting the scribing mechanism posture, the problems of low manual operation efficiency and low sensor accuracy in the prior art are solved, and efficient and high-precision road marking is achieved.
Patent Information
- Application Number
- CN202510926303.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-07
- Publication Date
- 2025-08-01
- Estimated Expiration
- 2045-07-07
AI Technical Summary
The existing road marking method relies on manual operation and is inefficient. The traditional positioning navigation sensors have low positioning accuracy in complex environments, which is affected by environmental factors and cumulative errors.
The road marking method based on visual standard specimens, by marking multiple standard specimens on the road to be marked, the current posture is obtained using the fusion data of the wheel odometer and the IMU, and combined with camera image processing and HSV color space analysis, the scribing mechanism posture is adjusted to achieve accurate scribing.
It realizes high-precision and stable road marking in complex environments, reduces the time-consuming and labor-intensive manual operation, and improves the marking efficiency and accuracy.
Smart Images

Figure CN120406107A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of automatic road marking, and in particular, to a road marking method based on visual reference points. Background Art
[0002] Traditional road marking is completed by manual operation, which relies on manual operation and judgment. The quality and efficiency of marking are affected by the skills and experience of operators, and it is difficult to meet the heavy road marking work in China at present. Therefore, road marking can be combined with modern science and technology to improve the efficiency and quality of marking.
[0003] However, some existing technologies have certain defects. For example, GPS (Global Positioning System) is difficult to achieve accurate positioning in urban high-rise building shading, tunnels, and indoor environments, and it is difficult to achieve high-precision and high-stability positioning in complex urban environments; traditional sensors such as WO (Wheel Odometer) and IMU (Inertial Measurement Unit) are prone to problems such as ground slippage and system cumulative error during long-term operation, resulting in a decrease in positioning accuracy.
[0004] Therefore, there is an urgent need for a road marking method that can solve the problems of high cost, low efficiency, and long time consumption of traditional road marking methods, as well as the limitations of various positioning and navigation sensors due to environmental factors and cumulative error effects. Summary of the Invention
[0005] Based on this, the purpose of the present invention is to provide a road marking method based on visual reference points to solve the deficiencies in the prior art.
[0006] To achieve the above purpose, the present invention provides a road marking method based on visual reference points, and the method includes: Mark a plurality of reference points on the road to be marked, start the marking operation, obtain the current pose of the marking mechanism based on the fusion data of the wheel odometer and the IMU, and obtain the current pose error based on the current pose; When the current pose error is less than the preset threshold and exceeds the allowable marking error range, use a camera to collect images of the reference points to obtain an initial image, where the camera is installed on the marking mechanism; Perform image processing on the initial image to obtain an HSV color image, mark the contour of the reference points based on the HSV color image, and calculate the feature center of the reference points; Construct a bounding circle with the feature center of the reference points as the center and the preset threshold as the radius, judge the position relationship between the image anchor point and the bounding circle, and adjust the pose of the marking mechanism based on the judgment result to perform road marking.
[0007] The beneficial effects of the present invention are as follows: by marking multiple reference points on a road to be marked, after starting the road marking operation, the current posture of the road marking mechanism is obtained based on the fusion data of the wheel odometer and the IMU, and the current posture error is obtained based on the current posture. When the current posture error is less than a preset threshold and exceeds the allowable error range of road marking, the camera on the road marking mechanism is used to capture an image of the reference points to obtain an initial image, and the initial image is processed to obtain an HSV color image. The contours of the reference points are marked using the HSV color image, and the characteristic centers of the reference points are calculated and obtained. Then, a defining circle is constructed with the characteristic centers of the reference points as the circle center and a preset threshold as the radius. By determining the positional relationship between the image anchor point and the defining circle, the posture of the road marking mechanism is adjusted to achieve accurate and stable road marking operation. The problem of time-consuming, labor-intensive and inefficient road marking operation caused by relying on manual operation and judgment is solved, and the problem of inaccurate road marking caused by various positioning and navigation sensors being limited by environmental factors and accumulated errors is solved.
[0008] Furthermore, the method further comprises: The defined circle is divided into eight regions by determining one region every π / 4 in a clockwise direction, wherein the eight regions are a first region, a second region, a third region, a fourth region, a fifth region, a sixth region, a seventh region, and an eighth region; A rectangular coordinate system is established with the center of the defined circle as the origin, the axis of symmetry of the first region or the fifth region as the Y axis, and the axis of symmetry of the third region or the seventh region as the X axis.
[0009] Furthermore, the step of adjusting the posture of the marking mechanism based on the judgment result includes: When the image anchor point is located within the first area and close to the right side of the Y-axis, controlling the marking mechanism to move leftward; When the image anchor point is located within the first area and close to the left side of the Y-axis, controlling the marking mechanism to move rightward; When the image anchor point is located within the second area and close to the symmetry axis of the second area, controlling the marking mechanism to move leftward; When the image anchor point is located within the third area and close to the symmetry axis of the third area, controlling the marking mechanism to move leftward; When the image anchor point is located within the fourth region and close to the symmetry axis of the fourth region, controlling the marking mechanism to move leftward; When the image anchor point is located within the fifth area and close to the right side of the Y-axis, controlling the scribing mechanism to move leftward; When the image anchor point is located within the fifth region and close to the left side of the Y-axis, control the scribing mechanism to move to the right; When the image anchor point is located within the sixth region and close to the position of the axis of symmetry of the sixth region, control the scribing mechanism to move to the right; When the image anchor point is located within the seventh region and close to the position of the axis of symmetry of the seventh region, control the scribing mechanism to move to the right; When the image anchor point is located within the eighth region and close to the position of the axis of symmetry of the eighth region, control the scribing mechanism to move to the right.
[0010] Further, the method further includes: Obtain the lateral deviation amount of the scribing mechanism, compare the lateral deviation amount with a preset initial condition, and adjust the proportional gain of the adaptive PID controller based on the comparison result to perform an adjustment operation on the scribing mechanism.
[0011] Further, the calculation formula of the feature center is as follows:
[0012] where max(d) represents the distance between the two sets of points M and N that are farthest apart, represents the circumcircle, represents the feature center of the standard sample points, m1 and m2 both represent elements in the point set M, and n1 and n2 both represent elements in the point set N.
[0013] Further, before starting the scribing operation, the method further includes: Calibrate the wheel odometer, and jointly calibrate the camera and the IMU through the Kalibr toolbox; Adjust the position of the scribing mechanism according to the driving direction, and set the scribing distance between the scribing mechanism and the standard sample points. The expression of the scribing distance is as follows:
[0014] where, represents the scribing distance, represents the lateral offset between the camera and the standard sample points, represents the lateral offset between the camera and the movement center, represents the lateral offset between the movement center and the scribing mechanism.
[0015] Further, the method further includes: When the current attitude error is less than the preset threshold and exceeds the scribing allowable error range, reset the fusion data of the wheel odometer and the IMU; When the current attitude error is less than the preset threshold and less than the allowable error range of the scribing, normal scribing operation is performed.
[0016] Further, the method further includes: When the current attitude error is greater than the preset threshold, the buzzer is activated for warning and the scribing operation is stopped. Description of the Drawings
[0017] Figure 1 It is a flowchart of a road scribing method based on visual fiducial points according to an embodiment of the present invention; Figure 2 It is a schematic diagram of a scribing mechanism according to an embodiment of the present invention; Figure 3 It is a schematic diagram of the positional relationship between different regions of a defined circle and image anchor points according to an embodiment of the present invention; Figure 4 It is a schematic diagram of the characteristic center of a fiducial point according to an embodiment of the present invention; Figure 5 It is a schematic diagram of the principle of an adaptive PID controller controlling the scribing mechanism to perform attitude adjustment operation according to an embodiment of the present invention; Figure 6 It is an application schematic diagram of a road scribing method based on visual fiducial points according to an embodiment of the present invention.
[0018] The following specific embodiments will further illustrate the present invention in conjunction with the above-mentioned drawings. Specific Embodiments
[0019] In order to make the objectives, technical solutions and advantages of the present application clearer, the present application will be described and explained below in conjunction with the drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application. All other embodiments obtained by those of ordinary skill in the art based on the embodiments provided in the present application without creative efforts fall within the scope of protection of the present application.
[0020] Obviously, the drawings in the following description are only some examples or embodiments of the present application. For those of ordinary skill in the art, without creative efforts, the present application can also be applied to other similar scenarios based on these drawings. In addition, it can also be understood that although the efforts made in this development process may be complex and lengthy, for those of ordinary skill in the art related to the content disclosed in the present application, some design, manufacturing or production changes made on the basis of the technical content disclosed in the present application are only conventional technical means and should not be understood that the content disclosed in the present application is insufficient.
[0021] References herein to "embodiments" mean that a particular feature, structure, or characteristic described in connection with an embodiment can be included in at least one embodiment of the present application. The phrase appears in various places in the specification and does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment mutually exclusive of other embodiments. It is explicitly and implicitly understood by those of ordinary skill in the art that the embodiments described in the present application can be combined with other embodiments without conflict.
[0022] Unless otherwise defined, technical terms or scientific terms involved in this application shall have the ordinary meaning as understood by those of ordinary skill in the technical field to which this application pertains. The words such as "a", "an", "one", "the" and the like involved in this application do not denote a limitation of quantity and can represent a singular or plural number. The terms "comprising", "including", "having" and any variations thereof involved in this application are intended to cover non-exclusive inclusion; for example, a process, method, system, product or device that includes a series of steps or modules (units) is not limited to the steps or units listed, but may further include steps or units not listed, or may further include other steps or units inherent to these processes, methods, products or devices. The terms "connected", "coupled" and the like involved in this application are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. The term "plurality" involved in this application means two or more. "And / or" describes the association relationship of associated objects and indicates that three relationships may exist. For example, "A and / or B" may represent: A exists alone, A and B exist simultaneously, and B exists alone. The character " / " generally represents an "or" relationship between the associated objects before and after. The terms "first", "second", "third", etc. involved in this application are only used to distinguish similar objects and do not represent a specific order of the objects.
[0023] Embodiment 1 Please refer to Figures 1-6 , the method for road marking based on visual fiducial points in the first embodiment of the present invention, as Figure 1 shown, the method includes the following steps: Step S101: Mark a plurality of fiducial points on the road to be marked, start the marking operation, obtain the current pose of the marking mechanism based on the fused data of the wheel odometer and the IMU, and obtain the current pose error based on the current pose; Among them, the number of the standard sample points is determined according to the road marking plan. The wheel odometer and the IMU (Inertial Measurement Unit) are both installed on the marking mechanism. The wheel odometer is equipped with a high-precision encoder, which can measure the rotation speed of the coded motor of the marking mechanism, so as to infer the pose (displacement and attitude) of the marking mechanism. The IMU includes an accelerometer and a gyroscope, and the two respectively measure the acceleration and angular velocity of each axis of the marking mechanism, so as to measure the attitude of the marking mechanism. However, in practical applications, the wheel odometer and the IMU are affected by slipping, temperature drift, noise, etc., resulting in system cumulative errors. Therefore, it is necessary to fuse the data of the two to reduce the influence of errors and obtain a more accurate attitude.
[0024] It should be noted that the step of obtaining the current pose error based on the current pose is specifically as follows: the offset in the horizontal direction can be calculated through the obtained current pose, and the projections in each direction are calculated by constructing a vector triangle, so as to obtain the current pose error.
[0025] Step S102: When the current pose error is less than the preset threshold and exceeds the allowable error range of marking, the camera is used to collect images of the standard sample points to obtain an initial image, where the camera is arranged on the marking mechanism; Among them, the current pose error is first compared with the preset threshold. When the current pose error is less than the preset threshold, the current pose error is then compared with the allowable error range of marking.
[0026] Further, the method further includes: When the current pose error is greater than the preset threshold, the buzzer is activated to give a warning and the marking operation is stopped.
[0027] Step S103: Perform image processing on the initial image to obtain an HSV color image, mark the contour of the standard sample points based on the HSV color image, and calculate the characteristic center of the standard sample points; Among them, RGB (Red, Green, Blue) is a hardware-based color representation, and HSV (Hue, Saturation, Value) is more in line with the intuitive perception of color by the human eye. The value (V) channel in the HSV space is directly related to the light intensity, while the hue (H) and saturation (S) channels are relatively insensitive to light changes. This makes it more stable to use the HSV space for color segmentation and recognition under changing lighting conditions. And in image processing algorithms, using the HSV space can simplify the calculation process and improve the calculation efficiency. Therefore, in this application, the original image is adjusted and processed into an HSV color image in the HSV space. Further, the step of performing image processing on the initial image includes: The initial image is successively subjected to panoramic image filtering, near-view image processing, bilateral filtering, and color conversion processing.
[0028] Furthermore, the circumscribed contour of the standard sample point is obtained, and the circumscribed circle with the maximum diameter in the circumscribed contour is calculated. The coordinates of the pixel point in the HSV color image where the center of the circumscribed circle with the maximum diameter is located are the characteristic center of the standard sample point.
[0029] The calculation formula for the characteristic center of the standard sample point is as follows:
[0030] where, is the characteristic center of the standard sample point, is the maximum diameter of the circumscribed contour, is the circumscribed circle with the maximum diameter.
[0031] Step S104: Construct a defining circle with the characteristic center of the standard sample point as the center and the preset threshold as the radius, judge the position relationship between the image anchor point and the defining circle, and adjust the posture of the line marking mechanism based on the judgment result to perform road line marking.
[0032] Among them, the preset threshold can judge the deviation degree of the line marking mechanism. Therefore, a defining circle is constructed with the preset threshold as the radius. When the image anchor point is located within the defining circle, it indicates that the deviation between the line marking mechanism and the road section to be marked is within a reasonable adjustment range. It should be noted that different line marking scenarios have different line marking standards. In some places with high line marking accuracy, the error is between 1 cm and 3 cm. The preset threshold is determined according to these line marking standards to ensure that the line marking accuracy can reach the standard.
[0033] In addition, the defining circle is determined by the standard sample point, and the standard sample point is a precise point placed in advance on the road section to be marked. If the relative position between the image anchor point and the defining circle remains unchanged, it ensures that the posture of the line marking mechanism is correct at each point, thereby ensuring the accuracy of line marking. Therefore, the position of the image anchor point can be judged with reference to this defining circle.
[0034] Through the above steps, a plurality of standard sample points are marked on the road to be marked. After starting the line marking operation, the current pose of the line marking mechanism is obtained based on the fused data of the wheel odometer and the IMU, and the current pose error is obtained based on the current pose. When the current pose error is less than the preset threshold and exceeds the allowable error range of line marking, the camera on the line marking mechanism is used to collect images of the standard sample points to obtain an initial image, and the initial image is processed to obtain an HSV color image, so as to mark the contour of the standard sample points through the HSV color image, and calculate and obtain the feature center of the standard sample points. Then, a defining circle is constructed with the feature center of the standard sample points as the center and the preset threshold as the radius. By judging the position relationship between the image anchor points and the defining circle, the pose of the line marking mechanism is adjusted to achieve accurate and stable road line marking operations, solving the problems of time-consuming and laborious line marking operations and low efficiency caused by manual operation and judgment in existing road line marking, and also solving the problem of inaccurate line marking caused by various positioning and navigation sensors being limited by environmental factors and cumulative errors.
[0035] Further, before starting the line marking operation, the method further includes: Calibrate the wheel odometer, and jointly calibrate the camera and the IMU through the Kalibr toolkit; Among them, the wheel odometer is driven in a straight line distance and rotated in place by the line marking machine, and the straight line parameters and rotation angle parameters of the wheel odometer are calibrated until the errors of the right angle parameters and the rotation angle parameters reach the corresponding wheel odometer thresholds, then the calibration operation of the wheel odometer is completed.
[0036] Adjust the position of the line marking mechanism according to the driving direction, and set the line marking distance between the line marking mechanism and the standard sample points. The expression of the line marking distance is as follows:
[0037] Among them, represents the line marking distance, represents the lateral offset between the camera of the camera and the standard sample point, represents the lateral offset between the camera of the camera and the movement center, represents the lateral offset between the movement center and the line marking mechanism. The line marking mechanism is a differential mobile robot, and the movement center refers to the center of the connection line of the left and right two independent drive wheels on the mobile robot.
[0038] It should be noted that as Figure 2 shown, the line marking mechanism includes a circumferential slide rail 1, a rectangular slide rail 2, a telescopic arm 3 and a line marking structure 4. The line marking structure 4 can adjust its position and lateral offset from the movement center according to the circumferential slide rail 1, the rectangular slide rail 2 and the telescopic arm 3 , let the total length of the rectangular slide rail 2 and the telescopic arm 3 be , and the angle between the rectangular slide rail 2 and the driving direction be , then .
[0039] Furthermore, the method further includes: When the current attitude error is less than the preset threshold and exceeds the allowable error range of the marking, reset the fusion data of the wheel odometer and the IMU; When the current attitude error is less than the preset threshold and less than the allowable error range of the marking, perform normal marking operation.
[0040] Furthermore, the method further includes: By determining each π / 4 clockwise as a region, divide the defined circle into 8 such regions, where the 8 regions are the first region, the second region, the third region, the fourth region, the fifth region, the sixth region, the seventh region, and the eighth region respectively; Taking the center of the defined circle as the origin, taking the symmetry axis of the first region or the fifth region as the Y-axis, and taking the symmetry axis of the third region or the seventh region as the X-axis, establish a rectangular coordinate system.
[0041] Among them, as Figure 3 shown, the symmetry axis of the first region is defined as the 0 position or the 2π position relative to the defined circle. Similarly, the symmetry axis of the second region is defined as position, the symmetry axis of the third region is defined as position, the symmetry axis of the fourth region is defined as position, the symmetry axis of the fifth region is defined as position, the symmetry axis of the sixth region is defined as position, the symmetry axis of the seventh region is defined as position, and the symmetry axis of the eighth region is defined as position.
[0042] Furthermore, the step of adjusting the attitude of the marking mechanism based on the judgment result includes: When the image anchor point is located within the first region and close to the right side of the Y-axis, control the marking mechanism to move left; When the image anchor point is located within the first region and close to the left side of the Y-axis, control the marking mechanism to move right; When the image anchor point is located within the second region and close to the position of the symmetry axis of the second region, control the marking mechanism to move left; When the image anchor point is located within the third region and close to the axis of symmetry of the third region, control the scribing mechanism to move leftward; When the image anchor point is located within the fourth region and close to the axis of symmetry of the fourth region, control the scribing mechanism to move leftward; When the image anchor point is located within the fifth region and to the right of the Y-axis, control the scribing mechanism to move leftward; When the image anchor point is located within the fifth region and to the left of the Y-axis, control the scribing mechanism to move rightward; When the image anchor point is located within the sixth region and close to the axis of symmetry of the sixth region, control the scribing mechanism to move rightward; When the image anchor point is located within the seventh region and close to the axis of symmetry of the seventh region, control the scribing mechanism to move rightward; When the image anchor point is located within the eighth region and close to the axis of symmetry of the eighth region, control the scribing mechanism to move rightward.
[0043] Among them, if the image anchor point is within the defined circle and close to the 0 position, if it is to the right of the 0 position, the scribing mechanism moves leftward, and if it is to the left of the 0 position, the scribing mechanism moves rightward; if the image anchor point is within the defined circle and close to the position, the lateral deviation of the scribing mechanism is to the right, and the scribing mechanism needs to move leftward; if the image anchor point is within the defined circle and close to the position, the lateral deviation of the scribing mechanism is to the right, and the scribing mechanism needs to move leftward; if the image anchor point is within the defined circle and close to the position, the lateral deviation of the scribing mechanism is to the right, and the scribing mechanism needs to move leftward; if the image anchor point is within the defined circle and close to the position, if it is to the right of the position, the scribing mechanism needs to move leftward, and if it is to the left of the position, the scribing mechanism moves rightward; if the image anchor point is within the defined circle and close to the position, the lateral deviation of the scribing mechanism is to the left, and the scribing mechanism needs to move rightward; if the image anchor point is within the defined circle and close to the position, the lateral deviation of the scribing mechanism is to the left, and the scribing mechanism needs to move rightward; if the image anchor point is within the defined circle and close to the position, the lateral deviation of the scribing mechanism is to the left, and the scribing mechanism needs to move rightward.
[0044] It should be noted that the deviation value between the image anchor point and the feature center is calculated first, and this deviation value is compared with the preset threshold to determine whether the image anchor point is located within the defined circle, and then the next judgment is made. Among them, the deviation value between the image anchor point and the feature center of the standard sample point is calculated as follows:
[0045] where, represents the coordinates of the image anchor point, represents the feature center of the standard sample point.
[0046] When it is judged that the image anchor point is located within the defined circle and the image anchor point is not the center of the defined circle, that is, the deviation value preset threshold , and the deviation value , then based on the complementary angle of the angle between the line connecting the image anchor point and the center of the defined circle and the horizontal direction, the attitude of the scribing mechanism is adjusted. Specifically, defining the preset small amount as , the following can be obtained: If , and within , within If , then it is to the left. If , then it is to the left. If , then it is to the left. If , and within , within ; If , then it is to the right. If , then it is to the right. If , then it is to the right.
[0047] Furthermore, the calculation formula of the feature center is as follows:
[0048] where, max(d) represents the distance between the two sets of points M and N that are farthest apart, that is, the maximum diameter of the circumscribed contour, represents the circumscribed circle, represents the feature center of the standard sample point, and m1, m2 both represent the elements in the point set M, and n1, n2 both represent the elements in the point set N.
[0049] It should be noted that as Figure 4 shown, it is a schematic diagram of the feature center of the standard sample point.
[0050] Furthermore, the method further includes: Obtain the lateral deviation amount of the scribing mechanism, compare the lateral deviation amount with a preset initial condition, and adjust the proportional gain of the adaptive PID controller based on the comparison result to perform an adjustment operation on the scribing mechanism.
[0051] Among them, as Figure 5 shown, it is a schematic diagram of controlling the scribing mechanism to perform attitude adjustment operations through an adaptive PID controller. Specifically, the preset initial conditions include a first initial threshold T1 and a second initial threshold T2. When the image anchor point is within the first region and the fifth region, the lateral deviation amount of the scribing mechanism is small, that is, the lateral deviation amount E is less than the first initial threshold T1, then the proportional gain is reduced; When the image anchor point is within the second region, the fourth region, the sixth region, and the eighth region, the lateral deviation amount of the scribing mechanism is moderate, that is, the lateral deviation amount E is greater than the first initial threshold T1 and less than the second initial threshold T2, then the proportional gain is maintained or moderately increased; When the image anchor point is within the third region and the seventh region, the lateral deviation amount of the scribing mechanism is large, that is, the lateral deviation value E is greater than the second initial threshold T2, the proportional gain is increased.
[0052] It should be noted that by adjusting and updating the proportional gain of the adaptive PID controller, the latest system output value U is obtained. This system output U is also the input value of the left and right coded motors of the scribing mechanism. That is, after the adaptive PID algorithm, the speed difference of the left and right coded motors is controlled. Through this system output value U, the left and right two coded motors of the independent drive wheels used to control the scribing mechanism are controlled to control the scribing mechanism to perform attitude adjustment. At the same time, the actual output value Y of the coded motors (the image deviation amount value actually obtained after adjusting the speed difference of the left and right coded motors) will be fed back to the adaptive PID controller to form a closed-loop control. It should be noted that the entire control system is in a process of cyclic adjustment until the target value is reached, and the adaptive PID controller acts through the combined action of proportional control, integral control, and derivative control to regulate the coded motors.
[0053] Furthermore, the expression of the lateral deviation amount E is as follows:
[0054] The expression of proportional control P is as follows:
[0055] The expression of integral control I is as follows:
[0056] The expression of derivative control D is as follows:
[0057] The expression of the total control Q of the adaptive PID controller is as follows:
[0058] Where R is the expected value, is the actual output value of the encoding motor in the previous time, t is the time, is the integral gain, is the differential gain, is the proportional gain.
[0059] Furthermore, the expressions for filtering the long-range image and processing the short-range image of the initial image are as follows:
[0060] Where, represents the acquired image, represents the height of the image, represents the width of the image, both represent the pixel points of the image.
[0061] The expression for converting the color space of the image is as follows:
[0062]
[0063]
[0064]
[0065] Where, represents the normalized RGB value, represents the maximum RGB value, represents the minimum RGB value, represents the difference between the maximum RGB value and the minimum RGB value, represents the hue, S represents the saturation, and V represents the brightness.
[0066] Embodiment 2 In the second embodiment of the present invention, based on the same inventive concept, a computer-readable storage medium is proposed. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the above-mentioned road marking method based on visual calibration points in the embodiment are realized.
[0067] Logic and / or steps represented in a flowchart or otherwise described herein can, for example, be considered a sequenced listing of executable instructions for implementing logical functions and can be embodied in any computer-readable medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, a system including a processor, or other systems that can fetch and execute instructions from the instruction execution system, apparatus, or device. As used in this specification, a "computer-readable medium" can be any device that can contain, communicate, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device.
[0068] More specific examples (a non-exhaustive list) of the computer-readable medium include the following: an electrical connection having one or more wires (electronic device), a portable computer diskette (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, the computer-readable medium can even be paper or other suitable medium upon which the program can be printed, as the program can be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, interpretation, or other suitable processing as necessary, and then storing it in a computer memory.
[0069] Among them, the memory may include a mass storage for data or instructions. By way of example and not limitation, the memory may include a hard disk drive (HDD), a floppy disk drive, a solid state drive (SSD), a flash memory, an optical disc, a magneto-optical disc, a magnetic tape, or a universal serial bus (USB) drive, or a combination of two or more of these. In suitable cases, the memory may include removable or non-removable (or fixed) media. In suitable cases, the memory may be internal or external to the data processing device. In a particular embodiment, the memory is a non-volatile memory. In a particular embodiment, the memory includes a read-only memory (ROM) and a random access memory (RAM). In suitable cases, the ROM may be a mask-programmed ROM, a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (EEPROM), an electrically alterable ROM (EAROM), or a flash memory, or a combination of two or more of these. In suitable cases, the RAM may be a static random access memory (SRAM) or a dynamic random access memory (DRAM), where the DRAM may be a fast page mode dynamic random access memory (FPMDRAM), an extended date out dynamic random access memory (EDODRAM), a synchronous dynamic random access memory (SDRAM), etc.
[0070] Embodiment III For the third embodiment of the present invention, based on the same inventive concept, a terminal proposed by the present invention includes: a processor and a memory; the processor and the memory communicate with each other; the memory is used to store instructions; the processor is used to execute the instructions in the memory and execute the road marking method based on visual standard points in the above embodiment.
[0071] It should be understood that each part of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above embodiment, multiple steps or methods can be implemented by software or firmware stored in the memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, any one or a combination of the following technologies well known in the art can be used: discrete logic circuits with logic gate circuits for implementing logical functions on data signals, application specific integrated circuits with appropriate combinational logic gate circuits, programmable gate arrays (PGAs), field programmable gate arrays (FPGAs), etc.
[0072] In the description of this specification, the description with reference to terms such as "one embodiment", "some embodiments", "example", "specific example", or "some examples" means that the specific features, structures, materials, or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in a suitable manner in any one or more embodiments or examples.
[0073] On the premise of no conflict, those skilled in the art can freely combine and superimpose the above additional technical features.
[0074] The above are only the preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent replacements, and improvements made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims
1. A road marking method based on visual standard points, characterized in that, The method includes: Marking a plurality of standard sample points on the road to be marked, starting the line marking operation, obtaining the current pose of the line marking mechanism based on the fusion data of the wheel odometer and the IMU, and obtaining the current pose error based on the current pose; When the current pose error is less than a preset threshold and exceeds the allowable error range of line marking, the camera is used to collect an image of the standard sample points to obtain an initial image, wherein the camera is arranged on the line marking mechanism; Performing image processing on the initial image to obtain an HSV color image, marking the contour of the standard sample points based on the HSV color image, and calculating the characteristic center of the standard sample points; Constructing a defining circle with the characteristic center of the standard sample points as the center and the preset threshold as the radius, judging the position relationship between the image anchor point and the defining circle, and adjusting the pose of the line marking mechanism based on the judgment result for road line marking.
2. The road marking method based on visual standard points according to claim 1, characterized in that, The method further includes: Determining each π / 4 in the clockwise direction as a region to divide the defining circle into 8 such regions, where the 8 regions are respectively the first region, the second region, the third region, the fourth region, the fifth region, the sixth region, the seventh region, and the eighth region; Taking the center of the defining circle as the origin, taking the symmetry axis of the first region or the fifth region as the Y-axis, and taking the symmetry axis of the third region or the seventh region as the X-axis to establish a rectangular coordinate system.
3. The method for road marking based on visual fiducial points according to claim 2, wherein The step of adjusting the pose of the line marking mechanism based on the judgment result includes: When the image anchor point is located within the first region and close to the right side of the Y-axis, controlling the line marking mechanism to move left; When the image anchor point is located within the first region and close to the left side of the Y-axis, controlling the line marking mechanism to move right; When the image anchor point is located within the second region and close to the symmetry axis of the second region, controlling the line marking mechanism to move left; When the image anchor point is located within the third region and close to the symmetry axis of the third region, controlling the line marking mechanism to move left; When the image anchor point is located within the fourth region and close to the symmetry axis of the fourth region, controlling the line marking mechanism to move left; When the image anchor point is located within the fifth region and close to the right side of the Y-axis, controlling the line marking mechanism to move left; When the image anchor point is located within the fifth region and close to the left side of the Y-axis, controlling the line marking mechanism to move right; When the image anchor point is located within the sixth region and close to the symmetry axis of the sixth region, controlling the line marking mechanism to move right; When the image anchor point is located within the seventh region and close to the symmetry axis of the seventh region, controlling the line marking mechanism to move right; When the image anchor point is located within the eighth region and close to the symmetry axis of the eighth region, controlling the line marking mechanism to move right.
4. The road marking method based on visual standard points according to claim 2, characterized in that The method further includes: Obtain the lateral deviation amount of the scribing mechanism, compare the lateral deviation amount with a preset initial condition, and adjust the proportional gain of the adaptive PID controller based on the comparison result to perform an adjustment operation on the scribing mechanism.
5. The method for road marking based on visual standard points according to claim 1, wherein The calculation formula of the feature center is as follows: Among them, max(d) represents the distance between the two sets of points M and N that are farthest apart. represents the circumcircle represents the characteristic center of the standard sample points. Both m1 and m2 represent elements in the point set M, and both n1 and n2 represent elements in the point set N.
6. The road marking method based on visual standard points according to claim 1, wherein Before starting the scribing operation, the method further includes: Calibrate the wheel odometer, and jointly calibrate the camera and the IMU through the Kalibr toolbox; Adjust the position of the scribing mechanism according to the driving direction, and set the scribing distance between the scribing mechanism and the sample point. The expression of the scribing distance is as follows: Among them, represents the described scribed distance, represents the lateral offset between the camera and the standard sample point, represents the lateral offset between the camera and the motion center, represents the lateral offset between the motion center and the scribing mechanism.
7. The method for road marking based on visual standard points according to claim 1, wherein The method further includes: When the current attitude error is less than the preset threshold and exceeds the scribing allowable error range, reset the fusion data of the wheel odometer and the IMU; When the current attitude error is less than the preset threshold and less than the scribing allowable error range, perform a normal scribing operation.
8. The method for road marking based on visual standard points according to claim 1, characterized in that, The method further includes: When the current attitude error is greater than the preset threshold, start the buzzer warning and stop the scribing operation.
Citation Information
Patent Citations
Full-automatic intelligent highway scribing method based on video image driving
CN114550118A
Road marking method and marking robot based on 3D laser radar
CN115877842A
Intelligent scribing method and intelligent scribing robot
CN116578097A
Operation method, device and equipment of scribing robot and storage medium
CN117434931A
Building robot integrating automatic point fixing and line drawing functions and path planning method thereof
CN119717796A