UAV flight speed adjustment method, electronic device and storage medium

By acquiring and processing image data of the target area in the drone, determining areas with high human density, and adjusting the flight speed of the drone according to the flight speed threshold, it solves the possibility of failure of the drone in high-risk areas, which can lead to failure in the drone flying in high-risk areas. The problem of injury to pedestrians on the ground has significantly improved the safety of pedestrians on the ground.

CN118192628BActive Publication Date: 2025-02-14SGCC GENERAL AVIATION
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410307256.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-03-18
Publication Date
2025-02-14
Estimated Expiration
2044-03-18

AI Technical Summary

Technical Problem

During drone flight, if you fly in high-risk areas such as dense crowds, if the drone fails, it may cause harm to pedestrians on the ground. How to reduce the risk of pedestrians on the ground is an urgent problem to be solved .

Method used

By obtaining the target image of the target area, dividing it into several sub-regions, obtaining the human density of each sub-region, determining the target sub-region, calculating the target point coordinates of each target sub-region, performing clustering, determining the reference point coordinates, and converting them into Latitude and longitude coordinates in the world coordinate system. If the drone has not reached a circular area centered at the reference point and the current flight speed is below or equal to a certain threshold, the flight speed is adjusted to ensure that the drone does not fall into the area.

Benefits of technology

By adjusting the flight speed of the drone, we ensure that the drone will not fall into crowded areas when there is a failure, thus greatly reducing the risk of injury to pedestrians on the ground and improving the safety of pedestrians on the ground.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118192628B_ABST
    Figure CN118192628B_ABST
Patent Text Reader

Abstract

The present invention provides a method for adjusting the flight speed of an unmanned aerial vehicle, an electronic device and a storage medium, and relates to the field of adjusting the flight speed of an unmanned aerial vehicle. The method comprises: obtaining a target image corresponding to a target area; dividing the target image into a plurality of adjacent sub-areas; obtaining a human body density corresponding to each sub-area; determining a target point coordinate list α; clustering all human body images into m clusters to obtain a cluster list β; obtaining the coordinates of the target cluster centroid of each cluster in β to obtain a cluster centroid coordinate list Z; determining a reference point coordinate C corresponding to the target image; converting C into a latitude and longitude coordinate C' in a world coordinate system; if a target unmanned aerial vehicle arrives in a circular area with C' as the center, and the current horizontal flight speed V of the target unmanned aerial vehicle is 0 ≤V Y , then V 0 The first target flight speed V1 is adjusted; the present invention reduces the probability of the UAV falling into the crowd and improves the safety of pedestrians on the ground.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of unmanned aerial vehicle flight speed adjustment, and in particular to a method for adjusting the flight speed of an unmanned aerial vehicle, an electronic device and a storage medium. Background Art

[0002] With the rapid development of drone technology, drones are being used more and more widely in various application scenarios, including crowded places, road traffic congestion areas and other areas; however, during the flight of a drone, if it is flying in a high-risk area, for example, above a densely populated area, if the drone malfunctions, it may cause an accident, for example, causing harm to pedestrians on the ground; therefore, how to reduce the risk of pedestrians on the ground being harmed by drones when the drone is flying has become an urgent problem to be solved. Summary of the invention

[0003] In view of the above technical problems, the technical solution adopted by the present invention is:

[0004] According to a first aspect of the present application, a method for adjusting the flight speed of a drone is provided, the method comprising the following steps:

[0005] S100, obtaining a target image corresponding to a target area; wherein the target area is an area including a number of human bodies, and the target image is obtained by taking an image of a preset camera of a target drone; the target image corresponds to a rectangular coordinate system QT.

[0006] S200, dividing the target image into a number of adjacent sub-regions to obtain a sub-region list W = (W1, W2, ..., W i , …, W n );i=1,2,…,n;where W i is the i-th sub-region corresponding to the target image, and n is the number of sub-regions corresponding to the target image.

[0007] S300, obtaining the human body density corresponding to each sub-region to obtain an initial human body density set ω=(ω1, ω2, ..., ω i ,…,ω n ), where ω i W i The corresponding human body density; ω i =N i / S i ; N i W i The number of human images in S i W i Area in QT.

[0008] S400, determining the sub-regions corresponding to the first m largest human body densities in ω as target sub-regions.

[0009] S500, according to the coordinates of each human body image in each target sub-region, determine the target point coordinates corresponding to each target sub-region to obtain a target point coordinate list α=(α1, α2, ..., α j , …, α m ), where α j Get the target point coordinates for the jth target sub-region; α j =(x j ,y j ); x j is α j The corresponding target point's X-axis coordinate in QT, y j is α j The Y-axis coordinate of the corresponding target point in QT.

[0010] S600, determining the target point corresponding to each target point coordinate in α as the initial clustering centroid, clustering all human body images to obtain a cluster list β = (β1, β2, ..., β j , …, β m ), j = 1, 2, ..., m; where β j is α j Corresponding clusters; each cluster corresponds to a target cluster centroid.

[0011] S700, obtaining the coordinates of the target cluster centroid of each cluster in β in QT to obtain a cluster centroid coordinate list Z = (Z1, Z2, ..., Z j , …, Z m ), where Z j β j The coordinates of the centroid of the target cluster; Z j =(Z j,x , Z j,y );Z j,x β j The X-axis coordinate of the centroid of the target cluster in QT, Z j,y β j The Y-axis coordinate of the target cluster centroid in QT.

[0012] S800, according to Z, determine the reference point coordinates C corresponding to the target image = (C x , C y ), where C x =1 / m×∑ m j= 1Z j,x , C x =1 / m×∑ m j=1 Z j,y .

[0013] S900, convert C into the latitude and longitude coordinates C' in the world coordinate system = (C lon , C lat ), where C lon is the longitude of the reference point corresponding to the target image in the world coordinate system, C lat is the latitude of the reference point corresponding to the target image in the world coordinate system.

[0014] S1000: If the target UAV has not reached the circular area with C' as the center, and the current horizontal flight speed of the target UAV V0≤V Y , then V0 is adjusted to the first target flight speed V1; where V1>V Y ; V Y is the flight speed threshold corresponding to the current position of the target UAV.

[0015] According to another aspect of the present application, a non-transitory computer-readable storage medium is also provided, in which at least one instruction or at least one program is stored, and the at least one instruction or at least one program is loaded and executed by a processor to implement the above-mentioned drone flight speed adjustment method.

[0016] According to another aspect of the present application, an electronic device is provided, including a processor and the above-mentioned non-transitory computer-readable storage medium.

[0017] The present invention has at least the following beneficial effects:

[0018] The method for adjusting the flight speed of a drone of the present invention divides a target image into a plurality of adjacent sub-areas, obtains the human body density corresponding to each sub-area, and determines m target sub-areas according to the human body density corresponding to each sub-area; determines the target point coordinates corresponding to each target sub-area according to the coordinates of each human body image in each target sub-area, determines the target point corresponding to each target point coordinate in α as the initial clustering centroid, clusters all human body images to obtain m clusters, determines the reference point coordinates C corresponding to the target image according to the target clustering centroid of each cluster, and converts C into the latitude and longitude coordinates C' in the world coordinate system; if the target drone does not reach the circular area with C' as the center, and the current horizontal flight speed V0≤V Y , then V0 is adjusted to the first target flight speed V1, and V1>V Y Thus, when a target UAV fails, the target UAV will not fall into the circular area with C' as the center, thereby greatly reducing the probability of falling into the crowd and improving the safety of pedestrians on the ground.

[0019] Furthermore, when determining the ground crowd area, the human density corresponding to each sub-area is combined so that the longitude and latitude coordinates corresponding to the reference point coordinates finally determined are closer to the densely populated area, thereby preventing the drone from falling into the area with a high human density, further reducing the probability of the drone falling into a dense crowd, and improving the safety of pedestrians on the ground. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] 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.

[0021] Figure 1 The present invention provides a flowchart of a method for adjusting the flight speed of a UAV. DETAILED DESCRIPTION

[0022] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.

[0023] It should be noted that various aspects of the embodiments within the scope of the appended claims are described below. It should be apparent that the aspects described herein may be embodied in a wide variety of forms, and any specific structure and / or function described herein is merely illustrative. Based on the present disclosure, it should be understood by those skilled in the art that an aspect described herein may be implemented independently of any other aspect, and two or more of these aspects may be combined in various ways. For example, any number of aspects described herein may be used to implement a device and / or practice a method. In addition, other structures and / or functionalities other than one or more of the aspects described herein may be used to implement this device and / or practice this method.

[0024] The following will refer to Figure 1 The flow chart of the UAV flight speed adjustment method introduces a UAV flight speed adjustment method.

[0025] The method for adjusting the flight speed of a UAV comprises the following steps:

[0026] S100, obtaining a target image corresponding to a target area; wherein the target area is an area including a number of human bodies, and the target image is obtained by taking an image of a preset camera of a target drone; the target image corresponds to a rectangular coordinate system QT.

[0027] In this embodiment, the target drone is preset with an optical sensor and an infrared sensor. For example, the optical sensor is a camera that can take images of the ground, and the infrared sensor can detect whether there is a human body on the ground. At the same time, the target drone is also preset with an altimeter and a GPS positioning device, which can obtain the altitude and longitude and latitude information of the target drone in real time. It should be noted that the target drone collects images of the ground in real time through a preset optical sensor. When a human body is detected, it is determined as the starting image corresponding to the target area, and then the ground image is continuously taken until there is no human body, and the area where the human body continuously exists on the ground is determined as the target area. Through the existing image stitching technology, the target image corresponding to the target area can be obtained.

[0028] In this embodiment, after obtaining the target image, a corresponding rectangular coordinate system QT is established in combination with the target image so that the target image is located in the first quadrant of the rectangular coordinate system to facilitate the subsequent calculation of the coordinates of the pixel points in the target image.

[0029] S200, dividing the target image into a number of adjacent sub-regions to obtain a sub-region list W = (W1, W2, ..., W i , …, W n );i=1,2,…,n;where W i is the i-th sub-region corresponding to the target image, and n is the number of sub-regions corresponding to the target image.

[0030] In this embodiment, the target image can be divided into several adjacent sub-areas by adding a grid on the target image. The grid can be a square or a rectangle. It can be understood that each sub-area on the target image corresponds to an actual area on the ground. There is a proportional relationship between the size of the target image and the size of the target area. According to the proportional relationship and the size of each sub-area, it can be determined that the sub-area corresponds to the actual size in the target area.

[0031] S300, obtaining the human body density corresponding to each sub-region to obtain an initial human body density set ω=(ω1, ω2, ..., ω i ,…,ω n ), where ω i W i The corresponding human body density; ω i =N i / S i ; N i W iThe number of human images in S i W i Area in QT.

[0032] In this embodiment, each sub-region includes a number of human body images. By acquiring the number of human body images in each sub-region and the pixel area of ​​the corresponding sub-region, the human body density of the corresponding sub-region can be obtained.

[0033] S400, determining the sub-regions corresponding to the first m largest human body densities in ω as target sub-regions.

[0034] In this embodiment, all human body densities in ω may be first arranged in descending order, and then the subregions corresponding to the first m human body densities may be determined as target subregions; for example, m=5, and 5 target subregions may be determined.

[0035] S500, according to the coordinates of each human body image in each target sub-region, determine the target point coordinates corresponding to each target sub-region to obtain a target point coordinate list α=(α1, α2, ..., α j , …, α m ), where α j Get the target point coordinates for the jth target sub-region; α j =(x j ,y j ); x j is α j The corresponding target point's X-axis coordinate in QT, y j is α j The Y-axis coordinate of the corresponding target point in QT.

[0036] In this embodiment, α j Obtained through the following steps:

[0037] S510, obtaining the coordinates of each human body image in the j-th target sub-region to obtain a human body image coordinate list L corresponding to the j-th target sub-region j =(L j,1 , L j,2 , …, L j,q , …, L j,f(j) ), q = 1, 2, ..., f(i); where L j,q is the coordinate of the qth human image in the jth target sub-region in QT, f(j) is the number of human images in the jth target sub-region; L j,q =(xL j,q ,yL j,q );xL j,q For L j,q is the X-axis coordinate of the qth human image in the jth target sub-region in QT, yLj,q is the Y-axis coordinate of the qth human image in the jth target sub-region in QT.

[0038] It can be understood that, since the number of human body images in each target sub-region is different in this embodiment, in this embodiment, f(j) does not refer to a specific function or function result value, but refers to a possible value that varies with the specific value of j. For example, when j=1, f(j)=30; when j=2, f(j)=40; when j=3, f(j)=30.

[0039] S520, according to L j,q , we get α j =(x j ,y j ), where x j =1 / f(j)×∑ f(j) q=1 xL j,q ,y j =1 / f(j)×∑ f(j) q=1 y j,q .

[0040] Furthermore, L j,q Obtained through the following steps:

[0041] S511, obtaining a marking frame TY of the qth human body image in the jth target area j,q Coordinate information of BK j,q =(BK j,q _xmin, BK j,q _xmax, BK j,q _ymin, BK j,q _ymax); where BK j,q _xmin is TY j,q The smallest X-axis coordinate in QT, BK j,q _xmax is TY j,q The maximum X-axis coordinate in QT, BK j,q _ymin is TY j,q The smallest Y-axis coordinate in QT, BK j,q _ymax is TY j,q The maximum Y coordinate in QT.

[0042] S512, according to BK j,q , determine L j,q =(xL j,q ,yL j,q ), where xL j,q =(BK j,q _xmin+BKj,q _xmax) / 2;yL j,q =(BK j,q _ymin+BK j,q _ymax) / 2.

[0043] In this embodiment, for any target sub-region, the coordinates of the four vertices of the target sub-region in QT can be obtained, and then compared with the coordinates of each human body image, so as to determine the number of human body images contained in the target sub-region; the area of ​​the target sub-region can be a pixel area, or the pixel area can be converted into the actual area corresponding to the ground.

[0044] S600, determining the target point corresponding to each target point coordinate in α as the initial clustering centroid, clustering all human body images to obtain a cluster list β = (β1, β2, ..., β j , …, β m ), j = 1, 2, ..., m; where β j is α j Corresponding clusters; each cluster corresponds to a target cluster centroid.

[0045] In this embodiment, the existing K-means clustering algorithm is used to cluster all human body images, as follows:

[0046] Calculate the Euclidean distance between any initial sub-region other than the target sub-region and the m target sub-regions, and obtain m Euclidean distances. Obtain the smallest Euclidean distance among the m Euclidean distances, and divide all human images in the initial sub-region into the cluster corresponding to the target sub-region corresponding to the smallest Euclidean distance. After clustering is completed, calculate whether the cluster centroid of each cluster changes. If it changes, continue clustering until the cluster centroid of each cluster does not change, thereby obtaining m clusters.

[0047] The above steps result in m clusters, each of which corresponds to a target cluster centroid, which can be understood as the center of the cluster.

[0048] S700, obtaining the coordinates of the target cluster centroid of each cluster in β in QT to obtain a cluster centroid coordinate list Z = (Z1, Z2, ..., Z j , …, Z m ), where Z j β j The coordinates of the centroid of the target cluster; Z j =(Z j,x , Z j,y );Z j,x β j The X-axis coordinate of the centroid of the target cluster in QT, Z j,y β jThe Y-axis coordinate of the target cluster centroid in QT.

[0049] S800, according to Z, determine the reference point coordinates C corresponding to the target image = (C x , C y ), where C x =1 / m×∑ m j= 1Z j,x , C x =1 / m×∑ m j=1 Z j,y .

[0050] In this embodiment, the mean of the coordinates of the target clustering centroids of the m clusters is determined as the reference point coordinate C corresponding to the target image, so that the pixel point corresponding to C is close to the sub-region with a higher human body density, and it is more reasonable to use the pixel point corresponding to C to represent the target image.

[0051] S900, convert C into the latitude and longitude coordinates C' in the world coordinate system = (C lon , C lat ), where C lon is the longitude of the reference point corresponding to the target image in the world coordinate system, C lat is the latitude of the reference point corresponding to the target image in the world coordinate system.

[0052] In this embodiment, the flight status data of the target UAV includes the flight direction of the target UAV, and converting C into the latitude and longitude coordinates C' in the world coordinate system includes the following steps:

[0053] S910, calculating the azimuth of the reference point coordinates.

[0054] The azimuth is the angle between the current reference point coordinates and the target drone in the world coordinate system. At this time, the reference point coordinates are established based on QT, which is divided into two coordinate axes: horizontal and vertical. The positive infinity direction of the vertical direction of QT is the direction of the drone's nose, and the positive infinity direction of the horizontal direction is the direction of the drone's horizontal displacement to the right. The world coordinate system is a coordinate system with three directions: due north, due east, and vertical to the surface downward. The target drone needs to convert its yaw angle and the angle of the reference point coordinates in pixel coordinates into the azimuth in the world coordinate system.

[0055] The angle between the reference point coordinates C and the origin of QT in the pixel coordinate system plus the yaw angle of the target drone at this time can be used to obtain the azimuth of the target drone; therefore, it is necessary to first calculate the angle between the reference point coordinates and the origin of QT; the azimuth is the direction angle between the reference point coordinates and the geographic coordinate system.

[0056] S920, convert the reference point coordinates into longitude and latitude coordinates.

[0057] S921, calculate the actual distance between the reference point coordinates and the target UAV dis = (dis x 2 +dis y 2 ) 1 / 2 ; Among them, dis x is the horizontal distance between the reference point coordinates and the target UAV, dis y is the vertical distance between the reference point coordinates and the target UAV.

[0058] S922, after obtaining the azimuth and actual distance of the reference coordinates, the longitude and latitude coordinates of the reference point can be determined in combination with the current longitude and latitude coordinates of the drone:

[0059] dis lon =lon+dis×sin(angle) / 111000×cos(lat×π / 180); where dis lon is the longitude value of the reference point coordinates, lon is the longitude value of the target drone, angle is the azimuth of the reference point coordinates, dis is the actual distance between the target drone and the reference point coordinates, and lat is the latitude value of the target drone. Longitude and latitude are in degrees, minutes, and seconds, so the distance value needs to be converted into degrees, minutes, and seconds. One degree of latitude corresponds to 111 kilometers, and the longitude will change according to the change of latitude. Therefore, 111000 in the formula needs to be multiplied by the cosine value of the latitude to get the corresponding value.

[0060] dis lat = lat + dis × sin (angle) / 111000; where dis lat is the latitude value of the reference coordinates, lat is the latitude value of the target drone, dis is the actual distance between the target drone and the reference point coordinates, angle is the azimuth of the reference point coordinates, and one degree of latitude is 111 kilometers on any surface of the earth.

[0061] S1000: If the target UAV has not reached the circular area with C' as the center, and the current horizontal flight speed of the target UAV V0≤V Y , then V0 is adjusted to the first target flight speed V1; where V1>V Y ; V Y is the flight speed threshold corresponding to the current position of the target UAV.

[0062] In this embodiment, after determining C', the coordinates of the target UAV in QT need to be converted into actual longitude and latitude coordinates; the longitude and latitude coordinates of the target UAV can also be directly obtained through the GPS module of the target UAV; then it is determined whether the target UAV is in a circular area with C' as the center, and the radius of the circular area is determined by the following steps:

[0063] S1021, obtain the distance between the latitude and longitude coordinates of the target cluster centroid of each cluster in β and C' to obtain a distance list D = (D1, D2, ..., D p , …, D m ), p = 1, 2, ..., m; D p is the distance between the latitude and longitude coordinates of the target cluster centroid of the p-th cluster and C'.

[0064] S1022, obtaining a target distance DS=MAX(D); wherein MAX() is a preset maximum value function.

[0065] S1023, determine DS as r.

[0066] In this embodiment, the circular area with C' as the center and r as the radius can cover the area with a high human density, thereby greatly reducing the probability of the target drone falling into a high-density crowd and improving the safety of pedestrians on the ground.

[0067] Furthermore, V Y Determine by following these steps:

[0068] S1010, obtaining the current flight altitude h of the target UAV and the distance d between the latitude and longitude coordinates of the target UAV and C'.

[0069] S1020, based on h and d, determine V Y =(d+r) / (2×h / g) 1 / 2 ; Where r is the radius of the circular area with the position corresponding to C' as the center; g is the gravitational acceleration.

[0070] In this embodiment, if a drone fails at a height of h, the time it takes for the target drone to fall freely to the ground is (2×h / g) 1 / 2 If the target UAV currently reaches the circular area, then the distance d between the target UAV and the position corresponding to C' is obtained. d can be obtained by the existing great circle distance formula, which will not be elaborated here.

[0071] It should be noted that, in this embodiment, V Y is the flight speed threshold corresponding to the current position of the target UAV, that is, V Y It will change with the position of the target drone. When the drone is in different positions, the corresponding VY different.

[0072] It should be noted that d+r is the maximum distance that the target drone passes through the circular area. If the target drone’s current horizontal flight speed V0≤V Y At this time, if the target drone fails, the target drone will have a probability of falling into the circular area, and the circular area is an area with a high human density; therefore, it is necessary to adjust the V0 of the target drone to V1, and V1>V Y ;Therefore, when a drone malfunctions, it can be ensured that the drone will not fall into the circular area, thereby greatly reducing the chance of falling into ground areas with a high human density and improving the safety of pedestrians on the ground.

[0073] Furthermore, after step S1000, the method further includes the following steps:

[0074] S1100: If the target UAV has not reached the circular area with C' as the center, and the current horizontal flight speed of the target UAV V0>V Y Then maintain the current horizontal flight speed V0 of the target UAV.

[0075] In this embodiment, if the target UAV does not reach the circular area with C' as the center, since V0>V Y ,Therefore, even if the target UAV fails, the target UAV will fall outside the circular area.

[0076] Furthermore, after step S1100, the method further includes the following steps:

[0077] S1200, if the target UAV reaches the circular area with C' as the center, and the target UAV does not pass through the auxiliary point on the flight path, then obtain the current horizontal flight speed V0 of the target UAV; wherein the auxiliary point on the flight path is the intersection of the auxiliary line corresponding to C' and the flight path, and the auxiliary line corresponding to C' is a straight line that passes through the position corresponding to C' and is perpendicular to the flight path.

[0078] S1300, if V0≤V Y , then adjust V0 to the second target flight speed V2; otherwise, maintain the current horizontal flight speed V0 of the target UAV; where V2>(d+r) / (2×h / g) 1 / 2 .

[0079] In this embodiment, after the target UAV reaches the circular area with C' as the center, there will be two situations. The first situation is that the target UAV does not pass through the auxiliary point on the flight path, that is, the target UAV does not fly over the front half of the circular area; at this time, the distance used to calculate V2 should be d+r; therefore, even if the target UAV fails, the target UAV will fall outside the circular area.

[0080] Furthermore, after step S1000, the method further includes the following steps:

[0081] S1400, if the target UAV reaches the circular area with C' as the center, and the target UAV has passed through the auxiliary point on the flight path, then obtain the current horizontal flight speed V0 of the target UAV; wherein the auxiliary point on the flight path is the intersection of the auxiliary line corresponding to C' and the flight path, and the auxiliary line corresponding to C' is a straight line passing through the position corresponding to C' and perpendicular to the flight path;

[0082] S1500, if V0≤V Y , then V0 is adjusted to the third target flight speed V3; otherwise, the current horizontal flight speed V0 of the target UAV is maintained; where V Y =(rd) / (2×h / g) 1 / 2 ; V3>(rd) / (2×h / g) 1 / 2 .

[0083] In this embodiment, after the target UAV reaches the circular area with C' as the center, the second situation that exists is that the target UAV has passed through the auxiliary point on the flight path, that is, the target UAV has flown over the front half of the circular area and is in the back half of the circular inner area; at this time, the distance used to calculate V2 should be rd; thereby, the V3 of the target UAV does not need to be too large to reduce the probability of the target UAV malfunctioning; at the same time, even if the target UAV malfunctions at this time, the target UAV will fall outside the circular area; thereby improving the safety of pedestrians on the ground.

[0084] The method for adjusting the flight speed of a drone of this embodiment divides the target image into several adjacent sub-areas, obtains the human body density corresponding to each sub-area, and determines m target sub-areas according to the human body density corresponding to each sub-area; determines the target point coordinates corresponding to each target sub-area according to the coordinates of each human body image in each target sub-area, determines the target point corresponding to each target point coordinate in α as the initial clustering centroid, clusters all human body images to obtain m clusters, determines the reference point coordinates C corresponding to the target image according to the target clustering centroid of each cluster, and converts C into the latitude and longitude coordinates C' in the world coordinate system; if the target drone has not reached the circular area with C' as the center, and the current horizontal flight speed V0≤VY , then V0 is adjusted to the first target flight speed V1, and V1>V Y Thus, when a target UAV fails, the target UAV will not fall into the circular area with C' as the center, thereby greatly reducing the probability of falling into the crowd and improving the safety of pedestrians on the ground.

[0085] In addition, when determining the ground crowd area, the human density corresponding to each sub-area is combined so that the latitude and longitude coordinates corresponding to the final reference point coordinates are closer to the densely populated area, avoiding the drone from falling into the area with a high human density, further reducing the probability of the drone falling into a dense crowd and improving the safety of pedestrians on the ground.

[0086] In addition, although the steps of the method in the present disclosure are described in a specific order in the drawings, this does not require or imply that the steps must be performed in this specific order, or that all the steps shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps, etc.

[0087] An embodiment of the present invention also provides a non-transitory computer-readable storage medium, which can be set in an electronic device to store at least one instruction or at least one program related to implementing a method in a method embodiment. The at least one instruction or the at least one program is loaded and executed by the processor to implement the method provided in the above embodiment.

[0088] The program product may employ any combination of one or more readable media; the readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination thereof. More specific examples of readable storage media (a non-exhaustive list) include: an electrical connection with one or more wires, a portable 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.

[0089] Computer readable signal media may include data signals propagated in baseband or as part of a carrier wave, which carry readable program code; such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Readable signal media may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.

[0090] The program code embodied on the readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the foregoing.

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

[0092] An embodiment of the present invention further provides an electronic device, comprising a processor and the aforementioned non-transitory computer-readable storage medium.

[0093] The electronic device of this embodiment of the present application is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.

[0094] The electronic device is presented in the form of a general-purpose computing device, and the components of the electronic device may include but are not limited to: the at least one processor mentioned above, the at least one storage device mentioned above, and a bus connecting different system components (including storage devices and processors).

[0095] The storage stores program codes, which can be executed by the processor, so that the processor executes the steps in various embodiments described in this specification.

[0096] The memory may include readable media in the form of volatile memory, such as random access memory (RAM) and / or cache memory, and may further include read only memory (ROM).

[0097] The storage may also include a program / utility having a set (at least one) of program modules, such program modules including but not limited to: an operating system, one or more application programs, other program modules and program data, each of which or some combination may include the implementation of a network environment.

[0098] The bus may represent one or more of several types of bus structures including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, a processor, or a local bus using any of a variety of bus architectures.

[0099] The electronic device may also communicate with one or more external devices (e.g., keyboards, pointing devices, Bluetooth devices, etc.), may communicate with one or more devices that enable a user to interact with the electronic device, and / or may communicate with any device (e.g., routers, modems, etc.) that enables the electronic device to communicate with one or more other computing devices. Such communication may be performed through an input / output (I / O) interface. Furthermore, the electronic device may also communicate with one or more networks (e.g., local area networks (LANs), wide area networks (WANs), and / or public networks, such as the Internet) through a network adapter. The network adapter communicates with other modules of the electronic device through a bus. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device, including but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, etc.

[0100] Through the description of the above implementation, it is easy for those skilled in the art to understand that the example implementation described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (which can be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the implementation of the present disclosure.

[0101] An embodiment of the present invention further provides a computer program product, which includes program code. When the program product is run on an electronic device, the program code is used to enable the electronic device to execute the steps of the method according to various exemplary embodiments of the present invention described above in this specification.

[0102] Although some specific embodiments of the present invention have been described in detail by way of example, it will be appreciated by those skilled in the art that the above examples are for illustration only and are not intended to limit the scope of the present invention. It will also be appreciated by those skilled in the art that various modifications may be made to the embodiments without departing from the scope and spirit of the present invention. The scope of the present invention is defined by the appended claims.

Claims

1. A method for adjusting the flight speed of an unmanned aerial vehicle, characterized in that: The method comprises the following steps: S100, obtaining a target image corresponding to a target area; wherein the target area is an area including a number of human bodies, and the target image is obtained by taking an image of a preset camera of a target drone; the target image corresponds to a rectangular coordinate system QT; S200, dividing the target image into a number of adjacent sub-regions to obtain a sub-region list W = (W1, W2, ..., W i , …, W n ), i=1, 2, …, n, where W i is the i-th sub-region corresponding to the target image, and n is the number of sub-regions corresponding to the target image; S300, obtaining the human body density corresponding to each sub-region to obtain an initial human body density set ω=(ω1, ω2, …, ω i ,…,ω n ), where ω i W i The corresponding human body density; ω i =N i / S i ; N i W i The number of human images in S i W i Area in QT; S400, determining the sub-regions corresponding to the first m largest human body densities in ω as target sub-regions; S500, according to the coordinates of each human body image in each target sub-region, determine the target point coordinates corresponding to each target sub-region to obtain a target point coordinate list α=(α1, α2, ..., α j , …, α m ), where α j Get the target point coordinates for the jth target sub-region; α j =(x j ,y j ); x j is α j The corresponding target point's X-axis coordinate in QT, y j is α j The Y-axis coordinate of the corresponding target point in QT; S600, determining the target point corresponding to each target point coordinate in α as the initial clustering centroid, clustering all human body images to obtain a cluster list β=(β1, β2, ..., β j , …, β m ), j = 1, 2, …, m; where β j is α j Corresponding clusters; each cluster corresponds to a target cluster centroid; S700, obtaining the coordinates of the target cluster centroid of each cluster in β in QT to obtain a cluster centroid coordinate list Z=(Z1, Z2, ..., Z j , …, Z m ), where Z j β j The coordinates of the centroid of the target cluster; Z j =(Z j,x , Z j,y );Z j,x β j The X-axis coordinate of the centroid of the target cluster in QT, Z j,y β j The Y-axis coordinate of the centroid of the target cluster in QT; S800, according to Z, determine the reference point coordinates C corresponding to the target image = (C x , C y ), where C x =1 / m×∑ m j=1 Z j,x , C y =1 / m×∑ m j=1 Z j,y ; S900, convert C into the latitude and longitude coordinates C'=(C lon , C lat ), where C lon is the longitude of the reference point corresponding to the target image in the world coordinate system, C lat is the latitude of the reference point corresponding to the target image in the world coordinate system; S1000: If the target UAV has not reached the circular area with C' as the center, and the current horizontal flight speed of the target UAV V0≤V Y , then V0 is adjusted to the first target flight speed V1; where V1>V Y ; V Y is the flight speed threshold corresponding to the current position of the target UAV.

2. The method for adjusting the flight speed of a drone according to claim 1, characterized in that: α j Obtained through the following steps: S510, obtaining the coordinates of each human body image in the j-th target sub-region to obtain a human body image coordinate list L corresponding to the j-th target sub-region j =(L j,1 , L j,2 , …, L j,q , …, L j,f(j) ), q=1, 2, …, f(i); where L j,q is the coordinate of the qth human image in the jth target sub-region in QT, f(j) is the number of human images in the jth target sub-region; L j,q =(xL j,q ,yL j,q );xL j,q For L j,q is the X-axis coordinate of the qth human image in the jth target sub-region in QT, yL j,q is the Y-axis coordinate of the qth human image in the jth target sub-region in QT; S520, according to L j,q , we get α j =(x j ,y j ), where x j =1 / f(j)×∑ f(j) q=1 xL j,q ,y j =1 / f(j)×∑ f(j) q= 1yL j,q .

3. The method for adjusting the flight speed of a drone according to claim 2, characterized in that: L j,q Obtained through the following steps: S511, obtaining a marking frame TY of the qth human body image in the jth target area j,q Coordinate information of BK j,q =(BK j,q _xmin, BK j,q _xmax, BK j,q _ymin, BK j,q _ymax); where BK j,q _xmin is TY j,q The smallest X-axis coordinate in QT, BK j,q _xmax is TY j,q The maximum X-axis coordinate in QT, BK j,q _ymin is TY j,q The smallest Y-axis coordinate in QT, BK j,q _ymax is TY j,q The maximum Y-axis coordinate in QT; S512, according to BK j,q , determine L j,q =(xL j,q ,yL j,q ), where xL j,q =(BK j,q _xmin+BK j,q _xmax) / 2;yL j,q =(BK j,q _ymin+BK j,q _ymax) / 2.

4. The method for adjusting the flight speed of a UAV according to claim 1, characterized in that: V Y Determine by following these steps: S1010, obtaining the current flight altitude h of the target UAV and the distance d between the latitude and longitude coordinates of the target UAV and C'; S1020, based on h and d, determine V Y =(d+r) / (2×h / g) 1 / 2 ; Where r is the radius of the circular area with the position corresponding to C' as the center; g is the gravitational acceleration.

5. The method for adjusting the flight speed of a drone according to claim 4, characterized in that: r is determined by the following steps: S1021, obtain the distance between the latitude and longitude coordinates of the target cluster centroid of each cluster in β and C' to obtain a distance list D=(D1, D2, ..., D p , …, D m ), p = 1, 2, …, m; D p is the distance between the latitude and longitude coordinates of the target cluster centroid of the p-th cluster and C'; S1022, obtaining a target distance DS=MAX(D); wherein MAX() is a preset maximum value function; S1023, determine DS as r.

6. The method for adjusting the flight speed of a UAV according to claim 4, characterized in that: After step S1000, the method further includes the following steps: S1100: If the target UAV has not reached the circular area with C' as the center, and the current horizontal flight speed of the target UAV V0>V Y Then maintain the current horizontal flight speed V0 of the target UAV.

7. The method for adjusting the flight speed of a UAV according to claim 4, characterized in that: After step S1000, the method further includes the following steps: S1200, if the target UAV reaches the circular area with C' as the center, and the target UAV does not pass through the auxiliary point on the flight path, then obtain the current horizontal flight speed V0 of the target UAV; wherein the auxiliary point on the flight path is the intersection of the auxiliary line corresponding to C' and the flight path, and the auxiliary line corresponding to C' is a straight line passing through the position corresponding to C' and perpendicular to the flight path; S1300, if V0≤V Y , then adjust V0 to the second target flight speed V2; otherwise, maintain the current horizontal flight speed V0 of the target UAV; where V2>(d+r) / (2×h / g) 1 / 2 .

8. The method for adjusting the flight speed of an unmanned aerial vehicle according to claim 4, characterized in that: After step S1000, the method further includes the following steps: S1400, if the target UAV reaches the circular area with C' as the center, and the target UAV has passed through the auxiliary point on the flight path, then obtain the current horizontal flight speed V0 of the target UAV; wherein the auxiliary point on the flight path is the intersection of the auxiliary line corresponding to C' and the flight path, and the auxiliary line corresponding to C' is a straight line passing through the position corresponding to C' and perpendicular to the flight path; S1500, if V0≤V Y , then V0 is adjusted to the third target flight speed V3; otherwise, the target UAV's current horizontal flight speed V0 is maintained; where V Y =(rd) / (2×h / g) 1 / 2 ; V3>(rd) / (2×h / g) 1 / 2 .

9. A non-transitory computer-readable storage medium, wherein at least one instruction or at least one program is stored in the storage medium, characterized in that: The at least one instruction or the at least one program is loaded and executed by the processor to implement the drone flight speed adjustment method as described in any one of claims 1-8.

10. An electronic device, characterized in that: The method comprises a processor and the non-transitory computer-readable storage medium of claim 9.

Citation Information

Patent Citations

  • Method for detecting and counting crowd distribution in video based on deep learning

    CN113255430A

  • Method and system for identifying crowd gathering at angle of unmanned aerial vehicle and application of method and system

    CN115880648A