CN109102499B - Detection method and system for top of bullet train - Google Patents

Detection method and system for top of bullet train Download PDF

Info

Publication number
CN109102499B
CN109102499B CN201810820346.4A CN201810820346A CN109102499B CN 109102499 B CN109102499 B CN 109102499B CN 201810820346 A CN201810820346 A CN 201810820346A CN 109102499 B CN109102499 B CN 109102499B
Authority
CN
China
Prior art keywords
image
bullet train
standard
detected
pixel point
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.)
Active
Application number
CN201810820346.4A
Other languages
Chinese (zh)
Other versions
CN109102499A (en
Inventor
杨凯
彭朝勇
高晓蓉
宋文伟
彭建平
赵全轲
王泽勇
王黎
谢利明
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Chengdu Tiean Science & Technology Co ltd
Original Assignee
Chengdu Tiean Science & Technology Co ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Chengdu Tiean Science & Technology Co ltd filed Critical Chengdu Tiean Science & Technology Co ltd
Priority to CN201810820346.4A priority Critical patent/CN109102499B/en
Publication of CN109102499A publication Critical patent/CN109102499A/en
Application granted granted Critical
Publication of CN109102499B publication Critical patent/CN109102499B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • G06T7/0004Industrial image inspection
    • G06T7/001Industrial image inspection using an image reference approach
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10004Still image; Photographic image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30108Industrial image inspection
    • G06T2207/30164Workpiece; Machine component
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30248Vehicle exterior or interior
    • G06T2207/30252Vehicle exterior; Vicinity of vehicle

Abstract

The invention discloses a method for detecting the top of a bullet train, which comprises the steps of obtaining an image of the top of the bullet train to be detected; determining target images corresponding to the standard vehicle passing templates one by one on the images; adjusting the target image according to a first preset rule to enable the position coordinates of each pixel point in the target image to be the same as the position coordinates of each pixel point in the standard image block where the standard vehicle passing template corresponding to the pixel point is located; splicing all the adjusted target images to obtain a new image of the top of the bullet train to be detected; acquiring the structural similarity of each pixel point in the new image relative to the standard vehicle passing image; and judging whether pixel points with structural similarity smaller than a preset value exist or not, and if so, performing abnormity alarm. The invention can detect whether the top of the bullet train is abnormal in real time under the condition that the bullet train does not stop, has high detection efficiency, saves labor cost and simultaneously ensures detection accuracy. The invention also discloses a detection system for the top of the bullet train, which has the beneficial effects.

Description

Method and system for detecting top of bullet train
Technical Field
The invention relates to the field of railway traffic, in particular to a method and a system for detecting the top of a bullet train.
Background
With the continuous development of high-speed railway technology, motor cars are popularized and the running speed is continuously improved, so that the safety problem becomes the most important problem for the operation of the motor cars. Due to the fact that key components such as a pantograph and a porcelain insulator on the top of the bullet train and the top of the bullet train are exposed for a long time and are influenced by external environmental factors, abnormal problems such as aging, loosening or loss may exist, and therefore the top of the bullet train needs to be detected frequently to guarantee running safety of the bullet train.
In the prior art, firstly, whether key components on the car roof are abnormal or not is diagnosed on site by a maintainer when the maintainer arrives at the car roof, but the condition that the maintainer leaves detection tools on the car roof often occurs, in the running process of a motor car, the detection tools can impact key components on the car roof, such as a pantograph and/or a porcelain insulator, and the like due to the inertia effect to cause the damage of the key components, so that the failure of the motor car is caused, and in the prior art, the detection can be performed only when the motor car is parked, and the real-time performance is poor; in the prior art, the camera is used for collecting the image of the top of the bullet train, and then the maintainer carries out manual detection according to the image, and the manual detection is monotonous, so that the maintainer is easy to feel tired, and the detection is neglected, and the detection effect is not ideal.
Therefore, how to provide a solution to the above technical problem is a problem that needs to be solved by those skilled in the art.
Disclosure of Invention
The invention aims to provide a detection method of a bullet train roof, which can detect whether the bullet train roof is abnormal or not in real time under the condition that a bullet train does not stop, has high detection efficiency, saves labor cost and ensures detection accuracy; another object of the present invention is to provide a detection system for a motor vehicle roof.
In order to solve the technical problem, the invention provides a detection method of a bullet train roof, which comprises the following steps:
acquiring an image of the top of the bullet train to be detected;
determining target images corresponding to the standard vehicle passing templates one by one on the images;
adjusting the target image according to a first preset rule to enable the position coordinates of each pixel point in the target image to be the same as the position coordinates of each pixel point in a standard image block where a standard vehicle passing template corresponding to the target image is located;
splicing all the adjusted target images to obtain a new image of the top of the bullet train to be detected;
acquiring the structural similarity of each pixel point in the new image relative to a standard vehicle passing image;
and judging whether the pixel points with the structural similarity smaller than a preset value exist, and if so, performing abnormity alarm.
Preferably, the process of acquiring the image of the top of the bullet train to be detected specifically includes:
collecting the row pixels of the top of the bullet train to be detected through a linear array electric coupling element CCD;
splicing the pixels in the row into an image block according to a second preset rule;
and carrying out image splicing processing on all the image blocks to obtain an image of the top of the bullet train to be detected.
Preferably, the process of determining the target images corresponding to the standard vehicle passing templates one to one on the image specifically includes:
and determining the matching range of the standard vehicle passing template on the image according to the position coordinates of the standard vehicle passing template, and determining the target images corresponding to the standard vehicle passing template one by one in the matching range.
Preferably, the process of adjusting the target image according to the first preset rule specifically includes:
and adjusting each target image according to an Enhanced Correlation Coefficient (ECC) algorithm.
Preferably, before the adjusting each target image according to the enhanced correlation coefficient ECC algorithm, the detecting method further includes:
the spacing between adjacent target images is adjusted by the lateral scaling process.
Preferably, after the image of the top of the bullet train to be detected is acquired, before the target images corresponding to the standard passing templates one by one are determined on the image, the detection method further includes:
and cutting the area, which does not comprise the top of the bullet train to be detected, in the image.
Preferably, after the new image of the top of the bullet train to be detected is obtained, before the structural similarity of each pixel point in the new image relative to the standard train passing image is obtained, the detection method further includes:
and performing the same scaling/zooming processing on the new image and the standard vehicle-passing image according to a user instruction.
In order to solve the above technical problem, the present invention further provides a detection system for a top of a bullet train, comprising:
the first acquisition module is used for acquiring an image of the top of the bullet train to be detected;
the matching module is used for determining target images which correspond to the standard vehicle passing templates one by one on the images;
the adjusting module is used for adjusting the target image according to a first preset rule, so that the position coordinates of each pixel point in the target image are the same as the position coordinates of each pixel point in the standard image block where the standard vehicle passing template corresponding to the pixel point is located;
the splicing module is used for splicing all the adjusted target images to obtain a new image of the top of the bullet train to be detected;
the second acquisition module is used for acquiring the structural similarity of each pixel point in the new image relative to a standard vehicle passing image;
the judging module is used for judging whether pixel points with the structural similarity smaller than a preset value exist or not, and if yes, the alarming module is triggered;
and the alarm module is used for carrying out abnormity alarm.
Preferably, the first obtaining module is specifically configured to:
collecting the row pixels of the top of the bullet train to be detected through a linear array electric coupling element CCD;
splicing the pixels in the row into an image block according to a second preset rule;
and carrying out image splicing processing on all the image blocks to obtain an image of the top of the bullet train to be detected.
Preferably, the matching module is specifically configured to:
and determining the matching range of the standard vehicle passing template on the image according to the position coordinates of the standard vehicle passing template, and determining the target images corresponding to the standard vehicle passing template one by one in the matching range.
The invention provides a method for detecting the top of a bullet train, which comprises the steps of obtaining an image of the top of the bullet train to be detected; determining target images corresponding to the standard vehicle passing templates one by one on the images; adjusting the target image according to a first preset rule to enable the position coordinates of each pixel point in the target image to be the same as the position coordinates of each pixel point in the standard image block where the standard vehicle passing template corresponding to the pixel point is located; splicing all the adjusted target images to obtain a new image of the top of the bullet train to be detected; acquiring the structural similarity of each pixel point in a new image relative to a standard vehicle passing image; and judging whether pixel points with structural similarity smaller than a preset value exist or not, and if so, performing abnormity alarm.
It can be seen that in practical application, the scheme of the invention is adopted, firstly, the obtained image of the top of the bullet train to be detected is divided into a plurality of target images according to the standard passing template, then each target image is adjusted, the position coordinate of each pixel point in the target image is enabled to be the same as the position coordinate of each pixel point in the standard image block of the corresponding standard passing template, then all the adjusted target images are spliced, the basically consistent new image of the top of the bullet train to be detected and the standard passing image are ensured to be obtained after splicing, finally, the structural similarity of each pixel point in the new image relative to the standard passing image is calculated, if the structural similarity is smaller than a preset value, the abnormality of the top of the bullet train is judged, and the abnormality alarm is carried out, the invention can detect whether the abnormality exists on the top of the bullet train in real time under the condition that the bullet train does not stop, the detection efficiency is high, the labor cost is saved, and the detection precision is guaranteed.
The invention also provides a detection system of the bullet train roof, which has the same beneficial effects as the detection method.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, it is obvious that the drawings in the following description are only embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
FIG. 1 is a flow chart illustrating steps of a method for inspecting a top of a motor vehicle according to the present invention;
FIG. 2a is a schematic view of an embodiment of a method for inspecting a top of a motor vehicle according to the present invention;
FIG. 2b is a schematic diagram of another embodiment of a method for inspecting a top of a motor vehicle according to the present invention;
fig. 3 is a schematic structural diagram of a detection system for a top of a bullet train provided by the invention.
Detailed Description
The core of the invention is to provide a detection method for the top of the bullet train, which can detect whether the top of the bullet train is abnormal in real time under the condition that the bullet train does not stop, has high detection efficiency, saves the labor cost and ensures the detection accuracy; the invention further provides a detection system for the top of the bullet train.
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Referring to fig. 1, fig. 1 is a flowchart illustrating steps of a method for detecting a top of a bullet train according to the present invention, including:
step 1: acquiring an image of the top of the bullet train to be detected;
specifically, before the top of the bullet train to be detected is detected, a standard passing template is selected in advance, the standard passing template is selected from a standard passing image, each standard passing template comprises key parts of the top of the bullet train, such as a harmony number printed on the head of the bullet train, a porcelain insulator, a pantograph, a pipeline with characteristics, a connecting part between carriages and the like on the top of the bullet train, and any historical passing image without faults or abnormalities can be used as the standard passing image. After the standard vehicle passing templates are selected, the invention also names each standard vehicle passing template and stores the template to a preset position for query, and the naming mode can be named by numbers or characters, and the invention does not limit the naming mode. In practical application, the roof of the same motor car needs to be detected every day, namely the standard vehicle passing template selected in the invention is suitable for any time period and does not need to be selected repeatedly, thereby improving the working efficiency of the invention.
Specifically, the image of the top of the bullet train to be detected can be acquired through the image acquisition device, the image acquisition device generally comprises a monitoring camera, a speed measurement sensor and a vehicle counting sensor, and the image acquisition device respectively acquires multi-angle panoramic images from the middle part and the left/right sides of the top of the bullet train to be detected.
Of course, other devices or methods may be used to acquire the image of the top of the bullet train, and the present invention is not limited thereto.
Step 2: determining target images corresponding to the standard vehicle passing templates one by one on the images;
specifically, the target images corresponding to the standard passing templates one by one are determined on the acquired image of the top of the bullet train to be detected, and the method can also be understood as matching the standard passing templates on the image to find the matching components matched with the standard passing templates on the image. Generally, a matching component closest to the standard passing template can be matched on the image of the top of the motor car to be detected by a normalized correlation coefficient matching algorithm in combination with a sequential similarity check algorithm, and the image of the top of the motor car to be detected is cut into a plurality of target images by taking the position coordinates of the matching component as a reference, as shown in fig. 2a, each target image has only one matching component, for example, the target image 2 includes a matching component a1, and the target image 3 includes a matching component B1, wherein the position coordinates can select the coordinates of the upper left corner of the matching component, and the matching component is relative to the standard passing template, and actually the matching component is the same key component on the image of the top of the motor car to be detected and the standard passing template.
Correspondingly, the mathematical relation of the normalized correlation coefficient matching algorithm is as follows:
Figure GDA0001791052420000061
wherein: i isr′(X)=Ir(X)-average(Ir(X)), representing a zero-mean matrix of the standard passing template; i'w(Y+X)=Iw(Y+X)-average(Iw(Y + X)), the zero mean matrix represents the top image of the bullet train to be detected, and the physical meaning of the mean value is the overall brightness of the image, so that the method adopted by the invention can ensure that the matching point closest to the standard passing template can still be matched on the top image of the bullet train to be detected under the condition that the brightness of the two images is different, thereby improving the applicability of the invention.
It can be understood that the relational expression of the normalized correlation coefficient matching algorithm includes operations of multiplication and evolution, which results in a heavy calculation process, and in order to reduce the calculation amount, the invention also adopts a sequential similarity check algorithm for preprocessing, and the mathematical relational expression of the sequential similarity check algorithm is as follows:
Figure GDA0001791052420000062
therefore, the algorithm only has simple addition and subtraction operations, so that the matching speed is improved, of course, the matching speed can be further improved, for example, a reasonable threshold is set for r (z) in combination with projects and experiences, so that where the images are not matched, r (z) can grow very fast and reach the threshold quickly, then the relevant calculation for the point can be stopped, and where r (z) grows slowly and cannot reach the threshold, so that a large part of unmatched regions can be removed more quickly, and thus the calculation amount is further reduced.
Of course, the present invention is not limited herein, and the target image may be obtained by other methods besides the above-mentioned method.
And 3, step 3: adjusting the target image according to a first preset rule to enable the position coordinates of each pixel point in the target image to be the same as the position coordinates of each pixel point in the standard image block where the standard vehicle passing template corresponding to the pixel point is located;
in particular, considering that the acquisition of the image of the top of the to-be-tested motor car is performed during the running process of the to-be-tested motor car, in practical applications, the running speed of the to-be-tested motor car cannot be kept consistent, the too high running speed may cause the acquired image of the top of the to-be-tested motor car to be compressed, and the too low running speed may cause the acquired image of the top of the to-be-tested motor car to be stretched, so that the image of the top of the to-be-tested motor car cannot be aligned with the standard passing image, wherein the alignment means that the size of the image of the top of the to-be-tested motor car is the same as that of the standard passing image, the positions of all components on the image of the top of the to-be-tested motor car are the same as the positions of corresponding components on the standard passing image, and all components mean all key components and components between any two adjacent key components.
Specifically, the standard image block where the standard vehicle-passing template is located may also be understood as being obtained by dividing the standard vehicle-passing image according to the coordinates of the upper left corner of the standard vehicle-passing template, and it may be understood that, in practical application, it is impossible to make each pixel point in the target image completely consistent with each pixel point in the standard image block matched with the target image, so the same in the present invention means that two matched pixels converge when aligned, that is, it is described that the two pixel points are the same, so that the position coordinate of each pixel point in the target image is the same as the position coordinate of each pixel point in the standard image block where the standard passing template corresponding to the target image is located, and it can also be understood that all contents included in the target image and the standard image block matched with the target image are basically the same, thereby providing a basis for aligning a new image of the top of the bullet train to be tested, which is obtained by subsequent splicing, with the standard passing image.
And 4, step 4: splicing all the adjusted target images to obtain a new image of the top of the bullet train to be detected;
specifically, all the target images adjusted according to the method are spliced, so that the size of the obtained image of the top of the bullet train to be detected, the position coordinates of the key components, the connection positions among all carriages and the like are the same as those of the standard passing image, the standard passing image and a new image can be conveniently compared in the follow-up process, the comparison result is more accurate, and the fact that whether the key components on the top of the bullet train to be detected are lost or damaged, whether the connecting pipelines are normal or not can be accurately judged.
And 5: acquiring the structural similarity of each pixel point in a new image relative to a standard vehicle passing image;
specifically, the invention adopts SSIM (Structural Similarity Index) to compare extended comparison areas with the same size of the same pixel point in two images, the pixel point is the central point of the comparison areas, then the Structural Similarity of the two comparison areas is calculated, and the whole image is traversed according to the comparison areas with the same size. In the actual algorithm design, the Gaussian filter with the preset size is adopted to carry out Gaussian filtering on the two images, and different weights are set at different positions away from the central point by the Gaussian filter, so that the influence of the pixel point close to the central point on the central point is large, and the influence of the pixel point far away from the central point on the central point is small.
For example, a 21 × 21 gaussian filter may be used to perform gaussian filtering on a new image and a standard passing image, that is, a comparison area with a size of 21 × 21 is selected from the same pixel points of the two images, and at this time, the pixel point is a central point of the comparison area, the structural similarity of the comparison area is calculated, the obtained structural similarity is the structural similarity of the pixel point, and then the new image and the standard passing image are traversed by using the pixel as a sliding minimum unit, and the structural similarity of each pixel point is calculated respectively to obtain a structural similarity matrix.
It can be understood that if the selected comparison area is too small, the high structuralization of the two images cannot be reflected, and if the selected comparison area is too large, the calculation amount is increased, so that the calculation result of the structural similarity is tested repeatedly, and the comparison effect is optimal when the comparison area is 21 × 21.
Step 6: and judging whether pixel points with structural similarity smaller than a preset value exist or not, and if so, performing abnormity alarm.
Specifically, if the structural similarity obtained by calculating a certain pixel point on a new image is smaller than a preset value, it is indicated that the pixel point is different from the same pixel point on the standard passing image, that is, the position of the pixel point corresponding to the roof of the moving vehicle to be detected may be abnormal, and therefore if the pixel point with the structural similarity smaller than the preset value exists, an abnormal alarm is given to the pixel point, so that a maintainer is prompted to check the position of the roof of the moving vehicle to be detected corresponding to the pixel point.
Of course, there are many ways to perform the anomaly alarm, for example, a pixel point frame lower than a preset value is selected on the calculated structure similarity matrix, so that the inspection personnel can conveniently check the pixel point frame.
The invention provides a method for detecting the top of a bullet train, which comprises the steps of obtaining an image of the top of the bullet train to be detected; determining target images corresponding to the standard vehicle passing templates one by one on the images; adjusting the target image according to a first preset rule to enable the position coordinates of each pixel point in the target image to be the same as the position coordinates of each pixel point in the standard image block where the standard vehicle passing template corresponding to the pixel point is located; splicing all the adjusted target images to obtain a new image of the top of the bullet train to be detected; acquiring the structural similarity of each pixel point in a new image relative to a standard vehicle passing image; and judging whether pixel points with structural similarity smaller than a preset value exist or not, and if so, performing abnormity alarm.
It can be seen that in practical application, the scheme of the invention is adopted, firstly, the obtained image of the top of the bullet train to be detected is divided into a plurality of target images according to the standard passing template, then each target image is adjusted, the position coordinate of each pixel point in the target image is enabled to be the same as the position coordinate of each pixel point in the standard image block of the corresponding standard passing template, then all the adjusted target images are spliced, the basically consistent new image of the top of the bullet train to be detected and the standard passing image are ensured to be obtained after splicing, finally, the structural similarity of each pixel point in the new image relative to the standard passing image is calculated, if the structural similarity is smaller than a preset value, the abnormality of the top of the bullet train is judged, and the abnormality alarm is carried out, the invention can detect whether the abnormality exists on the top of the bullet train in real time under the condition that the bullet train does not stop, the detection efficiency is high, the labor cost is saved, and the detection precision is guaranteed.
On the basis of the above-described embodiment:
as a preferred embodiment, the process of acquiring the image of the top of the bullet train to be detected specifically includes:
acquiring row pixels of the top of the bullet train to be detected through a linear array electric coupling element CCD;
splicing the column pixels into image blocks according to a second preset rule;
and performing image splicing processing on all the image blocks to obtain an image of the top of the bullet train to be detected.
Specifically, considering that the length of the top of the motor car is very long, and the image acquisition needs to be performed in the running process of the motor car, affine transformation may exist in images shot by directly adopting a Charge-Coupled Device (CCD) and the splicing effect is not ideal when the images are spliced in the later period, the invention provides an image acquisition Device based on a linear array CCD, wherein a monitoring camera in the image acquisition Device adopts a linear array camera with ultrahigh resolution.
Specifically, the line-to-line shooting of the image of the top of the bullet train to be detected is carried out through the linear array CCD, so that the column pixels of the top of the bullet train to be detected are obtained, wherein the second preset rule can also be understood as an actual engineering requirement, namely, all the column pixels are spliced into image blocks with the size corresponding to the actual engineering requirement according to the actual engineering requirement, generally, the size of the image blocks can be 36 x 36 if the size of the column pixels is 36 x 1, all the image blocks are stored into a computer to achieve the purpose of storing the image of the top of the bullet train to be detected in a blocking mode, and finally, the image splicing processing is carried out on all the image blocks, so that the complete image of the top of the bullet train to be detected can be obtained.
As a preferred embodiment, the process of determining the target images corresponding to the standard passing templates one by one on the image specifically includes:
and determining the matching range of the standard vehicle-passing template on the image according to the position coordinates of the standard vehicle-passing template, and determining the target images corresponding to the standard vehicle-passing template one by one in the matching range.
Specifically, considering that the image of the top of the bullet train to be detected is very large, if a large amount of time is likely to be wasted in matching the image, the invention records the position coordinates of the standard passing template on the standard passing image when the standard passing template is selected, and then when the image of the top of the bullet train to be detected is matched by using the standard passing template, the matching range can be set according to the position coordinates of the standard passing template on the standard passing image, since the standard passing template is very small on the whole standard passing image and can be basically regarded as a mass point on the standard passing image, a position coordinate point which is the same as the position coordinates of the standard passing template can be determined on the image of the top of the bullet train to be detected as a matching center point, then preset pixels are respectively expanded on the left side/right side of the matching center point, the preset pixels can be 500 pixels, and the block area can be used as the matching range of the standard passing template on the image of the top of the bullet train to be detected, therefore, the matching range of the standard passing template on the image of the top of the bullet train to be detected is narrowed, and the matching accuracy and the matching speed are further improved.
It can be understood that, assuming that the image size of the top of the bullet train to be detected is 62687 × 317, the matching range can be narrowed from 62687 × 317 to 1000 × 317 by adopting the method of the present invention.
As a preferred embodiment, the process of adjusting the target image according to the first preset rule specifically includes:
and adjusting each target image according to an Enhanced Correlation Coefficient (ECC) algorithm.
Specifically, the method adopts an ECC (Enhanced Correlation Maximization) algorithm to adjust each target image, the ECC algorithm is not influenced by image deformation, specifically, the Correlation Coefficient between the target image and the standard image block is calculated through the ECC algorithm, whether the obtained Correlation Coefficient meets a preset value is judged, and if not, iterative calculation is carried out until the calculated Correlation Coefficient meets the preset value.
As a preferred embodiment, before adjusting each target image according to the enhanced correlation coefficient ECC algorithm, the detection method further includes:
the spacing between adjacent target images is adjusted by the lateral scaling process.
Specifically, in order to accelerate the adjustment speed, the target images may be roughly aligned in advance before each target image is adjusted by an ECC algorithm, for example, as shown in fig. 2a and fig. 2B, fig. 2a shows a screenshot of an image of a top of a motor car to be measured, which includes a target image 1, a target image 2, a target image 3, a key component a1 and a key component B1, fig. 2B shows a screenshot of a standard passing vehicle image, which includes a standard image block 1, a standard image block 2, a standard image block 3, a key component a0 and a key component B0, wherein the target image 2 and the target image 3 are adjacent, the size of an area between the key component a1 and the key component B1 is adjusted to be the same as the size of an area between the key component a0 and the key component B0 by a transverse scaling process, so that the target image 2 and the standard image block 2 are aligned, the adjustment of the distance can be generally completed by adopting a cvResize function in opencv, and after the adjustment is completed, coarse adjustment of the target image can be completed, so that the abscissa of the key component on the target image is the same as the abscissa of the standard vehicle-passing template matched with the key component (namely, the head and the tail of the target image are respectively aligned with the head and the tail of the standard image block).
As a preferred embodiment, after acquiring the image of the top of the bullet train to be detected, before determining the target image corresponding to the standard passing template one by one on the image, the detection method further comprises:
and cutting the area which does not comprise the top of the bullet train to be detected in the image.
Specifically, because the response time of shooting is different, the head and the tail of a series of images shot by the monitoring camera may not shoot the top of the bullet train to be detected but only shoot the track, and if the images are spliced, the head and/or the tail of the bullet train are not aligned, so that the images of the top of the bullet train to be detected are preprocessed before determining the target image, namely, the images of the top of the bullet train to be detected are cut in advance, excessive black areas are cut off, namely, areas not including the top of the bullet train to be detected, and the images of the top of the bullet train to be detected are preprocessed in advance, thereby providing a basis for determining the target image more quickly in the follow-up process.
As a preferred embodiment, after obtaining a new image of the top of the bullet train to be detected, before obtaining the structural similarity of each pixel point in the new image with respect to the standard passing image, the detection method further includes:
the same scaling/zooming process is performed on the new image and the standard passing image according to the user instruction.
Specifically, in order to reduce the amount of calculation, the present invention further performs scaling/scaling processing on the new image and the standard vehicle-passing image at the same ratio, for example, assuming that the width of the new image and the width of the standard vehicle-passing image are simultaneously scaled down by 6 times, and the height of the new image and the height of the standard vehicle-passing image are simultaneously scaled down by 2 times, after finding the abnormal point, the coordinate value of the abnormal point corresponding to the original image can be obtained by multiplying the coordinate of the abnormal point by the corresponding coefficient, and after performing the above processing on the new image and the standard vehicle-passing image according to the method of the present invention, the comparison speed is increased by 12 times, wherein the abnormal point is a pixel point whose structural similarity is smaller than the preset value.
Referring to fig. 3, fig. 3 is a schematic structural diagram of a detection system for a top of a motor car provided in the present invention, including:
the first acquisition module 1 is used for acquiring an image of the top of the bullet train to be detected;
the matching module 2 is used for determining target images which correspond to the standard vehicle passing templates one by one on the images;
the adjusting module 3 is used for adjusting the target image according to a first preset rule, so that the position coordinates of each pixel point in the target image are the same as the position coordinates of each pixel point in the standard image block where the standard vehicle passing template corresponding to the pixel point is located;
the splicing module 4 is used for splicing all the adjusted target images to obtain a new image of the top of the bullet train to be detected;
the second obtaining module 5 is used for obtaining the structural similarity of each pixel point in the new image relative to the standard vehicle passing image;
the judging module 6 is used for judging whether pixel points with the structural similarity smaller than a preset value exist or not, and if yes, the alarming module 7 is triggered;
and the alarm module 7 is used for carrying out abnormity alarm.
As a preferred embodiment, the first obtaining module 1 is specifically configured to:
acquiring row pixels of the top of the bullet train to be detected through a linear array electric coupling element CCD;
splicing the column pixels into image blocks according to a second preset rule;
and performing image splicing processing on all the image blocks to obtain an image of the top of the bullet train to be detected.
As a preferred embodiment, the matching module 2 is specifically configured to:
and determining the matching range of the standard vehicle passing template on the image according to the position coordinates of the standard vehicle passing template, and determining the target images corresponding to the standard vehicle passing template one by one in the matching range.
For the description of the detection system for the top of the bullet train provided by the present invention, please refer to the above embodiments, and the detailed description of the present invention is omitted here.
The embodiments in the present description are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other. The device disclosed by the embodiment corresponds to the method disclosed by the embodiment, so that the description is simple, and the relevant points can be referred to the method part for description.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (9)

1. A method for detecting a top of a motor vehicle, comprising:
acquiring an image of the top of the bullet train to be detected;
determining target images corresponding to the standard vehicle passing templates one by one on the images;
adjusting the target image according to a first preset rule to enable the position coordinates of each pixel point in the target image to be the same as the position coordinates of each pixel point in a standard image block where a standard vehicle passing template corresponding to the target image is located;
splicing all the adjusted target images to obtain a new image of the top of the bullet train to be detected;
acquiring the structural similarity of each pixel point in the new image relative to a standard vehicle passing image;
judging whether pixel points with structural similarity smaller than a preset value exist, and if yes, performing abnormal alarm;
the process of adjusting the target image according to the first preset rule specifically comprises the following steps:
and adjusting each target image according to an Enhanced Correlation Coefficient (ECC) algorithm.
2. The detection method according to claim 1, wherein the process of acquiring the image of the top of the bullet train to be detected is specifically as follows:
collecting the row pixels of the top of the bullet train to be detected through a linear array electric coupling element CCD;
splicing the pixels in the row into an image block according to a second preset rule;
and carrying out image splicing processing on all the image blocks to obtain an image of the top of the bullet train to be detected.
3. The detection method according to claim 1, wherein the process of determining the target images corresponding to the standard passing templates one by one on the image is specifically as follows:
and determining the matching range of the standard vehicle passing template on the image according to the position coordinates of the standard vehicle passing template, and determining the target images corresponding to the standard vehicle passing template one by one in the matching range.
4. The detection method according to claim 1, wherein before adjusting each of the target images according to the Enhanced Correlation Coefficient (ECC) algorithm, the detection method further comprises:
the spacing between adjacent target images is adjusted by the lateral scaling process.
5. The detection method according to any one of claims 1 to 4, wherein after the image of the top of the bullet train to be detected is acquired, before the target image corresponding to the standard passing template in a one-to-one manner is determined on the image, the detection method further comprises the following steps:
and cutting the area, which does not comprise the top of the bullet train to be detected, in the image.
6. The detection method according to claim 5, wherein after the new image of the top of the bullet train to be detected is obtained, before the structural similarity of each pixel point in the new image with respect to a standard passing image is obtained, the detection method further comprises:
and performing the same scaling/zooming processing on the new image and the standard vehicle-passing image according to a user instruction.
7. A detection system for a motor vehicle roof, comprising:
the first acquisition module is used for acquiring an image of the top of the bullet train to be detected;
the matching module is used for determining target images which correspond to the standard vehicle passing templates one by one on the images;
the adjusting module is used for adjusting the target image according to a first preset rule, so that the position coordinates of each pixel point in the target image are the same as the position coordinates of each pixel point in the standard image block where the standard vehicle passing template corresponding to the pixel point is located;
the splicing module is used for splicing all the adjusted target images to obtain a new image of the top of the bullet train to be detected;
the second acquisition module is used for acquiring the structural similarity of each pixel point in the new image relative to a standard vehicle passing image;
the judging module is used for judging whether pixel points with the structural similarity smaller than a preset value exist or not, and if yes, the alarming module is triggered;
the alarm module is used for carrying out abnormity alarm;
the process of adjusting the target image according to the first preset rule specifically comprises the following steps:
and adjusting each target image according to an Enhanced Correlation Coefficient (ECC) algorithm.
8. The detection system of claim 7, wherein the first acquisition module is specifically configured to:
collecting the row pixels of the top of the bullet train to be detected through a linear array electric coupling element CCD;
splicing the pixels in the row into an image block according to a second preset rule;
and carrying out image splicing processing on all the image blocks to obtain an image of the top of the bullet train to be detected.
9. The detection system according to claim 7, wherein the matching module is specifically configured to:
and determining the matching range of the standard vehicle passing template on the image according to the position coordinates of the standard vehicle passing template, and determining the target images corresponding to the standard vehicle passing template one by one in the matching range.
CN201810820346.4A 2018-07-24 2018-07-24 Detection method and system for top of bullet train Active CN109102499B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810820346.4A CN109102499B (en) 2018-07-24 2018-07-24 Detection method and system for top of bullet train

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810820346.4A CN109102499B (en) 2018-07-24 2018-07-24 Detection method and system for top of bullet train

Publications (2)

Publication Number Publication Date
CN109102499A CN109102499A (en) 2018-12-28
CN109102499B true CN109102499B (en) 2022-06-14

Family

ID=64847268

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810820346.4A Active CN109102499B (en) 2018-07-24 2018-07-24 Detection method and system for top of bullet train

Country Status (1)

Country Link
CN (1) CN109102499B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112037182B (en) * 2020-08-14 2023-11-10 中南大学 Locomotive running part fault detection method and device based on time sequence image and storage medium
CN115760856B (en) * 2023-01-10 2023-04-28 惟众信(湖北)科技有限公司 Image recognition-based part spacing measurement method, system and storage medium

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2347238B1 (en) * 2008-10-22 2018-05-16 International Electronic Machines Corp. Thermal imaging-based vehicle analysis
CN102034220B (en) * 2010-12-23 2012-12-26 武汉大学苏州研究院 Digital watermark-based electronic bill image anti-tamper method
CN103512762B (en) * 2012-06-29 2016-12-21 北京华兴致远科技发展有限公司 Image processing method, device and train failure detection system
CN104634592A (en) * 2014-12-18 2015-05-20 成都铁安科技有限责任公司 Train running gear fault diagnosis method and train running gear fault diagnosis device
CN105571508B (en) * 2016-01-25 2018-03-30 成都国铁电气设备有限公司 The deformation detecting method and system of OCS and pantograph
CN206479334U (en) * 2017-01-06 2017-09-08 苏州华兴致远电子科技有限公司 The comprehensive detecting system of high-precision train

Also Published As

Publication number Publication date
CN109102499A (en) 2018-12-28

Similar Documents

Publication Publication Date Title
CN104236478B (en) Automatic vehicle overall size measuring system and method based on vision
Akagic et al. Pothole detection: An efficient vision based method using rgb color space image segmentation
CN109102499B (en) Detection method and system for top of bullet train
CN112381791A (en) Bolt looseness detection method based on 3D point cloud
CN110503638B (en) Spiral adhesive quality online detection method
CN108257125B (en) Depth image quality non-reference evaluation method based on natural scene statistics
CN111539927B (en) Detection method of automobile plastic assembly fastening buckle missing detection device
CN113781537B (en) Rail elastic strip fastener defect identification method and device and computer equipment
CN108871185B (en) Method, device and equipment for detecting parts and computer readable storage medium
CN111223078B (en) Method for determining flaw level and storage medium
CN111415339A (en) Image defect detection method for complex texture industrial product
CN102175172A (en) Image-identification-based system for detecting contour dimension of motor vehicle
CN105184792A (en) Circular saw web wear extent online measuring method
CN105607218A (en) Image auto-focusing method measurement data transmission device and method based on fuzzy entropy
CN107403429B (en) Method for quickly and automatically acquiring parameters of periodic sequence image model
US10062155B2 (en) Apparatus and method for detecting defect of image having periodic pattern
CN107292932B (en) Head-on video speed measurement method based on image expansion rate
CN113727022A (en) Inspection image acquisition method and device, electronic equipment and storage medium
CN103630547B (en) There is flaw detection method and the pick-up unit thereof of the optical thin film of periodic structure
CN112037536A (en) Vehicle speed measuring method and device based on video feature recognition
CN112233063A (en) Circle center positioning method for large-size round object
CN112229500B (en) Structural vibration displacement monitoring method and terminal equipment
CN116894775B (en) Bolt image preprocessing method based on camera motion model recovery and super-resolution
CN113358058B (en) Computer vision detection method for weld contour features based on discrete sequence points
CN112967303B (en) Image edge detection and edge precision verification method thereof

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