A method, device and equipment for testing the rise and fall time of electric barriers for toll collection

By combining high-speed video acquisition sensors and a main control unit with edge detection and Hough transform algorithms, the video images of electric barriers are processed automatically, solving the problems of large errors in the calculation of the lifting and lowering time of electric barriers and high labor costs, and achieving efficient and accurate time measurement.

CN114792306BActive Publication Date: 2025-01-14CHINA MERCHANTS CHONGQING HIGHWAY ENG TESTING CENT CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210412514.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-19
Publication Date
2025-01-14
Estimated Expiration
2042-04-19

AI Technical Summary

Technical Problem

Existing technologies for electric barriers suffer from large errors in calculating the lifting and lowering time, as well as high labor and time costs.

Method used

A method for testing the raising and lowering time of toll-charging electric barriers is adopted. By using a high-speed video acquisition sensor and a main control unit, combined with edge detection and Hough transform algorithms, the video images of the electric barriers are automatically processed to calculate the raising and lowering time of the electric barriers.

Benefits of technology

It improves the accuracy of measuring the lifting and lowering time of electric barriers, reduces manual intervention, saves time and labor costs, and improves testing efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114792306B_ABST
    Figure CN114792306B_ABST
Patent Text Reader

Abstract

The present invention provides a method, device and equipment for testing the rise and fall time of electric barriers for charging. The scheme divides the collected rise and fall video into frames, divides the ROI area, obtains a grayscale image after preprocessing, performs edge lifting and binarization on the grayscale image to obtain a binary edge image, performs differential processing on two adjacent frames of binary edge images, and when the non-zero pixels in the differential image are greater than a preset value, performs Hough transform on the binary edge image, obtains candidate straight lines that meet preset requirements in the current frame image, further calculates the angle between the electric barrier and the horizontal direction, and when the current frame is the last frame, obtains the start frame number and the stop frame number according to the angle, and finally calculates the rise and fall time of the electric barrier. The present invention reduces manual participation, thereby improving the accuracy of time calculation, while saving manpower and time costs.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of electric barrier testing, and in particular to a method, device and equipment for testing the rise and fall time of an electric barrier for charging. Background Art

[0002] At present, in the inspection and assessment of highway engineering quality, the "Highway Engineering Quality Inspection and Assessment Standard Volume 2 Mechanical and Electrical Engineering" requires that the rise / fall time of electric guardrails for toll collection be ≤1.0 second. The existing detection methods are divided into the stopwatch method and the video frame reading method. When the stopwatch method is used for detection, the judgment of the rise / fall time of the guardrail is too subjective, and it is difficult to synchronize the time of the stopwatch action with the rise / fall of the guardrail, so the time measurement error is generally large. When the video frame reading method is used for detection, it is necessary to record the video of the movement process of the electric guardrail on site, copy the video to the computer, and use the playback software to read and display it frame by frame. Several inspection personnel subjectively determine the rise / fall image frame of the guardrail, and calculate the rise / fall time of the guardrail based on the image frame time interval. This method has high manpower and time costs and low automation. Summary of the invention

[0003] In view of the shortcomings of the prior art, the present invention proposes a method, device and equipment for testing the rise and fall time of an electric barrier for charging, so as to solve the technical problems in the prior art of large error in measuring the rise and fall time of the electric barrier and high manpower and time costs.

[0004] A method for testing the rise and fall time of a toll electric barrier, comprising: S1, according to a preset frame rate, performing frame processing on the collected rise and fall video, obtaining a total frame number Num, and setting a variable C frame Indicates the current image frame number, variable C frame The initial value of is 1; S2 starts from the first frame image, and sequentially takes the rectangular area covering the maximum motion range of the electric railing in each frame image as the ROI area; S3 preprocesses the image of the ROI area to obtain a grayscale image; S4 extracts the edge of the grayscale image according to the edge detection algorithm, and performs binarization processing to obtain a binary edge image; S5 frame The binary edge image of the frame and the C frame -1 frame binary edge image is subjected to differential operation to obtain a differential image; S6 counts the number of non-zero pixels in the differential image to determine whether the number of non-zero pixels is less than a preset threshold, if not, proceeds to step S7, if so, takes the angle solved in the previous frame as the current angle, and proceeds to step S9; S7 performs Hough transform on the binary edge image to obtain the Cth frame binary edge image. frame A candidate straight line that meets the set requirements in the frame image; S8 calculates the angle between the electric railing and the horizontal direction based on the candidate straight line S9 judgement C frameIs the frame image the last frame image? If so, proceed to step S10. If not, obtain the next frame image after the current image as the new Cth frame image. frame frame image, repeat steps S3 to S9; S10 according to the angle Get the starting frame number C frame_start and stop frame number C frame_end S11 calculates the unit frame time interval according to the preset frame rate, and calculates the unit frame time interval according to the unit frame time interval and the starting frame number C frame_start and stop frame number C frame_end Calculate the raising / lowering time of the electric barrier.

[0005] In one of the embodiments, before step S1, it also includes: installing an electric railing rise and fall time test device at the location where the electric railing whose rise and fall time is to be tested is located; starting video acquisition in the electric railing rise and fall time test device to continuously obtain real-time images of the electric railing; controlling the electric railing to start the raising / lowering movement; identifying the state of the raising / lowering movement of the electric railing, and when the electric railing stops the raising / lowering movement, stopping video acquisition to obtain a rising and lowering video.

[0006] In one embodiment, the preprocessing in step S3 includes grayscale processing and filtering and denoising processing.

[0007] In one embodiment, step S7 includes: setting the length l of the electric barrier within a set range [l min , l max ] Take m discrete values ​​l at equal intervals within 1 , l 2 ,…,l m , the horizontal angle θ is within the setting range [θ min ,θ max ] Take n discrete values ​​θ at equal intervals within 1 ,θ 2 ,…,θ n ; Define a two-dimensional array S[m][n], initialize all elements of the two-dimensional array S[m][n] to 0; traverse all non-zero pixels (i, j) of the ROI binary edge image, and for all (l p ,θ q ) combination to vote, and the result is stored in the element S[p][q] of the two-dimensional array S[m][n]:

[0008] l p =i×cosθ q +j×sinθ q

[0009] Wherein, 1≤p≤m, 1≤q≤n; sort all elements of the two-dimensional array S[m][n] from large to small, and take the k elements with the highest sorting points (l p ,θ q ) to represent the C frame k candidate straight lines in the frame image, denoted as L 1 , L 2 ,…,L k .

[0010] In one embodiment, step S8 includes: S81 defines the lifting motion as θ(0)=0°, defines the falling motion as θ(0)=90°, and defines variable a=1; S82 determines the straight line L a (l p ,θ q ) satisfies the following formula conditions. If so, then the straight line L a The corresponding θ q That is, the angle θ between the electric railing and the horizontal direction (C frame ), and go to step S9, if not, then increase the variable a by 1:

[0011]

[0012] Among them, θ(C frame -1) is the angle between the electric barrier and the horizontal direction obtained in the previous frame image, θ thed is the preset threshold of the angle change between adjacent frame images; S83 repeats step S82 until the angle θ (C frame ), or a=k+1 is established; S84 When the angle θ (C frame ), θ(C frame ) uses the angle θ(C frame )=θ(C frame -1).

[0013] In one embodiment, step S10 includes: forming a matrix C of the frame number of each image frame and the angle between the corresponding electric barrier and the horizontal direction. frame -θ sequence; starting from the second frame image to the Num-1th frame image, for the movement of the starting rod, search frame by frame for the first frame image that meets the following formula constraint conditions, and use its frame number as C frame_start :

[0014]

[0015] From C frame_startStarting from the frame image to the Num-1 frame image, for the start of the rod movement, search frame by frame for the first frame image that satisfies the constraint adjustment of the following formula, and use its frame number as C frame_end :

[0016]

[0017] Among them, θ(C frame +1) is the angle between the electric barrier and the horizontal direction obtained in the next frame of image.

[0018] In one embodiment, the frame number of each image frame and the angle between the corresponding electric barrier and the horizontal direction form C frame -θ sequence; starting from the second frame image to the Num-1th frame image, for the falling rod motion, search frame by frame for the first frame image that meets the following formula constraint conditions, and use its frame number as C frame_start :

[0019]

[0020] From C frame_start Starting from the Num-1th frame image, for the falling bar motion, search frame by frame for the first frame image that meets the following constraint conditions, and use its frame number as C frame_end :

[0021]

[0022] Among them, θ(C frame +1) is the angle between the electric barrier and the horizontal direction obtained in the next frame of image.

[0023] In one embodiment, the formula for calculating the electric barrier rise / fall time T in step S11 is as follows:

[0024] T=(C frame_end -C frame_start )×Δt

[0025] Wherein, Δt is the unit frame time interval.

[0026] A device for testing the rise and fall time of an electric barrier for charging, characterized in that it comprises a high-speed video acquisition sensor, a main control unit and a special bracket, wherein the frame rate of the high-speed video acquisition sensor is at least 100 frames per second.

[0027] A device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of a method for testing the rise and fall time of a toll-collecting electric barrier described in the above-mentioned embodiments when executing the computer program.

[0028] It can be seen from the above technical solution that the beneficial technical effects of the present invention are as follows:

[0029] 1. The whole process uses a device to collect video, and a charging electric barrier rise and fall time test method is provided to test the rise and fall time of the electric barrier, which reduces manual participation, thereby improving the accuracy of time calculation and saving manpower and time costs.

[0030] 2. Performing differential processing on two adjacent frames of binary edge images can quickly determine whether the railing is still moving, improve test efficiency, and further save time costs. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] In order to more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the following is a brief introduction to the drawings required for the specific embodiments or the prior art description. In all the drawings, similar elements or parts are generally identified by similar reference numerals. In the drawings, the elements or parts are not necessarily drawn according to the actual scale.

[0032] Figure 1 This is an application scenario diagram of a device for testing the rise and fall time of an electric barrier for charging in one embodiment;

[0033] Figure 2 A schematic diagram of a process for obtaining a video of an electric barrier rising and falling in one embodiment;

[0034] Figure 3 A schematic diagram of a flow chart of a method for testing the rise and fall time of a toll-collecting electric barrier in an embodiment;

[0035] Figure 4 A schematic diagram of the division range of the ROI area in one embodiment;

[0036] Figure 5 FIG. 4 is a diagram showing the internal structure of a device in one embodiment. DETAILED DESCRIPTION

[0037] The following embodiments of the technical solution of the present invention are described in detail in conjunction with the accompanying drawings. The following embodiments are only used to more clearly illustrate the technical solution of the present invention, and are therefore only used as examples, and cannot be used to limit the protection scope of the present invention.

[0038] It should be noted that, unless otherwise specified, the technical terms or scientific terms used in this application should have the common meanings understood by those skilled in the art to which the present invention belongs.

[0039] In one embodiment, Figure 1As shown, a device for testing the rise and fall time of an electric barrier for toll collection is provided, including a high-speed video acquisition sensor, a main control unit and a special bracket, wherein the frame rate of the high-speed video acquisition sensor is at least 100 frames per second. Specifically, the main control unit contains a human-computer interaction part, which is installed on one side of the electric barrier through a special bracket and the central optical axis of the sensor is perpendicular to the vertical plane where the barrier is located. In actual use, an industrial camera with a frame rate of 200 frames per second and a resolution of 2592×1944 can be used as a high-speed video acquisition sensor, which is installed on a triangular bracket 10 meters away from the electric barrier and 1.1 meters high; a portable computer is used as the main control unit. At the same time, in the toll booth, the toll computer sends a lift / drop command to the electric barrier to start the movement of the electric barrier, thereby performing video acquisition.

[0040] In one embodiment, Figure 2 As shown, a method for obtaining a rising and lowering video of an electric railing is provided, comprising: installing an electric railing rising and lowering time testing device at a location where an electric railing whose rising and lowering time is to be tested is located; starting video acquisition in the electric railing rising and lowering time testing device to continuously acquire real-time images of the electric railing; controlling the electric railing to start the raising / lowering movement; identifying the state of the raising / lowering movement of the electric railing, and when the electric railing stops the raising / lowering movement, stopping video acquisition to obtain a rising and lowering video.

[0041] Specifically, the video acquisition method needs to be combined with Figure 1 The toll-collecting electric barrier raising and lowering time test device (hereinafter referred to as the "test device") is used in the layout of the test device. When the test device is arranged, if the background of the barrier image captured by the high-speed video acquisition sensor is relatively complex, a solid-color curtain is set up on the other side of the electric barrier to simplify the background of the captured barrier image, and the time interval between the captured video image frames should be kept constant. A single on-site acquisition is only for one bar raising movement or one bar lowering movement. During the video acquisition process, the high-speed video acquisition sensor should remain stationary.

[0042] In one embodiment, Figure 3 As shown, a method for testing the rise and fall time of an electric barrier for charging is provided, comprising the following steps:

[0043] S1 processes the collected take-off and landing videos according to the preset frame rate, obtains the total number of frames Num, and sets the variable C frame Indicates the current image frame number, variable C frame The initial value of is 1.

[0044] Specifically, open the video captured on site, obtain the total number of video image frames Num, and initialize the variable C frame =1, and construct the 0th frame binary edge image with all pixel values ​​​​being 0.

[0045] S2 starts from the first frame image and sequentially takes the rectangular area covering the maximum motion range of the electric barrier in each frame image as the ROI area.

[0046] Specifically, the first frame image is read, and a rectangular area covering the maximum motion range of the electric barrier is defined as a region of interest (ROI area) through human-computer interaction, such as Figure 4 As shown; once the region is defined, subsequent image frames use the same ROI region pixel coordinates as the first frame image.

[0047] S3 preprocesses the image in the ROI area to obtain a grayscale image.

[0048] Specifically, the preprocessing in step S3 includes grayscale processing and filtering and denoising processing. During image preprocessing, for the color ROI area image, it is converted into a grayscale image by the calculation formula Gray = 0.30R + 0.59G + 0.11B, where Gray is the pixel gray value, and R, G, and B are the three primary color components; the grayscale image is processed by the mean filtering algorithm to reduce the interference of image noise on the subsequent analysis process.

[0049] S4 extracts the edge of the grayscale image according to the edge detection algorithm, and performs binarization processing to obtain a binary edge image;

[0050] Specifically, the Laplacian second-order differential operator is used for edge detection.

[0051] S5 will be C frame The binary edge image of the frame and the C frame -1 frame binary edge image is subjected to differential operation to obtain a differential image;

[0052] S6: Count the number of non-zero pixels in the differential image, and determine whether the number of non-zero pixels is less than a preset threshold. If not, proceed to step S7; if yes, take the angle solved in the previous frame as the current angle, and proceed to step S9;

[0053] S7 performs Hough transform on the binary edge image to obtain the C frame Candidate straight lines in the frame image that meet the set requirements;

[0054] In one embodiment, step S7 includes: setting the length l of the electric barrier within a set range [l min , l max ] Take m discrete values ​​l at equal intervals within 1 , l 2 ,…,l m , the horizontal angle θ is within the setting range [θ min ,θ max ] Take n discrete values ​​θ at equal intervals within 1 ,θ 2 ,…,θn ; Define a two-dimensional array S[m][n], and initialize all elements of the two-dimensional array S[m][n] to 0; traverse all non-zero pixels (i, j) of the ROI binary edge image, and for all (l p ,θ q ) combination votes, and the result is stored in the element S[p][q] of the two-dimensional array S[m][n]:

[0055] l p =i×cosθ q +j×sinθ q (1)

[0056] Among them, 1≤p≤m, 1≤q≤n; sort all the elements of the two-dimensional array S[m][n] from large to small, and take the (l p ,θ q ) to represent the C frame k candidate straight lines in the frame image, denoted as L 1 , L 2 ,…,L k .

[0057] S8 calculates the angle between the electric railing and the horizontal direction based on the candidate straight line

[0058] In one embodiment, step S8 includes: S81 defines the lifting motion as θ(0)=0°, defines the falling motion as θ(0)=90°, and defines variable a=1; S82 determines the straight line L a (l p ,θ q ) satisfies the condition of formula (2), and the combination of “0≤θ q -θ(C frame -1)≤θ thed " is used to judge the movement of the rod, "0≤θ(C frame -1)-θ q ≤θ thed " is used to judge the falling rod movement. If so, then the straight line L a The corresponding θ q That is, the angle θ between the electric railing and the horizontal direction (C frame ), and go to step S9, if not, then increase the variable a by 1:

[0059]

[0060] Among them, θ(C frame -1) is the angle between the electric barrier and the horizontal direction obtained in the previous frame image, θ thedis a preset threshold value of the angle change between adjacent frame images;

[0061] S83 repeats step S82 until the angle θ (C frame ), or a=k+1 holds, where k is the k candidate straight lines in step S7 above; S84 When the angle θ (C frame ), θ(C frame ) uses the angle θ(C frame )=θ(C frame -1).

[0062] S9 judgement C frame Is the frame image the last frame image? If so, proceed to step S10. If not, obtain the next frame image after the current image as the new Cth frame image. frame frame image, repeat steps S3 to S9.

[0063] Specifically, judging the frame Whether the frame image is the last frame image, that is, judging C frame ≤Num, if it is true, go directly to step S10, if not, set variable C frame =C frame +1, iteratively repeat the processing of steps S3-S9 until C frame Until ≤Num is established.

[0064] S10 according to the angle Get the starting frame number C frame_start and stop frame number C frame_end .

[0065] In one embodiment, for the pole lifting movement, step S10 includes: forming a C matrix by combining the frame number of each image frame and the angle between the corresponding electric barrier and the horizontal direction. frame -θ sequence; starting from the second frame image to the Num-1th frame image, for the motion of the starting rod, search frame by frame for the first frame image that satisfies the constraint condition of formula (3), and take its frame number as C frame_start :

[0066]

[0067] From C frame_start Starting from the frame image to the Num-1 frame image, for the start rod movement, search frame by frame for the first frame image that satisfies the constraint adjustment of formula (4), and use its frame number as C frame_end :

[0068]

[0069] Among them, θ(Cframe +1) is the angle between the electric barrier and the horizontal direction obtained in the next frame of image.

[0070] In one embodiment, for the falling bar movement, step S10 includes: forming a C matrix with the frame number of each image frame and the angle between the corresponding electric barrier and the horizontal direction. frame -θ sequence; starting from the second frame image to the Num-1th frame image, for the falling rod motion, search frame by frame for the first frame image that satisfies the constraint condition of the following equation (5), and take its frame number as C frame_start :

[0071]

[0072] From C frame_start Starting from the Num-1th frame image, for the falling bar motion, search frame by frame for the first frame image that satisfies the constraint condition of equation (6), and use its frame number as C frame_end :

[0073]

[0074] Among them, θ(C frame +1) is the angle between the electric barrier and the horizontal direction obtained in the next frame of image.

[0075] S11 calculates the unit frame time interval according to the preset frame rate, and calculates the unit frame time interval according to the unit frame time interval and the starting frame number C frame_start and stop frame number C frame_end Calculate the raising / lowering time of the electric barrier.

[0076] In one embodiment, the formula (7) for calculating the electric barrier rise / fall time T in step S11 is:

[0077] T=(C frame_end -C frame_start )×Δt (7)

[0078] Wherein, Δt is the unit frame time interval.

[0079] Specifically, the unit frame time interval is the image frame time interval Δt=1 second÷frame rate.

[0080] In one embodiment, a device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 5As shown. The device includes a processor, a memory, a network interface and a database connected through a system bus. Among them, the processor of the device is used to provide computing and control capabilities. The memory of the device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the device is used to store configuration templates and can also be used to store target web page data. The network interface of the device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a method for testing the rise and fall time of a toll-collecting electric barrier is implemented.

[0081] Those skilled in the art will understand that Figure 5 The structure shown in the figure is merely a block diagram of a partial structure related to the scheme of the present application, and does not constitute a limitation on the device to which the scheme of the present application is applied. The specific device may include more or fewer components than shown in the figure, or combine certain components, or have a different arrangement of components.

[0082] Obviously, those skilled in the art should understand that the modules or steps of the present invention described above can be implemented by a general-purpose computing device, they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, and optionally, they can be implemented by a program code executable by a computing device, so that they can be stored in a computer storage medium (ROM / RAM, magnetic disk, optical disk) and executed by the computing device, and in some cases, the steps shown or described can be executed in a different order than that here, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Therefore, the present invention is not limited to any specific combination of hardware and software.

[0083] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein by equivalents. These modifications or replacements do not make the essence of the corresponding technical solutions deviate from the scope of the technical solutions of the embodiments of the present invention, and they should all be included in the scope of the claims and specification of the present invention.

Claims

1. A method for testing the rise and fall time of an electric barrier for toll collection, characterized in that: include: S1 processes the collected take-off and landing videos according to the preset frame rate, obtains the total number of frames Num, and sets the variable C frame Indicates the current image frame number, variable C frame The initial value of is 1; S2 starts from the first frame image and sequentially takes the rectangular area covering the maximum motion range of the electric barrier in each frame image as the ROI area; S3 preprocesses the image of the ROI area to obtain a grayscale image; S4 extracts the edge of the grayscale image according to an edge detection algorithm, and performs binarization processing to obtain a binary edge image; S5 will be C frame The binary edge image of the frame and the C frame -1 frame binary edge image is subjected to differential operation to obtain a differential image; S6: counting the number of non-zero pixels in the differential image, determining whether the number of non-zero pixels is less than a preset threshold, if not, proceeding to step S7; if yes, taking the angle solved in the previous frame as the current angle, and proceeding to step S9; S7 performs Hough transform on the binary edge image to obtain the C frame Candidate straight lines in the frame image that meet the set requirements include: Set the length l of the electric railing within the setting range [l min , l max ] Take m discrete values ​​l1, l2, ..., l at equal intervals within m , the horizontal angle θ is within the setting range [θ min ,θ max ] take n discrete values ​​θ1, θ2, ..., θ at equal intervals n ; Define a two-dimensional array S[m][n], and initialize all elements of the two-dimensional array S[m][n] to 0; Traverse all non-zero pixels (i, j) of the ROI binary edge image, and for all (l p ,θ q ) combination to vote, and the result is stored in the element S[p][q] of the two-dimensional array S[m][n]: l p =i×cosθ q +j×sinθ q Among them, 1≤p≤m, 1≤q≤n; Sort all elements of the two-dimensional array S[m][n] from large to small, and take the (l p ,θ q ) to represent the C frame The k candidate lines in the frame image are denoted as L1, L2, ..., L k ; S8 calculates the angle θ (C frame ),include: S81 defines the lifting motion as θ(0)=0°, the lowering motion as θ(0)=90°, and defines the variable a=1; S82 determines the straight line L a (l p ,θ q ) satisfies the following formula conditions. If so, then the straight line L a The corresponding θ q That is, the angle θ between the electric railing and the horizontal direction (C frame ), and go to step S9, if not, then increase the variable a by 1: Among them, θ(C frame -1) is the angle between the electric barrier and the horizontal direction obtained in the previous frame image, θ thed is a preset threshold value of the angle change between adjacent frame images; S83 repeats step S82 until the angle θ (C frame ), or a=k+1 holds; S84 If the angle θ (C frame ), θ(C frame ) uses the angle θ(C frame )=θ(C frame -1); S9 judgement C frame Is the frame image the last frame image? If so, proceed to step S10. If not, obtain the next frame image after the current image as the new Cth frame image. frame frame image, repeating steps S3 to S9; S10 is based on the angle θ(C frame ), get the starting frame number C frame_start and stop frame number C frame_end ,include: The frame number of each image frame and its corresponding angle between the electric barrier and the horizontal direction form C frame -θ sequence; Starting from the second frame image to the Num-1th frame image, for the movement of the rod, search frame by frame for the first frame image that meets the following constraint conditions, and use its frame number as C frame_start : From C frame_start Starting from the frame image to the Num-1 frame image, for the start of the rod movement, search frame by frame for the first frame image that meets the following constraints, and use its frame number as C frame_end : Among them, θ(C frame +1) is the angle between the electric barrier and the horizontal direction obtained in the next frame of image; The frame number of each image frame and its corresponding angle between the electric barrier and the horizontal direction form C frame -θ sequence; Starting from the second frame image to the Num-1th frame image, for the falling rod motion, search frame by frame for the first frame image that meets the following constraint conditions, and use its frame number as C frame_start : From C frame_start Starting from the Num-1th frame image, for the falling bar motion, search frame by frame for the first frame image that meets the following constraint conditions, and use its frame number as C frame_end : Among them, θ(C frame +1) is the angle between the electric barrier and the horizontal direction obtained in the next frame of image; S11 calculates the unit frame time interval according to the preset frame rate, and calculates the unit frame time interval according to the unit frame time interval and the starting frame number C frame_start and stop frame number C frame_end Calculate the raising / lowering time of the electric barrier.

2. The method according to claim 1, characterized in that Before step S1, the method further includes: Install an electric barrier rise and fall time test device at the location where the electric barrier whose rise and fall time is to be tested is located; Starting the video acquisition in the electric barrier rise and fall time testing device to continuously acquire the real-time image of the electric barrier; Control the electric barrier to start the lifting / lowering movement; Identify the state of the raising / lowering movement of the electric barrier. When the electric barrier stops raising / lowering movement, stop video acquisition to obtain the raising / lowering video.

3. The method according to claim 1, characterized in that The preprocessing in step S3 includes grayscale processing and filtering and denoising processing.

4. The method according to claim 1, characterized in that: The formula for calculating the electric barrier rise / fall time T in step S11 is as follows: T=(C frame_end -C frame_start )×Δt Wherein, Δt is the unit frame time interval.

Citation Information

Patent Citations

  • Infrared video detection method for dangerous gas leakage under moving target low contrast

    CN108921878A

  • Control method and device for lifting rod

    CN109887137A