CN112528747A - Motor vehicle turning behavior identification method, system, electronic device and storage medium - Google Patents

Motor vehicle turning behavior identification method, system, electronic device and storage medium Download PDF

Info

Publication number
CN112528747A
CN112528747A CN202011266382.4A CN202011266382A CN112528747A CN 112528747 A CN112528747 A CN 112528747A CN 202011266382 A CN202011266382 A CN 202011266382A CN 112528747 A CN112528747 A CN 112528747A
Authority
CN
China
Prior art keywords
motor vehicle
target
target motor
video image
vehicle
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.)
Pending
Application number
CN202011266382.4A
Other languages
Chinese (zh)
Inventor
魏东东
潘武
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Dahua Technology Co Ltd
Original Assignee
Zhejiang Dahua Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang Dahua Technology Co Ltd filed Critical Zhejiang Dahua Technology Co Ltd
Priority to CN202011266382.4A priority Critical patent/CN112528747A/en
Publication of CN112528747A publication Critical patent/CN112528747A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/50Context or environment of the image
    • G06V20/52Surveillance or monitoring of activities, e.g. for recognising suspicious objects
    • G06V20/54Surveillance or monitoring of activities, e.g. for recognising suspicious objects of traffic, e.g. cars on the road, trains or boats

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Multimedia (AREA)
  • Theoretical Computer Science (AREA)
  • Image Analysis (AREA)
  • Traffic Control Systems (AREA)

Abstract

The application relates to a method, a system, an electronic device and a storage medium for identifying a turning behavior of a motor vehicle. The method for identifying the turning-around behavior of the motor vehicle comprises the following steps: acquiring a video image; detecting a suspected turning position of a target motor vehicle in a video image; detecting the maximum value of the length-width ratio of the image of the target motor vehicle after the target motor vehicle passes through the suspected turning position; determining that the target motor vehicle is turning around if the maximum value of the aspect ratio of the image of the target motor vehicle exceeds a preset threshold. By the method and the device, the problem of low accuracy of motor vehicle turning behavior identification is solved, and the accuracy of motor vehicle turning behavior identification is improved.

Description

Motor vehicle turning behavior identification method, system, electronic device and storage medium
Technical Field
The present application relates to the field of traffic incident detection, and in particular, to a method, a system, an electronic device, and a storage medium for identifying a turning behavior of a motor vehicle.
Background
In an urban traffic scene, under the condition of a turning area with a revolving door, turning of a motor vehicle is easy to recognize, but under the traffic scenes such as a highway, an urban expressway, a viaduct, a tunnel, a sea-crossing bridge and the like, no fixed turning area exists, turning of a cross lane, turning of a same lane and turning of lanes in different directions can occur, the speed of the motor vehicle is higher, and the turning behavior of the motor vehicle in the scenes is very challenging to recognize for traffic departments.
However, the current common method is to identify the turning behavior of the motor vehicle by combining the lane direction and the historical track of the motor vehicle, but the method has obvious disadvantages, for example, the track trends of the turning behavior and the reversing behavior of the motor vehicle are the motion tracks returned after the motor vehicle runs to the farthest point, and the problems of low efficiency and low identification precision exist, and no effective solution is provided at present.
Disclosure of Invention
The embodiment provides a method, a system, an electronic device and a storage medium for identifying a turning behavior of a motor vehicle, so as to solve the problem of low accuracy in identifying the turning behavior of the motor vehicle in the related art.
In a first aspect, in this embodiment, a method for identifying a u-turn behavior of a motor vehicle is provided, the method comprising:
acquiring a video image;
detecting a suspected turning position of a target motor vehicle in the video image;
detecting the maximum value of the aspect ratio of the image of the target motor vehicle after the target motor vehicle passes through the suspected turning position;
determining that the target motor vehicle turns around if the maximum value of the aspect ratio of the image of the target motor vehicle exceeds a preset threshold.
In some of these embodiments, detecting a suspected u-turn location of a target vehicle in the video image comprises:
acquiring an initial position of the target motor vehicle in the video image and positions of the target motor vehicle in video image frames of the video image, wherein the initial position of the target motor vehicle in the video image refers to the position of the motor vehicle in the video image when the target motor vehicle is detected for the first time in the video image;
and taking the position, which is the largest in distance from the initial position, of the positions of the target motor vehicle in the video image frames of the video image as the suspected turning position.
In some of these embodiments, obtaining the initial position of the target vehicle in the video image and the position of the target vehicle in each video image frame of the video image comprises:
tracking a position change trajectory of the target motor vehicle in the video image;
according to the position change track, the initial position of the target motor vehicle in the video image and the position of the target motor vehicle in each video image frame of the video image are determined.
In some of these embodiments, the detecting the maximum value of the aspect ratio of the image of the target vehicle at the suspected u-turn position includes:
tracking the image of the target motor vehicle by using a circumscribed rectangle frame in a video image frame after the target motor vehicle reaches the suspected turning position detected from the video image;
and acquiring the size value of the circumscribed rectangle frame in the tracking process, determining the maximum value of the aspect ratio of the circumscribed rectangle frame according to the size value, and taking the maximum value of the aspect ratio of the circumscribed rectangle frame as the maximum value of the aspect ratio of the image of the target motor vehicle at the suspected turning position.
In some of these embodiments, in a case where a maximum value of an aspect ratio of the image of the target vehicle exceeds a preset threshold, detecting a posture of the target vehicle before passing through the suspected u-turn position and a posture of the target vehicle after passing through the suspected u-turn position, and determining that the target vehicle turns around includes:
detecting the attitude of the target motor vehicle before passing through the suspected turning position and the attitude of the target motor vehicle after passing through the suspected turning position under the condition that the maximum value of the aspect ratio of the image of the target motor vehicle exceeds a preset threshold value;
if the postures of the target motor vehicle before and after passing through the suspected turning position are different, determining that the motor vehicle turns around;
wherein the postures of the target motor vehicle before and after passing through the suspected turning-around position include a posture that a vehicle head is over against an acquisition device for shooting the video image or a posture that a vehicle tail is over against the acquisition device.
In some of these embodiments, after detecting the attitude of the target vehicle before passing the suspected u-turn location and after passing the suspected u-turn location, the method further comprises:
and if the postures of the target motor vehicle before and after passing through the suspected turning-around position are the same, determining that the motor vehicle does not turn around.
In some of these embodiments, determining that the target vehicle is turning around in the case where the maximum value of the aspect ratio of the image of the target vehicle exceeds a preset threshold comprises:
when the initial movement direction of the target motor vehicle is that the target motor vehicle drives towards an acquisition device for shooting the video image, detecting whether the posture of the target motor vehicle after passing through the suspected turning position is the posture that the tail of the vehicle is opposite to the acquisition device;
and if the posture of the target motor vehicle after passing through the suspected turning-around position is the posture that the tail of the vehicle is over against the acquisition device, determining that the motor vehicle turns around.
In some of these embodiments, determining that the target vehicle is turning around in the case where the maximum value of the aspect ratio of the image of the target vehicle exceeds a preset threshold value comprises:
when the initial movement direction of the target motor vehicle is that the target motor vehicle drives away from the acquisition device for shooting the video image, detecting whether the posture of the target motor vehicle after passing through the suspected turning position is the posture that the vehicle head faces the acquisition device;
and if the posture of the target motor vehicle after passing through the suspected turning-around position is the posture that the vehicle head is over against the acquisition device, determining that the motor vehicle turns around.
In a second aspect, there is provided a motor vehicle u-turn behavior recognition system in the present embodiment, including: a terminal device, a transmission device and a server device; the terminal equipment is connected with the server equipment through the transmission equipment;
the terminal equipment is used for operating and collecting video images;
the transmission equipment is used for transmitting video images;
the server device is configured to execute the method for identifying a u-turn behavior of a motor vehicle according to the first aspect.
In a third aspect, in this embodiment, an electronic device is provided, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, and when the processor executes the computer program, the method for identifying a u-turn behavior of a motor vehicle according to the first aspect is implemented.
In a fourth aspect, in the present embodiment, a storage medium is provided, on which a computer program is stored, which when executed by a processor, implements the method for identifying a u-turn behavior of a motor vehicle as described in the first aspect above.
Compared with the related art, the method, the system, the electronic device and the storage medium for identifying the turning-around behavior of the motor vehicle provided by the embodiment are realized by acquiring a video image; detecting a suspected turning position of a target motor vehicle in a video image; detecting the maximum value of the length-width ratio of the image of the target motor vehicle after the target motor vehicle passes through the suspected turning position; and under the condition that the maximum value of the length-width ratio of the image of the target motor vehicle exceeds the preset threshold value, determining that the target motor vehicle turns around, solving the problem of low accuracy rate of motor vehicle turning around behavior identification, and realizing the effect of improving the accuracy rate of motor vehicle turning around behavior identification.
The details of one or more embodiments of the application are set forth in the accompanying drawings and the description below to provide a more thorough understanding of the application.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the application and together with the description serve to explain the application and not to limit the application. In the drawings:
FIG. 1 is a block diagram showing a hardware configuration of a terminal of a method for recognizing a turning-around behavior of a motor vehicle according to an embodiment;
FIG. 2 is a first flowchart of a method for identifying a u-turn behavior of a vehicle according to an embodiment;
FIG. 3 is a flow chart diagram of a method for identifying a u-turn behavior of a motor vehicle according to an embodiment;
FIG. 4 is a flowchart III of a method for identifying a u-turn behavior of a motor vehicle according to an embodiment;
FIG. 5 is a flow chart of a method for identifying a u-turn behavior of a motor vehicle in a preferred embodiment;
FIG. 6 is a first schematic diagram of a video image frame in a preferred embodiment;
FIG. 7 is a second schematic diagram of a video image frame in a preferred embodiment;
FIG. 8 is a schematic diagram three of a video image frame in a preferred embodiment;
figure 9 is a schematic diagram four of a video image frame in a preferred embodiment.
Detailed Description
For a clearer understanding of the objects, aspects and advantages of the present application, reference is made to the following description and accompanying drawings.
Unless defined otherwise, technical or scientific terms used herein shall have the same general meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The use of the terms "a" and "an" and "the" and similar referents in the context of this application do not denote a limitation of quantity, either in the singular or the plural. The terms "comprises," "comprising," "has," "having," and any variations thereof, as referred to in this application, are intended to cover non-exclusive inclusions; for example, a process, method, and system, article, or apparatus that comprises a list of steps or modules (elements) is not limited to the listed steps or modules, but may include other steps or modules (elements) not listed or inherent to such process, method, article, or apparatus. Reference throughout this application to "connected," "coupled," and the like is not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. Reference to "a plurality" in this application means two or more. "and/or" describes an association relationship of associated objects, meaning that three relationships may exist, for example, "A and/or B" may mean: a exists alone, A and B exist simultaneously, and B exists alone. In general, the character "/" indicates a relationship in which the objects associated before and after are an "or". The terms "first," "second," "third," and the like in this application are used for distinguishing between similar items and not necessarily for describing a particular sequential or chronological order.
The method embodiments provided in the present embodiment may be executed in a terminal, a computer, or a similar computing device. For example, the method is executed on a terminal, and fig. 1 is a hardware structure block diagram of the terminal of the method for identifying a u-turn behavior of a motor vehicle according to the embodiment. As shown in fig. 1, the terminal may include one or more processors 102 (only one shown in fig. 1) and a memory 104 for storing data, wherein the processor 102 may include, but is not limited to, a processing device such as a microprocessor MCU or a programmable logic device FPGA. The terminal may also include a transmission device 106 for video image transmission functions and an input-output device 108. It will be understood by those of ordinary skill in the art that the structure shown in fig. 1 is merely an illustration and is not intended to limit the structure of the terminal described above. For example, the terminal may also include more or fewer components than shown in FIG. 1, or have a different configuration than shown in FIG. 1.
The memory 104 may be used to store a computer program, for example, a software program and a module of application software, such as a computer program corresponding to the method for identifying a u-turn behavior of a motor vehicle in the present embodiment, and the processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, so as to implement the method. The memory 104 may include high speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include memory located remotely from the processor 102, which may be connected to the terminal over a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The transmission device 106 is used to receive or transmit data via a network. The network described above includes a wireless network provided by a communication provider of the terminal. In one example, the transmission device 106 includes a Network adapter (NIC) that can be connected to other Network devices through a base station to communicate with the internet. In one example, the transmission device 106 may be a Radio Frequency (RF) module, which is used to communicate with the internet in a wireless manner.
In the present embodiment, a method for recognizing a u-turn behavior of a motor vehicle is provided, and fig. 2 is a flowchart of the method for recognizing a u-turn behavior of a motor vehicle according to the present embodiment, as shown in fig. 2, the flowchart includes the following steps:
in step S201, a video image is acquired.
And step S202, detecting a suspected turning position of the target motor vehicle in the video image.
Step S203, detecting the maximum value of the length-width ratio of the image of the target motor vehicle after the target motor vehicle passes through the suspected turning position.
And step S204, determining that the target motor vehicle turns around under the condition that the maximum value of the aspect ratio of the image of the target motor vehicle exceeds a preset threshold value.
After the target motor vehicle passes through the suspected end-off position, the posture of the target motor vehicle can be changed, wherein the posture of the target motor vehicle can be changed from a device for acquiring the video image just opposite to the head of the target motor vehicle to a device for acquiring the video image just opposite to the body of the target motor vehicle, or from a device for acquiring the video image just opposite to the body of the target motor vehicle to a device for acquiring the video image just opposite to the body of the target motor vehicle. Therefore, the target vehicle image acquired by the video image acquisition device is different. Therefore, the aspect ratio of the image of the target vehicle may also be different. Through the steps, after the video image of the target motor vehicle is obtained, the suspected turning position of the target motor vehicle in the video image is detected and confirmed, and then whether the motor vehicle turns around is identified according to the length-width ratio of the image of the target motor vehicle passing through the suspected turning position. The suspected turning position refers to a position with the largest distance from the initial position in the positions of the target motor vehicle in the video image frames of the video image.
In the steps, the aspect ratio of the image of the target motor vehicle and the suspected turning-around position of the target motor vehicle are adopted to identify the turning-around behavior of the target motor vehicle, the historical track of the vehicle target does not need to be used, the lane line does not need to be considered, and the method is simple to operate. And for computer equipment, the data processing amount is small, and the memory of the computer equipment is not required to be too high. Therefore, the turning behavior of the motor vehicle is identified by adopting the steps, and the efficiency can be improved.
In some embodiments, the method for detecting the suspected u-turn position of the target vehicle in the video image in step S202 may adopt an initial position of the target vehicle in the video image and positions of the target vehicle in each video image frame of the video image, and then use a position of the target vehicle with a largest distance from the initial position in the positions of the target vehicle in each video image frame of the video image as the suspected u-turn position. Wherein the initial position of the target vehicle in the video image is determined by the position of the vehicle in the video image when the target vehicle is first detected in the video image.
In the steps, the suspected turning-around position of the target motor vehicle can be judged by detecting the initial position of the target motor vehicle and the position of the target motor vehicle in each video image frame in the video image, and the method is simple to implement and easy to operate.
In some embodiments, the method for obtaining the initial position of the target vehicle in the video image and the position of the target vehicle in each video image frame of the video image may track a position change track of the target vehicle in the video image, and determine the initial position of the target vehicle in the video image and the position of the target vehicle in each video image frame of the video image according to the position change track.
In the above steps, the position of the target motor vehicle in the video image can be determined simply and clearly by tracking the position change track of the target motor vehicle in the video image, and the efficiency can be improved.
In some embodiments, the method for detecting the maximum value of the aspect ratio of the image of the target vehicle at the suspected turning position may track the image of the target vehicle using the circumscribed rectangular frame in the video image frame after the target vehicle is detected to reach the suspected turning position from the video image, obtain a size value of the circumscribed rectangular frame in the tracking process, determine the maximum value of the aspect ratio of the circumscribed rectangular frame according to the size value, and use the maximum value of the aspect ratio of the circumscribed rectangular frame as the maximum value of the aspect ratio of the image of the target vehicle at the suspected turning position.
In some embodiments, obtaining the aspect ratio of the image of the target vehicle may also be achieved by methods of target tracking and target detection. For example, the target motor vehicle is identified by using a correlation algorithm of target tracking and target detection, and the proportion of the surrounding frame of the target motor vehicle is obtained.
In the above steps, the aspect ratio of the image of the motor vehicle can be accurately obtained by a method for determining the aspect ratio of the image of the motor vehicle by detecting the aspect ratio of the circumscribed rectangular frame of the target motor vehicle in the video image.
According to the method for identifying the turning-around behavior of the motor vehicle, when the target motor vehicle at the suspected turning-around position is detected in the video image, the turning-around of the motor vehicle can be identified in time under the condition that the length-width ratio of the image of the target motor vehicle exceeds the preset threshold value, and the accuracy rate of identifying the turning-around behavior of the motor vehicle is improved.
The embodiment also provides a method for identifying the turning behavior of the motor vehicle. Fig. 3 is a flowchart of a method for identifying a u-turn behavior of a motor vehicle according to the embodiment, and as shown in fig. 3, the flowchart includes the following steps:
in step S301, a video image is acquired.
And step S302, detecting the suspected turning position of the target motor vehicle in the video image.
Step S303, detecting the maximum value of the length-width ratio of the image of the target motor vehicle after the target motor vehicle passes through the suspected turning position.
Step S304, under the condition that the maximum value of the length-width ratio of the image of the target motor vehicle exceeds a preset threshold value, whether the postures of the target motor vehicle before and after passing through the suspected turning position are the same or not is detected.
Step S305, after the gesture of the target motor vehicle before passing through the suspected turning position and the gesture of the target motor vehicle after passing through the suspected turning position are detected, if the gestures of the target motor vehicle before and after passing through the suspected turning position are different, turning of the motor vehicle is determined;
step S306, after the gesture of the target motor vehicle before passing through the suspected turning position and the gesture of the target motor vehicle after passing through the suspected turning position are detected, if the gestures of the target motor vehicle before and after passing through the suspected turning position are the same, determining that the motor vehicle does not turn around;
when the target motor vehicle passes through the position before or after the suspected turning-around position, the images of the target motor vehicle collected by the image collecting device are different. For example, the target vehicle may be changed from the target vehicle head facing the image capturing device to the target vehicle tail facing the image capturing device, or from the target vehicle tail facing the image capturing device to the target vehicle head facing the image capturing device. In the above steps, after the length-width ratio of the image of the detected target motor vehicle passing through the suspected turning position is primarily judged, the target motor vehicle is secondarily identified by detecting the postures of the target motor vehicle before and after passing through the suspected turning position, so that false alarm can be filtered, and the report rate is increased.
In some of these embodiments, in a case where the maximum value of the aspect ratio of the image of the target vehicle exceeds a preset threshold value, if the postures of the target vehicle before and after passing through the suspected turning position are different, it is determined that the vehicle turns around; and if the postures of the target motor vehicle before and after passing through the suspected turning-around position are the same, determining that the motor vehicle does not turn around, wherein the postures of the target motor vehicle before and after passing through the suspected turning-around position comprise a posture that the front of the vehicle is over against an acquisition device for shooting the video image or a posture that the tail of the vehicle is over against the acquisition device.
The embodiment also provides a method for identifying the turning behavior of the motor vehicle. Fig. 4 is a flowchart of a method for identifying a u-turn behavior of a motor vehicle according to the embodiment, and as shown in fig. 4, the flowchart includes the following steps:
in step S401, a video image is acquired.
And step S402, detecting the suspected turning position of the target motor vehicle in the video image.
Step S403, detecting a maximum value of an aspect ratio of the image of the target vehicle after the target vehicle passes through the suspected turning position.
And step S404, detecting the attitude after the suspected turning position and the initial motion direction of the target motor vehicle under the condition that the maximum value of the aspect ratio of the image of the target motor vehicle exceeds a preset threshold value.
Step S405, when the initial movement direction of the target motor vehicle is that the target motor vehicle drives away from the acquisition device for shooting the video image, detecting whether the posture of the target motor vehicle after passing through the suspected turning position is the posture that the vehicle head faces the acquisition device.
Step S406, under the condition that the initial movement direction of the target motor vehicle drives away from the acquisition device for shooting the video image, if the posture of the target motor vehicle after passing through the suspected turning position is the posture that the vehicle head faces the acquisition device, turning around of the motor vehicle is determined.
Step S407, when the initial movement direction of the target motor vehicle is driving towards the acquisition device for shooting the video image, detecting whether the posture of the target motor vehicle after passing through the suspected turning position is the posture that the tail of the vehicle is opposite to the acquisition device.
Step S408, when the initial movement direction of the target motor vehicle is driving towards the acquisition device for shooting the video image, if the posture of the target motor vehicle after passing through the suspected turning position is the posture that the tail of the vehicle is opposite to the acquisition device, the motor vehicle is determined to turn around.
Because the initial moving directions of the target vehicles are different, the postures of the target vehicles after passing through the suspected turning positions are also different. For example, when the initial movement direction of the target motor vehicle is toward the image capturing device, the posture of the target motor vehicle captured by the image capturing device is that the head of the target motor vehicle faces the image capturing device. And then after the target motor vehicle passes through the suspected turning-around position and performs the turning-around behavior, the posture of the target motor vehicle is changed into that the tail of the vehicle is opposite to the image acquisition device. And vice versa, if the initial movement direction of the target motor vehicle is away from the image acquisition device, the posture of the target motor vehicle is changed from the position that the tail of the vehicle faces the image acquisition device to the position that the head of the vehicle faces the image acquisition device. Therefore, under the condition that the length-width ratio of the motor vehicle image is determined to exceed the preset threshold value, the turning behavior of the target motor vehicle is secondarily identified through the posture of the target motor vehicle, and the accuracy of motor vehicle turning behavior identification can be improved.
In some embodiments, in a case where the initial movement direction of the target vehicle is toward the acquisition device for capturing the video image, it is detected whether the posture of the target vehicle after passing through the suspected turning position is a posture in which the vehicle rear is facing the acquisition device; if the posture of the target motor vehicle after passing through the suspected turning position is the posture that the tail of the vehicle is opposite to the acquisition device, determining that the motor vehicle turns around; when the initial movement direction of the target motor vehicle is away from the acquisition device for shooting the video image, detecting whether the head of the target motor vehicle is opposite to the attitude of the acquisition device or not after the target motor vehicle passes through the suspected turning position; and if the posture of the target motor vehicle after passing through the suspected turning position is the posture that the vehicle head is over against the acquisition device, determining that the motor vehicle turns around.
According to the method for identifying the turning-around behavior of the motor vehicle, when the target motor vehicle at the suspected turning-around position is detected in the video image, the turning-around of the motor vehicle can be accurately identified under the condition that the length-width ratio of the image of the target motor vehicle exceeds the preset threshold value, the turning-around behavior of the target motor vehicle is secondarily identified based on the posture of the motor vehicle, and the accuracy of identifying the turning-around behavior of the motor vehicle is further improved.
The present embodiment is described and illustrated below by means of preferred embodiments.
Fig. 5 is a preferred flowchart of the method for recognizing a u-turn behavior of a motor vehicle according to the present embodiment, and as shown in fig. 5, the method for recognizing a u-turn behavior of a motor vehicle includes the following steps:
step S501, a video image coordinate system is established.
In some embodiments, after determining that the video coordinate system is established for the whole picture or the partial picture of the video image, the upper left corner of the image is taken as the origin, the positive direction from the upper left corner to the upper right corner is the positive direction of the X axis, and the positive direction from the upper left corner to the lower left corner is the positive direction of the Y axis.
Step S502, a region of interest is determined in the video image.
In the above steps, the turning-around region with the important attention can be selected by determining the region of interest in the video image, so that the data to be processed by the computer is reduced, and the data processing efficiency is improved.
In some embodiments, a u-turn rule region is drawn in a monitoring video image and is used as a region of interest; and if the target motor vehicle finishes the turning behavior in the area, snapping and reporting information.
Step S503, determining the initial position (x) of the target motor vehicle0,y0) And a circumscribed rectangle detection frame of the target motor vehicle.
In some embodiments, when the target vehicle is first presented in the video, the first frame of the target vehicle is used as the initial position of the target vehicle tracking, and the target vehicle model is obtained to obtain the circumscribed rectangle detection frame of the target vehicle area, and the initial position (x) of the target vehicle can be determined by the circumscribed rectangle detection frame0,y0)。
And step S504, judging that the target motor vehicle runs to the farthest position according to the relation between the initial position and the current position of the target motor vehicle.
In some of these embodiments, the target vehicle farthest coordinate variable (x) is set and initializedmax,ymax) If the current position y of the target motor vehicle is subtracted by the initial position y of the third step0Is greater than the target farthest position ymaxMinus the target initial position y0Then the current position y of the target motor vehicle is assigned to the farthest position y of the target motor vehiclemaxContinuously updating the coordinates y of the farthest position of the target motor vehicle in this waymax(ii) a If the current position y of the target motor vehicle is subtracted by the initial position y of the third step0Is less than the farthest position y of the target vehiclemaxSubtracting the initial position y of the target motor vehicle0The current position y of the target motor vehicle is not assigned to the farthest target position y of the target motor vehicle any moremaxAnd the farthest target position y of the target vehicle at this timemaxIt is the farthest position y of the target vehicle for U-turn drivingmax
And step S505, when the target motor vehicle turns around after being at the farthest position, capturing the target by detecting a rectangular detection frame externally connected with the target motor vehicle.
In some embodiments, the head or the tail of the vehicle faces the camera, and the side body of the vehicle faces the camera, so that the ratio of the width to the height of the target motor vehicle external rectangular detection frame is obviously changed; and if the ratio of the width to the height of the target motor vehicle external rectangular detection frame exceeds a preset threshold value, wherein the threshold value can be 1.1, identifying the target motor vehicle as a U-turn and carrying out snapshot.
In step S506, the relationship between the initial position and the farthest position of the turning target vehicle captured in step S505 and the posture of the target vehicle after passing the farthest position are detected.
Step S507, if the target farthest position ymaxMinus the target initial position y0The value of (A) is negative, and whether the posture of the target motor vehicle is that the head of the target motor vehicle is over against the camera is detected.
And step S508, if the posture of the target motor vehicle in the step S507 is that the head of the target motor vehicle is over against the camera, judging that the target motor vehicle turns around.
And step S509, if the posture of the target motor vehicle in the step S507 is that the tail of the target motor vehicle is opposite to the camera, filtering and snapshotting the target motor vehicle.
In some embodiments, as shown in fig. 6, when the target vehicle appears from the bottom of the video image, the tail of the target vehicle faces the camera, after the target vehicle passes through the farthest position, it may be determined that the farthest position of the target vehicle minus the initial position of the target vehicle is a negative number, and if the head of the target vehicle faces the camera, as shown in fig. 7, the target vehicle turns around and drives to the camera, and at this time, turn around alarm information is reported.
Step S510, if the target farthest position ymaxMinus the target initial position y0The value of (1) is positive number, and whether the posture of the target motor vehicle is that the tail of the target motor vehicle is opposite to the camera is detected.
In step S511, if the posture of the target vehicle in step S509 is that the tail of the target vehicle is directly facing the camera, it is determined that the target vehicle turns around.
In step S512, if the posture of the target vehicle in step S509 is that the tail of the target vehicle is facing the camera, it is determined that the target vehicle turns around.
In some embodiments, as shown in fig. 8, when the target vehicle appears from the top of the video image, the head of the target vehicle faces the camera, after the target vehicle passes through the farthest position, it may be determined that the farthest position of the target vehicle minus the initial position of the target vehicle is a positive number, and if the tail of the target vehicle faces the camera at this time, as shown in fig. 9, the target vehicle drives away from the camera in a u-turn manner, and at this time, a u-turn warning message is reported.
In the steps, after the suspected target motor vehicle is judged to turn around through the change of the external rectangular frame of the target motor vehicle, the farthest position and the initial position of the target motor vehicle and the posture of the target motor vehicle after passing through the farthest position are judged, the turning-around behavior of the target motor vehicle is secondarily identified, false alarms are filtered, and the reporting accuracy is improved.
It should be noted that the steps illustrated in the above-described flow diagrams or in the flow diagrams of the figures may be performed in a computer system, such as a set of computer-executable instructions, and that, although a logical order is illustrated in the flow diagrams, in some cases, the steps illustrated or described may be performed in an order different than here. For example, step S502 may be reversed from step S503.
In this embodiment, there is also provided a system for recognizing a turning behavior of a motor vehicle, including: a terminal device, a transmission device and a server device; the terminal equipment is connected with the server equipment through the transmission equipment; the terminal equipment is used for operating and collecting video images; the transmission equipment is used for transmitting video images; the server device is used for executing the motor vehicle turning behavior identification method.
There is also provided in this embodiment an electronic device comprising a memory having a computer program stored therein and a processor arranged to run the computer program to perform the steps of any of the above method embodiments.
Optionally, the electronic apparatus may further include a transmission device and an input/output device, wherein the transmission device is connected to the processor, and the input/output device is connected to the processor.
Optionally, in this embodiment, the processor may be configured to execute the following steps by a computer program:
s1, acquiring a video image;
s2, detecting the suspected turning position of the target motor vehicle in the video image;
s3, detecting the maximum value of the aspect ratio of the image of the target motor vehicle after the target motor vehicle passes through the suspected turning position;
and S4, determining that the target motor vehicle turns around when the maximum value of the aspect ratio of the image of the target motor vehicle exceeds a preset threshold value.
In addition, in combination with the method for identifying a u-turn behavior of a motor vehicle in the above embodiments, embodiments of the present application may be implemented by providing a computer-readable storage medium. The computer readable storage medium having stored thereon computer program instructions; the computer program instructions, when executed by a processor, implement any of the above-described embodiments of the method for identifying a u-turn behavior of a motor vehicle.
By the method for identifying the turning-around behavior of the motor vehicle, the turning-around behavior of the motor vehicle can be identified without using a motor vehicle target historical track or considering the direction of a lane line or drawing the lane line, and the method for identifying the turning-around behavior of the motor vehicle is simplified. In addition, the secondary recognition of the turning behavior of the motor vehicle is carried out by judging the posture of the motor vehicle, and the misinformation is filtered, so that the recognition accuracy of the turning behavior of the motor vehicle is improved, and the misinformation of the turning behavior caused by the reversing behavior is reduced.
It should be noted that, for specific examples in this embodiment, reference may be made to the examples described in the foregoing embodiments and optional implementations, and details are not described again in this embodiment.
It should be understood that the specific embodiments described herein are merely illustrative of this application and are not intended to be limiting. All other embodiments, which can be derived by a person skilled in the art from the examples provided herein without any inventive step, shall fall within the scope of protection of the present application.
It is obvious that the drawings are only examples or embodiments of the present application, and it is obvious to those skilled in the art that the present application can be applied to other similar cases according to the drawings without creative efforts. Moreover, it should be appreciated that in the development of any such actual implementation, as in any engineering or design project, numerous implementation-specific decisions must be made to achieve the developers' specific goals, such as compliance with system-related and business-related constraints, which may vary from one implementation to another.
The term "embodiment" is used herein to mean that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the present application. The appearances of such phrases in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. It is to be expressly or implicitly understood by one of ordinary skill in the art that the embodiments described in this application may be combined with other embodiments without conflict.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the patent protection. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present application shall be subject to the appended claims.

Claims (11)

1. A method for identifying a u-turn behavior of a motor vehicle, comprising:
acquiring a video image;
detecting a suspected turning position of a target motor vehicle in the video image;
detecting the maximum value of the aspect ratio of the image of the target motor vehicle after the target motor vehicle passes through the suspected turning position;
determining that the target motor vehicle turns around if the maximum value of the aspect ratio of the image of the target motor vehicle exceeds a preset threshold.
2. The method of claim 1, wherein detecting a suspected u-turn location of a target vehicle in the video image comprises:
acquiring an initial position of the target motor vehicle in the video image and positions of the target motor vehicle in video image frames of the video image, wherein the initial position of the target motor vehicle in the video image refers to the position of the motor vehicle in the video image when the target motor vehicle is detected for the first time in the video image;
and taking the position, which is the largest in distance from the initial position, of the positions of the target motor vehicle in the video image frames of the video image as the suspected turning position.
3. The method of claim 2, wherein obtaining the initial position of the target vehicle in the video image and the position of the target vehicle in each video image frame of the video image comprises:
tracking a position change trajectory of the target motor vehicle in the video image;
according to the position change track, the initial position of the target motor vehicle in the video image and the position of the target motor vehicle in each video image frame of the video image are determined.
4. The method of claim 1, wherein detecting a maximum value of an aspect ratio of the image of the target vehicle at the suspected u-turn location comprises:
tracking the image of the target motor vehicle by using a circumscribed rectangle frame in a video image frame after the target motor vehicle reaches the suspected turning position detected from the video image;
and acquiring the size value of the circumscribed rectangle frame in the tracking process, determining the maximum value of the aspect ratio of the circumscribed rectangle frame according to the size value, and taking the maximum value of the aspect ratio of the circumscribed rectangle frame as the maximum value of the aspect ratio of the image of the target motor vehicle at the suspected turning position.
5. The method of claim 1, wherein determining that the target vehicle is turning around in the event that the maximum value of the aspect ratio of the image of the target vehicle exceeds a preset threshold comprises:
detecting the attitude of the target motor vehicle before passing through the suspected turning position and the attitude of the target motor vehicle after passing through the suspected turning position under the condition that the maximum value of the aspect ratio of the image of the target motor vehicle exceeds a preset threshold value;
if the postures of the target motor vehicle before and after passing through the suspected turning position are different, determining that the motor vehicle turns around;
wherein the postures of the target motor vehicle before and after passing through the suspected turning-around position include a posture that a vehicle head is over against an acquisition device for shooting the video image or a posture that a vehicle tail is over against the acquisition device.
6. The method according to claim 5, wherein after detecting the attitude of the target vehicle before passing the suspected u-turn location and after passing the suspected u-turn location, the method further comprises:
and if the postures of the target motor vehicle before and after passing through the suspected turning-around position are the same, determining that the motor vehicle does not turn around.
7. The method of claim 1, wherein determining that the target vehicle is turning around in the event that the maximum value of the aspect ratio of the image of the target vehicle exceeds a preset threshold comprises:
when the initial movement direction of the target motor vehicle is that the target motor vehicle drives towards an acquisition device for shooting the video image, detecting whether the posture of the target motor vehicle after passing through the suspected turning position is the posture that the tail of the vehicle is opposite to the acquisition device;
and if the posture of the target motor vehicle after passing through the suspected turning-around position is the posture that the tail of the vehicle is over against the acquisition device, determining that the motor vehicle turns around.
8. The method of claim 1, wherein determining that the target vehicle is turning around in the event that the maximum value of the aspect ratio of the image of the target vehicle exceeds a preset threshold comprises:
when the initial movement direction of the target motor vehicle is that the target motor vehicle drives away from the acquisition device for shooting the video image, detecting whether the posture of the target motor vehicle after passing through the suspected turning position is the posture that the vehicle head faces the acquisition device;
and if the posture of the target motor vehicle after passing through the suspected turning-around position is the posture that the vehicle head is over against the acquisition device, determining that the motor vehicle turns around.
9. A motor vehicle u-turn behavior recognition system, comprising: a terminal device, a transmission device and a server device; the terminal equipment is connected with the server equipment through the transmission equipment;
the terminal equipment is used for operating and collecting video images;
the transmission equipment is used for transmitting video images;
the server device is configured to execute the motor vehicle u-turn behavior recognition method according to any one of claims 1 to 8.
10. An electronic device comprising a memory and a processor, wherein the memory stores a computer program, and the processor is configured to execute the computer program to perform the method for identifying u-turn behavior of a motor vehicle according to any one of claims 1 to 8.
11. A storage medium, in which a computer program is stored, wherein the computer program is configured to execute the method for identifying a u-turn behavior of a motor vehicle according to any one of claims 1 to 8 when the computer program is run.
CN202011266382.4A 2020-11-13 2020-11-13 Motor vehicle turning behavior identification method, system, electronic device and storage medium Pending CN112528747A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011266382.4A CN112528747A (en) 2020-11-13 2020-11-13 Motor vehicle turning behavior identification method, system, electronic device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011266382.4A CN112528747A (en) 2020-11-13 2020-11-13 Motor vehicle turning behavior identification method, system, electronic device and storage medium

Publications (1)

Publication Number Publication Date
CN112528747A true CN112528747A (en) 2021-03-19

Family

ID=74982363

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011266382.4A Pending CN112528747A (en) 2020-11-13 2020-11-13 Motor vehicle turning behavior identification method, system, electronic device and storage medium

Country Status (1)

Country Link
CN (1) CN112528747A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113177509A (en) * 2021-05-19 2021-07-27 浙江大华技术股份有限公司 Method and device for recognizing backing behavior

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050128291A1 (en) * 2002-04-17 2005-06-16 Yoshishige Murakami Video surveillance system
CN103778786A (en) * 2013-12-17 2014-05-07 东莞中国科学院云计算产业技术创新与育成中心 Traffic violation detection method based on significant vehicle part model
CN110348332A (en) * 2019-06-24 2019-10-18 长沙理工大学 The inhuman multiple target real-time track extracting method of machine under a kind of traffic video scene
CN111145555A (en) * 2019-12-09 2020-05-12 浙江大华技术股份有限公司 Method and device for detecting vehicle violation
CN111260932A (en) * 2020-01-19 2020-06-09 上海眼控科技股份有限公司 Method and device for determining vehicle illegal behavior, computer equipment and storage medium
CN111311710A (en) * 2020-03-20 2020-06-19 北京四维图新科技股份有限公司 High-precision map manufacturing method and device, electronic equipment and storage medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050128291A1 (en) * 2002-04-17 2005-06-16 Yoshishige Murakami Video surveillance system
CN103778786A (en) * 2013-12-17 2014-05-07 东莞中国科学院云计算产业技术创新与育成中心 Traffic violation detection method based on significant vehicle part model
US20160034778A1 (en) * 2013-12-17 2016-02-04 Cloud Computing Center Chinese Academy Of Sciences Method for detecting traffic violation
CN110348332A (en) * 2019-06-24 2019-10-18 长沙理工大学 The inhuman multiple target real-time track extracting method of machine under a kind of traffic video scene
CN111145555A (en) * 2019-12-09 2020-05-12 浙江大华技术股份有限公司 Method and device for detecting vehicle violation
CN111260932A (en) * 2020-01-19 2020-06-09 上海眼控科技股份有限公司 Method and device for determining vehicle illegal behavior, computer equipment and storage medium
CN111311710A (en) * 2020-03-20 2020-06-19 北京四维图新科技股份有限公司 High-precision map manufacturing method and device, electronic equipment and storage medium

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
周灿灿: "基于视频检测技术的违法变道监测系统", 中国优秀硕士学位论文全文数据库信息科技辑, no. 7 *
房广江;赵敏;郭航宇;林亮;: "低照度下的海上目标识别与跟踪", 机械制造与自动化, no. 02 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113177509A (en) * 2021-05-19 2021-07-27 浙江大华技术股份有限公司 Method and device for recognizing backing behavior

Similar Documents

Publication Publication Date Title
CN108845574B (en) Target identification and tracking method, device, equipment and medium
Luo et al. Fast and furious: Real time end-to-end 3d detection, tracking and motion forecasting with a single convolutional net
CN109035304B (en) Target tracking method, medium, computing device and apparatus
CN111399492A (en) Robot and obstacle sensing method and device thereof
CN110782433B (en) Dynamic information violent parabolic detection method and device based on time sequence and storage medium
CN109377694B (en) Monitoring method and system for community vehicles
CN108647587B (en) People counting method, device, terminal and storage medium
CN112150514A (en) Pedestrian trajectory tracking method, device and equipment of video and storage medium
CN111738225B (en) Crowd gathering detection method, device, equipment and storage medium
CN111291646A (en) People flow statistical method, device, equipment and storage medium
CN112700478A (en) Target tracking method, system, computer-readable storage medium, and program product
CN111899279A (en) Method and device for detecting motion speed of target object
CN112528747A (en) Motor vehicle turning behavior identification method, system, electronic device and storage medium
FAN et al. Robust lane detection and tracking based on machine vision
CN112819889B (en) Method and device for determining position information, storage medium and electronic device
CN113936042B (en) Target tracking method and device and computer readable storage medium
US9183448B2 (en) Approaching-object detector, approaching object detecting method, and recording medium storing its program
CN116363628A (en) Mark detection method and device, nonvolatile storage medium and computer equipment
CN114913470A (en) Event detection method and device
CN115019242A (en) Abnormal event detection method and device for traffic scene and processing equipment
CN113673362A (en) Method and device for determining motion state of object, computer equipment and storage medium
CN113962338A (en) Indoor monitoring method and system for RFID-assisted multi-camera detection and tracking
CN113221800A (en) Monitoring and judging method and system for target to be detected
CN114663793A (en) Target behavior identification method and device, storage medium and terminal
CN112861711A (en) Regional intrusion detection method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination