Disclosure of Invention
The embodiment of the application provides a bag-turning control method, a device and a robot, which are used for dumping out packages in a target packaging bag by grabbing and moving the target packaging bag, so that the automation degree and efficiency of dismounting the packaging bag are improved, and the method is suitable for a box body and a box body with regular shapes and hard shells, and can also be suitable for various types of storage bags with irregular surfaces, curved surfaces, flexible materials and the like.
In a first aspect, an embodiment of the present application provides a method for controlling a reverse packet, where the method includes:
detecting a target packaging bag;
determining N grabbing points on the outer surface of the target packaging bag, wherein N is a natural number;
controlling the gripper to exert acting force on the N grabbing points to grab the target packaging bag;
and controlling the clamp holder to move according to a preset moving direction according to the opening direction of the target packaging bag, so that the object in the target packaging bag is separated from the target packaging bag and poured out, wherein the preset moving direction and the opening direction of the target packaging bag have a preset relative angle.
Adopt the technical scheme of this application embodiment, through selecting N on target package bag surface and snatching the point, snatch the target package bag after according to the direction removal package bag that forms preset relative angle with the opening direction to realized that the robot dismantles the degree of automation and the efficiency of package bag, not only be suitable for shape rule, the hard box body of shell and box etc. can also be applicable to various types of storage bag such as surface irregularity, curved surface, flexible material.
In a possible embodiment, the determining N gripping points on the outer surface of the target packaging bag specifically includes:
obtaining surface area data of the target packaging bag;
determining N grabbing points meeting grabbing conditions according to the surface area of a target packing bag, wherein the grabbing conditions are that the area of a grabbing surface determined by the N grabbing points is not smaller than a preset lowest value of the surface area of the target packing bag.
By adopting the scheme, a large enough grabbing surface can be formed, so that the bag can be grabbed and dumped by applying small force, or the motion planning of the mechanical arm is facilitated.
In a possible embodiment, the determining N gripping points on the outer surface of the target packaging bag specifically includes:
and determining N grabbing points capable of forming the shape of the preset grabbing surface on the surface of the target packaging bag according to the shape of the preset grabbing surface.
By adopting the scheme, the packaging bag has high applicability to various packaging bags of different types, and facilitates the motion planning of the mechanical arm.
In a possible embodiment, the determining N gripping points on the outer surface of the target packaging bag specifically includes:
and determining at least one grabbing point according to the opening direction of the target packaging bag, wherein the at least one grabbing point is positioned in the tail end area of the surface of the target packaging bag opposite to the opening direction.
By adopting the scheme, the grabbing and pouring success rate can be greatly improved.
In a possible embodiment, the controlling the gripper to move according to the preset moving direction according to the opening direction of the target packing bag specifically includes:
detecting that the opening direction is within a preset turning direction range;
the gripper is controlled to move according to the preset moving direction.
Adopt above-mentioned scheme, can be fast with parcel and the separation of target baling bag in the target baling bag to empty the parcel in the target baling bag.
In a possible embodiment, the controlling the gripper to move according to the preset moving direction according to the opening direction of the target packing bag specifically includes:
detecting that the opening direction is not located in a preset ladle-to-ladle direction range;
controlling the holder to turn over the target packaging bag until the opening direction of the target packaging bag is within the preset bag turning direction range;
the gripper is controlled to move according to the preset moving direction.
By adopting the scheme, the opening direction of the target packaging bag can be adjusted by turning the target packaging bag, so that the target packaging bag which is difficult to topple originally is toppled more easily.
In a second aspect, an embodiment of the present application provides a device for controlling a package transfer, including:
the detection unit is used for detecting a target packaging bag;
the processing unit is used for determining N grabbing points on the outer surface of the target packaging bag, wherein N is a natural number;
controlling the gripper to exert acting force on the N grabbing points to grab the target packaging bag;
and controlling the clamp holder to move according to a preset moving direction according to the opening direction of the target packaging bag, so that the object in the target packaging bag is separated from the target packaging bag and poured out, wherein the preset moving direction and the opening direction of the target packaging bag have a preset relative angle.
In a possible implementation, the processing unit is specifically configured to:
obtaining surface area data of the target packaging bag;
determining N grabbing points meeting grabbing conditions according to the surface area of a target packing bag, wherein the grabbing conditions are that the area of a grabbing surface determined by the N grabbing points is not smaller than a preset lowest value of the surface area of the target packing bag.
In a possible implementation, the processing unit is specifically configured to:
and determining N grabbing points capable of forming the shape of the preset grabbing surface on the surface of the target packaging bag according to the shape of the preset grabbing surface.
In a possible implementation, the processing unit is specifically configured to:
and determining at least one grabbing point according to the opening direction of the target packaging bag, wherein the at least one grabbing point is positioned in the tail end area of the surface of the target packaging bag opposite to the opening direction.
By adopting the scheme, the grabbing and pouring success rate can be greatly improved.
In a possible implementation, the processing unit is specifically configured to:
and controlling the gripper to move according to the preset moving direction when the opening direction is detected to be within the preset ladle-to-ladle direction range.
In a possible implementation, the processing unit is specifically configured to:
detecting that the opening direction is not located in a preset ladle-to-ladle direction range;
controlling the holder to turn over the target packaging bag until the opening direction of the target packaging bag is within the preset bag turning direction range;
the gripper is controlled to move according to the preset moving direction.
In a third aspect, an embodiment of the present application provides a device for controlling a package transfer, including: a processor and a memory. Wherein the memory is used for storing programs, and the processor calls the programs stored in the memory to execute the method according to any one of the possible embodiments of the first aspect.
In a fourth aspect, the present application provides a computer-readable storage medium, which stores computer program code, and when the computer program code runs on a computer, the computer is caused to execute the method according to any one of the possible implementation manners of the first aspect.
In a fifth aspect, an embodiment of the present application provides a computer program product, where the computer program product includes: computer program code which, when run on a computer, causes the computer to perform the method of any of the possible embodiments of the first aspect as described above.
In a sixth aspect, the present application provides a computer program which, when run on a computer, causes the computer to perform the method according to any one of the possible embodiments of the first aspect.
In a seventh aspect, an embodiment of the present application provides a robot, including a sensor, a gripper, a robot arm, a memory, and a processor;
the sensor is used for detecting objects including the target packaging bag;
the gripper is used for gripping a target packaging bag;
the mechanical arm is used for moving the gripper;
the memory is used for storing programs;
the processor is configured to call a program stored in the memory to perform a method according to any one of the possible embodiments of the first aspect.
Detailed Description
The present application will be described in further detail with reference to the following drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the relevant invention and not restrictive of the invention. It should be noted that, for convenience of description, only the portions related to the related invention are shown in the drawings.
It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict.
Please refer to fig. 1, which is a schematic structural diagram of a robot according to an embodiment of the present application; as shown in fig. 1, the robot 100 mainly includes:
a sensor 101, a gripper 102, a robotic arm 103, a memory 104, and a processor 105.
Wherein the sensor 101 is used to detect objects including the target bag.
The gripper 102 is used to grasp the target bag.
The robot arm 103 is used to move the gripper 102.
Specifically, the gripper 102 is used to grip N gripping points on the surface of the target bag to grasp and move the target bag. The arrangement of the gripper 102 and the robot arm 103 can be flexibly selected among various combinations as needed. For example, a plurality of robot arms 103 may be provided, each robot arm 103 carrying one or more grippers 102; alternatively, only one robot arm 103 may be provided, and one or more grippers 102 may be mounted on the robot arm 103; the gripper 102 may be configured as one or more mechanical jaws, grippers, flexible bag chucks, or the like, corresponding to different gripping points.
The memory 104 is used to store programs.
The processor 105 is configured to call a program stored in the memory, so as to control the gripper 102 to perform grabbing and moving operations on the target packaging bag, and pour out the packages in the target packaging bag.
Referring to fig. 2, an embodiment of the present application provides a method for controlling bag dumping, so as to dump out packages in a target packaging bag by grabbing and moving the target packaging bag, thereby improving the automation degree and efficiency of bag dumping, and being applicable to not only a box body and a box body with regular shapes, but also various types of storage bags with irregular surfaces, curved surfaces, flexible materials, and the like.
Before the method shown in fig. 4 is used for the reverse packet control, the following contents need to be preset:
first, the opening direction range of the target packaging bag.
When the opening direction of the target packing bag is within a specific range, for example, in a horizontal or downward state (for example, the opening direction is within an angle range of [180 °, 360 ° ] to the horizontal), it is possible to very easily achieve the separation of the target packing bag from the bag package by moving the target packing bag by selecting an appropriate moving direction, and therefore, the opening direction range of the target packing bag can be very flexibly set by the user as desired.
Second, the relative angle of the moving direction of the clamper to the opening direction.
When the opening direction of the target packaging bag is in a horizontal or downward state, the packaging bag can be separated from the bag only by applying displacement which forms a certain relative angle with the opening direction to the target packaging bag, and therefore, the range of the moving direction of the clamp holder can be set at a certain angle according to the opening direction of the target packaging bag set by a user. For example, the user may set the moving direction of the gripper directly opposite to the opening direction of the objective bag (i.e., the relative angle is 180 °), as desired.
The preset content may be stored in a memory inside the robot or in a network server accessible by the robot.
Referring to fig. 2, an embodiment of the present application provides a method for controlling a reverse packet, including:
step 200: detecting a target packaging bag;
the target packaging bag can be a bag with any surface, for example, the bag can be a box body or a box body with a hard shell and a regular shape, and can also be a bag with an irregular surface, a curved surface, a flexible surface and the like and provided with a package.
In particular, the target bag may be detected by a visual sensor, or an identification code reading device, but other detection devices may also be used.
It should be understood that the above-mentioned detection method is only an example, and the embodiment of the present application does not limit the detection method of the target bag.
Step 210: determining N grabbing points on the outer surface of the target packaging bag, wherein N is a natural number;
specifically, the determination of the N gripping points on the outer surface of the target packaging bag may take the following forms, but is not limited to:
mode 1:
obtaining surface area data of the target packaging bag;
determining N grabbing points meeting grabbing conditions according to the surface area of a target packing bag, wherein the grabbing conditions are that the area of a grabbing surface determined by the N grabbing points is not smaller than a preset lowest value of the surface area of the target packing bag.
By adopting the mode 1, a large enough gripping surface can be formed, which is beneficial to gripping the bag and dumping the bag by applying smaller force or is convenient for the motion planning of the mechanical arm.
Mode 2:
and determining N grabbing points capable of forming the shape of the preset grabbing surface on the surface of the target packaging bag according to the shape of the preset grabbing surface.
By adopting the mode 2, the packaging bag has higher applicability to various different types of packaging bags.
Mode 3:
and determining at least one grabbing point according to the opening direction of the target packaging bag, wherein the at least one grabbing point is positioned in the tail end area of the surface of the target packaging bag opposite to the opening direction.
The determination of the end region can be model training in advance, for example, deep learning is performed on various postures of the full-filling packaging bag, and a reasonable end region is determined by using a mathematical model so as to adapt to optimal dumping and bag clearing under different postures; or a packaging bag for several common specifications, each of which is fixed at the end region, for example, the size of the packaging bag can be directly set to 10 multiplied by 10cm according to different specifications; 15 x 20 cm; 20X 30cm, etc.
By adopting the scheme, the grabbing and pouring success rate can be greatly improved.
The above-listed various modes can be used alone or in combination as necessary, for example:
assuming that N is 3, that is, 3 grabbing points are selected on the outer surface of the target packaging bag, the shape of the 3 grabbing points may satisfy any one or more of the above manners:
for mode 1, the selected 3 grabbing points may form a triangle A1The triangle A1Can be set to satisfy the grabbing condition of mode 1, for example, assuming that the preset minimum value is 1/4, the area of triangle A is set to satisfy1Is not less than 1/4 of the surface area of the target packaging bag, the selected 3 grabbing points are all effective;
for the mode 2, the selected 3 grabbing points can form a triangle A2If the preset grabbing surface is a triangle, the triangle A2The shape of (2) is the preset shape of the grabbing surface, in this case, 3 grabbing points are selectedAre all effective;
for mode 3, the selected 3 grabbing points may form a triangle A3The straight line B1 may be formed regardless of the triangle A3Or straight line B1The 3 catch points selected are also valid as long as they are located in the end region opposite to the opening direction.
By analogy, if N is 4, the shape formed by the 4 grabbing points may be a straight line, a quadrangle or a tetrahedron; if N is 5, the shape page formed by the 5 grabbing points may be a straight line, a pentagon, a hexahedron, or the like, and the principle is the same as above, which is not repeated herein.
When N is 1 or N is 2, the straight line formed by 1 grabbing point/2 grabbing points may be effective as long as the preset shape of the grabbing surface (at this time, the grabbing surface may be expanded to be preset as a straight line) is satisfied or the grabbing surface is located in the terminal region opposite to the opening direction, and only 1 or 2 grabbing points are selected.
Step 220: controlling the gripper to apply acting force on the N grabbing points to grab the target packaging bag;
under normal conditions, the step 220 is executed once, and the target packaging bag can be successfully grabbed; however, a failed grasping may occur, and at this time, the grasping point may be reselected according to the various manners provided in step 210, and step 220 may be executed again until the grasping of the target packaging bag is successful.
Specifically, the number of the newly selected grabbing points can be 1-N, that is, only the grabbing points which failed in the previous grabbing can be replaced; all the grabbing points selected last time can be replaced.
For example, in the case where N is 4, it is assumed that there are 3 grasping points C1、C2、C3All grabbing successfully, only one grabbing point C4 is invalid, if only the grabbing point failed last time is replaced, the successful grabbing point C can be reserved in the re-grabbing process1、C2、C3Reselecting only one grab point C5Replacement of the gripping point C4In one particular embodiment, this may be at the grab point C4Is continued aroundSelecting a grasping point C5Until the grabbing is successful. Or, if all the grabbing points selected last time are replaced, directly replacing C1、C2、C3、C4All are discarded, and 4 new grabbing points are reselected until grabbing is successful.
Step 230: and controlling the clamp holder to move according to a preset moving direction according to the opening direction of the target packaging bag, so that the object in the target packaging bag is separated from the target packaging bag and poured out, wherein the preset moving direction and the opening direction of the target packaging bag have a preset relative angle.
Before performing step 230, the processor in the robot first determines the opening direction of the target packaging bag, which is obtained by detecting the target packaging bag. Specifically, the implementation may be directly achieved by performing step 200 once, or may be achieved by performing step 200 again, or implemented in other ways, and the embodiments of the present application do not limit this.
In a possible embodiment, the gripper can be directly controlled to move according to the preset moving direction when the opening direction is detected to be within the preset range of the turning direction.
In a possible implementation manner, it is detected that the opening direction is not located in a preset turning direction range; the clamp holder can be controlled to turn over the target packaging bag until the opening direction of the target packaging bag is within the preset bag turning direction range; the gripper is controlled to move according to the preset moving direction.
Based on the above embodiments, please refer to fig. 3, an embodiment of the present application further provides a bag-turning control device for controlling a gripper to grasp and move a target packaging bag, so as to pour out a package in the target packaging bag, the bag-turning control device 300 includes:
a detection unit 301, configured to detect a target packaging bag;
a processing unit 302, configured to determine N grabbing points on an outer surface of the target packaging bag, where N is a natural number;
controlling the gripper to exert acting force on the N grabbing points to grab the target packaging bag;
and controlling the clamp holder to move according to a preset moving direction according to the opening direction of the target packaging bag, so that the object in the target packaging bag is separated from the target packaging bag and poured out, wherein the preset moving direction and the opening direction of the target packaging bag have a preset relative angle.
In a possible implementation, the processing unit 302 is specifically configured to:
obtaining surface area data of the target packaging bag;
determining N grabbing points meeting grabbing conditions according to the surface area of a target packing bag, wherein the grabbing conditions are that the area of a grabbing surface determined by the N grabbing points is not smaller than a preset lowest value of the surface area of the target packing bag.
In a possible implementation, the processing unit 302 is specifically configured to:
and determining N grabbing points capable of forming the shape of the preset grabbing surface on the surface of the target packaging bag according to the shape of the preset grabbing surface.
In a possible implementation, the processing unit is specifically configured to:
and determining at least one grabbing point according to the opening direction of the target packaging bag, wherein the at least one grabbing point is positioned in the tail end area of the surface of the target packaging bag opposite to the opening direction.
By adopting the scheme, the grabbing and pouring success rate can be greatly improved.
In a possible implementation, the detection unit 301 is specifically configured to: detecting that the opening direction is within a preset turning direction range;
the processing unit 302 is specifically configured to: the gripper is controlled to move according to the preset moving direction.
In a possible implementation, the detection unit 301 is specifically configured to: detecting that the opening direction is not located in a preset ladle-to-ladle direction range;
the processing unit 302 is specifically configured to:
controlling the holder to turn over the target packaging bag until the opening direction of the target packaging bag is within the preset bag turning direction range;
the gripper is controlled to move according to the preset moving direction.
Based on the above embodiments, the present application further provides a bag-turning control device, where the bag-turning control device 400 may be a component module of the robot shown in fig. 1, or may be a separate device or a component module in another device, and the present application does not limit this.
Referring to fig. 4, the apparatus 400 includes: a processor 401 and a memory 402.
The memory 402 is used to store programs;
the processor 401 is configured to call a program stored in the memory 402 to implement the actions performed by any processing unit 402 in fig. 3, so as to implement the actions of the robot provided in the embodiment shown in fig. 1. It should be noted that, in practical applications, the ladle control device may include one or more processors, and the structure of the ladle control device 400 is not limited to the embodiment of the present application.
The embodiments of the present application also provide a computer-readable storage medium, which stores computer program codes, and when the computer program codes are run on a computer, the computer is caused to execute the method of any one of the possible embodiments in the foregoing embodiments.
An embodiment of the present application further provides a computer program product, where the computer program product includes: computer program code which, when run on a computer, causes the computer to perform the method according to any of the possible embodiments of the first or second aspect.
Embodiments of the present application further provide a computer program, which when run on a computer, causes the computer to execute the method of any one of the possible embodiments in any one of the foregoing embodiments.
It should be noted that the above-mentioned "first" and "second" have no special meaning, and are only used for distinguishing different modules.
Those skilled in the art will recognize that, in one or more of the examples described above, the functions described in the embodiments of the present application may be implemented in hardware, software, firmware, or any combination thereof. When implemented in software, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media includes both computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. A storage media may be any available media that can be accessed by a general purpose or special purpose computer.
It is to be noted that the foregoing is only illustrative of the preferred embodiments of the present application and the technical principles employed. It will be understood by those skilled in the art that the present application is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the application. Therefore, although the present application has been described in more detail with reference to the above embodiments, the present application is not limited to the above embodiments, and may include other equivalent embodiments without departing from the spirit of the present application, and the scope of the present application is determined by the scope of the appended claims.