Search

CN-118864884-B - Method, system, medium and equipment for identifying height of tobacco roll

CN118864884BCN 118864884 BCN118864884 BCN 118864884BCN-118864884-B

Abstract

The invention discloses a method, a system, a medium and equipment for identifying the height of a tobacco roll, wherein the method comprises the steps of acquiring two cameras which are arranged on a robot and are spaced at a preset distance, shooting inner and outer roll images obtained by feeding the roll on a tray, judging whether the roll exists on the tray according to the inner and outer roll images, acquiring target roll images corresponding to the inner and outer roll respectively when the roll contour in the roll image shot by one camera is a complete circle if the roll exists on the tray, calculating the inner roll height and the outer roll height according to the target roll images corresponding to the inner and outer roll respectively, and calculating the outer roll height according to the outer roll images shot by the two cameras respectively when the roll contour in the outer roll image shot by the two cameras is not a complete circle.

Inventors

  • ZHOU RUIFENG
  • LI DAWEI
  • YU HANG

Assignees

  • 法睿兰达科技(武汉)有限公司

Dates

Publication Date
20260508
Application Date
20240701

Claims (6)

  1. 1. A method of identifying a height of a roll of tobacco material, comprising the steps of: Acquiring images of an inner side material roll and an outer side material roll, wherein the images are formed by two cameras which are arranged on a robot at the same height and are spaced at a preset distance, and shooting a material roll on a tray; judging whether a material roll exists on the tray according to the inner and outer side material roll images; if the coil exists on the tray, acquiring target coil images corresponding to the inner and outer coils respectively when the coil outline in the coil image shot by one camera is a complete circle; calculating the height of the inner material roll and the height of the outer material roll according to the target material roll images respectively corresponding to the inner material roll and the outer material roll; when the fact that the material roll outline in the outer material roll images shot by the two cameras respectively is not a complete circle is recognized, calculating the outer material roll height according to the outer material roll images shot by the two cameras respectively; The step of calculating the height of the inner side material roll and the height of the outer side material roll according to the target material roll images respectively corresponding to the inner side material roll and the outer side material roll comprises the following steps: according to the target roll images corresponding to the inner and outer rolls, cameras corresponding to the inner and outer target roll images are obtained, and then the calculation formula of the inner roll height H 0 or the outer roll height H 0 is as follows: H 0 =d 1 -dsitance cos -d 2 -d 3 ; in the formula, The camera is installed at a certain angle, d 1 is installed at a certain height, d 2 is the thickness of the upper surface of the tray, d 3 is the height of the upper surface of the fork teeth of the robot, and dsitance is the distance between the inner roll or the outer roll and the corresponding camera.
  2. 2. The method of identifying a height of a roll of tobacco material according to claim 1, wherein said step of determining whether a roll is present on the tray based on said inner and outer roll images comprises the steps of: Extracting a coil outline in the inner and outer coil images by using an Opencv algorithm, and detecting a circle in the coil outline by using a Hough circle detection algorithm; And if the detected circular radius is within the preset radius range, judging that the coil exists on the tray.
  3. 3. The method for recognizing the height of a tobacco roll according to claim 1, wherein the step of calculating the height of the outer roll according to the outer roll images respectively photographed by the two cameras when it is recognized that the contour of the outer roll in the outer roll images respectively photographed by the two cameras is not a complete circle comprises the steps of: when the two cameras are identified to be respectively shot and the contour of the material roll in the obtained outside material roll image is not a complete circle, the corresponding two outside material roll areas and two initial outside material roll heights identified by the two cameras shot outside material rolls are obtained; when the difference value between the two initial outer side material roll heights is larger than a preset threshold value, taking the larger value of the two initial outer side material roll heights as the outer side material roll height; and when the difference value between the two initial outside material roll heights is smaller than a preset threshold value, calculating the outside material roll height according to the two outside material roll areas and the two initial outside material roll heights.
  4. 4. A system for identifying a height of a roll of tobacco material, comprising: The image acquisition module is used for acquiring images of the inner side material roll and the outer side material roll, wherein the images are formed by two cameras which are arranged on the robot at the same height and are spaced at a preset distance, and the images are obtained by shooting the material roll on the tray; the judging module is in communication connection with the image acquisition module and is used for judging whether a material roll exists on the tray according to the inner and outer material roll images; The target image module is in communication connection with the judging module and is used for acquiring target material roll images respectively corresponding to the inner and outer material rolls when the material roll outline in the material roll image shot by one camera is a complete circle if the material roll exists on the tray; a primary calculation module, which is in communication connection with the target image module and is used for calculating the height of the inner material roll and the height of the outer material roll according to the target material roll images corresponding to the inner material roll and the outer material roll respectively, and The secondary calculation module is in communication connection with the judging module and is used for calculating the height of the outer material roll according to the outer material roll images respectively shot by the two cameras when the material roll contours in the outer material roll images respectively shot by the two cameras are not a complete circle; The step of calculating the height of the inner side material roll and the height of the outer side material roll according to the target material roll images respectively corresponding to the inner side material roll and the outer side material roll comprises the following steps: according to the target roll images corresponding to the inner and outer rolls, cameras corresponding to the inner and outer target roll images are obtained, and then the calculation formula of the inner roll height H 0 or the outer roll height H 0 is as follows: H 0 =d 1 -dsitance cos -d 2 -d 3 ; in the formula, The camera is installed at a certain angle, d 1 is installed at a certain height, d 2 is the thickness of the upper surface of the tray, d 3 is the height of the upper surface of the fork teeth of the robot, and dsitance is the distance between the inner roll or the outer roll and the corresponding camera.
  5. 5. A storage medium having stored thereon a computer program which when executed by a processor implements a method of identifying a height of a tobacco roll as claimed in any one of claims 1 to 3.
  6. 6. An electronic device comprising a storage medium, a processor and a computer program stored in the storage medium and executable on the processor, characterized in that the processor implements a method of identifying a tobacco roll height according to any one of claims 1 to 3 when the computer program is run.

Description

Method, system, medium and equipment for identifying height of tobacco roll Technical Field The invention relates to the technical field of tobacco industry material rolls, in particular to a method, a system, a medium and equipment for identifying the height of a tobacco material roll. Background In the automatic feeding scene of a high-speed machine in the tobacco industry, the cooperative robot needs to feed the material rolls on the tray into the conveying line, but the number of the material rolls stacked on the tray is uncertain, if the material rolls are not judged, the mechanical arm of the cooperative robot cannot accurately judge the grabbing height, so that human intervention is still needed in an automatic process. Therefore, in view of the above problems, there is a need to design a solution for automatically identifying the height of a tobacco roll in an automated process, so as to identify whether there is a roll on a tray, and obtain the stacking height of the roll. Disclosure of Invention The invention provides a method, a system, a medium and equipment for identifying the height of a tobacco roll, which can identify whether the roll exists on a tray and obtain the stacking height of the roll. In a first aspect, there is provided a method of identifying a height of a roll of tobacco material, comprising the steps of: Acquiring images of an inner side material roll and an outer side material roll, wherein the images are formed by two cameras which are arranged on a robot at the same height and are spaced at a preset distance, and shooting a material roll on a tray; judging whether a material roll exists on the tray according to the inner and outer side material roll images; if the coil exists on the tray, acquiring target coil images corresponding to the inner and outer coils respectively when the coil outline in the coil image shot by one camera is a complete circle; calculating the height of the inner material roll and the height of the outer material roll according to the target material roll images respectively corresponding to the inner material roll and the outer material roll; when the fact that the material roll outline in the outer material roll images shot by the two cameras respectively is not a complete circle is recognized, the outer material roll height is calculated according to the outer material roll images shot by the two cameras respectively. According to the first aspect, in a first possible implementation manner of the first aspect, the step of determining whether a roll exists on the tray according to the inner and outer roll images specifically includes the following steps: Extracting a coil outline in the inner and outer coil images by using an Opencv algorithm, and detecting a circle in the coil outline by using a Hough circle detection algorithm; And if the detected circular radius is within the preset radius range, judging that the coil exists on the tray. According to the first aspect, in a second possible implementation manner of the first aspect, the step of calculating the inner roll height and the outer roll height according to the target roll images corresponding to the inner and outer rolls respectively specifically includes the following steps: according to the target roll images corresponding to the inner and outer rolls, cameras corresponding to the inner and outer target roll images are obtained, and then the calculation formula of the inner roll height H 0 or the outer roll height H 0 is as follows: H0=d1-dsitance*cosθ-d2-d3; Wherein θ is the mounting angle of the camera, d 1 is the mounting height of the camera, d 2 is the thickness of the upper surface of the tray, d 3 is the height of the upper surface of the fork teeth of the robot, and dsitance is the distance between the inner roll or the outer roll and the corresponding camera. According to the first aspect, in a third possible implementation manner of the first aspect, the step of calculating the outer roll height according to the outer roll images respectively shot by the two cameras when it is identified that the roll contours in the outer roll images respectively shot by the two cameras are not a complete circle specifically includes the following steps: when the two cameras are identified to be respectively shot and the contour of the material roll in the obtained outside material roll image is not a complete circle, the corresponding two outside material roll areas and two initial outside material roll heights identified by the two cameras shot outside material rolls are obtained; when the difference value between the two initial outer side material roll heights is larger than a preset threshold value, taking the larger value of the two initial outer side material roll heights as the outer side material roll height; and when the difference value between the two initial outside material roll heights is smaller than a preset threshold value, calculating the outside material roll height accord