CN116012937A - Traffic police gesture recognition method - Google Patents
Traffic police gesture recognition method Download PDFInfo
- Publication number
- CN116012937A CN116012937A CN202211608566.3A CN202211608566A CN116012937A CN 116012937 A CN116012937 A CN 116012937A CN 202211608566 A CN202211608566 A CN 202211608566A CN 116012937 A CN116012937 A CN 116012937A
- Authority
- CN
- China
- Prior art keywords
- hash
- image
- value
- hash algorithm
- traffic police
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000000034 method Methods 0.000 title claims abstract description 32
- 238000010586 diagram Methods 0.000 claims abstract description 63
- 238000012545 processing Methods 0.000 claims abstract description 42
- 238000004458 analytical method Methods 0.000 claims abstract description 16
- 238000012937 correction Methods 0.000 claims abstract description 5
- 239000011159 matrix material Substances 0.000 claims description 6
- 238000009825 accumulation Methods 0.000 claims description 3
- 238000010276 construction Methods 0.000 claims description 3
- 230000009467 reduction Effects 0.000 claims description 3
- 230000008569 process Effects 0.000 description 6
- 238000013461 design Methods 0.000 description 4
- 238000005516 engineering process Methods 0.000 description 4
- 238000004364 calculation method Methods 0.000 description 2
- 238000011161 development Methods 0.000 description 2
- 230000000694 effects Effects 0.000 description 2
- 206010039203 Road traffic accident Diseases 0.000 description 1
- 230000004075 alteration Effects 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000000903 blocking effect Effects 0.000 description 1
- 230000006835 compression Effects 0.000 description 1
- 238000007906 compression Methods 0.000 description 1
- 238000013527 convolutional neural network Methods 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 230000001419 dependent effect Effects 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 230000003993 interaction Effects 0.000 description 1
- 238000013507 mapping Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000035945 sensitivity Effects 0.000 description 1
Images
Landscapes
- Image Analysis (AREA)
Abstract
The invention discloses a traffic police gesture recognition method, which comprises the following steps: s1: acquiring a traffic police gesture image; s2: processing the traffic police gesture image by using a human body posture estimation algorithm to obtain four processing images; s3: respectively carrying out similarity analysis on the image recognition results of each processing diagram by using a hash correction algorithm based on an average value to obtain analysis results; s4: determining a target processing diagram for image recognition according to the analysis result; s5: and carrying out traffic police gesture recognition by utilizing the target processing diagram. The method and the device can extract the characteristics of the traffic police gesture so as to express the meaning of the gesture more accurately.
Description
Technical Field
The invention relates to the technical field of traffic, in particular to a traffic police gesture recognition method.
Background
Under the premise of increasing social development, the technology level is improved, and unmanned automobiles slowly enter the life of people, but the related problems are also caused. When the problems of traffic accidents, road blocking, traffic light faults and the like are encountered, traffic police can command traffic for the first time, and the unmanned automobile plays a vital role in identifying traffic police gestures. At the same time, various methods of image processing are endless, and thus it is a challenge to extract features of the traffic police gesture so as to express the meaning of the gesture more accurately.
Disclosure of Invention
The invention aims to provide a traffic police gesture recognition method which can extract characteristics of traffic police gestures so as to express meaning of the gestures more accurately.
The technical scheme for solving the technical problems is as follows:
the invention provides a traffic police gesture recognition method, which comprises the following steps:
s1: acquiring a traffic police gesture image;
s2: processing the traffic police gesture image by using a human body posture estimation algorithm to obtain four processing images;
s3: respectively carrying out similarity analysis on the image recognition results of each processing diagram by using a hash correction algorithm based on an average value to obtain analysis results;
s4: determining a target processing diagram for image recognition according to the analysis result;
s5: and carrying out traffic police gesture recognition by utilizing the target processing diagram.
Alternatively, the four process maps include a keypoint thermodynamic diagram, a keypoint thermodynamic diagram noise reduction map, an x-axis vector map, and a y-axis vector map.
Optionally, the step S3 includes:
s31: reducing the image size of each processing diagram to obtain a reduced image;
s32: simplifying the image color of the reduced image to obtain a gray image;
s33: calculating an average value of pixels of the gray scale image;
s34: comparing the gray scale of pixels in the gray scale image by using a difference hash algorithm to obtain a first comparison result;
s35: comparing the gray scale of the pixels in the gray scale image by using a mean value hash algorithm according to the average value to obtain a second comparison result;
s36: calculating a mean hash and a difference hash of the gray level image by utilizing a character string value hash construction function according to the first comparison result and the second comparison result respectively;
s37: obtaining a hash value based on an average value according to the average value hash and the difference value hash;
s38: comparing Hamming distances among the processing graphs according to the hash values of the processing graphs based on the average value;
s39: and obtaining a similarity analysis result according to the Hamming distance.
Optionally, the step S31 includes:
removing high frequency and details of each processing diagram, and reserving structural brightness of each processing diagram to obtain reserved images;
and reducing the reserved image to a size of 9x8 to obtain a reduced image.
Optionally, the step S33 includes:
the gray image is converted into a matrix by a traversal accumulation method, so that the average value of all pixels in the gray image is calculated.
Optionally, the step S34 includes:
each row of pixels in each gray level image are respectively compared independently, the pixel value larger than the latter pixel value is marked as 1, and the pixel value is marked as 0 to obtain a first comparison result; each gray scale image has 8 lines, 9 pixels and 8 differences in each line, so each gray scale image has 64 bits.
Optionally, the step S35 includes:
and marking the pixel in each gray level image larger than the average value as 1 and the pixel in each gray level image as 0 to obtain a second comparison result.
Optionally, the step S37 includes:
X 3 =α·X 1 +(1-α)·X 2 ,α∈(0,1)
wherein X is 3 Representing an average-based hash value, X 1 Representing the mean hash value, X 2 Representing the difference hash value, α represents the weight coefficient.
Alternatively, in the step S39, the hamming distance is obtained by:
the hamming distance value is the number of the different bits compared with how many different bits are between two words of the same length.
The invention has the following beneficial effects:
(1) In order to improve the accuracy of image recognition and more vividly express the shape of the traffic police gesture, the invention adopts the openpost human body posture estimation technology to process the image of the traffic police gesture, and four images are obtained after processing;
(2) In order to identify and classify the processed images, the method integrates the advantages of a mean value hash algorithm and a difference value hash algorithm, and adopts a correction hash based on an average value to compare, search, identify and classify the images so as to improve the gesture identification efficiency and accuracy of the traffic police.
Drawings
FIG. 1 is a flow chart of a method of gesture recognition for a traffic police according to the present invention;
fig. 2 is a schematic structural diagram of a human body posture estimation algorithm (openpost) network.
Detailed Description
The principles and features of the present invention are described below with reference to the drawings, the examples are illustrated for the purpose of illustrating the invention and are not to be construed as limiting the scope of the invention.
The invention provides a traffic police gesture recognition method, which is shown by referring to fig. 1, and comprises the following steps:
s1: acquiring a traffic police gesture image;
s2: processing the traffic police gesture image by using a human body posture estimation algorithm to obtain four processing images;
human body posture estimation is a simple point, namely, a technology for detecting and estimating human posture actions by recovering human body joint processes through digital expression, so that a computer can acquire the capability of recognizing various actions like a human. Human body posture estimation is not only a basic task of computer vision, but also a very valuable field to be studied based on the current and future development trend, such as automatic driving, man-machine interaction, medical treatment, movies, animation, VR technology, etc.
The principle of openpost is understood by first knowing the component association field (PAF), which is known as Part Affinity Fields. The function of the method is simple and can be understood as that the limbs of the human body are marked by finding key points of the limbs, then the limbs are divided, and finally the limbs are connected.
In the blue part of fig. 2, the first 10 layers of the vgg-19 model in convolutional neural networks are utilized as output and the original image is processed to generate a set of component-dependent fields. To produce a finer prediction, we combine the prediction of the previous stage with the features F of the original image in each subsequent stage. After iteration, a confidence loop s is performed: key points (joints of human body), such as ρ in fig. 2 t Partially shown.
Each 7x7 convolution kernel is replaced with three consecutive 3x3 convolution kernels. The purpose of this is to reduce considerable computation time while preserving the acceptance domain. The former has 2 x-1=97, and the latter has only 51. To preserve the underlying and higher layer features, the nonlinear layer number of the network is increased by a factor of two. At 2017, each stage refines the component association field and confidence map branches. However, the component association field improves the results of the confidence map, otherwise it does not. That is, by observing the output of the PAF channel, the position of the body part can be guessed. Finally, the bipartite graph matching problem is used to replace the multi-person detection problem, and a Hungary algorithm is used for obtaining more matches.
S3: respectively carrying out similarity analysis on the image recognition results of each processing diagram by using a hash correction algorithm based on an average value to obtain analysis results;
specifically, the Hash (Hash) may also be referred to as a Hash. Intuitively, the hash is to process a string of data x to obtain output data y, where the length of the data y is fixed, and the output is a hash value.
The hash function is characterized in that:
1. easy compression: the length of the Hash value generated by the Hash function is relatively small for any size data input, and in practical application, the length of the Hash value generated by the Hash function is fixed.
2. Easy calculation: for any given data, the Hash value is very easy to calculate, and the time for the Hash algorithm to calculate by using the Hash function is shorter than other algorithms.
3. Unidirectional: for any output sum hash value, we cannot derive the original input value from it. This feature also lays the foundation for the security of the hash function.
4. Crash resistance: the Hash function is most ideal without collision, but is not done in the design of the actual algorithm.
5. High sensitivity: when the output is changed, then at least half of the number of corresponding input bits will be changed.
In short, some complex data is mapped into a manner that is easier to search through a certain function mapping relation. Each data is mapped to a unique address where it is stored and fetched when it is stored. The hash algorithm is just like a dictionary, when the words need to be checked, the page numbers are found through the catalogue, and then the needed contents can be found after the corresponding page numbers are reached
The search speed of the hash algorithm is irrelevant to the data quantity, and the hash algorithm only needs to be read once under the condition that no collision or overflow occurs. Meanwhile, the confidentiality of the algorithm is particularly good, and the algorithm cannot be searched to obtain data if a hash function is not known in advance. (Note: it is important to design a good hash function that should hash every key as much as possible into every location.) the first problem faced is how to design a hash function that is easy to compute and evenly distributes all keys.
The image hash similarity comparison is also called an image sensing algorithm, and the whole thought is to compress the image to a uniform size, calculate a gray value and obtain an image matrix; and then converting the traversal matrix into character strings to obtain hash values, and finally calculating the Hamming distance. There are three algorithms for hash similarity comparison: a difference hash algorithm, a mean hash algorithm, and a perceptual hash algorithm. A difference hash algorithm and a mean hash algorithm are adopted in the text; on the basis, a modified hash algorithm based on an average value is proposed and adopted as a judging basis for image recognition and classification.
Therefore, optionally, the step S3 provided by the present invention includes:
s31: reducing the image size of each processing diagram to obtain a reduced image;
removing high frequency and details of each processing diagram, and reserving structural brightness of each processing diagram to obtain reserved images;
and reducing the reserved image to a size of 9x8 to obtain a reduced image.
The mean hash algorithm is reduced to 8x8 in size, and this step is to ignore the effect of image size and reduce the amount of computation.
S32: simplifying the image color of the reduced image to obtain a gray image; this step is to ignore the effect of slight chromatic aberration and reduce the amount of calculation.
S33: calculating an average value of pixels of the gray scale image;
the gray image is converted into a matrix by a traversal accumulation method, so that the average value of all pixels in the gray image is calculated.
S34: comparing the gray scale of pixels in the gray scale image by using a difference hash algorithm to obtain a first comparison result;
each row of pixels in each gray level image are respectively compared independently, the pixel value larger than the latter pixel value is marked as 1, and the pixel value is marked as 0 to obtain a first comparison result; each gray scale image has 8 lines, 9 pixels and 8 differences in each line, so each gray scale image has 64 bits.
S35: comparing the gray scale of the pixels in the gray scale image by using a mean value hash algorithm according to the average value to obtain a second comparison result;
and marking the pixel in each gray level image larger than the average value as 1 and the pixel in each gray level image as 0 to obtain a second comparison result.
S36: calculating a mean hash and a difference hash of the gray level image by utilizing a character string value hash construction function according to the first comparison result and the second comparison result respectively;
the invention uses a string value hash method, in many cases, a string may be a keyword. Thus creating a problem of how to design a hash function to solve the keyword as a string. The following is a hash function that constructs the first 10 characters of the string:
Int Hash_char(char*X)
{
int I,sum
i=0;
while(i 10&&X[i])
Sum+=X[i++];
sum% = N; the number of record is/N
}
The hash address is the sum of ASCII (American Standard Code for Information Interchange ) values of the first 10 characters of the string. As long as n is small enough, the hash addresses will be evenly distributed over the 0, n interval, so this function can be used. For the case where n is large, the following function may be used:
intELFhash(char*key)
{
Unsigned long h=0,g;
whie(*key)
{
h=(h<<4)+*key;
key++;
g=h&0xF0000000L;
if(g)h^=g>>24;
h&=~g;
}
h=h%N
return(h);
}
the absolute length of the string is used as input and the decimal values of the characters are combined in a manner that is effective for both long and short strings. Thus, uneven distribution of the positions is not caused.
S37: obtaining a hash value based on an average value according to the average value hash and the difference value hash;
X 3 =α·X 1 +(1-α)·X 2 ,α∈(0,1)
wherein X is 3 Representing an average-based hash value, X 1 Representing the mean hash value, X 2 Representing the difference hash value, α represents the weight coefficient. Inventive α=0.5.
S38: comparing Hamming distances among the processing graphs according to the hash values of the processing graphs based on the average value;
s39: and obtaining a similarity analysis result according to the Hamming distance.
Here, the hamming distance is obtained by:
the hamming distance value is the number of the different bits compared with how many different bits are between two words of the same length.
For example: the hamming distance between 17930339 and 17930338 is 1, and the hamming distance between 17930339 and 16920239 is 3.
The smaller the hamming distance is, the higher the similarity between images is. Because the openpost processing result is four images, in order to find out which processing result can make the hash algorithm search similarity highest, the invention respectively searches and identifies the four images to obtain the similarity of the mean hash algorithm and the difference hash algorithm and the average value of the similarity of the two hash algorithms. And taking the 25 Hamming distance as a limit, judging that the image and the template image are the same gesture when the Hamming distance is lower than the 25 Hamming value, and otherwise, judging that the image and the template image cannot be recognized.
The average value hash algorithm similarity, the difference hash algorithm similarity and the hash algorithm similarity average value are Hamming distances, and the character strings consisting of 0 and 1 are hash values.
Specifically:
searching similarity by key point thermodynamic diagram
1. Parking
Hash value of mean hash algorithm of comparison graph:
0000000000011100011111110011110000110001001000010000000000000000
hash value of the mean hash algorithm of the template map:
0001000001111100111111111111111100100101001000010000000000000000
similarity of mean hash algorithm: 10
Hash value of difference hash algorithm of comparison chart:
0000011100000111000101111000111000010100001001001010110000100011
hash value of difference hash algorithm of template diagram:
0000011100010111000101111000111000110100001101001010010000100011
similarity of difference hash algorithm: 4
Average value-based hash algorithm similarity: 7.0
This gesture is: parking
2. Straight going
Hash values of the contrast map mean hash algorithm:
0000000001101110111011110111100100001011001010110000000000000000
hash value of template map mean hash algorithm:
1001100011101111111111111110101111001111000000110000000000000000
similarity of mean hash algorithm: 14
Hash value of contrast map difference hash algorithm:
1010011100011110001011000000110100110000000100001001000100101011
hash value of template diagram difference hash algorithm:
1001011000101010001011110001100100100000001010001010100000001110
difference hash algorithm similarity: 21
Average value-based hash algorithm similarity: 17.5
This gesture is: straight going
3. Left turn
Hash values of the contrast map mean hash algorithm:
0000000011101110111101110111111100010001000100000001000000000000
hash value of template map mean hash algorithm:
0111110011100111111111111111111111100111000001110000000000000000
similarity of mean hash algorithm: 20
Hash value of contrast map difference hash algorithm:
0001110100001111000011101001010001110100101101001110110000010011
hash value of template diagram difference hash algorithm:
0001110100010011000101110001011000110010001001101011010000101000
difference hash algorithm similarity: 22
Average value-based hash algorithm similarity: 21.0
This gesture is: left turn
4. To turn left
Hash values of the contrast map mean hash algorithm:
1011110011101110111111111111111101100011001010010000000000000000
hash value of template map mean hash algorithm:
0000000001101110111111111111111100100001001000000000000000000000
similarity of mean hash algorithm: 10
Hash value of contrast map difference hash algorithm:
1000111100010111000101101001110100010000000111001010010000110011
hash value of template diagram difference hash algorithm:
1000111100110111110101010001110100100010001001001010010001110101
difference hash algorithm similarity: 15
Average value-based hash algorithm similarity: 12.5
This gesture is: to turn left
5. Right turn
Hash values of the contrast map mean hash algorithm:
0011100011111110111111111111111111100101000000010000000000000000
hash value of template map mean hash algorithm:
0011100011111110111111111111111111100101000000010000000000000000
similarity of mean hash algorithm: 0
Hash value of contrast map difference hash algorithm:
0001011100110111000101001000111000110000101101001101010000010011
hash value of template diagram difference hash algorithm:
0001011100001111100101101010111000100100101101001001010000011011
difference hash algorithm similarity: 10
Average value-based hash algorithm similarity: 5.0
This gesture is: right turn
6. Lane changing
Hash values of the contrast map mean hash algorithm:
0000000001101100111111111111111100000001000100010001000000000000
hash value of template map mean hash algorithm:
0111000011111111111111111111111111100111001001010000000000000000
similarity of mean hash algorithm: 16
Hash value of contrast map difference hash algorithm:
0001101100010111100011101001110010110110101001101110100100100011
hash value of template diagram difference hash algorithm:
0011101100101011000101001001010010100100101101101010010000100001
difference hash algorithm similarity: 18
Average value-based hash algorithm similarity: 17.0
This gesture is: lane changing
7. Deceleration of
Hash values of the contrast map mean hash algorithm:
0000000011110100111011111111111110001000000110000000000000000000
hash value of template map mean hash algorithm:
0111100011110111111111111111111111100111100001000000000000000000
similarity of mean hash algorithm: 17
Hash value of contrast map difference hash algorithm:
0001110100110011001101100001011011110010110101100101010000110011
hash value of template diagram difference hash algorithm:
0001111100010111000001100101011010010000110101101101010000010011
difference hash algorithm similarity: 11
Average value-based hash algorithm similarity: 14.0
This gesture is: deceleration of
8. Side parking
Hash values of the contrast map mean hash algorithm:
0010000001111100111111111111111110100111100010110000000000000000
hash value of template map mean hash algorithm:
1111000011101111111111111111111111101111101011110000000000000000
similarity of mean hash algorithm: 11
Hash value of contrast map difference hash algorithm:
0111101100001110000011101000110010001100110101001101010000110011
hash value of template diagram difference hash algorithm:
0010110100010111000111101000010010100100101101011110110100110010
difference hash algorithm similarity: 19
Average value-based hash algorithm similarity: 15.0
This gesture is: side parking
Noise reduction search similarity for key point thermodynamic diagram
1. Parking
Hash values of the contrast map mean hash algorithm:
0000000000011000000110000011100000111000000110000001000000010000
hash value of template map mean hash algorithm:
0001000001111100111111111111111100100101001000010000000000000000
similarity of mean hash algorithm: 25
Hash value of contrast map difference hash algorithm:
0000011100001111000011000000110000010100001011001010000000001001
hash value of template diagram difference hash algorithm:
0000011100010111000101111000111000110100001101001010010000100011
difference hash algorithm similarity: 15
Average value-based hash algorithm similarity: 20.0
This gesture is: parking
2. Straight going
Hash values of the contrast map mean hash algorithm:
0000000000110000001111100011000000110000001100000000000000000000
hash value of template map mean hash algorithm:
1001100011101111111111111110101111001111000000110000000000000000
similarity of mean hash algorithm: 31
Hash value of contrast map difference hash algorithm:
1001011000011110001110110010100001000100001010000110100101011001
hash value of template diagram difference hash algorithm:
1001011000101010001011110001100100100000001010001010100000001110
difference hash algorithm similarity: 19
Average value-based hash algorithm similarity: 25.0
Cannot be identified
3. Left turn
Hash values of the contrast map mean hash algorithm:
0000000000011000001110000001100000000000000100000001000000000000
hash value of template map mean hash algorithm:
0111110011100111111111111111111111100111000001110000000000000000
similarity of mean hash algorithm: 35
Hash value of contrast map difference hash algorithm:
0001001000001111000101010001010000010100100011001010110000001001
hash value of template diagram difference hash algorithm:
0001110100010011000101110001011000110010001001101011010000101000
difference hash algorithm similarity: 20
Average value-based hash algorithm similarity: 27.5
Cannot be identified
4. To turn left
Hash values of the contrast map mean hash algorithm:
0000000000011000001111000010100000100000000000000000000000000000
hash value of template map mean hash algorithm:
0000000001101110111111111111111100100001001000000000000000000000
similarity of mean hash algorithm: 17
Hash value of contrast map difference hash algorithm:
0000100100001110000001100010110100011010000111001010100000101001
hash value of template diagram difference hash algorithm:
1000111100110111110101010001110100100010001001001010010001110101
difference hash algorithm similarity: 26
Average value-based hash algorithm similarity: 21.5
This gesture is: to turn left
5. Right turn
Hash values of the contrast map mean hash algorithm:
0000000000011000000111000011100000111000000110000000000000000000
hash value of template map mean hash algorithm:
0011100011111110111111111111111111100101000000010000000000000000
similarity of mean hash algorithm: 27
Hash value of contrast map difference hash algorithm:
0001011000001110100001101000111010010000001011001001000000101011
hash value of template diagram difference hash algorithm:
0001011100001111100101101010111000100100101101001001010000011011
difference hash algorithm similarity: 14
Average value-based hash algorithm similarity: 20.5
This gesture is: right turn
6. Lane changing
Hash values of the contrast map mean hash algorithm:
0000000000011000001110000001100000011000000100000001000000000000
hash value of template map mean hash algorithm:
0111000011111111111111111111111111100111001001010000000000000000
similarity of mean hash algorithm: 33
Hash value of contrast map difference hash algorithm:
0001000100001010000111001001010000010100001011001010100000101001
hash value of template diagram difference hash algorithm:
0011101100101011000101001001010010100100101101101010010000100001
difference hash algorithm similarity: 16
Average value-based hash algorithm similarity: 24.5
This gesture is: lane changing
7. Deceleration of
Hash values of the contrast map mean hash algorithm:
0000000000011000001111000001110000011100000110000000000000000000
hash value of template map mean hash algorithm:
0111100011110111111111111111111111100111100001000000000000000000
similarity of mean hash algorithm: 31
Hash value of contrast map difference hash algorithm:
0001010000001110000101100101011010010010110001100101010000001010
hash value of template diagram difference hash algorithm:
0001111100010111000001100101011010010000110101101101010000010011
difference hash algorithm similarity: 13
Average value-based hash algorithm similarity: 22.0
This gesture is: deceleration of
8. Side parking
Hash values of the contrast map mean hash algorithm:
0000000000010000000100000001110000010000000100000001000000010000
hash value of template map mean hash algorithm:
1111000011101111111111111111111111101111101011110000000000000000
similarity of mean hash algorithm: 41
Hash value of contrast map difference hash algorithm:
0101001000101110000111001000010000101100100011001010100001110001
hash value of template diagram difference hash algorithm:
0010110100010111000111101000010010100100101101011110110100110010
difference hash algorithm similarity: 24
Average value-based hash algorithm similarity: 32.5
Cannot be identified
Vectormap search similarity on x-axis
1. Parking
Hash values of the contrast map mean hash algorithm:
0000000000011000000110000011100000111000000100000001000000010000
hash value of template map mean hash algorithm:
0001000001111100111111111111111100100101001000010000000000000000
similarity of mean hash algorithm: 24
Hash value of contrast map difference hash algorithm:
0000000000001100000011000000110000010000000010000000100000011000
hash value of template diagram difference hash algorithm:
0000011100010111000101111000111000110100001101001010010000100011
difference hash algorithm similarity: 28
Hash algorithm similarity average 26.0
Cannot be identified
2. Straight going
Hash values of the contrast map mean hash algorithm:
0000000000010000001110000011000000000000000000000000000000000000
hash value of template map mean hash algorithm:
1001100011101111111111111110101111001111000000110000000000000000
similarity of mean hash algorithm: 30
Hash value of contrast map difference hash algorithm:
0000000000011000000110000001100000010000000100000001000000000000
hash value of template diagram difference hash algorithm:
1001011000101010001011110001100100100000001010001010100000001110
difference hash algorithm similarity: 25
Hash algorithm similarity average value 27.5
Cannot be identified
3. Left turn
Hash values of the contrast map mean hash algorithm:
0000000000011000001110000001000000000000000000000000000000000000
hash value of template map mean hash algorithm:
0111110011100111111111111111111111100111000001110000000000000000
similarity of mean hash algorithm: 34
Hash value of contrast map difference hash algorithm:
0000000000101000000011000000110000001100000010000000100000000000
hash value of template diagram difference hash algorithm:
0001110100010011000101110001011000110010001001101011010000101000
difference hash algorithm similarity: 32
Hash algorithm similarity average value 33.0
Cannot be identified
4. To turn left
Hash values of the contrast map mean hash algorithm:
0000000000010000001110000011000000100000000000000000000000000000
hash value of template map mean hash algorithm:
0000000001101110111111111111111100100001001000000000000000000000
similarity of mean hash algorithm: 19
Hash value of contrast map difference hash algorithm:
1000000000001000000011000000100100011000000010000000100000001000
hash value of template diagram difference hash algorithm:
1000111100110111110101010001110100100010001001001010010001110101
difference hash algorithm similarity: 34
Hash algorithm similarity average 26.5
Cannot be identified
5. Right turn
Hash values of the contrast map mean hash algorithm:
0000000000011000000111000001100000001000000100000000000000000000
hash value of template map mean hash algorithm:
0011100011111110111111111111111111100101000000010000000000000000
similarity of mean hash algorithm: 27
Hash value of contrast map difference hash algorithm:
0000000000001000000001100000100000011000000010000000100000000000
hash value of template diagram difference hash algorithm:
0001011100001111100101101010111000100100101101001001010000011011
difference hash algorithm similarity: 30
Hash algorithm similarity average 28.5
Cannot be identified
6. Lane changing
Hash values of the contrast map mean hash algorithm:
0000000000010000001110000001000000011000000100000000000000000000
hash value of template map mean hash algorithm:
0111000011111111111111111111111111100111001001010000000000000000
similarity of mean hash algorithm: 34
Hash value of contrast map difference hash algorithm:
0000000000001000000011000000010000010100000010000000100000000000
hash value of template diagram difference hash algorithm:
0011101100101011000101001001010010100100101101101010010000100001
difference hash algorithm similarity: 27
Hash algorithm similarity average value 30.5
Cannot be identified
7. Deceleration of
Hash values of the contrast map mean hash algorithm:
0000000000001000001110000000100000011000000000000000000000000000
hash value of template map mean hash algorithm:
0111100011110111111111111111111111100111100001000000000000000000
similarity of mean hash algorithm: 34
Hash value of contrast map difference hash algorithm:
0000000000001100000011000000100000000100000010000000100000000000
hash value of template diagram difference hash algorithm:
0001111100010111000001100101011010010000110101101101010000010011
difference hash algorithm similarity: 33
Hash algorithm similarity average value 33.5
Cannot be identified
8. Side parking
Hash values of the contrast map mean hash algorithm:
0000000000010000000100000001010000010000000100000001000000000000
hash value of template map mean hash algorithm:
1111000011101111111111111111111111101111101011110000000000000000
similarity of mean hash algorithm: 41
Hash value of contrast map difference hash algorithm:
1000000000001000000110000000010000001000000010000001000000000000
hash value of template diagram difference hash algorithm:
0010110100010111000111101000010010100100101101011110110100110010
difference hash algorithm similarity: 33
Hash algorithm similarity average value 37.0
Cannot be identified
Vectormap search similarity on y-axis
1. Parking
Hash values of the contrast map mean hash algorithm:
0000000000010000000110000011100000111000000100000001000000010000
hash value of template map mean hash algorithm:
0001000001111100111111111111111100100101001000010000000000000000
similarity of mean hash algorithm: 25
Hash value of contrast map difference hash algorithm:
1000000000000100000011000000110000011000000010000000100000001000
hash value of template diagram difference hash algorithm:
0000011100010111000101111000111000110100001101001010010000100011
difference hash algorithm similarity: 28
Average value-based hash algorithm similarity: 26.5
Cannot be identified
2. Straight going
Hash values of the contrast map mean hash algorithm:
0000000000010000001100000011000000110000001100000011000000000000
hash value of template map mean hash algorithm:
1001100011101111111111111110101111001111000000110000000000000000
similarity of mean hash algorithm: 37
Hash value of contrast map difference hash algorithm:
0000000000011000000110010001100000001000000100000001000010000000
hash value of template diagram difference hash algorithm:
1001011000101010001011110001100100100000001010001010100000001110
difference hash algorithm similarity: 25
Average value-based hash algorithm similarity: 31.0
Cannot be identified
3. Left turn
Hash values of the contrast map mean hash algorithm:
0000000000011000000110000001100000011000000110000001000000000000
hash value of template map mean hash algorithm:
0111110011100111111111111111111111100111000001110000000000000000
similarity of mean hash algorithm: 39
Hash value of contrast map difference hash algorithm:
0000000000001000000011000010010000010100000010000010100000000000
hash value of template diagram difference hash algorithm:
0001110100010011000101110001011000110010001001101011010000101000
difference hash algorithm similarity: 28
Average value-based hash algorithm similarity: 33.5
Cannot be identified
4. To turn left
Hash values of the contrast map mean hash algorithm:
0000000000010000001110000011000000100000000100000001000000000000
hash value of template map mean hash algorithm:
0000000001101110111111111111111100100001001000000000000000000000
similarity of mean hash algorithm: 21
Hash value of contrast map difference hash algorithm:
1000000000001000010001000000100100011000000110000001100000001000
hash value of template diagram difference hash algorithm:
1000111100110111110101010001110100100010001001001010010001110101
difference hash algorithm similarity: 34
Average value-based hash algorithm similarity: 27.5
Cannot be identified
5. Right turn
Hash values of the contrast map mean hash algorithm:
0000000000011000000011000001100000011000000110000001100000000000
hash value of template map mean hash algorithm:
0011100011111110111111111111111111100101000000010000000000000000
similarity of mean hash algorithm: 32
Hash value of contrast map difference hash algorithm:
0000000000001000000011100001100000010100000010000000100000001000
hash value of template diagram difference hash algorithm:
0001011100001111100101101010111000100100101101001001010000011011
difference hash algorithm similarity: 29
Average value-based hash algorithm similarity: 30.5
Cannot be identified
6. Lane changing
Hash values of the contrast map mean hash algorithm:
0000000000010000000010000001000000011000000100000001000000000000
hash value of template map mean hash algorithm:
0111000011111111111111111111111111100111001001010000000000000000
similarity of mean hash algorithm: 37
Hash value of contrast map difference hash algorithm:
1000000000001000000111000000010000010100000010000000100000000000
hash value of template diagram difference hash algorithm:
0011101100101011000101001001010010100100101101101010010000100001
difference hash algorithm similarity: 27
Average value-based hash algorithm similarity: 32.0
Cannot be identified
7. Deceleration of
Hash values of the contrast map mean hash algorithm:
0000000000001000000110000001110000011000000110000001100000000000
hash value of template map mean hash algorithm:
0111100011110111111111111111111111100111100001000000000000000000
similarity of mean hash algorithm: 37
Hash value of contrast map difference hash algorithm:
0000000000001100000001000000110000000100000011000000100000000100
hash value of template diagram difference hash algorithm:
0001111100010111000001100101011010010000110101101101010000010011
difference hash algorithm similarity: 31
Hash algorithm similarity average 34.0
Cannot be identified
8. Side parking
Hash values of the contrast map mean hash algorithm:
0000000000010000000100000001000000010000000100000001000000000000
hash value of template map mean hash algorithm:
1111000011101111111111111111111111101111101011110000000000000000
similarity of mean hash algorithm: 42
Hash value of contrast map difference hash algorithm:
0000000000001000000010000001010000001000000010000001000010000000
hash value of template diagram difference hash algorithm:
0010110100010111000111101000010010100100101101011110110100110010
difference hash algorithm similarity: 35
Average value-based hash algorithm similarity: 38.5
Cannot be identified
All results are arranged into a table
TABLE 1 similarity analysis results
Through the conclusion shown in the table, the searching and the identification of eight traffic police gestures can be completely completed by adopting the key point thermodynamic diagram.
The key point thermodynamic diagram is adopted to remove noise, and besides the gesture of stopping by the side, the other seven gestures can also be used for completing search and identification.
But neither the vectormap on the x-axis nor the vectormap on the y-axis can complete the search recognition. In this case, the present invention has been further studied.
The images of vectormap on the x-axis and vectormap on the y-axis may be too abstract of the feature handling of the gesture, resulting in gaps between images at the time of search. It is preferable to process the image into a keypoint thermodynamic diagram through openpost to achieve higher search recognition accuracy.
2. Some gestures are similar, some gestures are too complex, and the hash algorithm search recognition accuracy is possibly low, but the influence of the problem of openpost is greatly reduced.
When openpost processes some gestures, such as joint overlapping, a certain gap may be caused, and the problem is a defect of openpost processing images, which cannot be solved by improving algorithms and other methods.
4. The different heights, backgrounds and the like of traffic polices can influence the searching and identifying precision of the hash algorithm, so that the influence caused by the problem of graying and the like is solved to a certain extent in the hash algorithm.
5. The difference of the templates of the search recognition may result in the difference of the search recognition of four processing results, but the problem cannot be effectively solved later due to the fact that the templates are fewer.
6. Hash collisions are generated, but since the data after the image is converted into a matrix is small, the probability of generating hash collisions is not high.
S4: determining a target processing diagram for image recognition according to the analysis result;
s5: and carrying out traffic police gesture recognition by utilizing the target processing diagram.
The foregoing description of the preferred embodiments of the invention is not intended to limit the invention to the precise form disclosed, and any such modifications, equivalents, and alternatives falling within the spirit and scope of the invention are intended to be included within the scope of the invention.
Claims (9)
1. The traffic police gesture recognition method is characterized by comprising the following steps of:
s1: acquiring a traffic police gesture image;
s2: processing the traffic police gesture image by using a human body posture estimation algorithm to obtain four processing images;
s3: respectively carrying out similarity analysis on the image recognition results of each processing diagram by using a hash correction algorithm based on an average value to obtain analysis results;
s4: determining a target processing diagram for image recognition according to the analysis result;
s5: and carrying out traffic police gesture recognition by utilizing the target processing diagram.
2. The traffic police gesture recognition method of claim 1, wherein the four processing graphs comprise a keypoint thermodynamic diagram, a keypoint thermodynamic diagram noise reduction graph, an x-axis vector graph, and a y-axis vector graph.
3. The traffic police gesture recognition method according to claim 1, wherein the step S3 comprises:
s31: reducing the image size of each processing diagram to obtain a reduced image;
s32: simplifying the image color of the reduced image to obtain a gray image;
s33: calculating an average value of pixels of the gray scale image;
s34: comparing the gray scale of pixels in the gray scale image by using a difference hash algorithm to obtain a first comparison result;
s35: comparing the gray scale of the pixels in the gray scale image by using a mean value hash algorithm according to the average value to obtain a second comparison result;
s36: calculating a mean hash and a difference hash of the gray level image by utilizing a character string value hash construction function according to the first comparison result and the second comparison result respectively;
s37: obtaining a hash value based on an average value according to the average value hash and the difference value hash;
s38: comparing Hamming distances among the processing graphs according to the hash values of the processing graphs based on the average value;
s39: and obtaining a similarity analysis result according to the Hamming distance.
4. A traffic police gesture recognition method according to claim 3, wherein step S31 comprises:
removing high frequency and details of each processing diagram, and reserving structural brightness of each processing diagram to obtain reserved images;
and reducing the reserved image to a size of 9x8 to obtain a reduced image.
5. A traffic police gesture recognition method according to claim 3, wherein step S33 comprises:
the gray image is converted into a matrix by a traversal accumulation method, so that the average value of all pixels in the gray image is calculated.
6. A traffic police gesture recognition method according to claim 3, wherein step S34 comprises:
each row of pixels in each gray level image are respectively compared independently, the pixel value larger than the latter pixel value is marked as 1, and the pixel value is marked as 0 to obtain a first comparison result; each gray scale image has 8 lines, 9 pixels and 8 differences in each line, so each gray scale image has 64 bits.
7. A traffic police gesture recognition method according to claim 3, wherein step S35 comprises:
and marking the pixel in each gray level image larger than the average value as 1 and the pixel in each gray level image as 0 to obtain a second comparison result.
8. A traffic police gesture recognition method according to claim 3, wherein step S37 comprises:
X 3 =α·X 1 +(1-α)·X 2 ,α∈(0,1)
wherein X is 3 Representing an average-based hash value, X 1 Representing the mean hash value, X 2 Representing the difference hash value, α represents the weight coefficient.
9. The traffic police gesture recognition method according to any one of claims 3 to 8, wherein in step S39, the hamming distance is obtained by:
the hamming distance value is the number of the different bits compared with how many different bits are between two words of the same length.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211608566.3A CN116012937B (en) | 2022-12-14 | 2022-12-14 | Traffic police gesture recognition method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211608566.3A CN116012937B (en) | 2022-12-14 | 2022-12-14 | Traffic police gesture recognition method |
Publications (2)
Publication Number | Publication Date |
---|---|
CN116012937A true CN116012937A (en) | 2023-04-25 |
CN116012937B CN116012937B (en) | 2024-06-18 |
Family
ID=86029000
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211608566.3A Active CN116012937B (en) | 2022-12-14 | 2022-12-14 | Traffic police gesture recognition method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN116012937B (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116701553A (en) * | 2023-05-12 | 2023-09-05 | 中国长江电力股份有限公司 | Similar rainfall runoff process searching method based on rainfall time distribution histogram |
Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106991386A (en) * | 2017-02-27 | 2017-07-28 | 杭州电子科技大学 | A kind of gesture identification method based on depth residual error network |
WO2018120459A1 (en) * | 2016-12-28 | 2018-07-05 | 平安科技(深圳)有限公司 | Method, apparatus and device for verifying authenticity of image, and storage medium and service end |
CN108629312A (en) * | 2018-05-04 | 2018-10-09 | 兰州理工大学 | A kind of dynamic hand tracking method and system |
CN108897775A (en) * | 2018-06-01 | 2018-11-27 | 昆明理工大学 | A kind of rapid image identifying system and method based on perceptual hash |
CN110096973A (en) * | 2019-04-16 | 2019-08-06 | 东南大学 | A kind of traffic police's gesture identification method separating convolutional network based on ORB algorithm and depth level |
CN110599486A (en) * | 2019-09-20 | 2019-12-20 | 福州大学 | Method and system for detecting video plagiarism |
CN111695507A (en) * | 2020-06-12 | 2020-09-22 | 桂林电子科技大学 | Static gesture recognition method based on improved VGGNet network and PCA |
US20210097644A1 (en) * | 2019-09-30 | 2021-04-01 | Microsoft Technology Licensing, Llc | Gaze adjustment and enhancement for eye images |
WO2022110564A1 (en) * | 2020-11-25 | 2022-06-02 | 苏州科技大学 | Smart home multi-modal human-machine natural interaction system and method thereof |
CN114973425A (en) * | 2022-08-01 | 2022-08-30 | 乐山师范学院 | Traffic police gesture recognition method and device |
CN115188080A (en) * | 2022-07-26 | 2022-10-14 | 浙江理工大学 | Traffic police gesture recognition method and system based on skeleton recognition and gated loop network |
-
2022
- 2022-12-14 CN CN202211608566.3A patent/CN116012937B/en active Active
Patent Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2018120459A1 (en) * | 2016-12-28 | 2018-07-05 | 平安科技(深圳)有限公司 | Method, apparatus and device for verifying authenticity of image, and storage medium and service end |
CN106991386A (en) * | 2017-02-27 | 2017-07-28 | 杭州电子科技大学 | A kind of gesture identification method based on depth residual error network |
CN108629312A (en) * | 2018-05-04 | 2018-10-09 | 兰州理工大学 | A kind of dynamic hand tracking method and system |
CN108897775A (en) * | 2018-06-01 | 2018-11-27 | 昆明理工大学 | A kind of rapid image identifying system and method based on perceptual hash |
CN110096973A (en) * | 2019-04-16 | 2019-08-06 | 东南大学 | A kind of traffic police's gesture identification method separating convolutional network based on ORB algorithm and depth level |
CN110599486A (en) * | 2019-09-20 | 2019-12-20 | 福州大学 | Method and system for detecting video plagiarism |
US20210097644A1 (en) * | 2019-09-30 | 2021-04-01 | Microsoft Technology Licensing, Llc | Gaze adjustment and enhancement for eye images |
CN111695507A (en) * | 2020-06-12 | 2020-09-22 | 桂林电子科技大学 | Static gesture recognition method based on improved VGGNet network and PCA |
WO2022110564A1 (en) * | 2020-11-25 | 2022-06-02 | 苏州科技大学 | Smart home multi-modal human-machine natural interaction system and method thereof |
CN115188080A (en) * | 2022-07-26 | 2022-10-14 | 浙江理工大学 | Traffic police gesture recognition method and system based on skeleton recognition and gated loop network |
CN114973425A (en) * | 2022-08-01 | 2022-08-30 | 乐山师范学院 | Traffic police gesture recognition method and device |
Non-Patent Citations (3)
Title |
---|
吴巧;霍亮生;: "交警手势的图像处理与识别", 北京工商大学学报(自然科学版), no. 01, 15 January 2009 (2009-01-15) * |
王前: "基于视频感知哈希的动态手势跟踪方法研究", 中国优秀硕士学位论文全文数据库电子期刊信息科技辑, 15 August 2018 (2018-08-15) * |
罗昆;王子华;黄祖邦;: "智能交警手势识别系统的设计与实现", 电脑知识与技术, no. 09, 25 March 2019 (2019-03-25) * |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116701553A (en) * | 2023-05-12 | 2023-09-05 | 中国长江电力股份有限公司 | Similar rainfall runoff process searching method based on rainfall time distribution histogram |
CN116701553B (en) * | 2023-05-12 | 2024-01-02 | 中国长江电力股份有限公司 | Similar rainfall runoff process searching method based on rainfall time distribution histogram |
Also Published As
Publication number | Publication date |
---|---|
CN116012937B (en) | 2024-06-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Xie et al. | Multicolumn networks for face recognition | |
Zheng et al. | Detection of people with camouflage pattern via dense deconvolution network | |
CN108664996B (en) | Ancient character recognition method and system based on deep learning | |
US10445602B2 (en) | Apparatus and method for recognizing traffic signs | |
CN110555475A (en) | few-sample target detection method based on semantic information fusion | |
CN108108732A (en) | Character recognition system and character recognition method thereof | |
Zagoris et al. | A document image retrieval system | |
CN108154102A (en) | A kind of traffic sign recognition method | |
CN105404886A (en) | Feature model generating method and feature model generating device | |
CN113128442A (en) | Chinese character calligraphy style identification method and scoring method based on convolutional neural network | |
CN111738048B (en) | Pedestrian re-identification method | |
US20240153240A1 (en) | Image processing method, apparatus, computing device, and medium | |
Iqbal et al. | An efficient image retrieval scheme for colour enhancement of embedded and distributed surveillance images | |
CN116012937B (en) | Traffic police gesture recognition method | |
CN110909678B (en) | Face recognition method and system based on width learning network feature extraction | |
CN115188084A (en) | Multi-mode identity recognition system and method for non-contact voiceprint and palm print palm vein | |
CN111723852A (en) | Robust training method for target detection network | |
Liu et al. | SLPR: A deep learning based Chinese ship license plate recognition framework | |
CN105844643B (en) | Distorted image detection method | |
Li et al. | PFYOLOv4: An improved small object pedestrian detection algorithm | |
Sruthi et al. | Double-handed dynamic gesture recognition using contour-based hand tracking and maximum mean probability ensembling (MMPE) for Indian Sign language | |
CN112668662B (en) | Outdoor mountain forest environment target detection method based on improved YOLOv3 network | |
CN108491883B (en) | Saliency detection optimization method based on conditional random field | |
CN114037886A (en) | Image recognition method and device, electronic equipment and readable storage medium | |
Zhao et al. | Memory-efficient document layout analysis method using LD-net |
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 |