Human leg detection method, device and readable medium based on support vector description

Through the support vector description method, the existing human leg detection algorithm is solved and the problem of complex and slow calculation is achieved, and accurate pedestrian leg recognition in multi-person and complex obstacle scenarios is achieved. It is suitable for low-cost embedded platforms.

CN114898408BActive Publication Date: 2024-12-27QUANZHOU INST OF EQUIP MFG +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210760254.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-30
Publication Date
2024-12-27
Estimated Expiration
2042-06-30

AI Technical Summary

Technical Problem

The existing human leg detection algorithm is complex in training and slow in computing, and is not suitable for low-cost embedded platforms, making it difficult to accurately identify pedestrian legs in multi-person and complex obstacle scenarios.

Method used

Using a method based on support vector description, laser point data is initially clustered through the k-nearest neighbor algorithm, density and geometric shape characteristics are calculated, and leg clustering is judged using support vector description and decision function to achieve fast and accurate pedestrian target recognition.

Benefits of technology

It improves detection speed, reduces computing costs, and can accurately identify pedestrian legs in multiple people and complex obstacle scenarios. It is suitable for real-time detection of low-cost embedded platforms.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114898408B_ABST
    Figure CN114898408B_ABST
Patent Text Reader

Abstract

The present invention discloses a human leg detection method, device and readable medium based on support vector description, which relates to the field of human leg detection. By acquiring two-dimensional laser point data of human legs collected by laser radar, the two-dimensional laser point data is preliminarily clustered by k-nearest neighbor algorithm to obtain multiple candidate leg clusters; density features and geometric shape features of each candidate leg cluster are calculated based on the candidate leg clusters; support vector description is used to calculate the leg support vector of each candidate leg cluster according to the density features and geometric shape features; based on the leg support vectors of the candidate leg clusters, whether two candidate leg clusters belong to the same pedestrian target cluster is judged according to the decision function to obtain the clustering result. The present invention solves the problems of complex training, slow calculation and high cost of human leg detection algorithm, improves the search speed of the detector, reduces the calculation cost, can be transplanted to the embedded robot platform, and obtains more accurate pedestrian leg detection results.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of human leg detection, and in particular to a human leg detection method, device and readable medium based on support vector description. Background Art

[0002] Mobile robots need to sense the position of target pedestrians in order to achieve motion planning, obstacle avoidance and human-machine interaction. Especially in the human-machine interaction link, in complex scenes with multiple people and multiple obstacles, mobile robots need to identify interactive targets and avoid interacting with interfering targets. LiDAR is often used as a sensor for mobile robots to identify targets because of its wide recognition range, high scanning accuracy and good environmental adaptability. Limited by the height of the robot, the most convenient way to perceive is to use LiDAR to detect pedestrians' legs.

[0003] The laser radar technology for detecting human legs mainly includes the Bounding-Box method, the Circle Fitting method, and the quasi-arc method. These methods describe the laser point data of the legs as simple geometric shapes.

[0004] There are two major difficulties in using lidar detectors: (1) in scenes with cylindrical obstacles, the laser points are often identified as the wrong target because of their similar shapes; (2) the detector fails in scenes with multiple people because the laser points on the legs are often partially blocked, resulting in the loss of key shape features.

[0005] In the authorized patent, a method for tracking human legs by a mobile robot that integrates vision and laser technology uses a leg arc feature recognition algorithm for the detector that detects human legs. A method for autonomous following a mobile robot based on multi-sensor fusion uses a two-dimensional laser radar, a camera, and an AOA beacon sensor to realize the robot's recognition of pedestrian targets. The two-dimensional laser radar method for identifying pedestrians is to "cluster the points returned by the laser, and the points less than a certain threshold are divided into a cluster, and geometric features are generated for these clusters; the geometric features include the number of laser points, the width and length of the laser cluster, and the distance and angle relative to the laser." This method still divides clusters by geometric features. A hierarchical clustering method used in a robot automatic following method based on the ROS robot operating system calculates the total length of each cluster, the straight-line distance between the first and last elements, and the curvature of each cluster.

[0006] In the patents that have been published and are under review, the shape of the laser points on the legs is mainly used as the basis for judgment. A human leg recognition and tracking method and its equipment and storage medium use span, length, and fitting radius as the basis for judging effective point cloud splines; a human leg detection method based on laser technology screens legs by inputting laser data into a random forest classifier that trains linearity, circularity, and curvature; a mobile robot automatic following method suitable for multi-person scenes screens human leg features based on the curvature and total length of leg clusters; the laser data in an efficient following method based on laser human body detection is a human leg recognition model obtained in advance through machine learning training, but the patent does not disclose the method and details of machine learning training; a pedestrian detection and tracking method based on laser radar uses a multi-scale adaptive random forest classifier algorithm to train human leg point clusters, but this method is complex to train and slow to calculate, and is not suitable for mobile robots equipped with embedded platforms. Summary of the invention

[0007] In view of the above-mentioned problems of complex training, slow operation, high cost and the like of the existing human leg detection algorithm, the embodiment of the present application aims to propose a human leg detection method, device and readable medium based on support vector description to solve the technical problems mentioned in the above background technology section.

[0008] In a first aspect, an embodiment of the present application provides a method for detecting human legs based on support vector description, comprising the following steps:

[0009] S1, obtaining the two-dimensional laser point data of the human leg collected by the laser radar, and performing preliminary clustering on the two-dimensional laser point data by using the k-nearest neighbor algorithm to obtain multiple candidate leg clusters;

[0010] S2, based on the candidate leg clusters, density features and geometric shape features of each candidate leg cluster are calculated;

[0011] S3, calculating the leg support vector of each candidate leg cluster using support vector description according to density features and geometric shape features;

[0012] S4, based on the leg support vectors of the candidate leg clusters, judging whether the two candidate leg clusters belong to the same pedestrian target cluster according to the decision function, and obtaining the clustering result.

[0013] Preferably, step S1 specifically includes:

[0014] S11, calculate the distance between each laser point and its nearby laser points d { x i , x i+1};

[0015] S12, distance d { x i , x i+1} Sort from small to large and select the first k distances d { x i , x i+1}The corresponding two-dimensional laser point data;

[0016] S13, determine the first k distances d { x i , x i+1} is less than the distance threshold, if so, output the first k distances d { x i , x i+1} is used as the candidate leg cluster, otherwise the value of k is adjusted, and steps S12-S13 are repeated to obtain the candidate leg cluster {C k} and candidate leg clusters { C k+1}.

[0017] Preferably, the density feature of the candidate leg cluster is a density weight, and the geometric shape feature of the candidate leg cluster includes a leg circumference weight and a leg width weight.

[0018] As a preference, the candidate leg cluster {C k The density weight of ρ k The calculation is done using the following formula:

[0019]

[0020] in, d { x i , x i+1} is the candidate leg cluster {C k Laser point inside x i To nearby laser points x i+1 The distance between d max { x i , x i+1} is a two-dimensional laser point x i To nearby laser points xi+1 The maximum distance between .

[0021] As a preference, the candidate leg cluster {C k Leg circumference weight G k The calculation is done using the following formula:

[0022]

[0023] Where m is the candidate leg cluster {C k}, is the distance between two adjacent laser points.

[0024] As a preference, the candidate leg cluster {C k Leg width weight W k The calculation is done using the following formula:

[0025]

[0026] in, Cluster the candidate legs {C k}The distance between the first laser point and the last laser point in .

[0027] As a preferred embodiment, step S3 specifically includes: clustering the candidate legs into {C k The two-dimensional laser point data in} is described as a hypersphere with center c and radius R, then the leg support vector is calculated as follows:

[0028]

[0029] in, R is the radius of the hypersphere in the support vector description, c is the center of the hypersphere, ξ i is the relaxation coefficient to reduce the influence of outliers, C is a balance coefficient between the volume of the hypersphere and the misclassification rate. It is a function that maps the two-dimensional laser point data from the original space to the feature space through nonlinear transformation; the final calculation is .

[0030] Preferably, step S4 specifically includes:

[0031] Decision function f SVDD The calculation formula is as follows:

[0032]

[0033] Among them, the sgn function is a step function with only 0 and 1 values, n is the number of pedestrian targets, α i and α j is the Lagrange multiplier, Cluster the candidate legs { C k}, Cluster the candidate legs { C k+1}, is the candidate leg cluster { C k}and{ C k+1} is the inner product of the support vectors, is the candidate leg cluster { C k}and{ C k+1 The kernel function of the support vector of};

[0034] like f SVDD = 1, then the candidate leg cluster { C k}and{ C k+1} are divided into the same pedestrian target cluster; if f SVDD = 0, then the candidate leg cluster { C k}and{ C k+1} cannot be classified into the same pedestrian target cluster.

[0035] In a second aspect, an embodiment of the present application provides a human leg detection device based on support vector description, comprising:

[0036] A preliminary clustering module is configured to obtain two-dimensional laser point data of a human leg collected by a laser radar, and perform preliminary clustering on the two-dimensional laser point data by a k-nearest neighbor algorithm to obtain a plurality of candidate leg clusters;

[0037] A feature calculation module is configured to calculate density features and geometric shape features of each candidate leg cluster based on the candidate leg cluster;

[0038] A support vector description module is configured to calculate a leg support vector of each candidate leg cluster using support vector description according to density features and geometric shape features;

[0039] The decision clustering module is configured to determine whether two candidate leg clusters belong to the same pedestrian target cluster based on the leg support vectors of the candidate leg clusters according to a decision function to obtain a clustering result.

[0040] In a third aspect, an embodiment of the present application provides an electronic device comprising one or more processors; a storage device for storing one or more programs, wherein when the one or more programs are executed by one or more processors, the one or more processors implement a method as described in any implementation manner in the first aspect.

[0041] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method described in any implementation manner in the first aspect.

[0042] Compared with the prior art, the present invention has the following beneficial effects:

[0043] (1) The present invention improves detection speed and reduces computational cost through the k-nearest neighbor algorithm, and can be transplanted to a low-cost embedded platform for real-time detection.

[0044] (2) The present invention improves the accuracy of human leg recognition by using a support vector description method based on density features and geometric features.

[0045] (3) The present invention can realize the detection of pedestrian legs and recognition of pedestrian targets by laser radar in scenes with multiple people and complex obstacles. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0047] Figure 1 is an exemplary device architecture diagram to which an embodiment of the present application may be applied;

[0048] Figure 2 A schematic diagram of the flow of a method for detecting human legs based on support vector description according to an embodiment of the present invention;

[0049] Figure 3 A schematic diagram of density features and geometric features of a human leg detection method based on support vector description according to an embodiment of the present invention;

[0050] Figure 4 A schematic diagram of space transformation of support vector description of a human leg detection method based on support vector description according to an embodiment of the present invention;

[0051] Figure 5 Schematic diagram of the results of the human leg detection method based on support vector description according to an embodiment of the present invention Figure 1 ;

[0052] Figure 6 Schematic diagram of the results of the human leg detection method based on support vector description according to an embodiment of the present invention Figure 2 ;

[0053] Figure 7 Schematic diagram of the results of the human leg detection method based on support vector description according to an embodiment of the present invention Figure 3 ;

[0054] Figure 8 It is a schematic diagram of a human leg detection device based on support vector description according to an embodiment of the present invention;

[0055] Fig. 9 It is a schematic diagram of the structure of a computer device suitable for implementing the electronic device of the embodiment of the present application. DETAILED DESCRIPTION

[0056] In order to make the purpose, technical scheme and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0057] Figure 1 An exemplary device architecture 100 is shown to which the method for detecting human legs based on support vector description or the device for detecting human legs based on support vector description according to the embodiments of the present application can be applied.

[0058] like Figure 1 As shown, the device architecture 100 may include terminal devices 101, 102, 103, a network 104 and a server 105. The network 104 is used to provide a medium for communication links between the terminal devices 101, 102, 103 and the server 105. The network 104 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.

[0059] Users can use terminal devices 101, 102, 103 to interact with server 105 through network 104 to receive or send messages, etc. Various applications, such as data processing applications, file processing applications, etc., can be installed on terminal devices 101, 102, 103.

[0060] Terminal devices 101, 102, 103 may be hardware or software. When terminal devices 101, 102, 103 are hardware, they may be various electronic devices, including but not limited to smart phones, tablet computers, laptop computers, desktop computers, etc. When terminal devices 101, 102, 103 are software, they may be installed in the electronic devices listed above. They may be implemented as multiple software or software modules (for example, software or software modules for providing distributed services), or as a single software or software module. No specific limitation is made here.

[0061] The server 105 may be a server that provides various services, such as a background data processing server that processes files or data uploaded by the terminal devices 101, 102, and 103. The background data processing server may process the acquired files or data and generate processing results.

[0062] It should be noted that the human leg detection method based on support vector description provided in the embodiment of the present application can be executed by the server 105, or by the terminal devices 101, 102, 103. Accordingly, the human leg detection device based on support vector description can be set in the server 105, or in the terminal devices 101, 102, 103.

[0063] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided as required. In the case where the processed data does not need to be obtained remotely, the above device architecture may not include a network, but only a server or a terminal device.

[0064] Figure 2 A method for detecting human legs based on support vector description provided by an embodiment of the present application is shown, comprising the following steps:

[0065] S1, obtain the two-dimensional laser point data of the human leg collected by the laser radar, and perform preliminary clustering on the two-dimensional laser point data through the k-nearest neighbor algorithm to obtain multiple candidate leg clusters.

[0066] In a specific embodiment, step S1 specifically includes:

[0067] S11, calculate the distance between each laser point and its nearby laser points d { x i , x i+1};

[0068] S12, distance d { x i ,x i+1} Sort from small to large and select the first k distances d { x i , x i+1}The corresponding two-dimensional laser point data;

[0069] S13, determine the first k distances d { x i , x i+1} is less than the distance threshold. If so, the corresponding two-dimensional laser point data is output as the candidate leg cluster. Otherwise, the value of k is adjusted and steps S12-S13 are repeated to obtain the candidate leg cluster {C k} and candidate leg clusters { C k+1}.

[0070] Specifically, the real-time captured two-dimensional laser point data are classified by the k-nearest neighbor algorithm, and the two-dimensional laser point data with a distance greater than the distance threshold are filtered to screen out the candidate leg clusters {C k}. Candidate leg clustering {C k} contains m two-dimensional laser point data, and uses the k-nearest neighbor algorithm for preliminary clustering, which can improve the detection speed and can be transplanted to a low-cost embedded platform for real-time detection. Among them, the candidate leg cluster {C k} contains k distances d { x i , x i+1} corresponding to the two-dimensional laser point data, candidate leg clustering { C k+1} contains k+1 distances d { x i , x i+1} corresponds to the two-dimensional laser point data. Candidate leg clustering {C k} and candidate leg clustering { C k+1} are two adjacent candidate leg clusters.

[0071] S2, based on the candidate leg clusters, density features and geometric shape features of each candidate leg cluster are calculated.

[0072] In a specific embodiment, the density feature of the candidate leg cluster is a density weight, and the geometric shape feature of the candidate leg cluster includes a leg circumference weight and a leg width weight. Figure 3 , leg circumference weight Gk The definition is: The leg circumference weight is the first laser point x in the kth cluster 1 To the last laser point x m The circumference is equal to x 1 x 2 The distance between + x 2 x 3 The distance between +…+ x m-1 x m Distance between legs; Leg width weight W k is defined as the first laser point x 1 and the last laser point x m The distance between.

[0073] In a specific embodiment, the candidate leg cluster {C k The density weight of ρ k The calculation is done using the following formula:

[0074]

[0075] in, d { x i , x i+1} is the candidate leg cluster {C k Laser point inside x i To nearby laser points x i+1 The distance between d max { x i , x i+1} is a two-dimensional laser point x i To nearby laser points x i+1 The maximum distance between .

[0076] In a specific embodiment, the candidate leg cluster {C k Leg circumference weight G k The calculation is done using the following formula:

[0077]

[0078] Where m is the candidate leg cluster {C k}, is the distance between two adjacent laser points.

[0079] In a specific embodiment, the candidate leg cluster {C k Leg width weight W k The calculation is done using the following formula:

[0080]

[0081] in, Cluster the candidate legs {C k}The distance between the first laser point and the last laser point in .

[0082] Specifically, the above distances are all Euclidean distances, and in other optional embodiments, Manhattan distances and the like may also be selected at the same time. Taking into account the density, length, and width features of the laser points, the leg clusters with relatively high confidence are described and divided, thereby obtaining more accurate pedestrian leg detection results, and solving the problem of misjudgment of the detector caused by cylindrical obstacles and partially blocked human legs.

[0083] S3, using support vector description to calculate the leg support vector of each candidate leg cluster according to the density feature and the geometric shape feature.

[0084] In a specific embodiment, step S3 specifically includes: referring to Figure 4 , the support vector describes the clustering of candidate legs {C k The two-dimensional laser point data in} is described as a hypersphere with center c and radius R, then the leg support vector is calculated as follows:

[0085]

[0086] in, R is the radius of the hypersphere in the support vector description, c is the center of the hypersphere, ξ i is the relaxation coefficient to reduce the influence of outliers, C is a balance coefficient between the volume of the hypersphere and the misclassification rate. It is a function that maps the two-dimensional laser point data from the original space to the feature space through nonlinear transformation; the final calculation is .

[0087] Construct the Lagrangian function for the leg support vectors:

[0088] in, α i and γ i is the Lagrange multiplier, α i ≥0, γ i ≥0;

[0089] For the Lagrangian function R , c and ξ i Find the partial derivative and set it equal to zero, and you can get the result of the Lagrange multiplier:

[0090]

[0091]

[0092]

[0093] According to the calculation results of Lagrange multipliers, the constraints of Lagrange function are obtained:

[0094]

[0095] in, α i and α j is the Lagrange multiplier, is the candidate leg cluster { C k}and{ C k+1} is the inner product of the support vectors, is the candidate leg cluster { C k}and{ C k+1} is the kernel function of the support vector.

[0096] S4, based on the leg support vectors of the candidate leg clusters, judging whether the two candidate leg clusters belong to the same pedestrian target cluster according to the decision function, and obtaining the clustering result.

[0097] In a specific embodiment, step S4 specifically includes:

[0098] Decision function f SVDD The calculation formula is as follows:

[0099]

[0100] Among them, the sgn function is a step function with only 0 and 1 values, n is the number of pedestrian targets, α i and α j is the Lagrange multiplier, Cluster the candidate legs { Ck}, Cluster the candidate legs { C k+1}, is the candidate leg cluster { C k}and{ C k+1} is the inner product of the support vectors, is the candidate leg cluster { C k}and{ C k+1 The kernel function of the support vector of};

[0101] like f SVDD = 1, then the candidate leg cluster { C k}and{ C k+1} are divided into the same pedestrian target cluster; if f SVDD = 0, then the candidate leg cluster { C k}and{ C k+1} cannot be classified into the same pedestrian target cluster.

[0102] The final experimental results are as follows Figure 5-7 As shown, the above algorithm can cluster the leg information of the same pedestrian target. There is no need to use deep learning for detection or train the model. LiDAR can detect pedestrian legs and identify pedestrian targets in scenes with multiple people and complex obstacles.

[0103] Further references Figure 8 As an implementation of the methods shown in the above figures, the present application provides an embodiment of a human leg detection device based on support vector description. Figure 2 Corresponding to the method embodiment shown, the device can be specifically applied to various electronic devices.

[0104] The embodiment of the present application provides a human leg detection device based on support vector description, including:

[0105] A preliminary clustering module 1 is configured to obtain two-dimensional laser point data of a human leg collected by a laser radar, and perform preliminary clustering on the two-dimensional laser point data by a k-nearest neighbor algorithm to obtain a plurality of candidate leg clusters;

[0106] A feature calculation module 2 is configured to calculate the density feature and geometric shape feature of each candidate leg cluster based on the candidate leg cluster;

[0107] A support vector description module 3 is configured to calculate a leg support vector of each candidate leg cluster using support vector description according to density features and geometric shape features;

[0108] The decision clustering module 4 is configured to determine whether two candidate leg clusters belong to the same pedestrian target cluster based on the leg support vectors of the candidate leg clusters according to a decision function to obtain a clustering result.

[0109] Reference below Fig. 9 , which shows an electronic device (eg Figure 1 A schematic diagram of the structure of a computer device 900 (a server or terminal device as shown). Fig. 9 The electronic device shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.

[0110] like Fig. 9 As shown, the computer device 900 includes a central processing unit (CPU) 901 and a graphics processing unit (GPU) 902, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 903 or a program loaded from a storage part 909 to a random access memory (RAM) 904. In the RAM 904, various programs and data required for the operation of the device 900 are also stored. The CPU 901, GPU 902, ROM 903, and RAM 904 are connected to each other through a bus 905. An input / output (I / O) interface 906 is also connected to the bus 905.

[0111] The following components are connected to the I / O interface 906: an input section 907 including a keyboard, a mouse, etc.; an output section 908 including a display such as a liquid crystal display (LCD), etc. and a speaker, etc.; a storage section 909 including a hard disk, etc.; and a communication section 910 including a network interface card such as a LAN card, a modem, etc. The communication section 910 performs communication processing via a network such as the Internet. A drive 911 can also be connected to the I / O interface 906 as needed. A removable medium 912, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 911 as needed, so that a computer program read therefrom is installed into the storage section 909 as needed.

[0112] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program contains a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through the communication part 910, and / or installed from a removable medium 912. When the computer program is executed by the central processing unit (CPU) 901 and the graphics processing unit (GPU) 902, the above-mentioned functions defined in the method of the present application are executed.

[0113] It should be noted that the computer-readable medium described in the present application may be a computer-readable signal medium or a computer-readable medium or any combination of the above two. The computer-readable medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor device, device or component, or any combination of the above. More specific examples of computer-readable media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present application, a computer-readable medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution device, device or device. In the present application, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The computer-readable signal medium may also be any computer-readable medium other than a computer-readable medium that can send, propagate or transmit a program for use by or in conjunction with an instruction execution device, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.

[0114] Computer program code for performing the operations of the present application may be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0115] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the device, method and computer program product according to various embodiments of the present application. In this regard, each box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flow chart, and the combination of the boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based device that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0116] The modules involved in the embodiments described in this application may be implemented by software or hardware, and the modules described may also be set in a processor.

[0117] As another aspect, the present application also provides a computer-readable medium, which may be included in the electronic device described in the above embodiment; or it may exist independently and not be assembled into the electronic device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by the electronic device, the electronic device: obtains the two-dimensional laser point data of the human leg collected by the laser radar, and preliminarily clusters the two-dimensional laser point data through the k-nearest neighbor algorithm to obtain multiple candidate leg clusters; based on the candidate leg clusters, calculates the density characteristics and geometric shape characteristics of each candidate leg cluster; uses the support vector description to calculate the leg support vector of each candidate leg cluster according to the density characteristics and geometric shape characteristics; based on the leg support vectors of the candidate leg clusters, judges whether two candidate leg clusters belong to the same pedestrian target cluster according to the decision function, and obtains the clustering result.

[0118] The above description is only a preferred embodiment of the present application and an explanation of the technical principles used. Those skilled in the art should understand that the scope of the invention involved in the present application is not limited to the technical solution formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above invention concept. For example, the above features are replaced with the technical features with similar functions disclosed in this application (but not limited to) by each other to form a technical solution.

Claims

1. A method for detecting human legs based on support vector description, characterized in that: The following steps are involved: S1, obtaining two-dimensional laser point data of a human leg collected by a laser radar, and performing preliminary clustering on the two-dimensional laser point data using a k-nearest neighbor algorithm to obtain a plurality of candidate leg clusters. The step S1 specifically includes: S11, calculate the distance d{x} between each laser point and its nearby laser points i , x i+1 }; S12, for the distance d{x i , x i+1 } Sort from small to large and select the first k distances d{x i , x i+1 }The corresponding two-dimensional laser point data; S13, determine the first k distances d{x i , x i+1 } is less than the distance threshold, if so, output the first k distances d{x i , x i+1 } is used as the candidate leg cluster, otherwise the value of k is adjusted, and steps S12-S13 are repeated to obtain the candidate leg cluster {C k } and candidate leg clusters {C k+1 }; S2, based on the candidate leg clusters, calculate the density feature and geometric shape feature of each of the candidate leg clusters, wherein the density feature of the candidate leg clusters is a density weight, and the geometric shape feature of the candidate leg clusters includes a leg circumference weight and a leg width weight. k The density weight ρ of k The calculation is done using the following formula: ρ k =1-d(x i ,x i+1 ) / d max (x i ,x i+1 ); Among them, d{x i , x i+1 } is the candidate leg cluster {C k } Laser point x i To each nearby laser point x i+1 The distance between max {x i , x i+1 } is the two-dimensional laser point x i To each nearby laser point x i+1 The maximum distance between the candidate leg clusters {C k }'s leg circumference weight G k The calculation is done using the following formula: Where m is the candidate leg cluster {C k The number of laser points in}, L(x i , x i+1 ) is the distance between two adjacent laser points, the candidate leg cluster {C k } Leg width weight W k The calculation is done using the following formula: W k =d(x1,x m ); Among them, d(x1,x m ) is the candidate leg cluster {C k The distance between the first laser point and the last laser point in}; S3, using support vector description to calculate the leg support vector of each of the candidate leg clusters according to the density feature and the geometric shape feature, the step S3 specifically includes: the support vector description calculates the leg support vector of each of the candidate leg clusters {C k The two-dimensional laser point data in} is described as a hypersphere with center c and radius R, then the leg support vector is calculated as follows: Where R is the radius of the hypersphere in the support vector description, c is the center of the hypersphere, and ξ i is the relaxation coefficient to reduce the influence of outliers, C is the balance coefficient between the volume of the hypersphere and the misclassification rate, is a function that maps the two-dimensional laser point data from the original space to the feature space through nonlinear transformation; and finally calculates S4, judging whether two candidate leg clusters belong to the same pedestrian target cluster based on the leg support vectors of the candidate leg clusters according to a decision function, and obtaining a clustering result.

2. The method for detecting human legs based on support vector description according to claim 1, characterized in that: The step S4 specifically includes: The decision function f SVDD The calculation formula is as follows: Among them, the sgn function is a step function with only 0 and 1 values, n is the number of pedestrian targets, and α i and α j is the Lagrange multiplier, Cluster the candidate legs {C k }, Cluster the candidate legs {C k+1 }, is the candidate leg cluster {C k } and {C k+1 } is the inner product of the support vectors, is the candidate leg cluster {C k } and {C k+1 The kernel function of the support vector of}; If f SVDD =1, then the candidate leg cluster {C k } and {C k+1 } are divided into the same pedestrian target cluster; if f SVDD = 0, then the candidate leg cluster {C k } and {C k+1 } cannot be classified into the same pedestrian target cluster.

3. A human leg detection device based on support vector description, characterized in that: include: The preliminary clustering module is configured to obtain two-dimensional laser point data of human legs collected by the laser radar, and perform preliminary clustering on the two-dimensional laser point data by using a k-nearest neighbor algorithm to obtain multiple candidate leg clusters. The preliminary clustering module specifically includes: The first submodule is configured to calculate the distance d{x} between each laser point and its neighboring laser points i , x i+1 }; The second submodule is configured to i , x i+1 } Sort from small to large and select the first k distances d{x i , x i+1 }The corresponding two-dimensional laser point data; The third submodule is configured to determine the first k distances d{x i , x i+1 } is less than the distance threshold, if so, output the first k distances d{x i , x i+1 } is used as the candidate leg cluster, otherwise the value of k is adjusted, and the second and third submodules are repeatedly executed to obtain the candidate leg cluster {C k } and candidate leg clusters {C k+1 }; The feature calculation module is configured to calculate the density feature and geometric shape feature of each of the candidate leg clusters based on the candidate leg clusters, wherein the density feature of the candidate leg clusters is a density weight, and the geometric shape feature of the candidate leg clusters includes a leg circumference weight and a leg width weight. k The density weight ρ of k The calculation is done using the following formula: ρ k =1-d(x i ,x i+1 ) / d max (x i ,x i+1 ); Among them, d{x i , x i+1 } is the candidate leg cluster {C k } Laser point x i To each nearby laser point x i+1 The distance between max {x i , x i+1 } is the two-dimensional laser point x i To each nearby laser point x i+1 The maximum distance between the candidate leg clusters {C k }'s leg circumference weight G k The calculation is done using the following formula: Where m is the candidate leg cluster {C k The number of laser points in}, L(x i , x i+1 ) is the distance between two adjacent laser points, the candidate leg cluster {C k } Leg width weight W k The calculation is done using the following formula: W k =d(x1,x m ); Among them, d(x1,x m ) is the candidate leg cluster {C k The distance between the first laser point and the last laser point in}; A support vector description module is configured to calculate the leg support vector of each of the candidate leg clusters using support vector description according to the density feature and the geometric shape feature. The support vector description module specifically includes: the support vector description clusters the candidate leg clusters {C k The two-dimensional laser point data in} is described as a hypersphere with center c and radius R, then the leg support vector is calculated as follows: Where R is the radius of the hypersphere in the support vector description, c is the center of the hypersphere, and ξ i is the relaxation coefficient to reduce the influence of outliers, C is the balance coefficient between the volume of the hypersphere and the misclassification rate, is a function that maps the two-dimensional laser point data from the original space to the feature space through nonlinear transformation; and is finally calculated; The decision clustering module is configured to determine whether two candidate leg clusters belong to the same pedestrian target cluster based on the leg support vectors of the candidate leg clusters according to a decision function to obtain a clustering result.

4. An electronic device, comprising: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1-2.

5. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 2 is implemented.