A ROS map processing method, a storage medium and a terminal device

By acquiring edge information from the ROS map, determining the effective image area, and correcting pixel values, the problem of noise in mobile robot maps was solved, improving the image quality of the map and the user experience.

CN115546040BActive Publication Date: 2026-01-23SHENZHEN TCL DIGITAL TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202110752133.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-06-30
Publication Date
2026-01-23
Estimated Expiration
2041-06-30

AI Technical Summary

Technical Problem

In existing technologies, the environmental maps built by mobile robots contain many irregular noise points, which affect user experience.

Method used

By acquiring edge information from the ROS map, the effective image area is determined, and the pixel values ​​of the target pixels are corrected based on the pixel values ​​to remove noise and form a denoised map.

Benefits of technology

The image quality of ROS maps has been improved, enhancing the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115546040B_ABST
    Figure CN115546040B_ABST
Patent Text Reader

Abstract

The application discloses a ROS map processing method, a storage medium and a terminal device. The processing method comprises the following steps: obtaining a ROS map to be processed, and obtaining edge information corresponding to the ROS map to be processed; determining an effective image area of the ROS map to be processed based on the edge information; determining a target pixel point in the effective image area based on a pixel value of each pixel point in the effective image area; and correcting the pixel value of the determined target pixel point to obtain a denoising map corresponding to the ROS map to be processed. After the ROS map is obtained, the effective image area corresponding to the ROS map is determined based on the edge information of the ROS map, and the pixel value of the target pixel point in the effective image area is corrected to remove the noise points in the ROS map, so that the image quality of the ROS map is improved, and the user is facilitated.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of robots, and particularly relates to a ROS map processing method, a storage medium and a terminal device. BACKGROUND

[0002] A mobile robot is a robot that can work in a complex environment and has self-planning, self-organization and self-adaptation capabilities. The mobile robot has the advantages of fast action, high work efficiency, simple structure, strong controllability and good safety, and is widely used at home and abroad at present.

[0003] In the related technical research of the mobile robot, the robot can form an environment map of an environment scene by scanning the environment scene, which has become the focus of attention. For example, a SLAM robot can use a laser radar to scan indoor walls and obstacles to construct an indoor map. However, the environment map constructed by the robot currently generally has many irregular noise points, which affects the use of users.

[0004] Therefore, the prior art still needs to be improved and enhanced. SUMMARY

[0005] The technical problem to be solved by the present application is to provide a ROS map processing method, a storage medium and a terminal device to solve the problems of the prior art.

[0006] In order to solve the above technical problems, the first aspect of the embodiment of the present application provides a ROS map processing method, which comprises:

[0007] Obtaining a ROS map to be processed, and obtaining edge information corresponding to the ROS map to be processed;

[0008] Determining an effective image region of the ROS map to be processed based on the edge information;

[0009] Determining a target pixel point in the effective image region based on a pixel value of each pixel point in the effective image region;

[0010] Correcting the pixel value of the determined target pixel point to obtain a denoising map corresponding to the ROS map to be processed.

[0011] The ROS map processing method, wherein, after obtaining the ROS map to be processed, before obtaining the edge information corresponding to the ROS map to be processed:

[0012] Performing denoising processing on the ROS map to be processed, and taking the ROS map obtained by the denoising processing as the ROS map to be processed.

[0013] The ROS map processing method, wherein, the obtaining of the ROS map to be processed is specifically:

[0014] An environment map corresponding to the environment scene is constructed by using the ROS system to obtain a ROS map to be processed.

[0015] The ROS map processing method, wherein the target pixel points in the effective image region are determined based on the pixel values of the respective pixel points in the effective image region, specifically includes:

[0016] The pixel values of the respective pixel points in the effective image region are obtained.

[0017] Based on the respective pixel values of the respective pixel points, target pixel points with pixel values less than a preset threshold value are selected in the effective image region to obtain the target pixel points in the effective image region.

[0018] The ROS map processing method, wherein the pixel values of the determined target pixel points are corrected to obtain a denoised map corresponding to the ROS map to be processed, specifically includes:

[0019] The pixel values of the respective target pixel points in the determined target pixel points are all set to a preset pixel value to obtain the denoised map corresponding to the ROS map to be processed.

[0020] The ROS map processing method, wherein after the pixel values of the respective target pixel points in the determined target pixel points are all set to the preset pixel value to obtain the denoised map corresponding to the ROS map to be processed, the method further includes:

[0021] The denoised map is divided into a plurality of image blocks.

[0022] For each image block in the plurality of image blocks, an average value of the pixel values of the respective pixel points in the image block is determined, and the pixel values of the respective pixel points in the image block are all set to the average value.

[0023] The ROS map processing method, wherein the respective image blocks in the plurality of image blocks do not overlap with each other, and the respective image blocks include an equal number of pixel points.

[0024] The second aspect of the embodiments of the present application provides a ROS map processing device, which specifically includes:

[0025] An acquisition module is configured to acquire a ROS map to be processed and acquire edge information corresponding to the ROS map to be processed.

[0026] A first determination module is configured to determine an effective image region of the ROS map to be processed based on the edge information.

[0027] a second determining module, configured to determine a target pixel point in the effective image region based on pixel values of each pixel point in the effective image region;

[0028] a correcting module, configured to correct the pixel value of the determined target pixel point to obtain a denoised map corresponding to the ROS map to be processed.

[0029] The third aspect of the embodiments of the present application provides a computer readable storage medium, which stores one or more programs, and the one or more programs can be executed by one or more processors to implement the steps in the ROS map processing method according to any one of the above.

[0030] The fourth aspect of the embodiments of the present application provides a terminal device, which comprises a processor, a memory and a communication bus; the memory stores a computer readable program which can be executed by the processor;

[0031] The communication bus realizes the connection and communication between the processor and the memory;

[0032] The processor realizes the steps in the ROS map processing method according to any one of the above when executing the computer readable program.

[0033] Advantages: compared with the prior art, the present application provides a ROS map processing method, a storage medium and a terminal device, the processing method comprises obtaining a ROS map to be processed, and obtaining edge information corresponding to the ROS map to be processed; based on the edge information, an effective image region of the ROS map to be processed is determined; based on pixel values of each pixel point in the effective image region, a target pixel point in the effective image region is determined; the pixel value of the determined target pixel point is corrected to obtain a denoised map corresponding to the ROS map to be processed. After obtaining the ROS map, the present application determines the corresponding effective image region of the ROS map through the edge information of the ROS map, and corrects the pixel value of the target pixel point in the effective image region to remove the noise points in the ROS map, thereby improving the image quality of the ROS map, and further bringing convenience to users. BRIEF DESCRIPTION OF DRAWINGS

[0034] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed in the embodiment description will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can also be obtained by those skilled in the art without creative labor.

[0035] Figure 1 The flowchart of the ROS map processing method provided by the present application.

[0036] Figure 2 An example of a ROS map to be processed in the processing method of the ROS map provided by the present application.

[0037] Figure 3 An example of a ROS map to be processed in the processing method of the ROS map provided by the present application. Figure 2 An example of a ROS map after performing the blurring processing on the ROS map shown in FIG. 8.

[0038] Figure 4 An example of an edge binary map.

[0039] Figure 5 An example of an effective image region.

[0040] Figure 6 An example of a ROS map after performing the blurring processing on the ROS map.

[0041] Figure 7 An example of a denoised image.

[0042] Figure 8 An example of a ROS map after performing the post-processing on the denoised image.

[0043] Figure 9 A structural schematic diagram of the processing of the ROS map provided by the present application.

[0044] Figure 10 A structural schematic diagram of the terminal device provided by the present application. DETAILED DESCRIPTION

[0045] The present application provides a processing method of a ROS map, a storage medium and a terminal device. In order to make the purpose, technical solutions and effects of the present application more clear and explicit, the present application 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 used to explain the present application and not to limit the present application.

[0046] Those skilled in the art can understand that, unless specifically stated otherwise, the singular forms "a", "an" and "the" used herein can also include the plural forms. It should be further understood that the phrase "comprising" used in the specification of the present application means that the features, integers, steps, operations, elements and / or components exist, 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 that an element is "connected" or "coupled" to another element, it can be directly connected or coupled to the other element, or there can be intermediate elements. In addition, "connected" or "coupled" used herein can include wireless connection or wireless coupling. The phrase "and / or" used herein includes all or any single unit and all combinations of the associated listed items.

[0047] Those skilled in the art of the technology will appreciate that unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art in the field to which this application belongs. It will be further understood that terms, such as those defined in commonly used dictionaries, should be interpreted as having a meaning that is consistent with their meaning in the context of the relevant art and will not be interpreted in an idealized or overly formal sense unless expressly so defined herein.

[0048] In particular implementations, the terminal devices described in the embodiments of the present application include, but are not limited to, mobile telephones such as those with touch-sensitive surfaces (e.g., touch display screens and / or touchpads), other portable devices such as laptop computers or tablet computers. It should also be understood that, in some embodiments, the device is not a portable communication device, but rather a desktop computer with a touch-sensitive surface (e.g., a touch display screen and / or a touchpad).

[0049] In the following discussion, a terminal device including a display and a touch-sensitive surface is described. It should be understood, however, that a terminal device can also include one or more other physical user-interface devices, such as a physical keyboard, a mouse and / or a joystick.

[0050] The terminal device supports a variety of applications, such as one or more of the following: a drawing application, a presentation application, a word processing application, a website creation application, a disk authoring application, a spreadsheet application, a game application, a telephone application, a video conferencing application, an e-mail application, an instant messaging application, a workout support application, a photo management application, a digital camera application, a digital video camera application, a web browsing application, a digital music player application, and / or a digital video player application, etc.

[0051] The various applications that can be executed on the terminal device can use at least one common physical user-interface device, such as the touch-sensitive surface. One or more functions of the touch-sensitive surface and display can be adjusted or changed by a respective application being executed by a respective application. By way of example, the display settings of a respective application can be adjusted as between the various applications. Thus, for example, the display setting of a calendar application can be adjusted independently from the display settings of a telephone application to provide optimal displays of both types of information.

[0052] It should be understood that the sequence numbers and sizes of the steps in the embodiments do not mean the order of execution, the execution order of the processes is determined by its function and inherent logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.

[0053] The inventor finds that the mobile robot is a robot that can work in a complex environment and has self-planning, self-organization and self-adaptation capabilities. The mobile robot has the advantages of fast action, high work efficiency, simple structure, strong controllability and good safety, and is widely used at home and abroad.

[0054] In the research of mobile robot related technology, the robot can form an environment map of an environment scene by scanning the environment scene, which has become the focus of attention. For example, a SLAM robot can use a laser radar to scan indoor walls and obstacles to construct an indoor map. However, the environment map constructed by the robot currently generally has many irregular noise points, which affects the user's use.

[0055] In order to solve the above problems, in the embodiment of the present application, a ROS map to be processed is obtained, and edge information corresponding to the ROS map to be processed is obtained; based on the edge information, a valid image area of the ROS map to be processed is determined; based on the pixel value of each pixel point in the valid image area, a target pixel point in the valid image area is determined; the pixel value of the determined target pixel point is corrected to obtain a denoising map corresponding to the ROS map to be processed. After obtaining the ROS map, the edge information of the ROS map is used to determine the corresponding valid image area, and the pixel value of the target pixel point in the valid image area is corrected to remove the noise points in the ROS map, thereby improving the image quality of the ROS map, and further bringing convenience to the user.

[0056] The application content will be further described by describing the embodiments in combination with the drawings.

[0057] The embodiment provides a ROS map processing method, as shown in Figure 1 The method comprises the following steps of:

[0058] S10, obtaining a ROS map to be processed, and obtaining edge information corresponding to the ROS map to be processed.

[0059] Specifically, the ROS map is an environment map of a target scene, for example, the target scene is an indoor environment, and the ROS map is an indoor environment map, wherein the ROS map to be processed can be stored in the local of an electronic device executing the ROS map processing method provided by the embodiment, or obtained through a network (such as Baidu), or sent by other external devices (such as a smart phone).

[0060] In one implementation manner of the embodiment, the ROS map to be processed is determined by a robot equipped with a ROS operating system. Correspondingly, the obtaining of the ROS map to be processed can be specifically as follows:

[0061] An environment map corresponding to the environment scene is constructed by using a ROS system to obtain a ROS map to be processed.

[0062] Specifically, the ROS system can be assembled on a robot. The robot uses the ROS system to scan environment scene three-dimensional data by using a camera or a radar, and generates two-dimensional point cloud data. The environment map is established by using a gmapping (navigation mapping) framework and a particle filter operator for local optimization. The two-dimensional point cloud data records data collected by the camera or the radar in the form of points. The data points can include color information and depth information, and convert spatial data into data on a plane. The particle filter algorithm approximates a probability density function by finding a set of random particles propagating in a state space. The mean value of the particles is used to replace the integral operation, so as to obtain a state minimum variance distribution.

[0063] In one implementation of the embodiment, after obtaining the ROS map to be processed, the edge information corresponding to the ROS map to be processed is obtained before the ROS map to be processed is processed.

[0064] The ROS map to be processed is denoised, and the ROS map obtained by the denoising is taken as the ROS map to be processed.

[0065] Specifically, the signal-to-noise ratio of the denoised ROS map is higher than that of the ROS map to be processed. It can be understood that the denoising of the ROS map to be processed is a denoising process of the ROS map to be processed. The noise points carried by the ROS map to be processed are removed to reduce the noise of the ROS map to be processed, and thus the signal-to-noise ratio of the ROS map obtained by the denoising can be improved. In one implementation of the embodiment, the denoising process can be performed by using a blur processing method, for example, a Gaussian blur processing method. The Gaussian blur processing can be implemented by using OpenCV, for example, the GaussianBlur function in OpenCV is used to perform Gaussian blur processing on the ROS map to be processed as shown in FIG. 4A, and the ROS map obtained by the blur processing is as shown in FIG. 4B. Figure 2 Figure 3

[0066] In one implementation of the embodiment, the edge information is obtained by performing edge detection on the ROS map to be processed. The edge detection is used to identify points with obvious brightness changes in the ROS map to be processed. The edge information can be detected by using an edge operator. The edge operator can be one of a Roberts Cross operator, a Prewitt operator, a Sobel operator, a Kirsch operator, a compass operator, a Canny operator, and a Laplacian operator. In one implementation of the embodiment, the edge information can be implemented by using OpenCV, for example, the Canny function in OpenCV is used to perform edge detection on the ROS map to be processed as shown in FIG. 4A, and the edge information obtained by the edge detection is as shown in FIG. 4C.​​Figure 3 The to-be-processed ROS map is subjected to edge recognition to obtain edge information corresponding to the to-be-processed ROS map, and based on the edge information, an edge binary image corresponding to the to-be-processed ROS map is obtained as shown in FIG. 2. Figure 4 The to-be-processed ROS map is subjected to edge recognition to obtain edge information corresponding to the to-be-processed ROS map, and based on the edge information, an edge binary image corresponding to the to-be-processed ROS map is obtained as shown in FIG. 2.

[0067] S20, based on the edge information, determining an effective image region of the to-be-processed ROS map;

[0068] Specifically, the effective image region is a partial image region in the ROS map, and the effective image region is determined based on the edge information, the partial image region in the effective image region is contained in the edge information of the to-be-processed ROS map, and the edge information of the to-be-processed ROS map can be partially contained in the image edge of the effective image region. In one implementation manner of the embodiment, the effective image region is the largest connected region in the connected regions determined based on the edge information, wherein the effective image region can be realized by OpenCV, for example, the cvFindContours function in OpenCV is used to determine the connected regions in the to-be-processed ROS map based on the edge information, and then the largest connected region in the determined connected regions is selected as the effective image region, for example, the rectangular region in FIG. 3 is the effective image region of the to-be-processed ROS map. Figure 5

[0069] S30, based on the pixel value of each pixel point in the effective image region, determining a target pixel point in the effective image region.

[0070] Specifically, the target pixel point is a pixel point in the effective image region, and the number of target pixel points can be one or more; of course, the effective image region can also have no target pixel point. It can be understood that after obtaining the pixel value of each pixel point in the effective image region, it is determined whether the pixel point meets the preset requirement corresponding to the target pixel point based on the pixel value of each pixel point, wherein the preset requirement is set in advance and is used to measure whether the pixel point in the effective image region is a target pixel point. The preset requirement can be set according to actual needs, for example, the preset requirement is that the pixel value is less than a preset threshold, or the preset requirement is that the pixel value is in a preset threshold interval.

[0071] In one implementation manner of the embodiment, the determination of the target pixel point in the effective image region based on the pixel value of each pixel point in the effective image region specifically includes:

[0072] obtaining the pixel value of each pixel point in the effective image region;

[0073] ​Based on the respective pixel values of the respective pixel points, target pixel points with pixel values less than a preset threshold are selected in the effective image region to obtain the target pixel points in the effective image region.

[0074] Specifically, the preset threshold is preset, and after obtaining the pixel values of the respective pixel points in the effective image region, the pixel value of each pixel point is compared with the preset threshold respectively. When the pixel value of a pixel point is less than the preset threshold, the pixel point is a target pixel point. Otherwise, when the pixel value of a pixel point is greater than or equal to the preset threshold, the pixel point is not a target pixel point. In this embodiment, the pixel values of the pixel points with pixel values less than the preset threshold are all regarded as target pixel points, and the pixel values of the target pixel points are corrected, so that the contrast of the ROS map can be avoided, and the image quality of the ROS map can be improved. In an implementation manner of this embodiment, the preset threshold can be 240, the effective image region includes a pixel point a, a pixel point b and a pixel point c, the pixel value of the pixel point a is 245, the pixel value of the pixel point b is 250, and the pixel value of the pixel point c is 220. Therefore, the pixel value 220 of the pixel point c is less than the preset threshold 240, and the pixel point c is a target pixel point. The pixel value 245 of the pixel point a is greater than the preset threshold 240, and the pixel value 250 of the pixel point b is greater than the preset threshold 240, so that the pixel point a and the pixel point b are not target pixel points.

[0075] S40, correcting the pixel value of the determined target pixel point to obtain a denoising map corresponding to the ROS map to be processed.

[0076] Specifically, correcting the pixel value of the target pixel point means adjusting the pixel value of the target pixel point to adjust the difference between the pixel value of the target pixel and the pixel value of the edge point of the effective image region, improve the contrast between the edge point and the non-edge point in the effective image region, and improve the display effect of the effective image region, which is convenient for users.

[0077] In an implementation manner of this embodiment, the correction of the pixel value of the determined target pixel point to obtain a denoising map corresponding to the ROS map to be processed is specifically as follows:

[0078] The pixel values of the respective target pixel points in the determined target pixel points are all set to a preset pixel value to obtain a denoising map corresponding to the ROS map to be processed.

[0079] Specifically, the preset pixel value is preset for replacing the pixel value of the target pixel point, wherein the preset pixel value can be 50, 60, etc. It can be understood that the pixel value of each target pixel point in the target pixel point is set to the preset pixel value. For example, the target pixel point includes target pixel point a and target pixel point b, and the pixel value of the target pixel point a is set to the preset pixel value, and the pixel value of the target pixel point b is set to the preset pixel value. In this way, the pixel value of each target pixel point is set to the preset pixel value, which can improve the contrast between the edge points and the non-edge points in the ROS map, thereby improving the display effect of the effective image region, bringing convenience to the user, for example, as shown in the ROS map Figure 6 obtained by modifying the pixel value of the target pixel point. Figure 7

[0080] In one specific implementation, the pixel value of each target pixel point in the determined target pixel point can be compared with the preset pixel value, and if the pixel value of the target pixel point is greater than the preset pixel value, the pixel value of the target pixel point is set to the preset pixel value, and if the pixel value of the target pixel point is less than the preset pixel value, the pixel value of the target pixel point is kept unchanged. In this way, only the pixel value of the target pixel point greater than the preset pixel value is set to the preset pixel value, which can reduce the number of target pixel points to be processed while improving the display effect of the effective image region, thereby improving the processing speed of the ROS map processing.

[0081] In one implementation of the present embodiment, after the pixel value of each target pixel point in the determined target pixel point is set to the preset pixel value to obtain the denoising map corresponding to the ROS map to be processed, the method further comprises:

[0082] dividing the denoising map into a plurality of image blocks;

[0083] For each image block in the plurality of image blocks, determining the average value of the pixel values of the pixel points in the image block, and setting the pixel values of the pixel points in the image block to the average value.

[0084] Specifically, each image block in the plurality of image blocks is included in the denoising map, each image block in the plurality of image blocks does not overlap, and the plurality of image blocks constitute the denoising map. For example, the plurality of image blocks include image block a, image block b and image block c, the image block a, the image block b and the image block c are part of the image region in the denoising map, the image block a, the image block b and the image block c do not overlap, and the image region formed by the image block a, the image block b and the image block c is the denoising map.

[0085] ​In one implementation of the embodiment, the number of pixels included in each image block is equal, that is, the image blocks are obtained by equally dividing the denoising map, and the denoising map can be obtained by using the ImageMagick tool to divide the ROS map into x rows and y columns of hexagons, and then modifying the RGB value in each hexagon to the average of the RGB values of all pixels in the original position to obtain the denoising image corresponding to the ROS map to be processed, for example, as shown in the image of Figure 8

[0086] In summary, the embodiment provides a ROS map processing method, which includes obtaining a ROS map to be processed and obtaining edge information corresponding to the ROS map to be processed; determining an effective image region of the ROS map to be processed based on the edge information; determining a target pixel point in the effective image region based on the pixel value of each pixel point in the effective image region; and modifying the pixel value of the determined target pixel point to obtain a denoising map corresponding to the ROS map to be processed. After obtaining the ROS map, the edge information of the ROS map is used to determine the corresponding effective image region, and the pixel value of the target pixel point in the effective image region is modified to remove the noise points in the ROS map, thereby improving the image quality of the ROS map and facilitating the use of the ROS map by users.

[0087] Based on the ROS map processing method described above, the embodiment provides a ROS map processing device, as shown in Figure 9 The ROS map processing device specifically includes:

[0088] An obtaining module 100 is configured to obtain a ROS map to be processed and obtain edge information corresponding to the ROS map to be processed;

[0089] A first determining module 200 is configured to determine an effective image region of the ROS map to be processed based on the edge information;

[0090] A second determining module 300 is configured to determine a target pixel point in the effective image region based on the pixel value of each pixel point in the effective image region;

[0091] A modifying module 400 is configured to modify the pixel value of the determined target pixel point to obtain a denoising map corresponding to the ROS map to be processed.

[0092] In one implementation, the obtaining module is specifically configured to:

[0093] perform blurring processing on the ROS map to be processed, and use the ROS map obtained by the blurring processing as the ROS map to be processed; ​

[0094] performing edge detection on the ROS map to be processed to obtain edge information corresponding to the ROS map to be processed.

[0095] In an implementation manner, the obtaining module is specifically configured to:

[0096] performing edge detection on the ROS map to be processed to obtain edge information corresponding to the ROS map to be processed.

[0097] The ROS map processing method, wherein the determining the target pixel points in the effective image region based on the pixel values of the pixel points in the effective image region specifically comprises:

[0098] obtaining the pixel values of the pixel points in the effective image region;

[0099] selecting, based on the respective pixel values of the pixel points, target pixel points with pixel values less than a preset threshold value in the effective image region to obtain the target pixel points in the effective image region.

[0100] In an implementation manner, the correcting module is specifically configured to:

[0101] setting the pixel values of the target pixel points to the preset pixel value to obtain a denoised map corresponding to the ROS map to be processed.

[0102] In an implementation manner, the ROS map processing apparatus further comprises:

[0103] a dividing module configured to divide the denoised map into a plurality of image blocks;

[0104] a setting module configured to, for each image block in the plurality of image blocks, determine an average value of the pixel values of the pixel points in the image block, and set the pixel values of the pixel points in the image block to the average value.

[0105] In an implementation manner, the plurality of image blocks are mutually exclusive, and each image block comprises an equal number of pixel points.

[0106] Based on the ROS map processing method described above, the embodiment provides a computer readable storage medium, which stores one or more programs, and the one or more programs can be executed by one or more processors to implement the steps in the ROS map processing method described in the above embodiment.

[0107] Based on the ROS map processing method described above, the present application further provides a terminal device, such as a mobile phone, a tablet computer, a computer, a server, or the like. Figure 10As shown, it comprises at least one processor 20, a display screen 21, and a memory 22, and can further comprise a communications interface 23 and a bus 24. Among them, the processor 20, the display screen 21, the memory 22 and the communications interface 23 can complete the communication among each other through the bus 24. The display screen 21 is arranged to display the preset user guide interface in the initial setting mode. The communications interface 23 can transmit information. The processor 20 can call the logical instructions in the memory 22 to execute the method in the above-mentioned embodiments.

[0108] In addition, the logical instructions in the memory 22 described above can be realized in the form of a software function unit and sold or used as an independent product, which can be stored in a computer readable storage medium.

[0109] The memory 22 as a computer readable storage medium can be arranged to store software programs, computer executable programs, such as program instructions or modules corresponding to the method in the embodiments of the present disclosure. The processor 20 executes the functions of the application and data processing by running the software programs, instructions or modules stored in the memory 22, that is, realizes the method in the above-mentioned embodiments.

[0110] The memory 22 can include a program storage area and a data storage area, wherein the program storage area can store an operating system and at least one application required by a function; the data storage area can store data created according to the use of the terminal device, etc. In addition, the memory 22 can include a high-speed random access memory, and can also include a non-volatile memory. For example, a variety of media that can store program codes, such as a U disk, a mobile hard disk, a read-only memory (Read-Only Memory, ROM), a random access memory (Random Access Memory, RAM), a magnetic disk or an optical disk, etc. can also be a transient storage medium.

[0111] In addition, the working process of the ROS map processing device, the storage medium, and the specific process of the multiple instruction processors in the mobile terminal loading and executing have been described in detail in the above method, and will not be repeated here.

[0112] Finally, it should be pointed out that: the above embodiments are only used to illustrate the technical solutions of the present application, and not to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that they can still modify the technical solutions recorded in the foregoing embodiments, or make equivalent replacement for part of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims

1. A method for processing ROS maps, characterized in that, The processing method includes: Obtain the ROS map to be processed, and obtain the edge information corresponding to the ROS map to be processed; Based on the edge information, the effective image region of the ROS map to be processed is determined; Based on the edge information, the connected regions in the ROS map to be processed are determined, and the largest connected region is selected as the effective image region from the determined connected regions. The target pixel in the effective image region is determined based on the pixel value of each pixel in the effective image region. Correct the pixel values ​​of the determined target pixels to obtain the denoised map corresponding to the ROS map to be processed; The process of correcting the pixel values ​​of the determined target pixels to obtain the denoised map corresponding to the ROS map to be processed specifically involves: Set the pixel value of each target pixel in the determined target pixel points to a preset pixel value to obtain the denoised map corresponding to the ROS map to be processed; The step of setting the pixel value of each target pixel in the determined target pixel points to a preset pixel value to obtain the denoised map corresponding to the ROS map to be processed specifically includes: The denoised map is divided into several image blocks; For each image block in a plurality of image blocks, determine the average value of the pixel values ​​of each pixel in the image block, and set the pixel values ​​of each pixel in the image block to the average value; Determining the target pixel in the effective image region based on the pixel values ​​of each pixel in the effective image region specifically includes: Obtain the pixel value of each pixel in the effective image region; Based on the pixel value corresponding to each pixel, target pixels with pixel values ​​less than a preset threshold are selected in the effective image area to obtain the target pixels in the effective image area; After obtaining the pixel values ​​of each pixel in the effective image area, it is determined whether the pixel meets the preset requirements corresponding to the target pixel based on the pixel values. The preset requirements are that the pixel value is less than a preset threshold or the pixel value is within a preset threshold range.

2. The ROS map processing method according to claim 1, characterized in that, After obtaining the ROS map to be processed and before obtaining the edge information corresponding to the ROS map to be processed, the method further includes: The ROS map to be processed is subjected to noise reduction processing, and the ROS map obtained by noise reduction processing is used as the ROS map to be processed.

3. The ROS map processing method according to claim 1, characterized in that, The specific steps for obtaining the ROS map to be processed are as follows: Use the ROS system to construct an environmental map corresponding to the environmental scene, so as to obtain the ROS map to be processed.

4. The ROS map processing method according to claim 1, characterized in that, The image blocks in the plurality of image blocks do not overlap with each other, and each image block includes an equal number of pixels.

5. A processing apparatus for ROS maps, characterized in that, The ROS map processing apparatus is applied to the ROS map processing method according to any one of claims 1-4, and the ROS map processing apparatus specifically includes: The acquisition module is used to acquire the ROS map to be processed and to acquire the edge information corresponding to the ROS map to be processed. The first determining module is used to determine the effective image region of the ROS map to be processed based on the edge information. The second determining module is used to determine the target pixel in the effective image region based on the pixel value of each pixel in the effective image region; The correction module is used to correct the pixel values ​​of the determined target pixels to obtain the denoised map corresponding to the ROS map to be processed.

6. 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 in the ROS map processing method as described in any one of claims 1-4.

7. 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 ROS map processing method as described in any one of claims 1-4.

Citation Information

Patent Citations

  • Indoor map construction method based on edge detection algorithm, computer storage medium and terminal

    CN110457417A

  • Image processing method, device and system

    CN111353958A