An image-based positioning method and related apparatus
By employing an image-based localization method that utilizes ellipse detection and DM code recognition, combined with image pyramids and subpixel processing, the problem of positioning accuracy and efficiency for unmanned forklifts under insufficient lighting and occlusion conditions is solved, achieving high-precision and low-latency positioning results.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- MULTIWAY ROBOTICS TECH (SHENZHEN) CO LTD
- Filing Date
- 2023-02-21
- Publication Date
- 2026-05-12
AI Technical Summary
Existing benchmark marking methods suffer from reduced positioning accuracy under insufficient lighting and occlusion conditions, and their complex algorithms lead to computational bottlenecks, failing to meet the high precision and high efficiency requirements of unmanned forklifts.
An image-based localization method is adopted, which uses ellipse detection, DM code recognition and block detection, combined with image pyramid and sub-pixel processing, to quickly obtain the three-dimensional and two-dimensional coordinates of the marked image and reduce the impact of environmental interference.
It improves positioning accuracy and processing efficiency, reduces latency, and achieves sub-millimeter pose estimation, meeting the high-precision and low-latency positioning requirements of unmanned forklifts.
Smart Images

Figure CN116245126B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of cargo transportation technology, and in particular to an image-based positioning method and related equipment. Background Technology
[0002] With the advent of Industry 4.0 and smart manufacturing, the industrial sector is continuously evolving from traditional manufacturing towards digitalization, intelligence, and automation. In the smart warehousing industry, the application of unmanned forklifts is becoming increasingly widespread. The accuracy of positioning is crucial for the navigation and control systems of unmanned forklifts; otherwise, accidents can easily occur.
[0003] However, existing benchmarking methods generally have high environmental requirements, and their positioning accuracy drops significantly in low-light or occluded conditions, failing to meet the needs of practical applications. Furthermore, existing methods often employ complex algorithms, which can easily create computational bottlenecks during large-scale data processing, leading to low system efficiency. Therefore, developing a positioning algorithm that simultaneously possesses high accuracy, low processing latency, and high stability is a key challenge for current industry applications. Summary of the Invention
[0004] The technical problem to be solved by this invention is the low efficiency and accuracy of positioning. In view of the shortcomings of the prior art, this invention provides an image-based positioning method and related equipment.
[0005] To solve the above-mentioned technical problems, the technical solution adopted by the present invention is as follows:
[0006] An image-based localization method, the method comprising:
[0007] The environment is photographed to obtain a marked image corresponding to a preset positioning image. The positioning image includes a DM code, a circular mark, and several marked squares from the inside out.
[0008] Based on the circular marker, ellipse detection is performed on the marker image to obtain ellipse position information;
[0009] Based on the ellipse position information, extract the three-dimensional coordinates of the marker corresponding to the DM code; and based on the ellipse position information, determine the block coordinate information corresponding to the marker block in the marker image;
[0010] Based on the block coordinate information, calculate the two-dimensional coordinates of the marker corresponding to the positioning image;
[0011] Based on the two-dimensional coordinates and three-dimensional coordinates of the marker, the positioning information corresponding to the marker image is calculated.
[0012] The image-based localization method, wherein the labeled image includes an initial image and a downsampled image; the step of capturing images of the environment to obtain a labeled image for a preset localization image includes:
[0013] The environment is photographed to obtain an initial image for the positioning image;
[0014] The initial image is downsampled to obtain the downsampled image.
[0015] The image-based localization method, wherein extracting the three-dimensional coordinates of the marker corresponding to the DM code based on the ellipse position information includes:
[0016] Based on the ellipse position information, extract the DM image corresponding to the DM code;
[0017] Perform an affine transformation on the DM image to obtain an aligned image;
[0018] Information is extracted from the aligned image to obtain the three-dimensional coordinates of the marker corresponding to the aligned image.
[0019] The image-based localization method, wherein extracting information from the aligned image to obtain the three-dimensional coordinates of the marker corresponding to the aligned image includes:
[0020] The aligned image is sampled to generate an image pyramid;
[0021] Multi-scale recognition is performed on the image pyramid to obtain the three-dimensional coordinates of the marker corresponding to the aligned image.
[0022] The image-based localization method, wherein the block coordinate information is sub-pixel coordinate; the step of determining the block coordinate information corresponding to the marked block in the marked image based on the ellipse position information includes:
[0023] Based on the ellipse position information, determine the square region in the marked image;
[0024] Perform block detection on the block region to obtain a block image;
[0025] Based on the block image, the marked image is subjected to subpixelization processing to obtain the subpixel coordinates corresponding to the block image.
[0026] The image-based localization method, wherein calculating the two-dimensional coordinates of the marker corresponding to the localization image based on the block coordinate information includes:
[0027] For each of the marked blocks, the two-dimensional coordinates of the marked block are obtained according to the block coordinate information corresponding to the marked block and the preset marking point rules.
[0028] The image-based localization method, after calculating the localization information corresponding to the marker image based on the marker's two-dimensional coordinates and three-dimensional coordinates, further includes:
[0029] Obtain odometer readings;
[0030] Based on the positioning information, the odometer value is corrected to obtain the location information.
[0031] An image-based positioning device, comprising:
[0032] The camera module is used to capture images of the environment and obtain a marked image for a preset positioning image. The positioning image includes a DM code, a circular mark, and several marked squares from the inside out.
[0033] The detection module is used to perform ellipse detection on the marker image based on the circular marker to obtain ellipse position information;
[0034] The extraction module is used to extract the three-dimensional coordinates of the marker corresponding to the DM code based on the ellipse position information; and to determine the block coordinate information corresponding to the marker block in the marker image based on the ellipse position information.
[0035] The first calculation module is used to calculate the two-dimensional coordinates of the marker corresponding to the positioning image based on the block coordinate information;
[0036] The second calculation module is used to calculate the positioning information corresponding to the marker image based on the two-dimensional coordinates and three-dimensional coordinates of the marker.
[0037] A computer-readable storage medium storing one or more programs that can be executed by one or more processors to implement the steps in any of the image-based localization methods described above.
[0038] A terminal device includes: a processor, a memory, and a communication bus; the memory stores a computer-readable program that can be executed by the processor;
[0039] The communication bus enables communication between the processor and the memory;
[0040] When the processor executes the computer-readable program, it implements the steps in any of the image-based localization methods described above.
[0041] Beneficial Effects: This invention provides an image-based localization method that uses ellipse detection to quickly locate DM codes and squares, effectively avoiding interference from environmental factors such as occlusion and insufficient lighting, thus ensuring reliable localization accuracy. Parallel processing of DM code recognition and square detection effectively improves detection speed and processing efficiency, thereby reducing latency. Attached Figure Description
[0042] Figure 1 A flowchart of the image-based localization method provided by the present invention.
[0043] Figure 2 This is an exemplary style of positioning image in the image-based positioning method provided by the present invention.
[0044] Figure 3 The overall flowchart of the image-based localization method provided by the present invention is shown below.
[0045] Figure 4 This is a schematic diagram of the image-based positioning device provided by the present invention.
[0046] Figure 5 The structural schematic diagram of the terminal device provided by the present invention. Detailed Implementation
[0047] This invention provides an image-based localization method. To make the objectives, technical solutions, and effects of this invention clearer and more explicit, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only for explaining the invention and are not intended to limit the invention.
[0048] Those skilled in the art will understand that, unless specifically stated otherwise, the singular forms “a,” “an,” “the,” and “the” used herein may also include the plural forms. It should be further understood that the term “comprising” as used in this specification means the presence of the stated features, integers, steps, operations, elements, and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and / or groups thereof. It should be understood that when we say an element is “connected” or “coupled” to another element, it can be directly connected or coupled to the other element, or there may be intermediate elements. Furthermore, “connected” or “coupled” as used herein can include wireless connections or wireless coupling. The term “and / or” as used herein includes all or any units and all combinations of one or more associated listed items.
[0049] It will be understood by those skilled in the art that, unless otherwise defined, all terms used herein (including technical and scientific terms) have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. It should also be understood that terms such as those defined in general dictionaries should be understood to have the same meaning as in the context of the prior art, and should not be interpreted in an idealized or overly formal sense unless specifically defined as herein.
[0050] The application scenario of this embodiment is the unmanned forklift handling goods. In this scenario, the unmanned forklift needs to carry out goods transportation work according to the issued route. The precise position of the unmanned forklift plays a key role. The more precise the position, the more reasonably the route and specific operation of the unmanned forklift can be arranged.
[0051] like Figure 1 As shown, this embodiment provides an image-based positioning method. For ease of explanation, a common server is used as the execution subject in the description. The server here can be replaced by a device with data processing capabilities, such as a tablet or computer. This device is installed on an unmanned forklift or other unmanned control instrument. The image-based positioning method includes the following steps:
[0052] S10. Take a picture of the environment to obtain a marked image for a preset positioning image, wherein the positioning image includes a DM code, a circular mark and several marked squares from the inside out.
[0053] Specifically, several positioning images are pre-placed at intervals on the aisle where the unmanned forklift operates, such as... Figure 2 As shown, the positioning image, from the inside out, includes a DM (Data Matrix, two-dimensional) image, a circular marker, and several marker squares. The arrangement of the positioning image can be adjusted according to the unmanned forklift's shooting cycle and operating speed to improve the effectiveness of capturing the marker images.
[0054] Since higher pixel counts result in slower processing speeds, but lower pixel counts lead to poorer positioning accuracy, this embodiment uses an initial image and a downsampled image as the marker image. First, the environment is captured to obtain a high-resolution initial image, which is then used for high-precision data processing. Next, the initial image is downsampled to obtain a lower-pixel image, which is used for subsequent information extraction.
[0055] Furthermore, in this embodiment, the number of marker blocks is 4, located at the top left, bottom left, top right, and bottom right of the positioning image, respectively. However, the marker blocks can also be located at the midpoints of each edge of the positioning image, and the number of marker blocks can be more or less, as long as there are at least four corner points that can be used for subsequent calculations. For example, if the number of marker blocks is 1, its four vertices can be used as corner points.
[0056] S20. Based on the circular marker, perform ellipse detection on the marker image to obtain ellipse position information.
[0057] Specifically, because it's difficult to guarantee that the shooting angle is perfectly aligned with the positioning image, circular markers in the marker image will be distorted into ellipses. To address this issue, this embodiment provides a method based on an ellipse detection algorithm, which can quickly and accurately detect ellipses in the marker image, thereby obtaining ellipse position information. First, an arc segment adjacency matrix is constructed. By traversing the arc segment adjacency matrix, combinations of candidate arc segments for true ellipses in the marker image are obtained. Then, through quadratic feature decomposition fitting, the position coordinates of the ellipse in the marker image are determined, ultimately obtaining the ellipse position information. Furthermore, the ellipse position information can also be used to assist in locating the regions containing DM codes and squares in the marker image. Therefore, to improve efficiency, downsampled images can be used to reduce computational load.
[0058] S30. Based on the ellipse position information, extract the three-dimensional coordinates of the marker corresponding to the DM code; and based on the ellipse position information, determine the block coordinate information corresponding to the marker block in the marker image.
[0059] Specifically, such as Figure 3 As shown, according to the preset settings, the circular marker inside the positioning circle contains the DM code, and the outer part is marked with a square. Therefore, based on the ellipse position information, the DM image corresponding to the DM code in the marker image and the square image corresponding to the marker square in the marker image can be determined.
[0060] The data area of the DM code includes an L-shaped frame and dotted lines. After capturing the DM code, the corresponding three-dimensional coordinates of the marker can be obtained by extracting and analyzing the information contained in the image. In this embodiment, the marker three-dimensional coordinates refer to the coordinates of the marker points in the positioning image, used to determine the geographical location of the positioning image. The marker point is a point with known three-dimensional coordinates. After calculating the two-dimensional coordinates of the corresponding marker point, the camera's extrinsic parameters can be calculated, thereby obtaining the camera pose. In this embodiment, the position of the marker three-dimensional coordinates relative to the entire positioning image is fixed; for example, the marker three-dimensional coordinates correspond to points A, B, C, and D.
[0061] Because the shooting angle causes distortion, in order to extract the three-dimensional coordinates of the markers in the DM code, the DM image corresponding to the DM code is first extracted based on the ellipse position information. Then, an affine transformation is performed on the DM image to obtain an aligned image.
[0062] One method of affine transformation is based on a circular marker. The diameter of the circular marker is pre-set, and the distortion parameters from the circular marker to the elliptical position coordinates can be determined using the elliptical position coordinates and the elliptical position coordinates. Based on these distortion parameters, an affine transformation is performed on the DM image to obtain an aligned image.
[0063] Another affine transformation method is based on the shape regularity of the DM code itself. Since the shape of the DM code is very regular, the distortion parameters from the DM code to the DM image can be calculated. Based on these distortion parameters, an affine transformation is performed on the DM image to obtain the aligned image. For cases with significant distortion, the former method can achieve more accurate alignment of the DM image.
[0064] Finally, information is extracted from the aligned image to obtain the three-dimensional coordinates of the marker. The extraction steps are existing technology and will not be described in detail here.
[0065] When extracting information corresponding to the DM code, this embodiment preferably uses an image pyramid. An image pyramid is a multi-scale representation of an image, providing an effective yet conceptually simple structure for interpreting an image at multiple resolutions. An image pyramid is a set of image resolutions that gradually decrease in a pyramid shape (from bottom to top) and originate from the same original image. It is obtained through stepwise downsampling until a certain termination condition is met. First, the aligned image is sampled to obtain the image pyramid. Then, multi-scale recognition is performed on the image pyramid to obtain the information it contains, resulting in the labeled three-dimensional coordinates. Considering recognition speed, this embodiment uses DM codes with a size not exceeding 16 for better results.
[0066] Based on the ellipse position information, the region where the marked square is located can be determined. Therefore, square detection can be performed outside the ellipse position information to obtain the square image and its corresponding coordinate information.
[0067] First, the square regions are determined based on the ellipse position information. Then, a gradient clustering algorithm is used for square detection, calculating all edges within the square regions to obtain initial bounding boxes. Next, the initial bounding boxes are filtered using preset parameters such as color, tolerance, and edge shape to obtain the square bounding boxes and their corresponding square images. Finally, the two-dimensional coordinates of this square image within the initial image or downsampled image are used as the square coordinate information.
[0068] This method has a high anti-interference capability and can avoid the effects of environmental interference, occlusion and uneven lighting intensity, thereby improving the efficiency of block detection.
[0069] Since the marked squares are used for positioning, high precision is required. In this embodiment, to achieve higher calculation accuracy, subpixel processing can be performed on the image. After obtaining the square selection box, the square image in the higher-resolution initial image is discretized to obtain a discrete image. Subpixel interpolation is then performed on the discrete image to obtain a higher-resolution processed image. Then, based on the square image, square detection is performed again to obtain the coordinates corresponding to the subpixel level square image, i.e., subpixel coordinates.
[0070] Furthermore, if the marker block is too large, the accuracy is low; if the marker block is too small, the block detection efficiency is too low. Therefore, in order to balance speed and confinement, the length of the marker block is 0.5 to 1 times the size of the DM code.
[0071] S40. Calculate the two-dimensional coordinates of the marker corresponding to the positioning image based on the block coordinate information.
[0072] Specifically, the block coordinate information contains the position coordinates of each vertex in each block image. Based on the coordinates of each vertex, the coordinates of the marker points in the entire positioning image can be calculated, i.e., the two-dimensional coordinates of the markers.
[0073] In this embodiment, since the four marker blocks are located at the four vertices of the positioning image, and the marker block information corresponding to each marker block includes the coordinates of the four vertices corresponding to that marker block, it is necessary to select from these four vertex coordinates to determine the marker two-dimensional coordinates corresponding to the positioning image. Therefore, for each block coordinate information, according to a preset vertex rule, the corresponding block vertex information is calculated to obtain the marker two-dimensional coordinates corresponding to the positioning image. For example, the marker two-dimensional coordinates correspond to points A', B', C', and D'.
[0074] In addition, to reduce the amount of information, the three-dimensional coordinates of the markers identified by the DM code can be limited to the coordinate values. After obtaining the two-dimensional coordinates of the markers, the three-dimensional coordinates of each marker are determined by the positional order calculation method. The two-dimensional coordinates and three-dimensional coordinates of the markers are matched one-to-one by the positional order relationship between the two-dimensional coordinates and the three-dimensional coordinates of the markers.
[0075] It is worth noting that the marker point is not limited to the top left corner of the marker block; it can also be located at the center of each marker block, or at the bottom left corner, etc.
[0076] S50. Calculate the positioning information corresponding to the marker image based on the two-dimensional coordinates and the three-dimensional coordinates of the marker.
[0077] Specifically, given the camera's intrinsic parameters and the known two-dimensional coordinates of several points and their corresponding three-dimensional coordinates, the mapping relationship from three-dimensional to two-dimensional, i.e., the camera's extrinsic parameters, can be calculated, thereby estimating the camera's current pose. With a fixed shape forklift and a fixed camera mounting position, the forklift's pose can be further calculated based on the camera's pose, thus obtaining the forklift's positioning information when capturing the marked image.
[0078] This scheme improves the reliability of positioning accuracy by using ellipse fitting, DM code recognition, and corner point localization to avoid environmental interference and reduce the impact of factors such as occlusion and uneven lighting intensity. Ellipse detection and DM code recognition are performed on low-resolution images, while sub-pixel pose estimation is performed on high-resolution images, resulting in sub-millimeter-level pose estimation. This parallel approach improves the algorithm's processing efficiency and reduces latency.
[0079] Automated forklifts typically incorporate a SLAM (Simultaneous Localization and Mapping) system. SLAM systems utilize sensors to achieve real-time localization and mapping, collecting odometer readings in real-time during movement to determine the forklift's motion state. However, these odometer readings only provide a coarse description of the forklift's movement, resulting in relatively low accuracy. The localization information obtained in this embodiment is more accurate, particularly for situations such as turning or going uphill. Therefore, based on the localization information calculated in this embodiment, the odometer readings can be corrected to obtain precise location information, which can then be used for path planning.
[0080] Based on the above-described image-based localization method, the present invention also provides an image-based localization device, such as... Figure 4 As shown, the device includes:
[0081] The shooting module 110 is used to capture images of the environment and obtain a marked image for a preset positioning image, wherein the positioning image includes a DM code, a circular mark and several marked squares from the inside out;
[0082] The detection module 120 is used to perform ellipse detection on the marker image based on the circular marker to obtain ellipse position information;
[0083] The extraction module 130 is used to extract the three-dimensional coordinates of the marker corresponding to the DM code based on the ellipse position information; and to determine the block coordinate information corresponding to the marker block in the marker image based on the ellipse position information.
[0084] The first calculation module 140 is used to calculate the two-dimensional coordinates of the marker corresponding to the positioning image based on the block coordinate information;
[0085] The second calculation module 150 is used to calculate the positioning information corresponding to the marker image based on the two-dimensional coordinates and the three-dimensional coordinates of the marker.
[0086] The marked image includes an initial image and a downsampled image; the capturing module 110 includes:
[0087] The imaging unit is used to capture images of the environment to obtain an initial image of the positioning image;
[0088] A downsampling unit is used to downsample the initial image to obtain the downsampled image.
[0089] The extraction module 130 includes:
[0090] The first extraction unit is used to extract the DM image corresponding to the DM code based on the ellipse position information;
[0091] A transformation unit is used to perform an affine transformation on the DM image to obtain an aligned image;
[0092] The second extraction unit is used to extract information from the aligned image to obtain the three-dimensional coordinates of the marker corresponding to the aligned image.
[0093] Specifically, the second extraction unit is used for:
[0094] The aligned image is sampled to generate an image pyramid;
[0095] Multi-scale recognition is performed on the image pyramid to obtain the three-dimensional coordinates of the marker corresponding to the aligned image.
[0096] Wherein, the block coordinate information is sub-pixel coordinate; the extraction module 130 further includes:
[0097] The determining unit is used to determine the square region in the marked image based on the ellipse position information;
[0098] The detection unit is used to perform block detection on the block area to obtain a block image;
[0099] The subpixelation unit is used to perform subpixelation processing on the marker image based on the block image to obtain the subpixel coordinates corresponding to the block image.
[0100] Specifically, the first calculation module 140 is used for:
[0101] For each of the marked blocks, the two-dimensional coordinates of the marked block are obtained according to the block coordinate information corresponding to the marked block and the preset marking point rules.
[0102] The image-based positioning device further includes a correction module for:
[0103] Obtain odometer readings;
[0104] Based on the positioning information, the odometer value is corrected to obtain the location information.
[0105] Based on the above image-based positioning method, the present invention also provides a terminal device, such as... Figure 5 As shown, it includes at least one processor 20; a display screen 21; and a memory 22, and may also include a communications interface 23 and a bus 24. The processor 20, display screen 21, memory 22, and communications interface 23 can communicate with each other via the bus 24. The display screen 21 is configured to display a preset user guide interface in the initial setup mode. The communications interface 23 can transmit information. The processor 20 can invoke logical commands stored in the memory 22 to execute the methods described in the above embodiments.
[0106] Furthermore, the logical commands in the aforementioned memory 22 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium.
[0107] The memory 22, as a computer-readable storage medium, can be configured to store software programs, computer-executable programs, such as program commands or modules corresponding to the methods in the embodiments of this disclosure. The processor 20 executes functional applications and data processing by running the software programs, commands, or modules stored in the memory 22, thereby implementing the methods in the above embodiments.
[0108] The memory 22 may include a program storage area and a data storage area. The program storage area may store the operating system and application programs required for at least one function; the data storage area may store data created based on the use of the terminal device. Furthermore, the memory 22 may include high-speed random access memory (RAM) and non-volatile memory. Examples include various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks; it may also be a transient computer-readable storage medium.
[0109] Furthermore, the specific process of loading and executing multiple command processors in the aforementioned computer-readable storage medium and terminal device has been described in detail in the above method, and will not be repeated here.
[0110] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. An image-based localization method, characterized in that, The method includes: The environment is photographed to obtain a marked image corresponding to a preset positioning image. The positioning image includes a DM code, a circular mark, and several marked squares from the inside out. Based on the circular marker, ellipse detection is performed on the marker image to obtain ellipse position information; Based on the ellipse position information, extract the three-dimensional coordinates of the marker corresponding to the DM code; and based on the ellipse position information, determine the block coordinate information corresponding to the marker block in the marker image; Based on the block coordinate information, calculate the two-dimensional coordinates of the marker corresponding to the positioning image; Based on the two-dimensional coordinates and three-dimensional coordinates of the marker, calculate the positioning information corresponding to the marker image; The step of extracting the three-dimensional coordinates of the marker corresponding to the DM code based on the ellipse position information includes: Based on the ellipse position information, extract the DM image corresponding to the DM code; Perform an affine transformation on the DM image to obtain an aligned image; Information is extracted from the aligned image to obtain the three-dimensional coordinates of the marker corresponding to the aligned image; The step of extracting information from the aligned image to obtain the corresponding three-dimensional coordinates of the marker includes: The aligned image is sampled to generate an image pyramid; Multi-scale recognition is performed on the image pyramid to obtain the three-dimensional coordinates of the marker corresponding to the aligned image.
2. The image-based localization method according to claim 1, characterized in that, The marked image includes an initial image and a downsampled image; the process of capturing images of the environment to obtain marked images based on a preset positioning image includes: The environment is photographed to obtain an initial image for the positioning image; The initial image is downsampled to obtain the downsampled image.
3. The image-based localization method according to claim 1, characterized in that, The block coordinate information is sub-pixel coordinate; determining the block coordinate information corresponding to the marked block in the marked image based on the ellipse position information includes: Based on the ellipse position information, determine the square region in the marked image; Perform block detection on the block region to obtain a block image; Based on the block image, the marked image is subjected to subpixelization processing to obtain the subpixel coordinates corresponding to the block image.
4. The image-based localization method according to claim 3, characterized in that, The step of calculating the two-dimensional coordinates of the marker corresponding to the positioning image based on the block coordinate information includes: For each of the marked blocks, the two-dimensional coordinates of the marked block are obtained according to the block coordinate information corresponding to the marked block and the preset marking point rules.
5. The image-based localization method according to claim 1, characterized in that, After calculating the positioning information corresponding to the marker image based on the marker's two-dimensional coordinates and three-dimensional coordinates, the method further includes: Obtain odometer readings; Based on the positioning information, the odometer value is corrected to obtain the location information.
6. An image-based positioning device, characterized in that, The image-based positioning device includes: The camera module is used to capture images of the environment and obtain a marked image for a preset positioning image. The positioning image includes a DM code, a circular mark, and several marked squares from the inside out. The detection module is used to perform ellipse detection on the marker image based on the circular marker to obtain ellipse position information; The extraction module is used to extract the three-dimensional coordinates of the marker corresponding to the DM code based on the ellipse position information; and to determine the block coordinate information corresponding to the marker block in the marker image based on the ellipse position information. The first calculation module is used to calculate the two-dimensional coordinates of the marker corresponding to the positioning image based on the block coordinate information; The second calculation module is used to calculate the positioning information corresponding to the marker image based on the two-dimensional coordinates and the three-dimensional coordinates of the marker; The step of extracting the three-dimensional coordinates of the marker corresponding to the DM code based on the ellipse position information includes: Based on the ellipse position information, extract the DM image corresponding to the DM code; Perform an affine transformation on the DM image to obtain an aligned image; Information is extracted from the aligned image to obtain the three-dimensional coordinates of the marker corresponding to the aligned image; The step of extracting information from the aligned image to obtain the corresponding three-dimensional coordinates of the marker includes: The aligned image is sampled to generate an image pyramid; Multi-scale recognition is performed on the image pyramid to obtain the three-dimensional coordinates of the marker corresponding to the aligned image.
7. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores one or more programs, which can be executed by one or more processors to implement the steps of the image-based localization method as described in any one of claims 1 to 5.
8. A terminal device, characterized in that, include: Processor, memory, and communication bus; The memory stores a computer-readable program that can be executed by the processor; The communication bus enables communication between the processor and the memory; When the processor executes the computer-readable program, it implements the steps of the image-based localization method as described in any one of claims 1 to 5.