System and method for object detection and dimensioning
A method for detecting and dimensioning a target object includes: obtaining depth data representing a target object; defining a mask having a structure which decreases in density away from a central point of the mask; overlaying the mask on the depth data and selecting a subset of the depth data comprising data points which contact the mask; detecting a cluster of data points from the subset; detecting, based on the cluster, the target object; and outputting a representation of the target object.
1. A method comprising:
obtaining, from a depth sensor, depth data representing a target object;
defining a mask having a structure which decreases in density away from a central point of the mask;
overlaying the mask on the depth data and selecting a subset of the depth data comprising data points having coordinates which match coordinates of a point of the mask;
detecting a cluster of data points from the subset;
detecting, based on the cluster, the target object; and
determining an object dimension of the target object based on the cluster.
2. The method of claim 1 , wherein the mask comprises an arrangement of lines which decrease in density away from the central point.
3. The method of claim 2 , wherein the lines extend radially from the central point of the mask.
4. The method of claim 1 , wherein overlaying the mask on the depth data comprises aligning the central point with a center of a frame of the depth data.
5. The method of claim 1 , wherein detecting the cluster of data points from the subset comprises:
selecting a starting point from the subset of the depth data, the starting point comprising a closest data point of the subset to the central point of the mask; and
selecting the cluster of data points about the starting point.
6. The method of claim 1 , wherein detecting the target object comprises applying plane and object detection to the detected cluster of data points.
7. The method of claim 1 , wherein detecting the target object comprises:
generating a bounding region for the cluster of data points;
selecting a second subset of the depth data comprising data points contained in the bounding region; and
applying plane and object detection to the second subset of depth data to identify the target object.
8. A device comprising:
a depth sensor configured to obtain depth data representing a target object;
a memory;
a processor interconnected with the depth sensor and the memory, the processor configured to:
obtain, from the depth sensor, depth data representing the target object;
define a mask having a structure which decreases in density away from a central point of the mask;
overlay the mask on the depth data and select a subset of the depth data comprising data points having coordinates which match coordinates of a point of the mask;
detect a cluster of data points from the subset;
detect, based on the cluster, the target object; and
determine an object dimension of the target object based on the cluster.
9. The device of claim 8 , wherein the mask comprises an arrangement of lines which decrease in density away from the central point.
10. The device of claim 9 , wherein the lines extend radially from the central point of the mask.
11. The device of claim 8 , wherein, to overlay the mask on the depth data, the processor is configured to align the central point of the mask with a center of a frame of the depth data.
12. The device of claim 8 , wherein, to detect the cluster of data points from the subset, processor is configured to:
select a starting point from the subset of the depth data, the starting point comprising a closest data point of the subset to the central point of the mask; and
select the cluster of data points about the starting point.
13. The device of claim 8 , wherein to detect the target object, the processor is configured to: apply plane and object detection to the detected cluster of data points.
14. The device of claim 8 , wherein to detect the target object, the processor is configured to:
generate a bounding region for the cluster of data points;
select a second subset of the depth data comprising data points contained in the bounding region; and
apply plane and object detection to the second subset of depth data to identify the target object.
15. A non-transitory computer-readable medium storing a plurality of computer-readable instructions executable by a processor, wherein execution of the instructions configures the processor to:
obtain, from a depth sensor, depth data representing a target object;
define a mask having a structure which decreases in density away from a central point of the mask;
overlay the mask on the depth data and select a subset of the depth data comprising data points having coordinates which match coordinates of a point of the mask;
detect a cluster of data points from the subset;
detect, based on the cluster, the target object; and
determine an object dimension of the target object based on the cluster.
16. The non-transitory computer-readable medium of claim 15 , wherein the mask comprises an arrangement of lines which decrease in density away from the central point.
17. The non-transitory computer-readable medium of claim 16 , wherein the lines extend radially from the central point of the mask.
18. The non-transitory computer-readable medium of claim 15 , wherein, to overlay the mask on the depth data, the instructions configure the processor to: align the central point of the mask with a center of a frame of the depth data.
19. The non-transitory computer-readable medium of claim 15 , wherein, to detect the cluster of data points from the subset, instructions configure the processor to:
select a starting point from the subset of the depth data, the starting point comprising a closest data point of the subset to the central point of the mask; and
select the cluster of data points about the starting point.
20. The non-transitory computer-readable medium of claim 15 , wherein to detect the target object, the instructions configure the processor to: apply plane and object detection to the detected cluster of data points.
21. The non-transitory computer-readable medium of claim 15 , wherein to detect the target object, the instructions configure the processor to:
generate a bounding region for the cluster of data points;
select a second subset of the depth data comprising data points contained in the bounding region; and
apply plane and object detection to the second subset of depth data to identify the target object.
22. The non-transitory computer-readable medium of claim 15 , wherein the instructions further configure the processor to: dimension the target object and output dimensions of the target object.