Point cloud display method and apparatus
A point cloud display method includes determining, from a first point cloud, points describing a target object, where the first point cloud describes a surrounding area of a vehicle in which the in-vehicle system is located, and the target object is to be identified by the in-vehicle system, generating a second point cloud based on the points, and displaying the second point cloud.
1. A method implemented by an in-vehicle system, wherein the method comprises:
determining, from a first point cloud, first points describing a target object that is to be identified by the in-vehicle system, wherein the first point cloud describes a surrounding area that surrounds a vehicle, wherein the target object comprises a first object and a second object, and wherein the in-vehicle system is located in the vehicle;
generating a second point cloud based on the first points and through sparsification on a third point cloud that comprises a set of second points that are in a first area and that describe the first object and a set of third points that are in a second area and that describe the second object, wherein a first distance between the first area and the vehicle is greater than a second distance between the second area and the vehicle, and wherein the sparsification comprises sparsification of the set of second points using a first sparsification multiple and sparsification of the set of third points using a second sparsification multiple that is different than the first sparsification multiple; and
displaying the second point cloud.
2. The method of claim 1 , wherein the second point cloud includes the first points, wherein positions of the first points in the second point cloud are the same as positions of the first points in the first point cloud, wherein the method further comprises identifying that a correlation between the target object and the vehicle exceeds a threshold, and wherein the correlation is based on at least one of:
a distance between the target object and the vehicle;
a location of the target object;
information indicated by the target object; or
a speed of the target object.
3. The method of claim 1 , wherein before determining the first points, the method further comprises:
presenting a setting request prompting a driver of the vehicle to set a type of an object comprised in the target object;
receiving a setting response; and
determining, based on the setting response, the type of the object.
4. The method of claim 1 , wherein the first sparsification multiple is less than the second sparsification multiple.
5. The method of claim 1 , further comprising:
obtaining an original point cloud sequence; and
performing sampling on the original point cloud sequence to obtain a first point cloud sequence, wherein the first point cloud is a frame of point cloud in the first point cloud sequence.
6. The method of claim 5 , further comprising:
determining a sampling frequency based on a current scenario of the vehicle; and
further performing sampling on the original point cloud sequence based on the sampling frequency to obtain the first point cloud sequence.
7. The method of claim 1 , further comprising:
identifying that the target object comprises an object outside a road; and
cropping, in response to the identifying, the first point cloud based on a location of a road marking on a map of the surrounding area to obtain third points describing the object outside the road.
8. The method of claim 1 , further comprising:
identifying that the target object comprises a target obstacle on a road;
determining, in response to the identifying, the target obstacle based on location information of the target object or speed information of the target object; and
cropping the first point cloud based on a location of the target obstacle and a size of the target obstacle to obtain fourth points describing the target obstacle.
9. The method of claim 1 , further comprising:
cropping the first point cloud based on first feature information of a first-type target object to obtain a first sub-point cloud describing the first-type target object, wherein the target object comprises the first-type target object and a second-type target object;
cropping the first point cloud based on second feature information of the second-type target object to obtain a second sub-point cloud describing the second-type target object; and
further generating the second point cloud based on the first sub-point cloud and the second sub-point cloud.
10. An apparatus applied to an in-vehicle system, wherein the apparatus comprises:
a memory configured to store instructions;
a processor coupled to the memory, wherein the instructions cause the processor to be configured to:
determine, from a first point cloud, first points describing a target object that is to be identified by the in-vehicle system, wherein the first point cloud describes a surrounding area that surrounds a vehicle, wherein the target object comprises a first object and a second object, and wherein the in-vehicle system is located in the vehicle; and
generate a second point cloud based on the first points and through sparsification on a third point cloud that comprises a set of second points that are in a first area and that describe the first object and a set of third points that are in a second area and that describe the second object, wherein a first distance between the first area and the vehicle is greater than a second distance between the second area and the vehicle, and wherein the sparsification comprises sparsification of the set of second points using a first sparsification multiple and sparsification of the set of third points using a second sparsification multiple that is different than the first sparsification multiple; and
a display coupled to the processor and configured to display the second point cloud.
11. The apparatus of claim 10 , wherein the instructions further cause the processor to be configured to identify that a correlation between the target object and the vehicle exceeds a threshold, and wherein the correlation is based on at least one of:
a distance between the target object and the vehicle;
a location of the target object;
information indicated by the target object; or
a speed of the target object.
12. The apparatus of claim 10 , wherein the instructions further cause the processor to be configured to:
present a setting request prompting a driver of the vehicle to set a type of an object comprised in the target object;
receive a setting response; and
determine, based on the setting response, the type of the object.
13. The apparatus of claim 10 , wherein the first sparsification multiple is less than the second sparsification multiple.
14. The apparatus of claim 10 , wherein the instructions further cause the processor to be configured to:
obtain an original point cloud sequence; and
perform sampling on the original point cloud sequence to obtain a first point cloud sequence, wherein the first point cloud is a frame of point cloud in the first point cloud sequence.
15. The apparatus of claim 14 , wherein the instructions further cause the processor to be configured to:
determine a sampling frequency based on a current scenario of the vehicle; and
further perform sampling on the original point cloud sequence based on the sampling frequency to obtain the first point cloud sequence.
16. The apparatus of claim 10 , wherein the instructions further cause the processor to be configured to:
identify that the target object comprises an object outside a road; and
crop, in response to the identifying, the first point cloud based on a location of a road marking on a map of the surrounding area to obtain third points describing the object outside the road.
17. The apparatus of claim 10 , wherein the instructions further cause the processor to be configured to:
identify that the target object comprises a target obstacle on a road;
determine, in response to the identifying, the target obstacle based on location information of the target object or speed information of the target object; and
crop the first point cloud based on a location of the target obstacle and a size of the target obstacle to obtain fourth points describing the target obstacle.
18. The apparatus of claim 10 , wherein the instructions further cause the processor to be configured to:
crop the first point cloud based on first feature information of a first-type target object to obtain a first sub-point cloud describing the first-type target object, wherein the target object comprises the first-type target object and a second-type target object;
crop the first point cloud based on second feature information of the second-type target object to obtain a second sub-point cloud describing the second-type target object; and
further generate the second point cloud based on the first sub-point cloud and the second sub-point cloud.
19. A computer program product comprising computer-executable instructions that are stored on a non-transitory computer-readable medium and that, when executed by a processor, cause an in-vehicle system to:
determine, from a first point cloud, first points describing a target object that is to be identified by the in-vehicle system, wherein the first point cloud describes a surrounding area that surrounds a vehicle, wherein the target object comprises a first object and a second object, and wherein the in-vehicle system is located in the vehicle;
generate a second point cloud based on the first points and through sparsification on a third point cloud that comprises a set of second points that are in a first area and that describe the first object and a set of third points that are in a second area and that describe the second object, wherein a first distance between the first area and the vehicle is greater than a second distance between the second area and the vehicle, and wherein the sparsification comprises sparsification of the set of second points using a first sparsification multiple and sparsification of the set of third points using a second sparsification multiple that is different than the first sparsification multiple; and
display the second point cloud.
20. The computer program product of claim 19 , wherein the computer-executable instructions further cause the in-vehicle system to identify that a correlation between the target object and the vehicle exceeds a threshold, and wherein the correlation is based on at least one of:
a distance between the target object and the vehicle;
a location of the target object;
information indicated by the target object; or
a speed of the target object.