| CPC G06T 15/06 (2013.01) [G06T 7/13 (2017.01); G06T 2207/20081 (2013.01); G06T 2207/20084 (2013.01)] | 11 Claims |

|
1. A method for generating disorderly stacked parcel images with grabbing tags, comprising:
a step of generating multiple simulative parcels according to pre-acquired true parcel feature data;
a step of disorderly stacking the multiple simulative parcels;
a step of photographing the multiple disorderly stacked simulative parcels, replacing a background of an image obtained by photographing with a selected true logistics scenario image, and performing brightness adjustment on the image with the background having been replaced within a preset brightness adjustment range to obtain a disorderly stacked parcel image of the disorderly stacked parcel images; and
a step of tagging a grabbable parcel in the disorderly stacked parcel image;
wherein, the multiple disorderly stacked simulative parcels are photographed by means of a virtual camera;
the step of tagging the grabbable parcel in the disorderly stacked parcel image comprises:
drawing a segment from a central point of the virtual camera to a current traversal pixel in the disorderly stacked parcel image;
determining a target parcel, that first intersects with the segment, in the disorderly stacked parcel image;
determining a grabbing surface of the target parcel;
determining whether the grabbing surface is a grabbable surface without grabbing obstacles; if so, transforming coordinates of four vertexes of the grabbing surface in a camera coordinate system into coordinates of the four vertexes of the grabbing surface in an image coordinate system; and
tagging an outline of the grabbing surface according to the coordinates of the four vertexes of the grabbing surface in the image coordinate system;
determining whether the grabbing surface is the grabbable surface without the grabbing obstacles comprises:
acquiring multiple pixels from the grabbing surface by uniform sampling;
drawing a segment from each of the multiple pixels to the central point of the virtual camera;
determining whether there is an obstacle on each segment by a ray tracing algorithm;
if there is no obstacle on each segment, determining that the grabbing surface is the grabbable surface; or
otherwise, determining that the grabbing surface is a non-grabbable surface.
|