CN113522583A - Spraying method and device for article, terminal and storage medium - Google Patents
Spraying method and device for article, terminal and storage medium Download PDFInfo
- Publication number
- CN113522583A CN113522583A CN202110648810.8A CN202110648810A CN113522583A CN 113522583 A CN113522583 A CN 113522583A CN 202110648810 A CN202110648810 A CN 202110648810A CN 113522583 A CN113522583 A CN 113522583A
- Authority
- CN
- China
- Prior art keywords
- area
- image
- spraying
- sample
- path
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Classifications
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B05—SPRAYING OR ATOMISING IN GENERAL; APPLYING FLUENT MATERIALS TO SURFACES, IN GENERAL
- B05B—SPRAYING APPARATUS; ATOMISING APPARATUS; NOZZLES
- B05B13/00—Machines or plants for applying liquids or other fluent materials to surfaces of objects or other work by spraying, not covered by groups B05B1/00 - B05B11/00
- B05B13/02—Means for supporting work; Arrangement or mounting of spray heads; Adaptation or arrangement of means for feeding work
- B05B13/04—Means for supporting work; Arrangement or mounting of spray heads; Adaptation or arrangement of means for feeding work the spray heads being moved during spraying operation
- B05B13/0431—Means for supporting work; Arrangement or mounting of spray heads; Adaptation or arrangement of means for feeding work the spray heads being moved during spraying operation with spray heads moved by robots or articulated arms, e.g. for applying liquid or other fluent material to 3D-surfaces
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B05—SPRAYING OR ATOMISING IN GENERAL; APPLYING FLUENT MATERIALS TO SURFACES, IN GENERAL
- B05B—SPRAYING APPARATUS; ATOMISING APPARATUS; NOZZLES
- B05B12/00—Arrangements for controlling delivery; Arrangements for controlling the spray area
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B05—SPRAYING OR ATOMISING IN GENERAL; APPLYING FLUENT MATERIALS TO SURFACES, IN GENERAL
- B05B—SPRAYING APPARATUS; ATOMISING APPARATUS; NOZZLES
- B05B12/00—Arrangements for controlling delivery; Arrangements for controlling the spray area
- B05B12/08—Arrangements for controlling delivery; Arrangements for controlling the spray area responsive to condition of liquid or other fluent material to be discharged, of ambient medium or of target ; responsive to condition of spray devices or of supply means, e.g. pipes, pumps or their drive means
- B05B12/12—Arrangements for controlling delivery; Arrangements for controlling the spray area responsive to condition of liquid or other fluent material to be discharged, of ambient medium or of target ; responsive to condition of spray devices or of supply means, e.g. pipes, pumps or their drive means responsive to conditions of ambient medium or target, e.g. humidity, temperature position or movement of the target relative to the spray apparatus
- B05B12/122—Arrangements for controlling delivery; Arrangements for controlling the spray area responsive to condition of liquid or other fluent material to be discharged, of ambient medium or of target ; responsive to condition of spray devices or of supply means, e.g. pipes, pumps or their drive means responsive to conditions of ambient medium or target, e.g. humidity, temperature position or movement of the target relative to the spray apparatus responsive to presence or shape of target
Landscapes
- Engineering & Computer Science (AREA)
- Robotics (AREA)
- Application Of Or Painting With Fluid Materials (AREA)
- Spray Control Apparatus (AREA)
Abstract
The application is applicable to the field of image processing, and provides a spraying method, a spraying device, a spraying terminal and a storage medium for an article. Wherein the spraying method of the article comprises the following steps: acquiring a first image, wherein the first image is an image obtained by shooting an article to be sprayed; determining a sample image from at least one sample image as a target sample image of the first image according to the first image; obtaining a sample spraying path associated with the target sample image, and correcting the sample spraying path to obtain a target spraying path of the object to be sprayed; and spraying the object to be sprayed according to the target spraying path. The embodiment of the application can improve the efficiency of article spraying.
Description
Technical Field
The application belongs to the field of image processing, and particularly relates to a spraying method, a spraying device, a spraying terminal and a storage medium for an article.
Background
Spray coating refers to a coating method in which a coating material is applied to the surface of an article by a spray gun by means of pressure or centrifugal force. With the development of science and technology, an automatic spraying technology combining machine vision becomes a research hotspot of the spraying industry.
However, the current automatic spraying method requires a terminal to spend a lot of time to perform calculation processing, resulting in low efficiency of spraying the objects.
Disclosure of Invention
The embodiment of the application provides a spraying method, a spraying device, a terminal and a storage medium for an article, and the spraying efficiency of the article can be improved.
In a first aspect, an embodiment of the present application provides a method for spraying an article, including:
acquiring a first image, wherein the first image is an image obtained by shooting an article to be sprayed;
determining a sample image from at least one sample image as a target sample image of the first image according to the first image;
obtaining a sample spraying path associated with the target sample image, and correcting the sample spraying path to obtain a target spraying path of the object to be sprayed;
and spraying the object to be sprayed according to the target spraying path.
According to a second aspect of the embodiments of the present application, there is provided an article spray coating device, including:
the device comprises a first image acquisition unit, a second image acquisition unit and a control unit, wherein the first image acquisition unit is used for acquiring a first image, and the first image is an image obtained by shooting an article to be sprayed;
a target sample image determining unit configured to determine, from at least one sample image, one sample image as a target sample image of the first image, based on the first image;
the target spraying path determining unit is used for acquiring a sample spraying path related to the target sample image, and correcting the sample spraying path to obtain a target spraying path of the object to be sprayed;
and the object spraying unit is used for spraying the object to be sprayed according to the target spraying path.
A third aspect of the embodiments of the present application provides a terminal, including a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor implements the steps of the method when executing the computer program.
A fourth aspect of the embodiments of the present application provides a computer-readable storage medium, which stores a computer program, and when the computer program is executed by a processor, the computer program implements the steps of the above method.
A fifth aspect of embodiments of the present application provides a computer program product, which when run on a terminal, causes the terminal to perform the steps of the method.
In the embodiment of the application, one sample image is determined as a target sample image from at least one sample image according to the first image; then, obtaining a sample spraying path associated with the target sample image, and correcting the sample spraying path to obtain a target spraying path of the object to be sprayed; spraying the object to be sprayed according to the target spraying path; the terminal does not need to carry out brand-new path planning on each object to be sprayed, and only needs to modify the existing sample spraying path to obtain the target spraying path of the object to be sprayed, so that the calculation amount of the terminal path planning is reduced, and the object spraying efficiency is improved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the embodiments or the prior art descriptions will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without inventive exercise.
Fig. 1 is a schematic flow chart of an implementation of a method for spraying an article according to an embodiment of the present disclosure;
fig. 2 is a schematic flow chart of a first specific implementation of correcting a sample spray path according to an embodiment of the present disclosure;
fig. 3 is a schematic flowchart of a second specific implementation of correcting a sample spray path according to an embodiment of the present disclosure;
FIG. 4 is a schematic diagram of a first image provided by an embodiment of the present application;
fig. 5 is a schematic flowchart of a specific implementation of determining a first sub-path according to an embodiment of the present application;
fig. 6 is a schematic flow chart of a specific implementation of spraying an article to be sprayed according to an embodiment of the present application;
FIG. 7 is a schematic structural diagram of a spraying device for spraying an article according to an embodiment of the present disclosure;
fig. 8 is a schematic structural diagram of a terminal according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the present application without making any creative effort, shall be protected by the present application.
Spray coating refers to a coating method in which a coating material is applied to the surface of an article by a spray gun by means of pressure or centrifugal force. With the development of science and technology, an automatic spraying technology combining machine vision becomes a research hotspot of the spraying industry.
The existing automatic spraying mode needs to establish a point cloud model according to point cloud data of each article and carry out path planning on the basis of the point cloud model. In this way, a terminal is required to perform brand-new point cloud model establishment and brand-new path planning on each article. When the specification of the article is large, the calculation amount for establishing the point cloud model and the calculation amount for path planning are increased by orders of magnitude, so that the terminal needs to spend a large amount of time for calculation processing, the efficiency of article spraying is reduced, and meanwhile, equipment needs to have high calculation capability, and the production cost is improved.
In order to explain the technical means of the present application, the following description will be given by way of specific examples.
Fig. 1 shows a schematic implementation flow diagram of a method for spraying an article according to an embodiment of the present application, where the method can be applied to a terminal and is applicable to a situation where the efficiency of spraying the article needs to be improved. The terminal can be a smart phone, a computer and other equipment.
Specifically, the method for spraying the article may include the following steps S101 to S104.
Step S101, a first image is acquired.
The first image is an image obtained by shooting an article to be sprayed, and the article to be sprayed is an article needing spraying.
In the embodiments of the present application, the manner and type of acquiring the first image are not limited. In some embodiments of the present application, the first image may be an RGB image obtained by shooting the object to be painted with an optical camera. In other embodiments of the present application, the first image may be a depth image obtained by shooting an object to be painted with a depth camera.
Step S102, determining a sample image from at least one sample image as a target sample image of the first image according to the first image.
In an embodiment of the present application, the sample image is an image obtained by shooting a sample article for which the spray path planning has been completed. The sample image may include images obtained by shooting different sample articles, and may also include images obtained by shooting the same article at different angles.
In some embodiments of the present application, the sample image may be stored in a memory of the terminal, or may be stored in the cloud server. When an article to be sprayed needs to be sprayed, the terminal can acquire at least one sample image from the memory or the cloud server. Then, based on the first image, one sample image is determined from the at least one sample image as a target sample image of the first image.
And step S103, obtaining a sample spraying path associated with the target sample image, and correcting the sample spraying path to obtain a target spraying path of the object to be sprayed.
In an embodiment of the present application, the spray path is a path used for controlling a spray gun to spray the article.
In an embodiment of the application, because the target sample image is an image obtained by shooting a sample article for which the spray path planning has been completed, the terminal may obtain the spray path for which the sample article corresponding to the target sample image is planned, that is, obtain the sample spray path associated with the target sample image. And then, correcting the planned sample spraying path to obtain a target spraying path of the object to be sprayed.
The sample spraying path can be stored in a memory of the terminal or a cloud server. When the sample image and the sample spraying path are stored, the sample image and the sample spraying path which are associated with each other can be identified by the same identification information, so that the terminal can acquire the sample spraying path associated with the target sample image based on the identification information of the target sample image.
After obtaining the sample spray path associated with the target sample image, the terminal may correct the sample spray path.
Specifically, in some embodiments of the application, the terminal may compare the first image with the target sample image, determine an image area in which a difference exists, and determine a new path required by the image area in which the difference exists in the first image, so as to correct the sample spraying path according to the new path required by the image area in which the difference exists in the first image, and obtain the target spraying path of the object to be sprayed.
The present application does not limit the determination method of the target sample image.
In some embodiments of the present application, the terminal may determine an image similarity, and then determine a sample image from at least one sample image as the target sample image according to the image similarity.
The image similarity refers to a similarity between each sample image of the at least one sample image and the first image.
In some embodiments of the present application, the higher the image similarity between the first image and the sample image, the more similar the surface of the portion of the object to be painted corresponding to the first image and the surface of the portion of the sample object corresponding to the sample image are.
Based on this, one sample image may be determined as the target sample image from among the at least one sample image according to the image similarity. For example, in some embodiments of the present application, an image whose image similarity is greater than a preset threshold may be taken as a target sample image.
And, as the image similarity between the target sample image and the first image is higher, the correction amount for correcting the sample spray path associated with the target sample image is smaller.
Therefore, in some embodiments of the present application, a sample image having the highest image similarity with the first image in the at least one sample image may be used as the target sample image. At the moment, the terminal only needs to modify the sample spraying path by a small amount to obtain the target spraying path, so that the calculation efficiency of the application can be effectively improved.
And step S104, spraying the object to be sprayed according to the target spraying path.
Specifically, the terminal can control the spray gun to move according to the target spraying path to spray the object to be sprayed, so that the surface of the object to be sprayed is sprayed with the spraying material.
In the embodiment of the application, one sample image is determined as a target sample image from at least one sample image according to the first image; then, obtaining a sample spraying path associated with the target sample image, and correcting the sample spraying path to obtain a target spraying path of the object to be sprayed; spraying the object to be sprayed according to the target spraying path; the terminal does not need to carry out brand-new path planning on each object to be sprayed, and only needs to modify the existing sample spraying path to obtain the target spraying path of the object to be sprayed, so that the calculation amount of the terminal path planning is reduced, and the object spraying efficiency is improved.
In order to determine the portion of the sample spray path that needs to be corrected, in some embodiments of the present application, the region to be corrected may be determined based on the similarity between the first image and the image region of each portion in the target sample image.
Specifically, in some embodiments of the present application, as shown in fig. 2, the correcting the sample spraying path to obtain the target spraying path of the object to be sprayed may include the following steps S201 to S205.
Step S201, performing image segmentation on the first image according to a preset segmentation policy to obtain at least one first region.
The application does not limit the specific rules of the segmentation strategy. In some embodiments of the present application, the preset segmentation policy may be an equal segmentation policy, that is, the first image is equally segmented to obtain at least one first region, and each first region is a region formed by at least one pixel in the first image.
In order to meet the requirement of practical application, in other embodiments of the present application, the segmentation strategy may further include: and determining the size and the step length of the sliding window based on the shape of the nozzle, and segmenting the image according to the size and the step length of the sliding window. Namely, the sliding window slides on the first image according to the step length, and the image area where the sliding window is located each time is used as a first area.
Step S202, image segmentation is carried out on the target sample image according to a preset segmentation strategy, and at least one second area is obtained.
That is, in some embodiments of the present application, it is necessary to perform image segmentation on the target sample image by using a segmentation strategy for performing image segmentation on the first image, so as to obtain at least one second region. Similarly, each second region is a region formed by at least one pixel point in the target sample image.
Step S203 calculates a first region similarity between each first region in the first image and a second region corresponding to each first region in the target sample image.
In some embodiments of the present application, the terminal may match, for each first region in the first image, a second region corresponding to each first region in the target sample image, based on image regions obtained by image segmentation of the first region and the second region with the same segmentation strategy.
For example, when the above-mentioned segmentation strategy is equal segmentation, a second region on the same pixel coordinate in the target sample image may be determined as a second region corresponding to the first region according to the pixel coordinate where the first region is located.
When similar image areas exist in the first image and the target sample image, the sub-path corresponding to the similar image area on the spraying path of the object to be sprayed is also the same or similar to the sub-path corresponding to the similar image area on the sample spraying path, which indicates that the sub-path corresponding to the similar image area on the sample spraying path may not be corrected.
Conversely, when the first image and the target sample image have dissimilar image areas, the sub-path corresponding to the dissimilar image area on the spraying path of the object to be sprayed and the sub-path corresponding to the dissimilar image area on the sample spraying path are dissimilar, which indicates that the sub-path corresponding to the dissimilar image area on the sample spraying path needs to be corrected.
Therefore, the terminal may calculate a first region similarity between each first region in the first image and a second region corresponding to each first region in the target sample image, and each first region similarity may represent a degree of similarity between the first region and the second region.
The calculation mode of the region similarity can be adjusted by a worker according to the actual situation. In some embodiments of the present application, a first region similarity between a first region and a second region corresponding to the first region may be calculated based on a mean value of pixel values of respective pixel points in the first region and a mean value of pixel values of respective pixel points in the second region corresponding to the first region. In other embodiments of the present application, the first region similarity between the first region and the corresponding second region may also be calculated based on other image parameters such as a depth value between the first region and the corresponding second region.
Step S204, a first area, with the similarity of the first area between the first image and the target sample image smaller than a first similarity threshold value, is used as an area to be corrected, and a second area, corresponding to the area to be corrected, in the target sample image is used as a sample correction area.
In some embodiments of the present application, when a similarity of a first region between the first region in the first image and a second region corresponding to the target sample image is smaller than a first similarity threshold, it indicates that there is a large difference between the first region and the second region corresponding to the first region. Correspondingly, the actual spraying path corresponding to the first area and the sub-path corresponding to the second area in the sample spraying path have a larger difference. At this time, a first region in the first image, where a similarity of the first region to the target sample image is smaller than a first similarity threshold, is required to be used as a region to be corrected, and a second region in the target sample image, which corresponds to the region to be corrected, is required to be used as a sample correction region, so that a sub-path corresponding to the sample correction region is corrected by using the region to be corrected.
The specific value of the first similarity threshold can be adjusted according to the actual situation.
And S205, correcting the sample spraying path according to the area to be corrected and the sample correction area to obtain a target spraying path of the object to be sprayed.
In the embodiment of the application, the first image and the target sample image are respectively divided into at least one first area and at least one second area by the same division strategy; then, a first area, with the similarity of the first area between the first image and the target sample image smaller than a first similarity threshold, is used as a to-be-corrected area, a second area, corresponding to the to-be-corrected area, in the target sample image is used as a sample correction area, so that a sub-path corresponding to the sample correction area is corrected by using the to-be-corrected area, the terminal can correct a sub-path corresponding to the second area, which is dissimilar to the first area, on the sample spraying path, and therefore the calculation amount required for path planning on the similar area is reduced, and the efficiency of spraying the article is improved.
It should be noted that the present application does not limit the specific implementation manner of correcting the sample spraying path.
In some embodiments of the application, the spraying position of the sample correction path corresponding to each to-be-corrected area on the sample spraying path may be updated in sequence according to each to-be-corrected area to obtain a new path, and the new path is used as the target spraying path of the to-be-sprayed article.
In order to further improve the correction efficiency, in other embodiments of the present application, as shown in fig. 3, the correcting the sample spraying path according to the area to be corrected and the sample correction area to obtain the target spraying path of the object to be sprayed may further include the following steps S301 to S305.
In step S301, a boundary region in a region composed of a region to be corrected is determined.
In some embodiments of the present application, each to-be-corrected region may be regarded as a point, a region composed of the to-be-corrected regions is determined based on a connected domain algorithm, and then a boundary region located on a boundary in the region composed of the to-be-corrected regions is determined based on a position of each to-be-corrected region, that is, it is determined that there is a to-be-corrected region in which any adjacent region is not the to-be-corrected region.
In particular, the connected component algorithm may include, but is not limited to, a two-pass scanning method, a seed filling method, or other connected component algorithms.
Step S302, a spraying direction corresponding to the sample spraying path is obtained, and a first boundary region in the spraying direction is used as a first region to be processed.
In some embodiments of the present application, the spraying direction refers to a traveling direction of the spray gun when spraying is performed based on the sample spraying path, and the spraying direction may be horizontal, vertical, or the like. In order to keep the actual trend of the sample spraying path, in the embodiment of the present application, the correction may be performed according to the sequence of the spraying directions corresponding to the sample spraying path.
First, a first boundary region in the spraying direction may be selected as a first region to be processed, which is a currently processed region to be corrected.
Step S303, detecting whether the first neighboring area is an area to be corrected.
The first adjacent area refers to an area adjacent to the first area to be processed in the spraying direction in the first image. That is, the terminal needs to detect whether an area adjacent to the first area to be processed in the painting direction in the first image is also an area to be corrected.
In some embodiments of the application, if the first adjacent area is an area to be corrected, it indicates that there is an area to be corrected that is communicated with the first area to be processed in the spraying direction, and at this time, the terminal may perform a batch path correction operation on a plurality of areas to be corrected that are communicated with each other in the spraying direction.
In other embodiments of the present application, if the first adjacent area is not the area to be corrected, it indicates that there is no area to be corrected communicating with the first area to be processed in the spraying direction, and at this time, the terminal may perform the path correction operation on the area to be processed alone.
Step S304, if the first adjacent area is an area to be corrected, determining a second area to be processed, wherein the second area to be processed is a next boundary area of the first area to be processed in the spraying direction, and a second adjacent area of the second area to be processed is not the area to be corrected, wherein the second adjacent area is an area adjacent to the second area to be processed in the spraying direction in the first image; determining a first sub-path according to the first to-be-processed area, the second to-be-processed area and each to-be-corrected area between the first to-be-processed area and the second to-be-processed area; determining a first sample correction area corresponding to the first area to be processed in the sample correction area and a second sample correction area corresponding to the second area to be processed in the sample correction area; updating a second sub-path between the first sample correction area and the second sample correction area on the sample spraying path into a first sub-path; and taking the next boundary area of the second area to be processed in the spraying direction as the first area to be processed, and re-executing the step of detecting whether the first adjacent area is the area to be corrected and the subsequent steps until the next boundary area does not exist in the spraying direction of the second area to be processed, so as to obtain the target spraying path of the object to be sprayed.
Specifically, in some embodiments of the present application, if the first adjacent area is an area to be corrected, the terminal may determine a second area to be processed, where the second area to be processed is a next boundary area of the first area to be processed in the spraying direction, and a second adjacent area of the second area to be processed is not the area to be corrected.
The second adjacent area refers to an area adjacent to the second area to be processed in the spraying direction in the first image.
At this time, the first to-be-processed region, the second to-be-processed region, and each to-be-corrected region between the first to-be-processed region and the second to-be-processed region are communicated with each other, and based on this, the terminal may determine the first sub-path according to the first to-be-processed region, the second to-be-processed region, and each to-be-corrected region between the first to-be-processed region and the second to-be-processed region.
The first sub-path is a walking path used by the spray gun to spray from the first area to be processed to the second area to be processed along the spraying direction.
Then, the terminal may determine a first sample correction area corresponding to the first to-be-processed area in the sample correction area, and a second sample correction area corresponding to the second to-be-processed area in the sample correction area; and updating a second sub-path between the first sample correction area and the second sample correction area on the sample spraying path to be the first sub-path.
The second sub-path is a walking path used by the spray gun to spray from the first sample correction area to the second sample correction area along the spraying direction.
That is, the terminal may replace the second sub-path in the sample spray path with the first sub-path to obtain the modified spray path.
Then, the terminal may use a next boundary region of the second region to be processed in the spraying direction as the first region to be processed, and re-perform the step of detecting whether the first adjacent region is the region to be corrected and the subsequent steps. That is, after completing the path correction step for the first to-be-processed region, the second to-be-processed region, and the connected region formed by the to-be-corrected regions between the first to-be-processed region and the second to-be-processed region, the terminal may skip the connected region and start processing the next to-be-processed region. Until the second area to be processed does not have the next boundary area in the spraying direction, the correction of the paths corresponding to all the areas to be corrected is completed, and the target spraying path of the object to be sprayed is obtained.
Step S305, if the first adjacent area is not the area to be corrected, determining a first sample correction area corresponding to the first area to be processed in the sample correction area, and updating the spraying position on the sample spraying path corresponding to the first sample correction area according to the first area to be processed; and taking the next boundary area of the first area to be processed in the spraying direction as the first area to be processed, and re-executing the step of detecting whether the first adjacent area is the area to be corrected and the subsequent steps until the next boundary area does not exist in the spraying direction in the first area to be processed, so as to obtain the target spraying path of the object to be sprayed.
The spraying position refers to a position where the spray gun is located when the spray gun sprays the surface of the article corresponding to the first sample correction area.
Specifically, in some embodiments of the present application, if the first adjacent region is not the region to be corrected, a first sample correction region corresponding to the first region to be processed in the sample correction region is determined. Based on this, the terminal can determine a first sample correction area corresponding to the first to-be-processed area in the sample correction area, and update the spraying position on the sample spraying path corresponding to the first sample correction area according to the first to-be-processed area.
That is, the terminal may replace the spraying position of the first sample correction area in the sample spraying path with the spraying position corresponding to the area to be corrected, so as to obtain the corrected spraying path.
Then, the terminal may use a next boundary region of the first region to be processed in the spraying direction as the first region to be processed, and re-perform the step of detecting whether the first adjacent region is the region to be corrected and the subsequent steps. That is, after completing the path correction step for the first region to be processed, the terminal may skip the first region to be processed and start processing the next first region to be processed. Until the first area to be processed does not have the next boundary area in the spraying direction, the correction of the corresponding paths of all the areas to be corrected is completed, and the target spraying path of the object to be sprayed is obtained.
For ease of illustration, FIG. 4 shows a schematic view of a first image; the dotted filling area and the oblique filling area both represent areas to be corrected, and the dotted filling area represents a boundary area in the areas to be corrected. When the correction is performed on the row where the area to be corrected 41 is located, the spraying direction is the spraying from the area to be corrected 41 to the area to be corrected 44 in the lateral direction. At this time, if the area to be corrected 41 is taken as the first area to be processed, and the first adjacent area 42 is taken as the area to be corrected, it is necessary to determine the second area to be processed, and since the second area to be processed is the next boundary area of the first area to be processed in the spraying direction, and the second adjacent area of the second area to be processed is not taken as the area to be corrected, the second area to be processed of the first adjacent area 42 is taken as the area to be corrected 43; then, a first sub-path from the first generation processing area 41 to the second to-be-processed area 43 is determined, and the sample spraying path is corrected.
Then, the next boundary area 44 above and below with respect to the spraying direction of the second area to be processed 43 can be selected as the first area to be processed. Since the region to be processed 44 does not have the first adjacent region, that is, the first adjacent region is not the region to be corrected, the first sample correction region corresponding to the first region to be processed 44 in the sample correction region can be determined, and the spraying position on the sample spraying path corresponding to the first sample correction region is updated according to the first region to be processed 44. Since there is no next boundary region in the painting direction with respect to the first region to be processed 44, which indicates that the painting path correction is completed, a final target painting path can be obtained.
In the embodiment of the application, the connected regions to be corrected are combined and corrected in the spraying direction, and meanwhile, the independent first regions to be corrected in the spraying direction are independently corrected, so that batch correction of the sample target regions can be realized, and compared with the case that the regions to be corrected one by one are corrected, the loss of information of the first adjacent region in the correction process can be reduced, and the path obtained through correction is higher in accuracy.
It should be noted that, in some embodiments of the present application, the terminal may determine the first sub-path between the first to-be-processed area and the second to-be-processed area in different manners when executing step S304.
In some embodiments of the present application, the terminal may determine the first sub-path according to the depth information of the first to-be-processed region, the depth information of the second to-be-processed region, and the depth information of each to-be-corrected region between the first to-be-processed region and the second to-be-processed region.
Specifically, according to the depth information of the first to-be-processed area, the depth information of the second to-be-processed area, and the depth information of each to-be-corrected area between the first to-be-processed area and the second to-be-processed area, the terminal may perform coordinate conversion on the depth information of each to-be-corrected area to obtain point cloud data corresponding to each to-be-corrected area, and determine the first sub-path based on the point cloud data corresponding to each to-be-corrected area.
The above-described depth information acquisition method may be adjusted according to actual conditions. For example, when the camera that collects the first image is a depth camera, the first image itself may carry depth information of each pixel point, and according to the depth information of the pixel points in each region to be corrected, the depth information of each correction region may be calculated, for example, an average value of the depth values of the pixel points in each region to be corrected is used as the depth value of the region to be corrected. In other embodiments of the present application, the depth information may also be determined by a binocular camera, or by an active measurement method such as laser ranging.
Considering that acquiring depth information requires field configuration with professional equipment, and determining a path based on the depth information increases the cost of practical application, in other embodiments of the present application, as shown in fig. 5, the determining a first sub-path according to the first to-be-processed area, the second to-be-processed area, and each to-be-corrected area between the first to-be-processed area and the second to-be-processed area may further include the following steps S501 to S503.
Step S501, a target correction area composed of the first area to be processed, the second area to be processed, and each area to be corrected between the first area to be processed and the second area to be processed is determined.
Since the first to-be-processed region, the second to-be-processed region, and each to-be-corrected region between the first to-be-processed region and the second to-be-processed region are one communicated region, the terminal can determine the target correction region composed of the first to-be-processed region, the second to-be-processed region, and each to-be-corrected region between the first to-be-processed region and the second to-be-processed region, that is, determine one region communicated in the spraying direction.
Step S502, whether an image area with the second area similarity larger than a second similarity threshold exists in each sample image of at least one sample image or not is detected.
Specifically, in some embodiments of the present application, the shape of the target correction region may be obtained, the shape of the target correction region is used as a window, the length of the target correction region in the spraying direction is used as a step length, the movement is performed in each sample image, and a second region similarity between an image region formed by pixel points in each window and the target correction region is calculated.
The calculation method of the similarity of the second region may refer to the calculation method of the similarity of the first region, which is not described in detail herein. Similarly, the specific value of the similarity of the second region may also be adjusted according to the actual situation.
In step S503, if there is an image area whose second area similarity with the target correction area is greater than the second similarity threshold, a third sub-path corresponding to the image area whose second area similarity with the target correction area is greater than the second similarity threshold is acquired, and the third sub-path is taken as the first sub-path.
In some embodiments of the present application, when a second region similarity between a certain image region and a target correction region is greater than a second similarity threshold, which indicates that the image contents of the image region and the target correction region are similar, a path used when a surface of an article corresponding to the image region is painted is similar to a path used when a surface of an article corresponding to the target correction region is painted.
Therefore, if there is an image area whose second area similarity with the target correction area is greater than the second similarity threshold, the terminal may acquire a third sub-path corresponding to the image area whose second area similarity with the target correction area is greater than the second similarity threshold, and use the third sub-path as the second sub-path.
Accordingly, in other embodiments of the present application, if there is no image area having a second area similarity greater than a second similarity threshold with the target correction area, the terminal may determine the second sub-path in the manner based on the depth information.
In the embodiment of the application, whether an image area with the second area similarity between the image area and the target correction area larger than the second similarity threshold exists in each sample image of at least one sample image or not can be detected, a third sub-path corresponding to the image area with the second area similarity between the image area and the target correction area larger than the second similarity threshold can be used as the second sub-path, so that the terminal does not need to obtain the depth information of the target correction area and establish a point cloud model, and only needs to splice the third sub-path in the existing sample spraying path to the sample spraying path associated with the target sample image, a target spraying path for spraying an article to be sprayed can be obtained, the equipment cost is saved, the calculation amount required for establishing the point cloud model can be saved, and the article spraying efficiency is improved.
In addition, in practical application, because the communicated areas to be corrected are combined for correction, a spray head with a larger caliber can be used for spraying, so that the spraying efficiency is improved, and the requirements on the caliber of the spray head used in a sample spraying path are not limited.
For example, in some embodiments of the present application, the terminal may determine whether the first sub-path is a straight line after determining the first sub-path according to the first to-be-processed region, the second to-be-processed region, and each to-be-corrected region between the first to-be-processed region and the second to-be-processed region. If the first sub-path is a straight line, the positions for spraying the areas to be corrected are on the same height. Therefore, the terminal may switch the nozzles according to the size of the target correction area when the first sub-path is a straight line, and re-determine a fourth sub-path as a new first sub-path based on the nozzle size of the new nozzle after switching and the target correction area. Optionally, the size of the new nozzle may be larger than the size of the nozzle used in the sample spraying path, so that the efficiency of spraying the object may be further improved.
In some embodiments of the application, after the spraying of the plane corresponding to the first image is completed, the terminal may further adjust a pose of an article to be sprayed; then, acquiring a second image obtained by shooting an article to be sprayed, and detecting an area which is not sprayed in the second image; and then, determining a new target spraying path of the object to be sprayed based on the non-spraying area, and spraying the object to be sprayed according to the new target spraying path. And repeating the steps until no non-spraying area exists in the newly acquired image, and finishing the spraying of the whole object to be sprayed.
In practical application, the object to be painted may be a brand-new object with a special surface shape, and at this time, there may be no image similar to the first image in the sample image. To avoid this problem, as shown in fig. 6, in some embodiments of the present application, after determining the image similarity between each of the at least one sample image and the first image, the following steps S601 to S605 may be further included.
Step S601, if the image similarity is smaller than the second similarity threshold, point cloud data of the object to be sprayed is obtained.
In some embodiments of the application, when the image similarity is smaller than the second similarity threshold, which indicates that there is no pattern that is relatively similar to the first image, the terminal needs to modify the path greatly based on the sample spray path associated with any one sample image. Based on the method, the terminal can directly acquire the point cloud data of the object to be sprayed and determine a target spraying path according to the point cloud data.
Specifically, the manner of acquiring the point cloud data may be selected according to actual conditions. For example, the object to be sprayed can be shot by a depth camera to obtain a point cloud model of the object to be sprayed.
Step S602, a point cloud model of the article to be sprayed is established according to the point cloud data of the article to be sprayed.
Specifically, in some embodiments of the present application, point cloud data may be subjected to point cloud aggregation and smoothing to remove noise, and a point cloud model is established in modeling software based on the point cloud data after the noise removal.
And step S603, fitting the point cloud model according to the first image corresponding plane to obtain the minimum external cuboid of the point cloud model.
Specifically, in some embodiments of the present application, an origin point may be determined from the first image corresponding plane, two axial directions crossing the origin point and perpendicular to each other in the first image corresponding plane, and a third axial direction perpendicular to the first image corresponding plane; next, the point cloud model is traversed to find the maximum values a1, b1, and c1 in each axis direction in the point cloud model, and the minimum values a2, b2, and c2 in each axis direction in the point cloud model. The minimum circumscribed cuboid can be obtained by using the three-dimensional points (a1, b1, c1) and (a2, b2, c2) as the diagonal points of the minimum circumscribed cuboid.
Step S604, determining a corresponding spraying path on each plane of the minimum external cuboid of the point cloud model, and determining a target spraying path of the object to be sprayed according to the corresponding spraying path on each plane of the minimum external cuboid of the point cloud model.
Specifically, the terminal may project the point cloud model onto each plane of the minimum external cuboid, and then calculate a corresponding spraying path on each plane of the minimum external cuboid of the point cloud model based on point cloud data of points on each plane. And then forming a target spraying path of the object to be sprayed based on the corresponding spraying path combination on each plane.
In some embodiments of the application, in order to facilitate spraying, the terminal may further cluster points on each plane according to a shape of a nozzle of the nozzle and three-dimensional point cloud data corresponding to each point on each plane to obtain at least one cluster, and determine a spraying path on each plane according to the cluster on each plane. Wherein, the nozzle is used for spraying the object to be sprayed. At this point, one spraying operation of the nozzle can complete the spraying of the dots in one cluster.
And step S605, spraying the object to be sprayed according to the target spraying path.
In the embodiment of the application, when the image similarity between the sample image and the first image is smaller than the second similarity threshold, point cloud data of an article to be sprayed is obtained, a point cloud model is established, and the point cloud model is subjected to minimum external cuboid fitting according to the plane where the first image is located to obtain the minimum external cuboid of the point cloud model; then, determining a target spraying path of the object to be sprayed according to the corresponding spraying path on each plane of the minimum external cuboid of the point cloud model; the terminal can directly establish the point cloud model and plan the path under the condition that the image similar to the first image probably does not exist in the sample image, the precision of the target spraying path is ensured, a large amount of calculation caused by excessive correction on the path is avoided, and the article spraying efficiency is improved.
Moreover, based on the manner shown in fig. 6, after the target spraying path is determined, the terminal may save the first image as a sample image, and save the spraying path corresponding to the plane where the first image is located as a sample spraying path corresponding to the sample image, so as to enrich the scale of the sample image.
In an actual production environment, a group of same products are often required to be continuously sprayed on a production line, and by adopting the spraying method for the articles, the products do not need to be modeled every time, and only the acquisition of point cloud data, the establishment of a point cloud model and the spraying path planning of a first product are required. Then, for other products which are the same as the first product, the path of the first product can be used as a sample spraying path, and the sample spraying path is slightly corrected to obtain target spraying paths of other products, so that the efficiency of spraying the articles is improved. Meanwhile, the first image of the actual object to be sprayed can be referred to in the correction process, so that the corrected target spraying path is more consistent with the actual condition of the object to be sprayed, and the spraying precision of the object is ensured.
It should be noted that, for simplicity of description, the foregoing method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present application is not limited by the order of acts, as some steps may, in accordance with the present application, occur in other orders.
Fig. 7 is a schematic structural diagram of an article spray coating device 700 according to an embodiment of the present disclosure, where the article spray coating device 700 is disposed on a terminal.
Specifically, the spraying device 700 for the object may include: a first image acquisition unit 701, a target sample image determination unit 702, a target spray path determination unit 703 and an article spray unit 704.
A first image obtaining unit 701, configured to obtain a first image, where the first image is an image obtained by shooting an article to be sprayed;
a target sample image determining unit 702, configured to determine, according to the first image, one sample image from at least one sample image as a target sample image of the first image;
a target spraying path determining unit 703, configured to obtain a sample spraying path associated with the target sample image, and correct the sample spraying path to obtain a target spraying path of the to-be-sprayed article;
and the article spraying unit 704 is used for spraying the article to be sprayed according to the target spraying path.
In some embodiments of the present application, the target spray path determining unit 703 may be further specifically configured to: carrying out image segmentation on the first image according to a preset segmentation strategy to obtain at least one first region; performing image segmentation on the target sample image according to the preset segmentation strategy to obtain at least one second region; calculating a first region similarity between each of the first regions in the first image and a second region corresponding to each of the first regions in the target sample image; taking a first area, with the first area similarity between the first image and the target sample image smaller than a first similarity threshold, as an area to be corrected, and taking a second area, corresponding to the area to be corrected, in the target sample image as a sample correction area; and correcting the sample spraying path according to the area to be corrected and the sample correction area to obtain a target spraying path of the object to be sprayed.
In some embodiments of the present application, the target spray path determining unit 703 may be further specifically configured to: determining a boundary region in a region composed of the region to be corrected; acquiring a spraying direction corresponding to a sample spraying path, and taking a first boundary area in the spraying direction as a first area to be processed; detecting whether a first adjacent area is the area to be corrected, wherein the first adjacent area is an area adjacent to the first area to be processed in the spraying direction in the first image; if the first adjacent area is the area to be corrected, determining a second area to be processed, wherein the second area to be processed is a next boundary area of the first area to be processed in the spraying direction, and a second adjacent area of the second area to be processed is not the area to be corrected, and the second adjacent area is an area adjacent to the second area to be processed in the spraying direction in the first image; determining a first sub-path according to the first to-be-processed area, the second to-be-processed area and each to-be-corrected area between the first to-be-processed area and the second to-be-processed area; determining a first sample correction area corresponding to the first area to be processed in the sample correction area and a second sample correction area corresponding to the second area to be processed in the sample correction area; updating a second sub-path between a first sample correction area and a second sample correction area on the sample spraying path into a first sub-path; taking the next boundary area of the second area to be processed in the spraying direction as a first area to be processed, and re-executing the step of detecting whether the first adjacent area is the area to be corrected and the subsequent steps until the next boundary area of the second area to be processed does not exist in the spraying direction, so as to obtain a target spraying path of the object to be sprayed; if the first adjacent area is not the area to be corrected, determining a first sample correction area corresponding to the first area to be processed in the sample correction area, and updating a spraying position on the sample spraying path corresponding to the first sample correction area according to the first area to be processed; and taking the next boundary area of the first area to be processed in the spraying direction as the first area to be processed, and re-executing the step of detecting whether the first adjacent area is the area to be corrected and the subsequent steps until the next boundary area of the first area to be processed does not exist in the spraying direction, so as to obtain the target spraying path of the object to be sprayed.
In some embodiments of the present application, the target spray path determining unit 703 may be further specifically configured to: and determining a first sub-path according to the depth information of the first to-be-processed area, the depth information of the second to-be-processed area and the depth information of each to-be-corrected area between the first to-be-processed area and the second to-be-processed area.
In some embodiments of the present application, the target spray path determining unit 703 may be further specifically configured to: determining a target correction area which is composed of a first area to be processed, a second area to be processed and each area to be corrected between the first area to be processed and the second area to be processed; detecting whether an image area with a second area similarity larger than the second similarity threshold exists in each sample image in at least one sample image; and if the image area with the second area similarity between the image area and the target correction area larger than the second similarity threshold exists, acquiring a third sub-path corresponding to the image area with the second area similarity between the image area and the target correction area larger than the second similarity threshold, and taking the third sub-path as the first sub-path.
In some embodiments of the present application, the target sample image determination unit 702 may be further specifically configured to: determining image similarity, wherein the image similarity refers to the similarity between each sample image in the at least one sample image and the first image; and determining a sample image from at least one sample image as the target sample image according to the image similarity.
In some embodiments of the present application, the article spray unit 704 described above may also be specifically configured to: if the image similarity is smaller than a second similarity threshold value, point cloud data of the to-be-sprayed article are obtained; establishing a point cloud model of the article to be sprayed according to the point cloud data of the article to be sprayed; performing minimum external cuboid fitting on the point cloud model according to the first image corresponding plane to obtain a minimum external cuboid of the point cloud model; determining a corresponding spraying path on each plane of the minimum external cuboid of the point cloud model, and determining a target spraying path of the object to be sprayed according to the corresponding spraying path on each plane of the minimum external cuboid of the point cloud model; and spraying the object to be sprayed according to the target spraying path.
It should be noted that, for convenience and simplicity of description, the specific working process of the spraying device 700 for the above-mentioned object may refer to the corresponding process of the method described in fig. 1 to fig. 6, and is not repeated herein.
Fig. 8 is a schematic diagram of a terminal according to an embodiment of the present application. The terminal 8 may include: a processor 80, a memory 81 and a computer program 82 stored in said memory 81 and operable on said processor 80, for example a spray coating program for an article. The processor 80, when executing the computer program 82, implements the steps in the above-described embodiments of the method of spray coating of various articles, such as the steps S101 to S104 shown in fig. 1. Alternatively, the processor 80, when executing the computer program 82, implements the functions of the modules/units in the above-described device embodiments, such as the first image obtaining unit 701, the target sample image determining unit 702, the target spraying path determining unit 703 and the object spraying unit 704 shown in fig. 7.
The computer program may be divided into one or more modules/units, which are stored in the memory 81 and executed by the processor 80 to accomplish the present application. The one or more modules/units may be a series of computer program instruction segments capable of performing specific functions, which are used to describe the execution of the computer program in the terminal.
For example, the computer program may be divided into: the device comprises a first image acquisition unit, a target sample image determination unit, a target spraying path determination unit and an article spraying unit.
The specific functions of each unit are as follows: the device comprises a first image acquisition unit, a second image acquisition unit and a control unit, wherein the first image acquisition unit is used for acquiring a first image, and the first image is an image obtained by shooting an article to be sprayed; a target sample image determining unit configured to determine, from at least one sample image, one sample image as a target sample image of the first image, based on the first image; the target spraying path determining unit is used for acquiring a sample spraying path related to the target sample image, and correcting the sample spraying path to obtain a target spraying path of the object to be sprayed; and the object spraying unit is used for spraying the object to be sprayed according to the target spraying path.
The terminal may include, but is not limited to, a processor 80, a memory 81. Those skilled in the art will appreciate that fig. 8 is merely an example of a terminal and is not intended to be limiting and may include more or fewer components than those shown, or some components may be combined, or different components, e.g., the terminal may also include input-output devices, network access devices, buses, etc.
The Processor 80 may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic device, discrete hardware component, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The memory 81 may be an internal storage unit of the terminal, such as a hard disk or a memory of the terminal. The memory 81 may also be an external storage device of the terminal, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, which are equipped on the terminal. Further, the memory 81 may also include both an internal storage unit and an external storage device of the terminal. The memory 81 is used for storing the computer program and other programs and data required by the terminal. The memory 81 may also be used to temporarily store data that has been output or is to be output.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-mentioned division of the functional units and modules is illustrated, and in practical applications, the above-mentioned function distribution may be performed by different functional units and modules according to needs, that is, the internal structure of the apparatus is divided into different functional units or modules to perform all or part of the above-mentioned functions. Each functional unit and module in the embodiments may be integrated in one processing unit, or each unit may exist alone physically, or two or more units are integrated in one unit, and the integrated unit may be implemented in a form of hardware, or in a form of software functional unit. In addition, specific names of the functional units and modules are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present application. The specific working processes of the units and modules in the system may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and reference may be made to the related descriptions of other embodiments for parts that are not described or illustrated in a certain embodiment.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus/terminal and method may be implemented in other ways. For example, the above-described apparatus/terminal embodiments are merely illustrative, and for example, the division of the modules or units is only one logical division, and there may be other divisions when actually implemented, for example, a plurality of units or components may be combined or may be integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated modules/units, if implemented in the form of software functional units and sold or used as separate products, may be stored in a computer readable storage medium. Based on such understanding, all or part of the flow in the method of the embodiments described above can be realized by a computer program, which can be stored in a computer-readable storage medium and can realize the steps of the embodiments of the methods described above when the computer program is executed by a processor. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, and the like. It should be noted that the computer readable medium may contain content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media does not include electrical carrier signals and telecommunications signals as is required by legislation and patent practice.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not substantially depart from the spirit and scope of the embodiments of the present application and are intended to be included within the scope of the present application.
Claims (10)
1. A method of spraying an article, comprising:
acquiring a first image, wherein the first image is an image obtained by shooting an article to be sprayed;
determining a sample image from at least one sample image as a target sample image of the first image according to the first image;
obtaining a sample spraying path associated with the target sample image, and correcting the sample spraying path to obtain a target spraying path of the object to be sprayed;
and spraying the object to be sprayed according to the target spraying path.
2. The method of claim 1, wherein the modifying the sample spray path to obtain the target spray path of the object to be sprayed comprises:
carrying out image segmentation on the first image according to a preset segmentation strategy to obtain at least one first region;
performing image segmentation on the target sample image according to the preset segmentation strategy to obtain at least one second region;
calculating a first region similarity between each of the first regions in the first image and a second region corresponding to each of the first regions in the target sample image;
taking a first area, with the first area similarity between the first image and the target sample image smaller than a first similarity threshold, as an area to be corrected, and taking a second area, corresponding to the area to be corrected, in the target sample image as a sample correction area;
and correcting the sample spraying path according to the area to be corrected and the sample correction area to obtain a target spraying path of the object to be sprayed.
3. The method for spraying an article according to claim 2, wherein the step of correcting the sample spraying path according to the area to be corrected and the sample correction area to obtain a target spraying path of the article to be sprayed comprises:
determining a boundary region in a region composed of the region to be corrected;
acquiring a spraying direction corresponding to a sample spraying path, and taking a first boundary area in the spraying direction as a first area to be processed;
detecting whether a first adjacent area is the area to be corrected, wherein the first adjacent area is an area adjacent to the first area to be processed in the spraying direction in the first image;
if the first adjacent area is the area to be corrected, determining a second area to be processed, wherein the second area to be processed is a next boundary area of the first area to be processed in the spraying direction, and a second adjacent area of the second area to be processed is not the area to be corrected, and the second adjacent area is an area adjacent to the second area to be processed in the spraying direction in the first image; determining a first sub-path according to the first to-be-processed area, the second to-be-processed area and each to-be-corrected area between the first to-be-processed area and the second to-be-processed area; determining a first sample correction area corresponding to the first area to be processed in the sample correction area and a second sample correction area corresponding to the second area to be processed in the sample correction area; updating a second sub-path between a first sample correction area and a second sample correction area on the sample spraying path into a first sub-path; taking the next boundary area of the second area to be processed in the spraying direction as a first area to be processed, and re-executing the step of detecting whether the first adjacent area is the area to be corrected and the subsequent steps until the next boundary area of the second area to be processed does not exist in the spraying direction, so as to obtain a target spraying path of the object to be sprayed;
if the first adjacent area is not the area to be corrected, determining a first sample correction area corresponding to the first area to be processed in the sample correction area, and updating a spraying position on the sample spraying path corresponding to the first sample correction area according to the first area to be processed; and taking the next boundary area of the first area to be processed in the spraying direction as the first area to be processed, and re-executing the step of detecting whether the first adjacent area is the area to be corrected and the subsequent steps until the next boundary area of the first area to be processed does not exist in the spraying direction, so as to obtain the target spraying path of the object to be sprayed.
4. A method of coating an article according to claim 3, wherein said determining a first sub-path based on the first area to be treated, the second area to be treated, and each of the areas to be corrected between the first area to be treated and the second area to be treated comprises:
and determining a first sub-path according to the depth information of the first to-be-processed area, the depth information of the second to-be-processed area and the depth information of each to-be-corrected area between the first to-be-processed area and the second to-be-processed area.
5. A method of coating an article according to claim 3, wherein said determining a first sub-path based on the first area to be treated, the second area to be treated, and each of the areas to be corrected between the first area to be treated and the second area to be treated comprises:
determining a target correction area which is composed of a first area to be processed, a second area to be processed and each area to be corrected between the first area to be processed and the second area to be processed;
detecting whether an image area with a second area similarity larger than a second similarity threshold value with the target correction area exists in each sample image in at least one sample image;
and if an image area with the second area similarity between the image area and the target correction area larger than the second similarity threshold exists, acquiring a third sub-path corresponding to the image area with the second area similarity between the image area and the target correction area larger than the second similarity threshold, and taking the third sub-path as the first sub-path.
6. The method of spraying an article according to any one of claims 1 to 5, wherein said determining a sample image from at least one sample image as a target sample image of the first image based on the first image comprises:
determining image similarity, wherein the image similarity refers to the similarity between each sample image in the at least one sample image and the first image;
and determining a sample image from at least one sample image as the target sample image according to the image similarity.
7. The method of spraying an article of claim 6, after said determining image similarity, further comprising:
if the image similarity is smaller than a second similarity threshold value, point cloud data of the to-be-sprayed article are obtained;
establishing a point cloud model of the article to be sprayed according to the point cloud data of the article to be sprayed;
performing minimum external cuboid fitting on the point cloud model according to the first image corresponding plane to obtain a minimum external cuboid of the point cloud model;
determining a corresponding spraying path on each plane of the minimum external cuboid of the point cloud model, and determining a target spraying path of the object to be sprayed according to the corresponding spraying path on each plane of the minimum external cuboid of the point cloud model;
and spraying the object to be sprayed according to the target spraying path.
8. An apparatus for spraying an article, comprising:
the device comprises a first image acquisition unit, a second image acquisition unit and a control unit, wherein the first image acquisition unit is used for acquiring a first image, and the first image is an image obtained by shooting an article to be sprayed;
a target sample image determining unit configured to determine, from at least one sample image, one sample image as a target sample image of the first image, based on the first image;
the target spraying path determining unit is used for acquiring a sample spraying path related to the target sample image, and correcting the sample spraying path to obtain a target spraying path of the object to be sprayed;
and the object spraying unit is used for spraying the object to be sprayed according to the target spraying path.
9. A terminal comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the steps of the method according to any of claims 1 to 7 when executing the computer program.
10. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110648810.8A CN113522583B (en) | 2021-06-10 | 2021-06-10 | Spraying method and device for article, terminal and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110648810.8A CN113522583B (en) | 2021-06-10 | 2021-06-10 | Spraying method and device for article, terminal and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN113522583A true CN113522583A (en) | 2021-10-22 |
CN113522583B CN113522583B (en) | 2022-03-11 |
Family
ID=78095861
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110648810.8A Active CN113522583B (en) | 2021-06-10 | 2021-06-10 | Spraying method and device for article, terminal and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113522583B (en) |
Citations (21)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20030185995A1 (en) * | 1999-10-20 | 2003-10-02 | Toyota Jidosha Kabushiki Kaisha | Thermal spraying method and apparatus for improved adhesion strength |
US20140076985A1 (en) * | 2010-09-22 | 2014-03-20 | Hexagon Technology Center Gmbh | Surface spattering device |
US20150147460A1 (en) * | 2012-05-21 | 2015-05-28 | Cmo Di Sodini Dino & C. S.N.C. | Method and apparatus for painting objects |
US20170326562A1 (en) * | 2016-05-12 | 2017-11-16 | Nemera La Verpillière S.A.S. | Detection Of The Presence Of A Product Sprayed Onto A Surface |
CN109520510A (en) * | 2018-12-26 | 2019-03-26 | 安徽智恒信科技有限公司 | A kind of indoor navigation method and system based on virtual reality technology |
CN109550614A (en) * | 2018-12-11 | 2019-04-02 | 宁波辰凌自动化科技有限公司 | A kind of control system and its workflow of automatic automobile spray painting |
CN110665707A (en) * | 2019-10-18 | 2020-01-10 | 马鞍山远荣机器人智能装备有限公司 | Automatic spraying robot |
US20200037521A1 (en) * | 2018-07-31 | 2020-02-06 | Walmart Apollo, Llc | System for watering live plants on a maneuverable rack |
US20200047207A1 (en) * | 2017-02-15 | 2020-02-13 | Eisenmann Se | Method and painting system for painting a workpiece by means of an atomizer |
CN110874170A (en) * | 2018-08-31 | 2020-03-10 | 杭州海康威视数字技术股份有限公司 | Image area correction method, image segmentation method and device |
US20200078954A1 (en) * | 2018-09-11 | 2020-03-12 | Teradyne, Inc. | Robotic coating application system and method |
CN112058559A (en) * | 2020-09-29 | 2020-12-11 | 广汽本田汽车有限公司 | Coating robot and vehicle body coating method |
CN112191467A (en) * | 2020-09-30 | 2021-01-08 | 库卡机器人(广东)有限公司 | Workpiece spraying method, workpiece spraying system and computer readable storage medium |
CN112238020A (en) * | 2020-09-28 | 2021-01-19 | 中建钢构武汉有限公司 | Spraying control system, method and storage medium |
CN112465809A (en) * | 2020-12-15 | 2021-03-09 | 北京市计算中心 | Mold defect detection method based on image recognition, computer-readable storage medium and device |
CN112529913A (en) * | 2020-12-14 | 2021-03-19 | 北京达佳互联信息技术有限公司 | Image segmentation model training method, image processing method and device |
CN112570229A (en) * | 2020-12-08 | 2021-03-30 | 江苏科技大学 | Spraying method for multiple types of car lamps |
CN112766171A (en) * | 2021-01-21 | 2021-05-07 | 京东数科海益信息科技有限公司 | Spraying method, device, system and medium |
CN112827772A (en) * | 2021-02-08 | 2021-05-25 | 湖州洛博特机械科技有限公司 | Workpiece identification automatic spraying control method and system |
WO2021103154A1 (en) * | 2019-11-25 | 2021-06-03 | 浙江明泉工业涂装有限公司 | Robot control method for smart spray coating of multiple vehicle models |
CN112893007A (en) * | 2021-01-15 | 2021-06-04 | 深圳市悦创进科技有限公司 | Dispensing system based on machine vision and dispensing method thereof |
-
2021
- 2021-06-10 CN CN202110648810.8A patent/CN113522583B/en active Active
Patent Citations (21)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20030185995A1 (en) * | 1999-10-20 | 2003-10-02 | Toyota Jidosha Kabushiki Kaisha | Thermal spraying method and apparatus for improved adhesion strength |
US20140076985A1 (en) * | 2010-09-22 | 2014-03-20 | Hexagon Technology Center Gmbh | Surface spattering device |
US20150147460A1 (en) * | 2012-05-21 | 2015-05-28 | Cmo Di Sodini Dino & C. S.N.C. | Method and apparatus for painting objects |
US20170326562A1 (en) * | 2016-05-12 | 2017-11-16 | Nemera La Verpillière S.A.S. | Detection Of The Presence Of A Product Sprayed Onto A Surface |
US20200047207A1 (en) * | 2017-02-15 | 2020-02-13 | Eisenmann Se | Method and painting system for painting a workpiece by means of an atomizer |
US20200037521A1 (en) * | 2018-07-31 | 2020-02-06 | Walmart Apollo, Llc | System for watering live plants on a maneuverable rack |
CN110874170A (en) * | 2018-08-31 | 2020-03-10 | 杭州海康威视数字技术股份有限公司 | Image area correction method, image segmentation method and device |
US20200078954A1 (en) * | 2018-09-11 | 2020-03-12 | Teradyne, Inc. | Robotic coating application system and method |
CN109550614A (en) * | 2018-12-11 | 2019-04-02 | 宁波辰凌自动化科技有限公司 | A kind of control system and its workflow of automatic automobile spray painting |
CN109520510A (en) * | 2018-12-26 | 2019-03-26 | 安徽智恒信科技有限公司 | A kind of indoor navigation method and system based on virtual reality technology |
CN110665707A (en) * | 2019-10-18 | 2020-01-10 | 马鞍山远荣机器人智能装备有限公司 | Automatic spraying robot |
WO2021103154A1 (en) * | 2019-11-25 | 2021-06-03 | 浙江明泉工业涂装有限公司 | Robot control method for smart spray coating of multiple vehicle models |
CN112238020A (en) * | 2020-09-28 | 2021-01-19 | 中建钢构武汉有限公司 | Spraying control system, method and storage medium |
CN112058559A (en) * | 2020-09-29 | 2020-12-11 | 广汽本田汽车有限公司 | Coating robot and vehicle body coating method |
CN112191467A (en) * | 2020-09-30 | 2021-01-08 | 库卡机器人(广东)有限公司 | Workpiece spraying method, workpiece spraying system and computer readable storage medium |
CN112570229A (en) * | 2020-12-08 | 2021-03-30 | 江苏科技大学 | Spraying method for multiple types of car lamps |
CN112529913A (en) * | 2020-12-14 | 2021-03-19 | 北京达佳互联信息技术有限公司 | Image segmentation model training method, image processing method and device |
CN112465809A (en) * | 2020-12-15 | 2021-03-09 | 北京市计算中心 | Mold defect detection method based on image recognition, computer-readable storage medium and device |
CN112893007A (en) * | 2021-01-15 | 2021-06-04 | 深圳市悦创进科技有限公司 | Dispensing system based on machine vision and dispensing method thereof |
CN112766171A (en) * | 2021-01-21 | 2021-05-07 | 京东数科海益信息科技有限公司 | Spraying method, device, system and medium |
CN112827772A (en) * | 2021-02-08 | 2021-05-25 | 湖州洛博特机械科技有限公司 | Workpiece identification automatic spraying control method and system |
Non-Patent Citations (1)
Title |
---|
李达辉: "《数字图像处理核心技术及应用》", 30 June 2018 * |
Also Published As
Publication number | Publication date |
---|---|
CN113522583B (en) | 2022-03-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111311632B (en) | Object pose tracking method, device and equipment | |
US20150321694A1 (en) | Refined row guidance parameterization with hough transform | |
US20130177211A1 (en) | Travel path estimation apparatus and program | |
EP3766644A1 (en) | Workpiece picking device and workpiece picking method | |
WO2021093288A1 (en) | Magnetic stripe-simulation positioning method and device based on ceiling-type qr codes | |
US20130016915A1 (en) | Crosswalk detection device, crosswalk detection method and recording medium | |
CN111433780A (en) | Lane line detection method, lane line detection apparatus, and computer-readable storage medium | |
JP2019191145A (en) | Identification method for charging stand, device, robot, and computer readable storage | |
CN114777792A (en) | Path planning method and device, computer readable medium and electronic equipment | |
CN111123951A (en) | Biped robot and track following method and device thereof | |
CN113362238A (en) | Test image processing method and device, electronic equipment and storage medium | |
CN110096999B (en) | Chessboard recognition method, chessboard recognition device, electronic equipment and storable medium | |
CN113522583B (en) | Spraying method and device for article, terminal and storage medium | |
CN111488762A (en) | Lane-level positioning method and device and positioning equipment | |
CN112991162B (en) | Layering method and device for point cloud data | |
CN117387593A (en) | Repositioning method, repositioning device, electronic equipment and computer readable storage medium | |
Koval et al. | An image segmentation method for obstacle detection in a mobile robot environment | |
US20100128973A1 (en) | Stereo image processing apparatus, stereo image processing method and computer-readable recording medium | |
JP7283378B2 (en) | Self-position estimation device, mobile object, self-position estimation method, and self-position estimation program | |
US20210385425A1 (en) | Method and device for calibrating binocular camera | |
CN114842057A (en) | Distance information complementing method, apparatus, storage medium, and computer program product | |
CN114693546A (en) | Image denoising method and device, electronic equipment and computer readable storage medium | |
CN113409344A (en) | Template information acquisition method, device and computer-readable storage medium | |
CN110763243B (en) | Sliding map updating method and device | |
CN116342858B (en) | Object detection method, device, electronic equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |