Snakelike running examination method and implementation device thereof
By automatically identifying and dividing the serpentine run assessment area using image processing technology, the problem of inaccuracy in manual assessment is solved, and high-precision automated testing is achieved.
Patent Information
- Application Number
- CN202210536374.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-17
- Publication Date
- 2025-11-18
- Estimated Expiration
- 2042-05-17
AI Technical Summary
The existing serpentine run assessment method mainly relies on manual assessment, which leads to inaccurate test results.
By acquiring image information of the assessment area, identifying pole and ground information, calculating pole coordinates, dividing the test area, detecting whether the tester passes through the test area in a preset order, and calculating the test time, automated assessment is achieved.
The serpentine run assessment has been automated, improving the accuracy and precision of the test.
Smart Images

Figure CN114972475B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of machine vision technology, and in particular to a serpentine running assessment method and its implementation device. Background Technology
[0002] The serpentine run, also known as the "S"-shaped run, is a common assessment item in military physical training syllabus. It involves setting up several poles on the test area, and the test taker must navigate around all the poles in a specific order to reach the finish line, without missing or falling over any poles. Its main purpose is to enhance speed and agility, and improve the ability to change direction quickly. Currently, serpentine run assessments are generally conducted manually, which has significant drawbacks, resulting in less accurate test scores.
[0003] Therefore, there is an urgent need in this field for a new serpentine running assessment method and its implementation device to solve the technical problems existing in the background technology. Summary of the Invention
[0004] To solve the above-mentioned technical problems, one technical solution adopted by the present invention is: to provide a serpentine running assessment method, comprising:
[0005] Acquire image information of the assessment area, including ground image information and several pole image information;
[0006] Calculate the coordinate information of all poles in the assessment area based on the image information of several poles;
[0007] Based on the coordinate information of all the poles, the ground image information is divided into several test areas;
[0008] The image information obtained includes the tester's image information;
[0009] Based on the tester's image information, it is detected whether the tester passes through several preset test areas in a preset order and completes all the pole-walking actions specified in the assessment.
[0010] If yes, the test time is calculated based on the timestamps of the tester entering the first test area and reaching the finish line; otherwise, the tester's assessment is deemed invalid.
[0011] Preferably, the step of calculating the coordinate information of all poles in the assessment area based on the image information of the plurality of poles includes:
[0012] Obtain the rectangular outer frame region corresponding to each of the rods based on the image information of each rod;
[0013] Based on each of the rectangular outer frame regions, obtain the pole endpoint coordinates, pole width, and pole height corresponding to the outer frame region;
[0014] The coordinates of the midpoint of the bottom edge of the corresponding rectangular outer frame region are calculated based on the coordinates of the pole endpoints, the pole width, and the pole height of each rectangular outer frame region, and the midpoint coordinates are used as the coordinate information of the corresponding pole body.
[0015] Preferably, the step of dividing the ground image information into several test areas based on the coordinate information of all the poles includes:
[0016] Based on the coordinate information of all the poles, obtain the main judgment area and auxiliary judgment area of the ground image information;
[0017] The main judgment area is divided into several test areas based on the coordinate information of all the rods.
[0018] Preferably, the step of obtaining the main judgment region and auxiliary judgment region of the ground image information based on the coordinate information of all the poles includes:
[0019] Based on the position of each midpoint coordinate in the image information, the coordinates are divided into left midpoint coordinates and right midpoint coordinates;
[0020] A first dividing line is obtained by drawing a straight line through the coordinates of all the left midpoints, and a second dividing line is obtained by drawing a straight line through the coordinates of all the right midpoints.
[0021] The coordinates of the midpoints closest to and farthest from the starting line are set at the first dividing line. The coordinates of the closest and farthest midpoints are shifted to the left by a first preset distance and to the right by a second preset distance to obtain the coordinates of the four endpoints, wherein the second preset distance crosses the second dividing line.
[0022] The four endpoint coordinates are connected sequentially to form the main judgment area, and the area outside the main judgment area is the auxiliary judgment area.
[0023] Preferably, the step of dividing the main judgment area into several test areas based on the coordinate information of all the rods includes:
[0024] By drawing straight lines that intersect the first dividing line and the second dividing line through the coordinates of each midpoint, several parallel third dividing lines are obtained.
[0025] The first dividing line, the second dividing line, and the third dividing line divide the main judgment area into several test areas.
[0026] Preferably, the step of detecting whether the tester has passed through a predetermined number of test areas in a predetermined order and completed all the required pole-driving actions according to the tester's image information includes a method for determining the pole-driving actions:
[0027] If the test subject passes the first dividing line once in the forward / reverse direction and then passes the second dividing line twice in succession, or passes the second dividing line once and then passes the first dividing line twice in succession, it is determined that one pole-walking cycle has been completed.
[0028] Preferably, the step of detecting whether the tester has passed through a predetermined number of test areas in a predetermined order and completed all the required pole-driving actions according to the tester's image information includes a method for determining the pole-driving actions:
[0029] Except for the midpoint coordinates closest to and farthest from the starting line, all other midpoint coordinates are surrounded by four test areas, which are designated as the first test area, the second test area, the third test area, and the fourth test area respectively along a preset forward direction. If the tester passes through the first test area, the second test area, the third test area, and the fourth test area in sequence in the forward direction, or passes through the fourth test area, the third test area, the second test area, and the first test area in sequence in the turnaround direction, it is determined that one round of the pole is completed.
[0030] The coordinates of the midpoint furthest from the starting line are surrounded by two test areas and an auxiliary judgment area. The test areas are designated as the fifth and sixth test areas respectively along the preset forward direction. The tester passes through the fifth test area, the sixth test area and the auxiliary judgment area in sequence in the forward direction, and then passes through the auxiliary judgment area and the fifth test area in sequence in the turn-back direction. This is considered as completing one round of the pole.
[0031] Preferably, the serpentine running assessment method further includes:
[0032] After the tester reaches the finish line but before the tester's test time is calculated, it is determined from the image information whether the pole has fallen.
[0033] If yes, the test taker's assessment is deemed invalid; if no, the test taker's test time is calculated.
[0034] Preferably, the step of determining whether the pole has fallen based on the image information includes:
[0035] Before testing, the image information of a preset number of frames is obtained as a standard image group;
[0036] The values of the R, G, and B channels of each pixel in the same rectangular frame region in each frame of the standard image group are obtained, and the average value of the R, G, and B channels of each pixel in the rectangular frame region before the test is calculated. The calculated average value of the R, G, and B channels of each pixel in the rectangular frame region before the test is used as the first set of average values of the R, G, and B channels of the pixel in the rectangular frame region.
[0037] During the test, the image information is used to obtain the preset number of pre-start images of the test subject before entering the first test area and the post-finish images after crossing the finish line.
[0038] The values of the R, G, and B channels of each pixel in the rectangular frame region corresponding to the standard image group in each frame of the pre-start image group are obtained, and the average value of the R, G, and B channels of each pixel in the rectangular frame region before the start is calculated. The calculated average value of the R, G, and B channels of each pixel in the rectangular frame region before the start is used as the set of average values of the R, G, and B channels of the second pixel in the rectangular frame region.
[0039] The values of the R, G, and B channels of each pixel in the rectangular outer frame region corresponding to the standard image group in each frame of the post-race image group are obtained, and the average value of the R, G, and B channels of each pixel in the rectangular outer frame region after the race is calculated. The calculated average value of the R, G, and B channels of each pixel in the rectangular outer frame region after the race is used as the set of the average values of the R, G, and B channels of the third pixel in the rectangular outer frame region.
[0040] Based on the R, G, and B channel mean values of the first pixel, the second pixel, and the third pixel within the same rectangular outer frame region, determine whether the corresponding pole has fallen.
[0041] The present invention also provides a serpentine running assessment device, comprising:
[0042] The first acquisition module is used to acquire image information of the assessment area, including ground image information and several pole image information;
[0043] The first calculation module is used to calculate the coordinate information of all poles in the assessment area based on the image information of the several poles;
[0044] The second calculation module is used to divide the ground image information into several test areas based on the coordinate information of all the poles;
[0045] The second acquisition module is used to acquire the tester image information, which includes the tester, from the image information;
[0046] The detection module is used to detect whether the tester has passed through a number of preset test areas in a preset order and completed all the pole-walking actions required by the assessment based on the tester's image information; if so, the tester's test time is calculated based on the timestamps of the tester entering the first test area and reaching the end point; if not, the tester's assessment is deemed invalid.
[0047] The beneficial effects of this invention are as follows: In implementing the serpentine running assessment method, this invention first acquires image information within the assessment area and identifies ground image information and several pole image information. Then, based on the pole image information, it obtains the coordinate information of all poles within the assessment area. Next, based on the coordinate information of all poles, the ground image information is divided into several test areas. Finally, it detects whether the test taker has passed through several preset test areas in a preset order and completed all the pole-walking actions required by the assessment. If so, the test time can be calculated based on the timestamps of the test taker entering the first test area and reaching the finish line. This invention can achieve automated testing of the serpentine running assessment with high accuracy. Attached Figure Description
[0048] Figure 1 This is a flowchart illustrating the serpentine running assessment method according to an embodiment of the present invention;
[0049] Figure 2 yes Figure 1 A flowchart illustrating step S102;
[0050] Figure 3 yes Figure 1 A flowchart illustrating step S103;
[0051] Figure 4 yes Figure 3 A flowchart illustrating step S301;
[0052] Figure 5 This invention is based on Figure 1 A schematic diagram of the process for judging the pole fall in the serpentine running test method of the embodiment;
[0053] Figure 6 yes Figure 5 A flowchart illustrating step S501;
[0054] Figure 7 This is a schematic diagram of the serpentine running assessment device according to an embodiment of the present invention;
[0055] Figure 8 This is a schematic diagram of the assessment area according to an embodiment of the present invention;
[0056] Figure 9 This is a schematic diagram of the travel route of the tester in an embodiment of the present invention. Detailed Implementation
[0057] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of the present invention.
[0058] The terms "comprising" and "having," and any variations thereof, used in this invention are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or apparatus that includes a series of steps or units is not limited to the steps or units listed, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to such process, method, product, or apparatus.
[0059] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of the invention. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0060] Figure 1 This is a flowchart illustrating the serpentine running assessment method according to an embodiment of the present invention. It should be noted that if substantially the same result is obtained, the method of the present invention is not necessarily identical. Figure 1 The illustrated process sequence is limited. For example... Figure 1 As shown, the method includes the following steps:
[0061] Step S101: Obtain image information of the assessment area, including ground image information and several pole image information.
[0062] Specifically, in step S101, staff first set up the assessment area on-site. Please refer to... Figure 8 and Figure 9 In this implementation, a total of 7 poles are required. Along the tester's direction of travel, the 7 poles are staggered on the left and right sides. Four poles are placed on the left side in a straight line, and three poles are placed on the right side in a straight line, with the two lines parallel. During the assessment, the tester must start from the left side where the four poles are placed, i.e., from... Figure 9 Starting from area 0, navigate around all the poles specified in the assessment in sequence, finally turning back to the finish line on the right side where there are 3 poles (corresponding to...). Figure 9 The test was completed in area 20. After setting up the assessment area, image information of the assessment area was acquired through external equipment, specifically by setting up test equipment with camera capabilities. The image information included ground image information and pole image information.
[0063] Step S102: Calculate the coordinate information of all poles in the assessment area based on the image information of several poles.
[0064] Specifically, please see Figure 2 Step S102 includes the following steps:
[0065] Step S201: Obtain the rectangular outer frame area of the corresponding rod based on the image information of each rod.
[0066] Specifically, through manual or automatic identification, the rectangular outline area of each of the seven poles is marked in the image information. The rectangular outline area is the area occupied by the pole in the image information. It should be noted that the rectangular outline area, once marked, does not change with the movement of the poles without calibration.
[0067] Step S202: Obtain the pole endpoint coordinates, pole width, and pole height of each rectangular outer frame region based on the rectangular outer frame region.
[0068] Specifically, in step S202, please refer to... Figure 8 The system automatically identifies the pole's endpoint coordinates (Rxn, Ryn), pole width Rwn, and pole height Rhn within a rectangular outer frame area. Here, (Rxn, Ryn) represents the top-left coordinates, meaning the pole endpoint coordinates (Rxn, Ryn) are the coordinates of the top-left corner of the rectangular outer frame area of the pole, and n is the pole's label; for example, (Rx1, Ry1) represents the endpoint coordinates of pole number 1.
[0069] Step S203: Calculate the midpoint coordinates of the bottom edge of the corresponding rectangular outer frame area based on the pole endpoint coordinates, pole width, and pole height, and use the midpoint coordinates as the coordinate information of the corresponding pole.
[0070] Specifically, the midpoint coordinates are (Xn, Yn), and the calculation formula is as follows:
[0071] Xn = Rxn + Rwn / 2;
[0072] Yn = Ryn + Rhn.
[0073] Therefore, there are a total of 7 midpoint coordinates. The 4 midpoint coordinates on the left are called the left midpoint coordinates, namely (X1,Y1), (X3,Y3), (X5,Y5), and (X7,Y7); the 3 midpoint coordinates on the right are called the right midpoint coordinates, namely (X2,Y2), (X4,Y4), and (X6,Y6).
[0074] Step S103: Divide the ground image information into several test areas based on the coordinate information of all poles.
[0075] Specifically, please see Figure 3 Step S103 specifically includes the following steps:
[0076] Step S301: Obtain the main judgment area and auxiliary judgment area of the ground image information based on the coordinate information of all poles.
[0077] Specifically, please see Figure 4 Step S301 includes:
[0078] Step S401: Divide the position of each midpoint coordinate in the image information into left midpoint coordinates and right midpoint coordinates.
[0079] Step S402: Draw a straight line through the coordinates of all left midpoints to obtain the first dividing line, and draw a straight line through the coordinates of all right midpoints to obtain the second dividing line.
[0080] Step S403: Set the coordinates of the nearest and farthest midpoints from the starting line to be located on the first dividing line. The coordinates of the nearest and farthest midpoints are both shifted to the left by a first preset distance and to the right by a second preset distance to obtain the coordinates of the four endpoints; wherein the second preset distance crosses the second dividing line.
[0081] Step S404: Connect the coordinates of the four endpoints in sequence to form the main judgment area. The area outside the main judgment area is the auxiliary judgment area.
[0082] In this embodiment, please refer to Figure 8 and Figure 9The four midpoints on the left are called the left midpoint coordinates, namely (X1,Y1), (X3,Y3), (X5,Y5), and (X7,Y7), corresponding to poles 1, 3, 5, and 7 respectively. The three midpoints on the right are called the right midpoint coordinates, namely (X2,Y2), (X4,Y4), and (X6,Y6), corresponding to poles 2, 4, and 6 respectively. A straight line is drawn through (X1,Y1), (X3,Y3), (X5,Y5), and (X7,Y7), denoted as L1. A straight line is drawn through (X2,Y2), (X4,Y4), and (X6,Y6), denoted as L2. Since L1 and L2 are parallel, the line containing L1 is the first dividing line, and the line containing L2 is the second dividing line. Draw a horizontal line H1 through (X1, Y1), and mark the intersection of the extension of L2 and H1 as (X0, Y0). Draw a horizontal line H2 through (X7, Y7), and mark the intersection of the extension of L2 and H2 as (X8, Y8). (X7,Y7) is shifted to the left by a first preset distance to point P1. The first preset distance is half the distance between the intersection points on the same horizontal line that intersects both L1 and L2. In this embodiment, it is half the horizontal distance between (X7,Y7) and (X8,Y8), which is (X8-X7) / 2. (X7,Y7) is then shifted to the right by a second preset distance and crosses the second dividing line to point P4. The second preset distance includes the distance between the intersection points on the same horizontal line that intersects both L1 and L2, and the distance the horizontal line is shifted by the first preset distance after crossing the second dividing line. In this embodiment, it is 1.5 times the horizontal distance between (X7,Y7) and (X8,Y8). This can be seen as (X8,Y8) shifting to the right by a distance of (X8-X7) / 2; (X1,Y1) is similarly shifted to the left by a first preset distance to point P2, which in this embodiment is half the horizontal distance between (X1,Y1) and (X0,Y0), that is, (X0-X1) / 2; (X1,Y1) is then shifted to the right by a second preset distance and crosses the second dividing line to point P3, which in this embodiment is 1.5 times the horizontal distance between (X1,Y1) and (X0,Y0), and can be seen as (X0,Y0) shifting to the right by a distance of (X0-X1) / 2; then the parallelogram formed by P1-P2-P3-P4 is the main judgment area, and the area outside the main judgment area is the auxiliary judgment area.
[0083] Step S302: Divide the main judgment area into several test areas based on the coordinate information of all rods.
[0084] Specifically, step S302 includes the following steps:
[0085] Draw lines through the coordinates of each midpoint that intersect the first and second dividing lines, resulting in several parallel third dividing lines. The first, second, and third dividing lines divide the main decision region into several test regions.
[0086] In this embodiment, H1 and H2 are two of the third dividing lines, and there are a total of 7 third dividing lines. Through the above steps, the main judgment area composed of P1-P2-P3-P4 is divided into several independent test areas, specifically 18 test areas (corresponding to...). Figure 9 (Numbers 1-18 in the original text). Adding the auxiliary judgment area outside the main judgment area, L1, L2, and H1 divide the auxiliary judgment area into a starting region (corresponding to...). Figure 9 (number 0 in the middle) and the endpoint area (corresponding to) Figure 9 In the section number 20), the auxiliary judgment area outside H2 is also treated as a separate area (corresponding to...). Figure 9 (Number 19 in the original text). A total of 21 identifiable individual regions.
[0087] By following the steps S101-S103 above, the preparations for the test can be completed.
[0088] Step S104: Obtain image information including the tester's image information.
[0089] In step S104, the test subject is located within the assessment area, and the image information includes the test subject's image information. By recognizing the outer frame data of the test subject within the image, the coordinates of the bottom center of the human body are taken as the test subject's position within the assessment area.
[0090] Step S105: Based on the tester's image information, detect whether the tester has passed through several preset test areas in a preset order and completed all the pole-walking actions required by the assessment.
[0091] In step S105, the detection method checks whether the center coordinates of the bottom of the human body pass through a predetermined number of test areas in a predetermined order. Whether the test subject passes through the predetermined number of test areas in a predetermined order is essentially determining whether the test subject has completed the pole-walking motion according to a predetermined route.
[0092] Except for the coordinates of the midpoints closest to and farthest from the starting line, all other midpoint coordinates are surrounded by four test areas, designated as the first, second, third, and fourth test areas along the preset direction of travel. The tester completes one round of navigating the pole by passing through these four test areas sequentially in the forward direction, or sequentially in the reverse direction. Taking pole number 2 as an example, the first, second, third, and fourth test areas corresponding to pole number 2, 3, 4, and 5 in the diagram are shown. The tester completes one round of navigating pole number 2 by passing through these four test areas in the forward direction in the order of 2-3-4-5, and so on.
[0093] The coordinates of the midpoint furthest from the starting line are surrounded by two testing zones and an auxiliary judgment zone, which are the fifth testing zone along the preset direction of travel (corresponding to...). Figure 9 Number 17) and the sixth test area (corresponding to Figure 9 (Number 18) The tester passes through the fifth test area, the sixth test area, and the auxiliary judgment area in sequence in the direction of travel (corresponding to...). Figure 9 If the number is 19, and then the auxiliary judgment area and the fifth test area are passed in sequence in the turning direction, it is determined that the circle around pole 7 has been completed once.
[0094] Specifically, for the complete assessment process, please refer to [link / reference]. Figure 9 The tester needs to follow the path shown in the diagram, sequentially traversing the areas numbered 0-1-2-3-4-5-6-7-8-9-10-11-12-13-14-15-16-17-18-19, and then, starting from 19, sequentially traversing the areas numbered 17-16-15-14-13-12-11-10-9-8-7-6-5-4-3-20 to complete the serpentine run test. Therefore, the tester's movement from 0 to 1 is considered the start; from 2 to 5, it's considered the first time around pole 2; from 5 to 8, it's considered the first time around pole 3; from 8 to 11, it's considered the first time around pole 4, and so on. Finally, the tester's movement directly from 3 to 20 is considered reaching the finish line. In one embodiment, when the tester turns back, passing through at least one of 17 and 16 from 19 is also considered as turning back around pole 7.
[0095] In other embodiments, the determination of the pole-driving action can also be based on the following method: if the tester, in the forward / reverse direction, passes the first dividing line once and then passes the second dividing line twice consecutively, or passes the second dividing line once and then passes the first dividing line twice consecutively, then it is determined that one pole-driving action has been completed. It should be noted that the forward / reverse direction mentioned in all embodiments of this specification refers to the tester running according to the route planned by the tester in the serpentine running assessment content. The method of this invention also uses the planned route as a preset path, and uses the preset path as the standard for determining whether the tester runs according to the planned route.
[0096] Step S106: If yes, calculate the test time based on the timestamps of the tester entering the first test area and reaching the finish line; if no, determine that the tester's assessment is invalid.
[0097] Specifically, the test time can be calculated by marking the timestamps when the test subject enters the first test area and when they reach the finish line, and then calculating the time difference between the two timestamps. It should be noted that the first test area corresponds to... Figure 9 Number 1, the endpoint corresponds to Figure 9 Number 20.
[0098] This method acquires image information within the assessment area and identifies ground and pole images. It then obtains the coordinates of all poles within the assessment area based on the pole images. Next, it divides the ground image into several test zones based on the pole coordinates. Finally, it checks whether the test taker passes through the preset test zones in a predetermined order and completes all the required pole-walking movements. If so, the test time is calculated based on the timestamps of the test taker entering the first test zone and reaching the finish line. This method automates the serpentine run assessment with high accuracy.
[0099] Since whether the pole falls down is also a criterion for judging the serpentine run, please refer to the following steps based on S101-S106 above. Figure 5 In an optional embodiment, the method further includes:
[0100] Step S501: After the tester reaches the finish line but before calculating the tester's test time, determine whether the pole has fallen based on the image information;
[0101] Step S502: If yes, the tester's assessment is deemed invalid; if no, the tester's test time is calculated.
[0102] By determining whether the pole has fallen, we can further assist in judging whether the tester's assessment is valid.
[0103] Specifically, please see Figure 6 Step S501 includes the following steps:
[0104] Step S601: Before conducting the test, obtain image information of a preset number of frames as a standard image group.
[0105] In this embodiment, 10 frames of image information are used as a standard image group, but it is not limited to this. It should be noted that "before the test" here refers to the time period after step S103 is completed, before the tester appears in the image information.
[0106] Step S602: Obtain the R, G, and B channel values of each pixel in the same rectangular outer frame region of each frame in the standard image group, and calculate the average value of the R, G, and B channels of each pixel in the rectangular outer frame region before the test. Use the calculated average value of the R, G, and B channels of each pixel in the rectangular outer frame region before the test as the set of the average values of the R, G, and B channels of the first pixel in the rectangular outer frame region.
[0107] Specifically, the rectangular bounding area of each frame of image information has a number of pixels, for example, 15,000. Each pixel has three values corresponding to the R, G, and B channels, for a total of 45,000 values. By calculating the average R, G, and B values of pixels at the same location over 10 frames of images, we obtain the average values for each channel of R, G, and B for the 15,000 pixels, resulting in 45,000 average values. These 45,000 average values are collected as a set, called the set of R, G, and B channel average values for each pixel in the rectangular bounding area.
[0108] In this embodiment, the calculation formula (1) for the set of R, G, and B channel mean values of each pixel in the rectangular outer frame region is as follows:
[0109]
[0110] Let the coordinates of any pixel within the rectangular bounding region be (x, y). Pxy represents the set of the R, G, and B channel mean values for all pixels within the rectangular bounding region; P xy_R P xy_G P xy_B The average value of each of the R, G, and B channels for any pixel (x, y) within the rectangular bounding area, obtained from 10 frames of images; Fn xy_R 、Fn xy_G 、Fn xy_B These are the R, G, and B channel values of the corresponding pixel (x, y) in the rectangular outer frame region of the nth frame image.
[0111] Using the above formula (1), the set of average values of the first pixel points (R, G, B channels) of the rectangular outer frame region, including all its pixels, can be calculated. For ease of expression, Pxy is also used. Each of the seven rods has its corresponding set of average values of the first pixel points (R, G, B channels) of the rectangular outer frame region before the test.
[0112] Step S603: During the test, the image information is used to obtain a preset number of pre-start images of the tester before entering the first test area and a post-race image after crossing the finish line.
[0113] In step S603, the testing process described here refers to the test taker entering the starting area (corresponding to) within the assessment area. Figure 9 Number 0) continues until reaching the destination (corresponding to Figure 9 The test process (number 20). Specifically, when the tester is in... Figure 9 The area designated as zone 0, but before entering zone 1, is considered the starting point. When the test subject reaches... Figure 9Area number 20 is the finish line. This step involves capturing the same number of frames (10 frames) as the standard image set, including the pre-start image set before entering the first test area and the post-finish image set after crossing the finish line, for pole reversal detection.
[0114] Step S604: Obtain the R, G, and B channel values of each pixel in the rectangular outer frame region corresponding to the standard image group in each frame of the pre-start image group, and calculate the average value of the R, G, and B channels of each pixel in the rectangular outer frame region before the start. Use the calculated average value of the R, G, and B channels of each pixel in the rectangular outer frame region before the start as the second set of average values of the R, G, and B channels of the rectangular outer frame region.
[0115] In this step, formula (1) is also used to calculate the set of R, G, and B channel mean values of all pixels in the rectangular frame corresponding to the standard image group in the pre-start image, denoted as Bxy, which includes B xy_R B xy_G B xy_B The average values of the R, G, and B channels for any pixel within the rectangular frame region of the corresponding pre-start image are obtained from 10 frames of pre-start images. Similarly, each of the seven poles has its own set of average values for the R, G, and B channels of the second pixel within its corresponding pre-start rectangular frame region.
[0116] Step S605: Obtain the R, G, and B channel values of each pixel in the rectangular outer frame region of the same frame in the post-race image group and corresponding to the standard image group, and calculate the average value of the R, G, and B channels of each pixel in the rectangular outer frame region after the race. Use the calculated average value of the R, G, and B channels of each pixel in the rectangular outer frame region after the race as the set of the average values of the R, G, and B channels of the third pixel in the rectangular outer frame region.
[0117] In this step, formula (1) is also used to calculate the set of average values of the R, G, and B channels of all pixels in the rectangular frame corresponding to the standard image group in the post-crossing image, denoted as Exy, which includes E xy_R E xy_G E xy_B The average values of the R, G, and B channels for any pixel within the rectangular frame region of the corresponding post-race image are obtained by analyzing 10 frames of post-race images. Similarly, each of the seven poles has its own set of average values for the R, G, and B channels of the third pixel within the rectangular frame region of the post-race image.
[0118] Step S606: Determine whether the corresponding pole has fallen down based on the R, G, and B channel mean values of the first pixel, the second pixel, and the third pixel within the same rectangular outer frame region.
[0119] In step S606, within the rectangular outer frame region representing the pole, the sum of the differences between the set of average values of the three channels R, G, and B of the second pixel point before the start and the set of average values of the three channels R, G, and B of the first pixel point before the test is calculated. The calculation formula (2) is as follows:
[0120]
[0121] Next, for the rectangular outer frame area, calculate the sum of the differences between the set of average values of the R, G, and B channels of the third pixel point after the test and the set of average values of the R, G, and B channels of the first pixel point before the test. The calculation formula (3) is as follows:
[0122]
[0123] A judgment parameter DIFF_K is set, where DIFF_K = DIFF_END / DIFF_BEGIN. By calculating the DIFF_K value of each rectangular frame area, it can be determined whether a corresponding pole has fallen. This is because if a pole falls, the R, G, and B channel values of the pixels in the rectangular frame area will change. Specifically, when DIFF_K ≤ 3, the corresponding pole is considered not to have fallen. If the DIFF_K value of all 7 poles is not higher than 3, the test time of the tester can be calculated. To further reduce the influence of changes in the external environment, when DIFF_K > 10, it is determined that the corresponding pole has fallen, and the tester's assessment is deemed invalid.
[0124] By following the steps above, the inversion of the lever can be automatically determined during the testing process, thus automating the entire testing process.
[0125] Figure 7 This is a schematic diagram of the serpentine running assessment device 70 according to an embodiment of the present invention. Figure 7 As shown, the device 70 includes a first acquisition module 71, a first calculation module 72, a second calculation module 73, a second acquisition module 74, and a detection module 75.
[0126] The first acquisition module 71 is used to acquire image information of the assessment area, including ground image information and several pole image information.
[0127] The first calculation module 72 is used to calculate the coordinate information of all poles in the assessment area based on the image information of several poles.
[0128] The second calculation module 73 is used to divide the ground image information into several test areas based on the coordinate information of all poles.
[0129] The second acquisition module 74 is used to acquire the tester's image information, which includes the tester's image information.
[0130] The detection module 75 is used to detect whether the tester has passed through several preset test areas in a preset order and completed all the pole-walking actions required by the assessment based on the tester's image information; if so, the tester's test time is calculated based on the timestamps of the tester entering the first test area and reaching the end point; if not, the tester's assessment is deemed invalid.
[0131] For specific limitations regarding the serpentine running assessment device 70, please refer to the limitations on the serpentine running assessment method mentioned above, which will not be repeated here. Each module in the aforementioned serpentine running assessment device can be implemented entirely or partially through software, hardware, or a combination thereof.
[0132] In the embodiments provided by this invention, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces, indirect coupling or communication connection between apparatuses or units, and may be electrical, mechanical, or other forms.
[0133] The above are merely embodiments of the present invention and do not limit the patent scope of the present invention. Any equivalent structural or procedural transformations made based on the content of the present invention's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of the present invention.
Claims
1. A method for assessing serpentine running, characterized in that, include: Acquire image information of the assessment area, including ground image information and several pole image information; Calculate the coordinate information of all poles in the assessment area based on the image information of several poles; Based on the coordinate information of all the poles, the ground image information is divided into several test areas; The image information obtained includes the tester's image information; Based on the tester's image information, it is detected whether the tester passes through several preset test areas in a preset order and completes all the pole-walking actions specified in the assessment. If yes, the test time is calculated based on the timestamps of the tester entering the first test area and reaching the finish line; if no, the tester's assessment is deemed invalid. The step of calculating the coordinate information of all poles in the assessment area based on the image information of the poles includes: Obtain the rectangular outer frame region corresponding to each of the rods based on the image information of each rod; Based on each of the rectangular outer frame regions, obtain the pole endpoint coordinates, pole width, and pole height corresponding to the rectangular outer frame region; The coordinates of the midpoint of the bottom edge of the corresponding rectangular outer frame region are calculated based on the coordinates of the pole endpoints, the pole width, and the pole height of each rectangular outer frame region, and the midpoint coordinates are used as the coordinate information of the corresponding pole body; The step of dividing the ground image information into several test areas based on the coordinate information of all the poles includes: Based on the coordinate information of all the poles, obtain the main judgment area and auxiliary judgment area of the ground image information; The main judgment area is divided into several test areas based on the coordinate information of all the rods; The steps for obtaining the main judgment region and auxiliary judgment region of the ground image information based on the coordinate information of all the poles include: Based on the position of each midpoint coordinate in the image information, the coordinates are divided into left midpoint coordinates and right midpoint coordinates; A first dividing line is obtained by drawing a straight line through the coordinates of all the left midpoints, and a second dividing line is obtained by drawing a straight line through the coordinates of all the right midpoints. The coordinates of the midpoints closest to and farthest from the starting line are set at the first dividing line. The coordinates of the closest and farthest midpoints are shifted to the left by a first preset distance and to the right by a second preset distance to obtain the coordinates of the four endpoints, wherein the second preset distance crosses the second dividing line. The four endpoint coordinates are connected sequentially to form the main judgment area, and the area outside the main judgment area is the auxiliary judgment area. The step of dividing the main judgment area into several test areas based on the coordinate information of all the rods includes: By drawing straight lines that intersect the first dividing line and the second dividing line through the coordinates of each midpoint, several parallel third dividing lines are obtained. The first dividing line, the second dividing line, and the third dividing line divide the main judgment area into several test areas.
2. The serpentine running assessment method according to claim 1, characterized in that, The step of detecting whether the tester has passed through several preset test areas in a preset order and completed all the pole-driving actions required by the assessment based on the tester's image information includes a method for determining the pole-driving action: If the test subject passes the first dividing line once in the forward / reverse direction and then passes the second dividing line twice consecutively; or passes the second dividing line once and then passes the first dividing line twice consecutively, it is considered to have completed one pole-driving cycle.
3. The serpentine running assessment method according to claim 1, characterized in that, The step of detecting whether the tester has passed through several preset test areas in a preset order and completed all the pole-driving actions required by the assessment based on the tester's image information includes a method for determining the pole-driving action: Except for the midpoint coordinates closest to and farthest from the starting line, the other midpoint coordinates are surrounded by four test areas, which are respectively designated as the first test area, the second test area, the third test area and the fourth test area along the preset forward direction. If the tester passes through the first test area, the second test area, the third test area and the fourth test area in sequence in the forward direction, or passes through the fourth test area, the third test area, the second test area and the first test area in sequence in the turning direction, it is determined that one pole-driving cycle has been completed. The coordinates of the midpoint furthest from the starting line are surrounded by two test areas and an auxiliary judgment area. The test areas are designated as the fifth and sixth test areas respectively along the preset forward direction. The tester passes through the fifth test area, the sixth test area and the auxiliary judgment area in sequence in the forward direction, and then passes through the auxiliary judgment area and the fifth test area in sequence in the turn-back direction. This is considered as completing one round of the pole.
4. The serpentine running assessment method according to claim 1, characterized in that, The serpentine running assessment method also includes: After the tester reaches the finish line but before the tester's test time is calculated, it is determined from the image information whether the pole has fallen. If yes, the test taker's assessment is deemed invalid; if no, the test taker's test time is calculated.
5. The serpentine running assessment method according to claim 4, characterized in that, The step of determining whether the pole has fallen based on the image information includes: Before testing, the image information of a preset number of frames is obtained as a standard image group; The values of the R, G, and B channels of each pixel in the same rectangular frame region in each frame of the standard image group are obtained, and the average value of the R, G, and B channels of each pixel in the rectangular frame region before the test is calculated. The calculated average value of the R, G, and B channels of each pixel in the rectangular frame region before the test is used as the first set of average values of the R, G, and B channels of the pixel in the rectangular frame region. During the test, the image information is used to obtain the preset number of pre-start images of the test subject before entering the first test area and the post-finish images after crossing the finish line. The values of the R, G, and B channels of each pixel in the rectangular frame region corresponding to the standard image group in each frame of the pre-start image group are obtained, and the average value of the R, G, and B channels of each pixel in the rectangular frame region before the start is calculated. The calculated average value of the R, G, and B channels of each pixel in the rectangular frame region before the start is used as the second set of average values of the R, G, and B channels of the pixel in the rectangular frame region. The values of the R, G, and B channels of each pixel in the rectangular outer frame region corresponding to the standard image group in each frame of the post-race image group are obtained, and the average value of the R, G, and B channels of each pixel in the rectangular outer frame region after the race is calculated. The calculated average value of the R, G, and B channels of each pixel in the rectangular outer frame region after the race is used as the set of the average values of the R, G, and B channels of the third pixel in the rectangular outer frame region. Based on the R, G, and B channel mean values of the first pixel, the second pixel, and the third pixel within the same rectangular outer frame region, determine whether the corresponding pole has fallen.
6. A serpentine running assessment device, said device being used to implement the steps of the serpentine running assessment method as described in any one of claims 1-5, characterized in that, include: The first acquisition module is used to acquire image information of the assessment area, including ground image information and several pole image information; The first calculation module is used to calculate the coordinate information of all poles in the assessment area based on the image information of several poles; The second calculation module is used to divide the ground image information into several test areas based on the coordinate information of all the poles; The second acquisition module is used to acquire the tester image information, which includes the tester, from the image information; The detection module is used to detect whether the tester has passed through several preset test areas in a preset order and completed all the pole-walking actions specified in the assessment based on the tester's image information. If yes, the test time is calculated based on the timestamps of the tester entering the first test area and reaching the finish line; otherwise, the tester's assessment is deemed invalid.
Citation Information
Patent Citations
Snakelike running assessment method and system, electronic equipment and storage medium
CN114067427A