Automatic seed bag shipping device and method

By combining a multi-scale retinal contrast restoration algorithm and a deep learning model, the problem of image processing accuracy under illumination and occlusion interference in automated delivery equipment was solved, enabling efficient automated delivery of seed bags and reducing human error rate and maintenance costs.

CN122126569APending Publication Date: 2026-06-02BEIJING ACADEMY OF AGRICULTURE & FORESTRY SCIENCES +1

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
BEIJING ACADEMY OF AGRICULTURE & FORESTRY SCIENCES
Filing Date
2026-02-26
Publication Date
2026-06-02

Smart Images

  • Figure CN122126569A_ABST
    Figure CN122126569A_ABST
Patent Text Reader

Abstract

The application relates to the technical field of logistics automation and warehouse management, and provides a seed bag automatic delivery device and method, which comprises a cabinet, a plurality of goods units arranged in an array, a taking mechanism arranged in each of the goods units, a delivery outlet of the taking mechanism located at a set side of the cabinet, the taking mechanism used for storing seed bags, a conveying mechanism arranged at the set side of the cabinet, a goods inlet of the conveying mechanism located at the bottom of the delivery outlet, the conveying mechanism used for receiving the seed bags taken out from the taking mechanism, and a packaging mechanism arranged at a goods outlet of the conveying mechanism, the packaging mechanism being provided with an identification unit and a packaging unit, and the packaging unit used for packaging the seed bags that pass the verification. The device does not need manual intervention in the whole process, completely changes the traditional manual operation mode, greatly reduces the labor cost and human errors, and realizes highly automatic operation from order placement to package formation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of logistics automation and warehouse management technology, and in particular to an automatic seed bag delivery device and method. Background Technology

[0002] The warehousing and shipping of seed bags has long relied on traditional manual sorting. In this model, operators must navigate between shelves to find the corresponding type and quantity of seed bags based on order information, then manually sort, check, and pack them. This method is not only labor-intensive and inefficient, but also prone to errors such as misdelivery or omissions due to the wide variety of seed types and their high degree of similarity in appearance, making it difficult to meet the concurrent processing demands of modern seed e-commerce platforms handling tens of thousands of orders daily.

[0003] To improve efficiency, the industry has gradually introduced automated shipping equipment. However, existing automated shipping equipment has significant shortcomings in the visual recognition stage. The surface of seed bags is easily affected by uneven lighting, wrinkles, and occlusions, leading to insufficient accuracy in image processing algorithms. For example, traditional methods struggle to eliminate the influence of ambient lighting, and deep learning models do not sufficiently extract features from small targets, easily resulting in statistical errors in densely stacked scenarios. These deficiencies not only exacerbate the risk of shipping errors but also increase operational costs. Summary of the Invention

[0004] This invention provides an automatic seed bag dispensing device and method to address the significant shortcomings of existing automated dispensing equipment in the visual recognition process, where the surface of seed bags is easily affected by uneven lighting, wrinkles, and occlusion, leading to insufficient accuracy of image processing algorithms in verification.

[0005] This invention provides an automatic seed bag dispensing device, comprising: The container has multiple cargo units arranged in an array. Each cargo unit is equipped with a picking mechanism. The outlet of the picking mechanism is located on a designated side of the container. The picking mechanism is used to store seed bags. A conveying mechanism, disposed on the designated side of the container, wherein the inlet end of the conveying mechanism is located at the bottom of the outlet, is used to receive seed bags taken out from the picking mechanism; and A packaging mechanism is located at the shipping end of the conveying mechanism. The packaging mechanism includes an identification unit and a packaging unit. The packaging unit is used to package the verified seed bags. The identification unit is configured to perform the following visual verification steps: acquire an image of the seed bag; preprocess the image using a multi-scale retinal contrast restoration algorithm to eliminate illumination and wrinkle interference by separating the illumination and reflection components; input the preprocessed image into a deep learning model, extract small target features through a backbone network integrating channel attention and spatial attention, and use an adaptive spatial feature fusion module to process multi-scale features in occluded scenarios to generate candidate bounding boxes; finally, dynamically adjust the intersection-union threshold based on the seed bag width, and use an adaptive non-maximum suppression algorithm to filter candidate bounding boxes for seed bag quantity statistics; if the statistical results show that the seed bag category and quantity are consistent with the order, the packaging unit performs the packaging operation; if they are inconsistent, an exception handling is triggered.

[0006] According to the present invention, an automatic seed bag dispensing device includes a dispensing mechanism comprising: a driving wheel, a driven wheel, and a first motor; The conveying mechanism has a vertical stacking groove inside, and one end of the stacking groove has an outlet. A discharge channel is formed between the outlet and the discharge port. The driving wheel and the driven wheel are spaced apart in the discharge channel. The driving wheel and the driven wheel are connected by a drive mechanism. The first motor is connected by a drive mechanism to the driving wheel. The first motor is used to drive the driven wheel to rotate through the driving wheel. The driving wheel and the driven wheel work together to drive the seed bag to move in the discharge channel.

[0007] According to the present invention, an automatic seed bag dispensing device is provided, wherein the dispensing mechanism further includes: a photoelectric encoder and a photoelectric sensor; Both the photoelectric encoder and the photoelectric sensor are electrically connected to the first motor. The photoelectric encoder is located at the shaft end of the drive wheel and is used to detect the rotation angle of the drive wheel to calculate the conveying stroke of the seed bag. The photoelectric sensor is located at the outlet and is used to detect whether the seed bag has been successfully removed.

[0008] The present invention also provides an automatic seed bag dispensing method, applied to an automatic seed bag dispensing device, comprising the following steps: Receive order information, analyze the seed type and quantity, and locate the corresponding cargo unit in the container; The picking mechanism within the cargo unit removes the seed bags one by one according to instructions. The seed bags fall into the conveying mechanism and are then transported to the packing mechanism. When a seed bag reaches the recognition unit, an image of the seed bag is acquired. The image is preprocessed using a multi-scale retinal contrast restoration algorithm to eliminate interference from illumination and wrinkles by separating the illumination component and the reflection component. The preprocessed image is then input into a deep learning model. Small target features are extracted through a backbone network that integrates channel attention and spatial attention. An adaptive spatial feature fusion module is used to process multi-scale features in occluded scenes to generate candidate bounding boxes. Finally, the intersection-union ratio (IUU) threshold is dynamically adjusted based on the seed bag width, and an adaptive non-maximum suppression algorithm is used to filter candidate bounding boxes for seed bag count. If the statistical results show that the type and quantity of seed bags are consistent with the order, the packaging unit will perform the packaging operation; otherwise, an exception will be triggered.

[0009] According to the automatic seed bag delivery method provided by the present invention, the specific calculation process of image preprocessing using a multi-scale retinal contrast restoration algorithm is as follows: The captured images Decomposed into reflection components With light component Through multiple Gaussian filters G of different scales k k Convolve the image to estimate the illumination components. ; Represents the spatial coordinates of a specific pixel in an image; Calculating multiscale retinal contrast The illumination components are separated by logarithmic operations: The corrected image is obtained through contrast stretching. As input to deep learning models : This represents the minimum value among the multi-scale retinal contrast results. This represents the maximum value in the multi-scale retinal contrast results. This indicates that the result is normalized to a pixel value range of 0-255.

[0010] According to the seed bag automatic delivery method provided by the present invention, the deep learning model includes the following steps in the extraction of small target features: For feature map F, Perform channel attention calculation to obtain channel weights. ; ; in, For global average pooling, the spatial region of each channel ( ) average, and Feature map compression The vector captures global information for each channel, where C represents the number of channels, and H and W represent the height and width of the feature map; It is a multi-layer fully connected layer; first, the channel dimension is compressed, and then the channel information is reconstructed. For activation functions; Spatial attention is calculated on the feature map F to obtain the spatial weights. ; ; in, It is spatial pooling splicing; It is a convolution operation; Final feature map .

[0011] An automatic seed bag delivery method according to the present invention includes the following steps: processing multi-scale features in occluded scenes using an adaptive spatial feature fusion module: Feature maps at different scales All should be of the same size; Calculate the fusion weights for feature maps at each scale. ;in The mean of multi-scale features, for convolution; For activation functions; The feature maps at different scales are summed by dynamic weights to obtain the fused features. .

[0012] According to the automatic seed bag delivery method provided by the present invention, the deep learning model is trained using a dynamic effective focus loss function to adapt to seed varieties with different sample sizes. The calculation of the loss function includes: Calculate the dynamic gamma value based on the sample size of this product category. ;in This represents the sample size for this product category. and These are the maximum and minimum sample size thresholds, respectively; based on Calculate the loss value ; in This represents the model's predicted probability for the current product category. For parameters.

[0013] According to the present invention, an automatic seed bag delivery method includes the following steps for counting the number of seed bags using an adaptive nonmaximum suppression algorithm: Get the width of the seed bag Calculate the dynamic intersection-union ratio threshold. ; Calculate the current detection box With the highest-scoring detection box intersection ratio ; like Then retain the score of the current detection box. ; like The score of the current detection box is then decayed using a Gaussian function. ;in This is the attenuation parameter.

[0014] According to the automatic seed bag delivery method provided by the present invention, during automatic picking and conveying, the picking mechanism performs the following actions: Get the width information of the seed bags in the order; Based on this width information, the stacking slot inside the picking mechanism drives the two side uprights to move, adjusting the width of the stacking slot to the reserved gap value for the width of the seed bag; The roller assembly at the outlet of the picking mechanism rotates, driving the bottom seed bag to separate and slide out of the outlet through friction.

[0015] The automatic seed bag delivery device provided in this invention achieves fully automated operation through a highly integrated design of the container, conveying mechanism, and packaging mechanism, significantly reducing labor costs and human error. The array-style cargo units of the container ensure orderly storage of seed bags, adapt to various sizes of seed bags, and avoid jamming failures; the recognition unit of the packaging mechanism adopts a multi-scale retinal contrast recovery algorithm and a deep learning model to effectively eliminate the effects of light interference, wrinkles, and occlusion, improving the accuracy of visual verification, thereby ensuring a qualitative improvement in delivery efficiency and reliability. Attached Figure Description

[0016] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0017] Figure 1 This is a schematic diagram of the automatic seed bag dispensing device provided by the present invention.

[0018] Figure 2 This is a schematic diagram of the pickup mechanism provided by the present invention.

[0019] Figure 3 This is a flowchart illustrating the workflow of the automatic seed bag delivery device provided by the present invention.

[0020] Figure 4 This is a flowchart of the automatic seed bag delivery method provided by the present invention.

[0021] Figure 5 This is a flowchart of the image recognition process in the automatic seed bag delivery method provided by the present invention.

[0022] Figure label: 1. Cargo container; 11. Cargo unit; 12. Picking mechanism; 121. Stacking slot; 122. Outlet; 123. Drive wheel; 1231. Anti-slip strip; 124. Driven wheel; 125. First motor; 126. Photoelectric encoder; 127. Photoelectric sensor; 128. First upright plate; 129. Second upright plate; 130. Baffle; 131. Electronic display screen; 2. Conveying mechanism; 3. Packaging mechanism; 31. Identification unit; 32. Packaging unit. Detailed Implementation

[0023] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.

[0024] The following is combined with Figures 1 to 3 This invention describes an automatic seed bag dispensing device.

[0025] This invention provides an automatic seed bag dispensing device, such as... Figure 1 and Figure 2 As shown, it includes: a container 1, a conveying mechanism 2, and a packaging mechanism 3. The container 1 adopts a modular design and has multiple cargo units 11 arranged in an array. Each cargo unit 11 is an independent storage unit, and each cargo unit 11 is equipped with a picking mechanism 12. The outlet 122 of the picking mechanism 12 is located on the designated side of the container 1.

[0026] In this embodiment, the picking mechanism 12 includes a storage component and a pulley component. The storage component has a vertically oriented stacking groove 121 inside, specifically designed to accommodate multiple stacks of seed bags. The dimensions of the stacking groove 121 are precisely calculated to accommodate the specifications of standard seed bags while ensuring the stability of the seed bags during stacking. An outlet is provided at one end of the stacking groove 121, the width of which is adapted to the width of the seed bag, allowing the seed bag to slide out smoothly.

[0027] A pulley system is located at the outlet, its main function being to transport the single-bag seeds at the bottom of the stacking trough 121 to the outlet 122 of the picking mechanism 12. This outlet 122 is uniformly located on the same side of the container 1. The conveyor mechanism 2 is located on the side of the container 1, with its inlet directly below the outlet 122. This ensures that the seed bags retrieved from the picking mechanism 12 can be received by the conveyor mechanism 2. The conveyor mechanism 2 uses an anti-static conveyor belt with a specially roughened surface treatment, which prevents the potential impact of static electricity on the seeds and increases friction to ensure that the seed bags do not slip during transport. The conveyor belt's operating speed can be steplessly adjusted within the range of 0.5-2 m / s according to actual shipping needs. The packaging mechanism 3 is located at the outlet of the conveyor mechanism 2 and is the final link in completing the shipping process. This mechanism includes an identification unit 31 and a packaging unit 32. The identification unit 31 uses advanced machine vision technology, equipped with a high-resolution industrial camera and dedicated image processing algorithms, enabling rapid and accurate visual identification and verification of the transported seed bags. This unit can not only identify the type of seed bags but also count their quantity to ensure complete consistency with order requirements. Packaging unit 32 is responsible for the automated packaging of the verified seed bags. This unit integrates automatic sealing equipment and a labeling system, which can automatically adjust heat sealing parameters according to the material characteristics of the seed bags to ensure a secure seal; at the same time, it automatically prints and affixes a logistics label containing receiving information, completing the entire packaging process.

[0028] In this embodiment, the recognition unit is configured to perform the following visual verification steps: such as Figure 5 As shown, images of seed bags are acquired; the images are preprocessed using a multi-scale retinal contrast restoration algorithm to eliminate illumination and wrinkle interference by separating the illumination and reflection components; the preprocessed images are input into a deep learning model, and small target features are extracted through a backbone network integrating channel attention and spatial attention. An adaptive spatial feature fusion module is used to process multi-scale features in occluded scenes to generate candidate bounding boxes; finally, the intersection-union ratio threshold is dynamically adjusted based on the seed bag width, and an adaptive non-maximum suppression algorithm is used to filter candidate bounding boxes for seed bag quantity statistics; if the statistical results show that the seed bag category and quantity are consistent with the order, the packaging unit 32 performs the packaging operation; if they are inconsistent, an exception handling is triggered.

[0029] The automated seed bag delivery device provided in this embodiment achieves fully automated operation through a highly integrated design of the container, conveying mechanism, and packaging mechanism, significantly reducing labor costs and human error. The array-style cargo units of the container ensure orderly storage of seed bags, adapt to various sizes of seed bags, and avoid jamming failures; the recognition unit of the packaging mechanism adopts a multi-scale retinal contrast recovery algorithm and a deep learning model to effectively eliminate the effects of light interference, wrinkles, and occlusion, improving the accuracy of visual verification, thereby ensuring a qualitative improvement in delivery efficiency and reliability.

[0030] It should be noted that this device uses 10 sets of standardized containers 1, whose frames are made of anodized aluminum alloy profiles. These frames possess a load-bearing capacity of ≥500kg to support the long-term storage of a large number of seed bags, while also enhancing corrosion resistance to adapt to complex storage environments and extend service life. Each set of containers 1 is arranged in a 6-layer × 25-column layout, with 150 independent aisles per set (15 sets totaling 1500 aisles), capable of storing over 1500 varieties of seeds. This design balances sufficiency and rationality of storage space, avoiding wasted space or poor storage conditions. In addition to addressing the shortcomings, each cargo aisle has an internal space adapted to the specifications of seed bags (width ≤ 350mm, height ≤ 350mm, depth ≤ 450mm). It not only uses a three-level unique coding system of cabinet number, layer number, and column number, but also embeds a separate delivery device. At the same time, the cargo aisle entrance integrates a 5-inch electronic display screen 131, and the cargo aisle is equipped with RFID tags (storing seed varieties, batches, and other information). This data can support the delivery device to complete order parsing, cargo location positioning, and accurate retrieval, ultimately achieving a coordinated and unified system of high-density storage of multiple seed varieties, information visualization, and intelligent scheduling.

[0031] In some embodiments, such as Figure 1 and Figure 2 As shown, the pulley assembly includes: a driving wheel 123, a driven wheel 124, and a first motor 125.

[0032] In this embodiment, a vertically oriented stacking groove 121 is formed inside the conveying mechanism 2. One end of the stacking groove 121 has an outlet, forming a clear linear delivery channel between the outlet of the storage component and the delivery port 122 of the picking mechanism 12. The driving wheel 123 and the driven wheel 124 are arranged in parallel at a specific interval in this delivery channel. The driving wheel 123 and the driven wheel 124 are connected by a synchronous toothed belt or gear set to ensure that they can rotate synchronously and in opposite directions. The first motor 125 is usually a highly controllable stepper motor or servo motor, and its output shaft establishes a direct or reducer-connected transmission relationship with the driving wheel 123.

[0033] When the warehouse management system issues a picking instruction, the first motor 125 is started. The motor drives the drive wheel 123 to rotate in a predetermined direction, and the drive wheel 123 then drives the driven wheel 124 to rotate in the opposite direction via a belt. At this time, the bottom seed bag, which is located in the clamping area of ​​the drive wheel 123 and the driven wheel 124, is subjected to opposite frictional forces on its upper and lower surfaces by one or two rollers. Under the synergistic drive of these frictional forces, the seed bag is smoothly clamped and conveyed forward, and thus continuously pushed along the shipping channel from the internal outlet of the storage component to the external shipping port 122 of the picking mechanism 12.

[0034] Meanwhile, the pulley assembly also includes: a photoelectric encoder 126 and a photoelectric sensor 127; both the photoelectric encoder 126 and the photoelectric sensor 127 are electrically connected to the first motor 125. The photoelectric encoder 126 is located at the shaft end of the drive wheel 123 and is used to detect the rotation angle of the drive wheel 123 to calculate the conveying stroke of the seed bag; the photoelectric sensor 127 is located at the outlet 122 and is used to detect whether the seed bag has been successfully removed.

[0035] When the picking process begins, the first motor 125 drives the drive wheel 123 to rotate, thereby conveying the seed bags through friction. During this process, the photoelectric encoder 126 installed at the shaft end of the drive wheel 123 monitors and records the precise rotation angle of the drive wheel 123 in real time. The control unit receives the pulse signal from the encoder and calculates the actual conveying distance of the seed bags in the delivery channel in real time using a built-in algorithm.

[0036] When the calculated conveying distance approaches the theoretical length of the seed bag, the control system predicts that it is about to reach the outlet 122. At this time, the photoelectric sensor 127 located at the outlet 122 enters the detection state. Once the front end of the seed bag successfully blocks the beam of light from the photoelectric sensor 127, the sensor immediately sends an arrival signal to the control system.

[0037] The control system cross-validates this signal with the travel data calculated by the photoelectric encoder 126. If they match, the pickup is considered successful. Subsequently, the control system controls the first motor 125 to continue operating for a short preset overshoot stroke to ensure that the seed bag is completely detached from the pickup mechanism 12 and falls onto the conveyor mechanism 2 below. Then, the first motor 125 stops working.

[0038] Conversely, if no arrival signal is received from the photoelectric sensor 127 within the preset time, or if the travel calculated by the photoelectric encoder 126 has far exceeded the length of the seed bag but there is still no detection signal, the control system will determine that the picking has failed (possibly due to empty material or jamming), trigger an alarm, and stop the first motor 125, waiting for manual intervention.

[0039] It should be noted that, to ensure retrieval, the entire cargo unit 11 is generally tilted, allowing the seed bags in the stacking slot 121 to be discharged through the tilted discharge channel. As the seed bags are stacked layer by layer within the stacking slot 121, their own weight (G) can be decomposed into two components: a normal force perpendicular to the bottom surface of the stacking slot 121, and a force parallel to the tilted bottom surface and pointing in the discharge direction. This downward force along the tilted surface provides a continuous and natural auxiliary force for the seed bags to move towards the outlet.

[0040] Anti-slip strips 1231 can be installed on the driving wheel 123 and / or driven wheel 124 as needed to enhance the friction between the roller and the seed bag and ensure the reliability of the conveying process. The anti-slip strips 1231 are preferably made of a high-friction elastic material, such as polyurethane or synthetic rubber, with a Shore hardness selectable in the range of A60 to A80 to achieve good grip and moderate deformation capacity. The anti-slip strips 1231 can be continuously or intermittently wrapped around the outer circumferential surface of the roller in a ring-like manner.

[0041] In a preferred embodiment, two or more anti-slip strips 1231 are arranged at intervals along the roller axis, thereby forming multiple parallel friction contact bands on the surface of the seed bag to prevent the seed bag from skewing or jamming during transport. The anti-slip strips 1231 significantly increase the static friction coefficient between the roller and the seed bag packaging material (whether smooth plastic film or rough paper bag). This ensures that even when only contacting the edge of the seed bag or on an uneven surface, the roller can provide sufficient driving force to effectively overcome inter-bag friction and discharge channel resistance, thus achieving stable and smooth output of the bottom seed bags and preventing failures caused by slippage or insufficient transport. Furthermore, the elastic strips also provide cushioning, reducing rigid impact on the seed bags and lowering the risk of packaging damage. The anti-slip strips 1231 can be fitted onto the roller base with an interference fit or firmly adhered with an adhesive, ensuring reliable connection.

[0042] In some examples, such as Figure 1 and Figure 2 As shown, the storage component includes: a baffle 130 and a first upright plate 128 and a second upright plate 129 spaced apart; the first upright plate 128 and the second upright plate 129 are mounted on a base plate, and a stacking groove 121 is formed between the first upright plate 128 and the second upright plate 129; the baffle 130 is located at the outlet. The baffle 130 always maintains a distance of ≤0.4mm between its lower edge and the upper surface of the bottom seed bag, completely blocking the falling path of the upper bags from a mechanical structure perspective, and controlling the multi-bag contamination rate to <0.1%. The first upright plate 128 and the second upright plate 129 are made of 2mm thick 304 stainless steel plate, taking into account both lightweight and structural strength, while also meeting the corrosion resistance requirements of the storage environment; guide rails can be installed at the bottom of the first upright plate 128 and the second upright plate 129, which can be mounted on the base plate, and the first upright plate 128 and the second upright plate 129 can be slidably mounted on the guide rails.

[0043] In this embodiment, the storage component further includes a second motor and a ball screw; the second motor drives the first upright plate 128 and / or the second upright plate 129 to move relative to each other via the ball screw.

[0044] The second motor (typically a miniature DC geared motor with precise speed and position control) is fixedly connected to the ball screw shaft end via a coupling. The ball screw nut seat is rigidly connected to the back frame of the first upright plate 128 and / or the second upright plate 129.

[0045] Specifically, this mechanism can be implemented in two ways: For example, a second motor and ball screw pair are positioned on one side, driving the first upright plate 128 (as a movable upright plate) to move relative to the fixed second upright plate 129. Alternatively, two sets of second motors and ball screw pairs can be configured, respectively connected to the first upright plate 128 and the second upright plate 129. A control system controls the two motors to rotate synchronously in opposite directions, driving the two upright plates to move towards or away from each other, thereby achieving centrally symmetrical adjustment of the width of the stacking slot 121. Furthermore, position feedback elements, such as laser displacement sensors or encoders coaxially connected to the motors, can be provided to accurately detect the actual position of the upright plates.

[0046] During operation, if an order instruction containing a specific seed variety name is issued, the control unit retrieves the standard width parameter L of the seed bag for that variety from the built-in database. Taking into account the manufacturing tolerances of the seed bags, the control unit calculates an optimized target adjustment width L target, L target = L actual + 0.5mm (leaving a 0.25mm gap on each side to avoid being too tight or too loose).

[0047] The control unit sends a command to the second motor to drive it to rotate. The rotational motion of the second motor is transmitted to the ball screw through a coupling, and the rotational motion of the screw is converted into precise linear motion of the nut (and the vertical plate connected to it) along the screw axis.

[0048] During the movement of the uprights, the position feedback sensor continuously monitors the actual distance Lactual between the two uprights in real time and feeds the data back to the control unit. The control unit compares Lactual with Ltarget and calculates the position deviation. Based on this deviation, the control unit uses PID and other control algorithms to dynamically adjust the speed and direction of the second motor for precise positioning until the error between Lactual and Ltarget falls within the allowable range.

[0049] The second motor achieves synchronous opening and closing of the upright plate through forward and reverse rotation, with an adjustment range of 80mm-250mm (covering seed bags with a width of 80mm-200mm) and an adjustment accuracy of ±0.5mm. For easy adjustment, the upright plate can also be manually adjusted via a manual adjustment knob located on the side of the device or in an easily accessible position. This knob is connected to the end of a ball screw shaft via a set of bevel gears or a universal joint mechanism, thus converting the rotational motion of the handwheel into the rotation of the screw, ultimately driving the linear movement of the upright plate.

[0050] As needed, the storage component may also include: a locking element; the locking element has a locked state and an unlocked state, and when the locking element is in the locked state, it fixes the first upright plate 128 and / or the second upright plate 129 in the current position.

[0051] The locking element is preferably an electromagnetic locking device, which is a locking coil that generates a strong electromagnetic attraction when energized. During adjustment, the locking element is in a de-energized, released state, allowing the upright plate to move freely.

[0052] After the locking component is powered on, ensure that its strength is ≥100N, which is sufficient to overcome the various vibrations and impact torques generated by the start and stop of the stepper motor, the rotation of the rollers, and the friction conveying of the seed bags during the subsequent picking process, and effectively prevent any slight displacement of the upright plate under stress.

[0053] Furthermore, after each locking action, the deviation between the actual locked position and the target position of the upright plate is strictly controlled within ±0.1mm. This ensures normal use, and the width of the stacking slot 121 can be accurately reproduced, thereby ensuring consistent and precise guidance and spatial constraints for different batches and types of seed bags during retrieval, fundamentally eliminating material jamming or retrieval failures caused by slight variations in width.

[0054] In some embodiments, such as Figure 1 and Figure 2 As shown, the baffle 130 is a retractable baffle, which is connected to the first upright plate 128 and / or the second upright plate 129 so that the retractable baffle extends and retracts synchronously during the movement of the first upright plate 128 and / or the second upright plate 129.

[0055] In this embodiment, the retractable flange is not a fixed plate, but is composed of multiple (e.g., two to three) nested wing plates that can slide relative to each other, and its structure is similar to the telescopic principle of a telescope or a folding linkage mechanism. These wing plates are connected by slide rails or hinges, allowing them to extend and retract flexibly in the length direction.

[0056] The fixed end of the retractable side guard is rigidly connected to the frame of the first upright plate 128 and / or the second upright plate 129 via a mounting bracket. Its extension and retraction are mechanically linked to the width adjustment mechanism of the upright plate. For example, the linear motion of the upright plate can be directly converted into the extension and retraction motion of the side guard wing plate via a linkage mechanism such as a connecting rod, rack, or flexible shaft. When the second motor drives the upright plate to move to change the width of the stacking slot 121, the motion of the upright plate is synchronously transmitted to the retractable side guard through the aforementioned linkage mechanism.

[0057] like Figure 1 and Figure 2As shown, curved guide strips are provided on the opposing inner sides of the first upright plate 128 and / or the second upright plate 129. The cross-section of the guide strip has a slightly arc-shaped profile, which can fit well with the curved surface formed by the seed bags in a natural stacking state, providing uniform lateral support. The guide strips are detachably fixed to the inner side of the upright plates by at least two adjusting bolts. The function of the guide strips is to guide the seed bags placed in the stacking slot 121, providing a natural centering guidance and forcing potentially tilted bags back to a vertical state, ensuring that the seed bags are stacked vertically in a straight line. By tightening the fixing bolts, the protrusion height of the guide strips relative to the inner surface of the upright plates can be adjusted, with an adjustment range designed to be from 0.5mm to 2mm. For thinner seed bags (e.g., 1-2mm), the protrusion of the guide strips can be appropriately increased (e.g., 1.5-2mm); for thicker seed bags (e.g., 4-5mm), the protrusion can be correspondingly reduced (e.g., 0.5-1mm), ensuring the guiding effect while avoiding excessive compression.

[0058] In some embodiments, such as Figure 1 and Figure 2 As shown, the storage component also includes a laser displacement sensor, which is mounted on either the first upright plate 128 or the second upright plate 129, with its detection end facing the other upright plate. The sensor is used to detect the distance between the first upright plate 128 and the second upright plate 129. The laser displacement sensor operates based on principles such as laser triangulation or phase interferometry. It emits a modulated laser beam towards the surface of the opposite upright plate and receives the light signal reflected back from the surface. By calculating the optical path difference or phase change of the laser beam during its round trip, the precise distance between the two upright plates can be calculated in real time and non-contactly.

[0059] Compared to traditional contact or relative position sensors such as potentiometers or optical scales, laser displacement sensors offer significant advantages in terms of non-contact operation, high resolution, and high-speed response. In this application, its detection accuracy reaches ±0.01mm, far exceeding the system's required adjustment accuracy (e.g., ±0.3mm). This extremely high accuracy provides a reliable feedback basis for closed-loop control of width adjustment, enabling the control system to accurately sense minute displacements of the vertical plate and promptly issue correction commands, thereby ensuring that the width of the stacking slot 121 converges to the target value quickly and stably.

[0060] In a specific embodiment, such as Figures 1 to 3 As shown, during operation, the system receives order data from upstream e-commerce platforms or warehouse management systems and automatically parses out information such as seed type, quantity, and specifications contained in the order.

[0061] Based on the parsed product category information, the system automatically locates the target storage channel containing the corresponding seed. The system simultaneously checks the real-time status of this channel, including remaining inventory and equipment functionality. The system then determines if the target channel is in a normal and usable state. If normal, the process proceeds to the next step. If an anomaly occurs, the system triggers an alarm and automatically returns to the re-verification stage, or prompts for manual intervention.

[0062] After confirming the driveway is functioning correctly, the system immediately locks the driveway to prevent conflicting calls from other order tasks. Subsequently, the system sends a command to the picking mechanism 12 within the driveway to initiate a driveway width adaptation program, automatically adjusting the width of the storage components according to the current seed bag specifications. Once the width adaptation is complete, the picking mechanism 12 performs a precise single-bag picking action, separating and pushing out the bottommost bag of seeds. The retrieved seed bag falls onto the conveyor belt at the front of container 1. The conveyor belt transports the seed bag to the identification unit 31 (AI visual verification station). Here, the identification unit 31 photographs the seed bag, and its built-in improved deep learning model quickly identifies its type and quantity, comparing it with the order information.

[0063] The system checks if the verification result matches the order. If the seed bags are qualified, they continue to the next stage. If the seed bags are unqualified, they are directed to an abnormal diversion channel for handling (such as re-sorting or manual inspection), which may trigger an alarm. Qualified seed bags enter packaging unit 32 (automatic packaging and labeling station). Packaging unit 32 automatically seals the packaging and prints and affixes the corresponding logistics label. The packaged parcels are then sent to the corresponding logistics sorting port via the logistics sorting conveyor line. Finally, the system executes a closed-loop process, including releasing the locked cargo channel, deducting inventory, updating the order status to "shipped," and reporting completion information to the management platform. At this point, a single order is completed.

[0064] In this embodiment, the picking principle is based on the automatic seed bag dispensing device technology system. Through the synergistic effect of mechanical design, closed-loop control, structural limit and stroke compensation, it is adapted to seed bags with a width range of 80-200mm and a thickness of 1-5mm, ensuring stable dispensing of seed bags of different specifications.

[0065] This principle is based on Coulomb's law of friction and force balance design. By adjusting the mechanical relationship between the driving force of the bottom bag and the resistance of the top bag, it achieves the layered effect of independent conveying of the bottom bag and stacking of the top bags, which can be adapted to the discharge requirements of seed bags of different widths.

[0066] The driving force of the bottom seed bag Provided by the static friction of the roller, according to Coulomb's law of friction: In the formula, μ is the coefficient of friction. Under positive pressure and in a standard storage environment, the measured static friction coefficient between the roller and the seed bag is stable at μ≈0.85, and this value is not affected by the width of the seed bag (the uniform texture of the anti-slip strip can ensure the consistency of contact friction between bags of different widths).

[0067] The positive pressure is provided by an eccentric wheel-driven spring-type elastic clamping mechanism integrated into the upper drive wheel bracket, and the basic positive pressure is set to... Its range is ( , To accommodate the upper and lower limits of the basic positive pressure for seed bags of different thicknesses; and also for widths > ( The seed bag (with a preset width threshold) is automatically increased. The positive pressure compensates for the local frictional attenuation caused by the dispersed contact area between the wide bag and the roller, ensuring static friction in wide bag scenarios. .

[0068] The resistance force of the upper bag to the lower bag is the static friction between the bags. The calculation formula is: The coefficient of friction between bags is determined by the surface properties of paper seed bags, which stabilize the coefficient of friction between bags in a stacked state. It is not affected by the stacking height. Let G be the total pressure of the upper bags, the weight of a single bag of seeds (including packaging) be G, and the maximum stacking capacity of the shipping channel be G. The total pressure of the upper bag on the lower bag ( (Based on the actual number of stacks), the maximum resistance is calculated. .

[0069] The rolling resistance between the shipping channel and the seed bag mainly comes from the contact friction between the upright plate and the bag body. The resistance is stabilized by the micro-arc surface guide strip design of the stacked guide components.

[0070] The guide strip is made of UHMW-PE material (abrasion resistance coefficient ≤0.15), and its micro-arc surface structure avoids hard contact with the seed bag when adjusting the width of the upright plate; at the same time, the protrusion height of the guide strip can be adaptively adjusted according to the bag thickness, reducing the contact area; the rolling resistance of the delivery channel is reduced. ≤ And the resistance fluctuation during the width adjustment process is ≤ This ensures consistent force balance across seed bags of different widths.

[0071] Combine cargo channels The inclined design (utilizing the component of gravity to assist the bottom bag in moving along the conveying direction, reducing the driving force requirement) ultimately forms a stable mechanical equilibrium relationship: ≤ Width adjustment is a process to achieve precise fit of seed bags for different varieties. Considering the seed bag width tolerance of ±2mm, the target adjustment width L target = L + 0.5mm (to ensure that a 0.25mm gap is reserved on both sides of the bag to avoid compression and prevent skewing). The control unit sends forward and reverse pulses to the DC geared motor, which drives the ball screw to move the vertical plate. The laser displacement sensor provides real-time feedback on the actual width L, and the motor speed is dynamically adjusted through a PID algorithm. Formula output It's the motor speed adjustment amount; the control unit will adjust it according to... The speed of the DC geared motor is dynamically adjusted to ultimately match the spacing between the uprights to the width of the seed bags (with a 0.25mm gap on one side). The width deviation e(t) = , This is the proportional coefficient, which is a direct response to the current deviation. The larger the deviation, the stronger the output control quantity (motor speed adjustment quantity), which is used to quickly reduce the gap between the vertical plate spacing and the target value. Here, the value is taken as 0.8. This is the integral coefficient, which is the response to the cumulative deviation; here, its value is taken as 0.2. The differential coefficient is the response to the rate of change of the deviation, and here it is set to 0.1 (optimized PID parameter), adjusting the steady-state error to ≤ ±0.3mm.

[0072] Once the adjustment is complete, the control unit sends a locking command, the locking mechanism activates, and a width ready signal is sent back, at which point the picking process can begin.

[0073] The width of the stacking slot is precisely matched to the width of the seed bag through closed-loop control, and the height is equal to the thickness of the seed bag plus 0.3mm. Combined with the interference fit of the roller assembly (roller spacing = seed bag thickness - 0.2mm), the upper bag is restricted from entering the picking area from a spatial perspective. The retractable baffle at the outlet is adjusted synchronously with the width to always maintain mechanical interference to block the path of the upper bag and ensure the uniqueness of each picking action for a single bag.

[0074] To ensure that seed bags of different widths and lengths can completely leave the roller conveying area without deviation, a photoelectric encoder (coaxially connected to the roller) provides real-time feedback of the roller's cumulative rotation angle θ. The control unit calculates the actual conveying stroke L of the seed bag using the arc length formula. First determine the total target distance. (Includes 10mm compensation stroke to ensure the bag is completely detached from the roller): In the formula, Given the seed length, derive the target rotation angle that the roller needs to turn. : Converted into the number of supplementary motor pulses (Step angle) (Subdivision multiple 128): When the width of the seed bag is greater than 150mm, the control unit reduces the pulse frequency by 20% to extend the picking time and prevent the bag from shifting due to inertia.

[0075] This invention also provides an automatic seed bag dispensing method, applied to an automatic seed bag dispensing device, such as... Figure 4 As shown, it includes the following steps: Step S410: Receive order information, parse the seed category and quantity, and locate the corresponding goods unit in the container.

[0076] Step S420: The picking mechanism in the cargo unit takes out the seed bags one by one according to the instructions. The seed bags fall into the conveying mechanism and are transported to the packaging mechanism.

[0077] Step S430: When the seed bag reaches the recognition unit, the seed bag image is acquired, and the image is preprocessed using a multi-scale retinal contrast recovery algorithm to eliminate illumination and wrinkle interference by separating the illumination component and the reflection component; the preprocessed image is input into a deep learning model, and small target features are extracted through a backbone network integrating channel attention and spatial attention, and multi-scale features under occlusion scenes are processed using an adaptive spatial feature fusion module to generate candidate bounding boxes; finally, the intersection-union ratio threshold is dynamically adjusted based on the width of the seed bag, and the candidate bounding boxes are filtered using an adaptive non-maximum suppression algorithm to count the number of seed bags; Step S440: If the statistical results show that the type and quantity of seed bags are consistent with the order, the packaging unit performs the packaging operation; if they are inconsistent, exception handling is triggered.

[0078] Specifically, the system can receive order information from a higher-level system (such as an e-commerce platform or enterprise ERP) via a network interface. The order parsing module extracts key fields, including seed type, specifications, quantity, and delivery requirements. Based on the seed type, the system looks up the coordinates of the corresponding cargo unit in a pre-stored container mapping table—the containers are typically multi-layered and multi-column designed, with each cell storing seed bags of the same specification. After positioning, the system sends a ready signal to the local controller of the target cargo unit and generates a queue for this pickup task.

[0079] The picking mechanism within the target cargo unit is activated upon instruction, separating and removing the seed bags one by one. The picking process must avoid pinching or throwing, ensuring the seed bags fall smoothly into the connecting conveyor (usually a belt conveyor or roller conveyor). The conveyor transports the seed bags to the packing station at a constant speed, and may include diversion or merging devices to accommodate multiple orders being processed concurrently.

[0080] As the seed bags pass through a specific identification station on the conveyor line, a high-resolution image is captured by an industrial camera under uniform lighting conditions. To overcome the effects of surface reflection, wrinkles, and uneven ambient lighting on the seed bags, a multi-scale retinal contrast restoration algorithm is used to preprocess the original image. This algorithm, by simulating the contrast enhancement mechanism of the human retina, decomposes the image into illumination and reflection components, effectively separating the texture and color information of the target itself, and significantly reducing interference caused by non-uniform lighting and surface wrinkles.

[0081] The preprocessed image is input into a dedicated deep learning detection model. This model, with a convolutional network integrating channel attention and spatial attention mechanisms as its backbone, can focus on small targets like seed bags in complex backgrounds, enhancing their feature representation capabilities. To address potential overlap and occlusion of seed bags on the delivery line, the model introduces an adaptive spatial feature fusion module. This module dynamically adjusts the contribution weights of feature maps at different scales, generating at least one candidate bounding box. This allows the model to better integrate shallow detail features with deep semantic features, improving robustness in occluded scenarios.

[0082] The model outputs the localized bounding boxes and class confidence scores for the seed bags. To further optimize detection performance in dense scenes, the system dynamically adjusts the intersection-union (IU) threshold based on the average width of the current seed bags, preventing duplicate detection of the same seed bag due to thresholds that are too close. In the subsequent non-maximum suppression (NMS) stage, an adaptive NMS algorithm is employed, dynamically adjusting the suppression threshold based on the density and confidence of surrounding detection boxes, thereby effectively suppressing redundant boxes while preserving all true targets. Finally, the system counts the number of all retained boxes (after filtering candidate bounding boxes) and summarizes the number for each class as the visual counting result.

[0083] The system automatically compares the visual statistics results with the order information. If the category and quantity are completely consistent, a packing permission signal is sent to the packing unit. After receiving the signal, the packing unit (such as an automatic folding and sealing machine or a bag sealing machine) performs sealing, labeling, and other operations to complete the package output.

[0084] If discrepancies are found during comparison (such as excess, shortage, or incorrect goods), the anomaly handling process is immediately triggered: the system pauses the conveyor line, issues an audible and visual alarm to the operator, and displays anomaly details (such as missing items or quantity differences) on the human-machine interface. Simultaneously, the system records anomaly images and data for subsequent traceability and analysis. After manual intervention confirms the anomaly or the goods are replenished, the system can resume the process from the point of anomaly or restart order processing.

[0085] The automated seed bag delivery method provided in this embodiment achieves unmanned and precise seed bag delivery. Utilizing advanced image processing and deep learning technologies, it effectively solves the identification challenges caused by the soft, easily wrinkled, and easily obscured packaging of agricultural materials, ensuring the accuracy and reliability of delivery. This provides a solution for automated delivery in seed e-commerce and large-scale agricultural material warehousing.

[0086] In some embodiments, to address the issue of image detail blurring caused by uneven warehouse lighting (such as strong light near windows and weak light in corners) and bag wrinkles, an improved Retinex algorithm (MSRCR) is used instead of the default YOLOv11 preprocessing. This algorithm eliminates lighting interference while preserving the details of the text and patterns on the seed bag labels. Its core logic is to decompose the image into real features (reflection component R) and environmental interference (light component L). By separating and suppressing the light component and preserving and enhancing the reflection component, the interference caused by uneven lighting and wrinkles is eliminated, restoring the true details of the label text and patterns.

[0087] Specifically, the calculation process for image preprocessing using the multi-scale retinal contrast restoration algorithm is as follows: The captured images Decomposed into reflection components With light component , ; Represents the spatial coordinates of a specific pixel in an image; The illumination components are estimated by convolving the image with three Gaussian filters Gk of different scales k. . scale: A three-scale Gaussian filter is used: a 3×3 small scale to capture local light changes at the folds of the seed bag; a 7×7 medium scale to capture light differences in the AI ​​verification work area; and a 15×15 large scale to capture global light fluctuations in the warehouse. This step uses multi-scale Gaussian filtering to simulate the human eye's perception of light in different ranges, avoiding the problem of inaccurate estimation at a single scale. The small scale (3×3) captures local light, the medium scale (7×7) captures regional light, and the large scale (15×15) captures global light. Represents the convolution budget. This represents the estimated illumination component at the k-th scale.

[0088] Calculating multiscale retinal contrast The illumination components are separated by logarithmic operations: The corrected image is obtained through contrast stretching. As input to the deep learning model: logarithmic operation is mainly used to compress the brightness range of the image and enhance the details in the dark areas. +1 avoids the meaningless case of log(0) in the logarithmic operation; taking the average means summing the results of the three scales and then taking the average (balancing local and global contrast).

[0089] This represents the minimum value among the multi-scale retinal contrast results. This represents the maximum value in the multi-scale retinal contrast results. This indicates that the result is normalized to a pixel value range of 0-255.

[0090] After this processing, the standard deviation of image grayscale is reduced, the image brightness becomes more uniform, and local details become clearer, that is, the clarity of label text is improved, meeting the stability requirements of YOLOv11 for input features.

[0091] Finally, output a calibration image with uniform brightness and clear labels (size 2000×2000×1), which is then directly imported. Figure 5 The shown is the Conv k=3 s=2→C3K2 backbone network module.

[0092] In some embodiments, the backbone network can also be improved. The native YOLOv11 C3K2 module (grouped convolution for parameter reduction and efficiency improvement) is retained, and a lightweight CoAtNet attention (channel attention + spatial attention collaboration) is added to the backbone output layer (P3 / P4 / P5) to specifically enhance the extraction of key small target features such as seed bag label text and category identification patterns, and suppress background interference such as conveyor belt texture and warehouse dust.

[0093] Specifically, the preprocessed corrected image is downsampled to extract semantic features at different scales. At the same time, attention mechanisms are used to enhance small target features such as label text and category identification, while suppressing background interference such as conveyor belt texture and warehouse dust.

[0094] The process is as follows: Correcting images by Figure 5 The process shown goes through the Conv k=3 s=2→C3K2 module 5 times in sequence, gradually reducing the resolution and increasing the feature dimensions: Conv k=3 s=2: 3×3 convolution kernel (stride s=2) to achieve image size reduction (downsampling), and the number of channels gradually increases from 1 channel to 64→128→256→512→1024 channels; C3K2 module: It adopts grouped convolution technology to reduce the amount of computation while retaining key features, and is adapted to the feature diversity of 1500+ seed bags. After 5 downsampling operations, the output is... Figure 5 The three core scale feature maps shown are (P3 / P4 / P5): P3 (80×80×256): Small-scale feature map, corresponding to 1 / 25 downsampling of the original image, focusing on fine-grained features such as label text and small patterns; P4 (40×40×512): Mesoscale feature map, corresponding to 1 / 50 downsampling of the original image, capturing the overall outline of the seed bag and the layout of the category label; P5 (20×20×1024): Large-scale feature map, corresponding to 1 / 100 downsampling of the original image, to extract global semantic features (such as stacking relationships). In the P3 / P4 / P5 feature map output layer, according to Figure 5 The embedded channel attention + spatial attention collaborative module shown enhances key features on feature map F. Perform channel attention calculation to obtain channel weights. ; ; Channel attention is used to determine which channels contain the features of the label text / image, assign higher weights to these channels, and suppress interference from the background channels.

[0095] in, For global average pooling, the spatial region of each channel ( ) average, and Feature map compression The vector captures global information for each channel, where C represents the number of channels, and H and W represent the height and width of the feature map; It is a multi-layer fully connected layer; first, the channel dimension is compressed, and then the channel information is reconstructed. The activation function scales the output to the range [0,1] to obtain the importance weight of each channel; Spatial attention is calculated on the feature map F to obtain the spatial weights. ; ; Spatial attention is used to determine which spatial locations in the feature map are label text / images, assigning higher weights to these regions and ignoring background areas such as conveyor belts and dust. It involves spatial pooling concatenation, performing average pooling and max pooling on the feature maps respectively, resulting in two... The feature maps, after being stitched together, become Simultaneously capture regional brightness and regional extreme value information; It's a convolution operation that compresses the concatenated 2-channel feature map into a 1-channel feature map. ), learn the dependencies between spatial regions; The activation function compresses the output to the range [0,1], thus obtaining the importance weight of each spatial location.

[0096] This improvement enhances the model's feature response to label text, resolving the issue of misidentification of bags with similar appearances. For example, it can output enhanced feature maps at three scales (P3_attn: 80×80×256, P4_attn: 40×40×512, P5_attn: 20×20×1024), which are then input into the model. Figure 5 The BiFPN infrastructure + ASFF feature fusion module shown.

[0097] In some embodiments, feature fusion improvements are also involved, integrating enhanced features from P3 / P4 / P5 to dynamically adapt to seed bag stacking occlusion scenarios (e.g., the upper bag occludes 1 / 3 of the lower bag's area), addressing the poor adaptability of native BiFPN feature weights. This embodiment replaces the fixed-weight fusion logic of YOLOv11's native BiFPN by adding an ASFF module. For seed bag stacking occlusion scenarios (e.g., the upper bag occludes 1 / 3 of the lower bag's area), it dynamically allocates weights for features of different scales. For example, for partially occluded lower bags, it automatically increases the weight of small-scale P3 features (to highlight local edges) and decreases the weight of large-scale P5 features (to avoid background interference).

[0098] Specifically, for feature maps of different scales All feature maps are unified to the same size (i=3,4,5 correspond to P3 / P4 / P5). By upsampling (small scale → large scale) / downsampling (large scale → small scale), all feature maps are unified to the same size to prepare for subsequent fusion.

[0099] A bidirectional feature transfer structure of upsampling + concatenation + downsampling is adopted: Upsampling path: P5_attn is upsampled by 2 times, concatenated with P4_attn, fused by C3K2 module, upsampled by 2 times again, concatenated with P3_attn, and fused by C3K2 to obtain small-scale fused features; Downsampling path: Small-scale fusion features are downsampled by 2 times, concatenated with P4_attn, fused with C3K2, downsampled by 2 times again, concatenated with P5_attn, and fused with C3K2, to achieve bidirectional complementarity of cross-scale features.

[0100] An ASFF module is embedded in each BiFPN fusion node, and weights are dynamically allocated in three steps: To unify the size of the enhanced feature maps P3_attn, P4_attn, and P5_attn, upsampling (small → large) or downsampling (large → small) is used to uniformly scale them to the target size of the current fusion node (e.g., when fusing P3 and P4, P4 is upsampled to 80×80). , , (Same size); Dynamic weight calculation calculates the fusion weights for each scale of the feature map after it has been standardized. ;in The mean of multi-scale features, for Convolution (compresses channels to learn the relationships between features); As the activation function, the weights are constrained to the range [0,1]. The feature maps at different scales are summed by dynamic weights to obtain the fused features. . As a constraint, the weights are guaranteed to be a normalized allocation ratio.

[0101] By dynamically allocating scale feature weights, the problem of poor feature weight adaptability of native BiFPN in occluded scenarios is solved, which directly improves the recognition rate in occluded scenarios with stacked seed bags. It can output dynamic fused feature maps of 3 scales (with the same size as the feature map of the input ASFF) and pass them into the classification + regression branch.

[0102] The classification and regression branches are mainly based on the fused feature maps, which predict the category of the seed bag and the parameters of the detection box, providing a basis for subsequent loss calculation and counting.

[0103] The processing flow is as follows: Each scale's fused feature map sequentially passes through Conv k=1 s=1 → BatchNorm → SiLU activation → Conv k=3 s=1 → fully connected layer; mapping the fused features to predicted probabilities for 1500+ categories. ( (Corresponding to a storage design for 1500+ product categories); Outputs a 1500-dimensional prediction probability vector (each dimension corresponds to the prediction probability of a product category); In parallel with the classification branch, the following steps are used: Conv k=1 s=1 → BatchNorm → SiLU activation → Conv k=3 s=1 → fully connected layer; Predict the four parameters of the seed bag detection box (center x-coordinate, center y-coordinate, width w, height h), and the current detection box score. ( , which represents the probability that the box is a seed bag); The width of the detection frame is linked to the width detection sensor data of the picking mechanism to provide width parameters for subsequent post-processing. Finally, the output can be categorized as follows: a prediction probability matrix of 1500+ categories (e.g., 80×80×1500); or a regression output: a bounding box parameter matrix (e.g., 80×80×4) + a confidence matrix (e.g., 80×80×1). Both types of outputs can be input simultaneously. Figure 5 The loss calculation (D-EFL) and post-processing (adaptive Soft-NMS) modules are shown.

[0104] In some embodiments, this application also improves the loss function. Based on the prediction results of the classification + regression branches and the true labels (manually labeled categories and detection boxes), the loss value is calculated for model parameter optimization, while adapting to the sample imbalance problem of 1500+ categories (niche categories with <50 samples, popular categories with >1500 samples). The native EFL (Effective Focal Loss) of YOLOv11 is improved by designing a dynamic gamma adjustment mechanism: for categories with small sample sizes (such as niche forage seeds), the gamma value is reduced (…). Reduce hard sample penalty; for categories with large sample sizes (such as common vegetable seeds), increase the gamma value ( ), suppress the weights of easily classified samples.

[0105] Specifically, the dynamic gamma value is calculated based on the sample size of this product category. ;in This represents the sample size for this product category. These are the maximum and minimum sample size thresholds, respectively; when , ,when , ,when In and In between, It fluctuates between 1.0 and 2.0.

[0106] based on Calculate the classification loss value ; in This represents the model's predicted probability for the current product category. For parameters. This formula is used to avoid the denominator being close to 0. It solves the problem of loss function adaptation under imbalanced samples by dynamically adapting the gamma value of different categories: for niche categories, it reduces the penalty for difficult samples, allowing the model to effectively learn its features from a small amount of data; for popular categories, it suppresses the interference of easily classified samples and focuses on the optimization of difficult samples.

[0107] The regression loss uses the native CIoU loss of YOLOv11. The total loss = D-EFL classification loss + CIoU regression loss, which is used for backpropagation to optimize model parameters (backbone network weights, attention module parameters, etc.). The total loss value is only used for parameter updates during the model training phase; in the actual shipping scenario (inference phase), it only outputs the classification prediction probability and detection box parameters and does not participate in the real-time verification process.

[0108] Ultimately, this significantly improves the accuracy of niche product category identification without affecting the identification of mainstream product categories, enabling the model to be adapted to the full range of seed bag verifications for 1500 product categories.

[0109] In some embodiments, the counting process can also be improved. For the counting problem in the post-detection processing stage of the YOLOv11 inference flow, and addressing the overlap issue in seed bag transmission (e.g., 2-3 bags stacked), the fixed IoU threshold of traditional Soft-NMS can be improved by adjusting the threshold based on the seed bag width. Calculate the dynamic crossover ratio threshold : wide bag ( Threshold increase ( ), avoid combining multiple bags for counting; narrow bags ( Threshold decreases ( ), to avoid missed detection.

[0110] Specifically, first filter the confidence levels. The detection boxes (considered as background noise) are excluded, and high-confidence candidate boxes are retained. The detection box width predicted based on the regression branch. Calculate the dynamic intersection-union ratio threshold. ; Calculate the current detection box With the highest-scoring detection box intersection ratio Candidate boxes are sorted by confidence level, and the current detection box score is calculated using adaptive Soft-NMS. .

[0111] ; like Then retain the score of the current detection box. ; like The score of the current detection box is then decayed using a Gaussian function. ;in This is the attenuation parameter.

[0112] , For decay rate parameter ( The smaller the value, the faster the score decays. (When overlapping...) This indicates that the current frame is an independent seed bag, and the original score is retained. ,when This indicates that the current bounding box is a duplicate detection box. Its score is decayed using an exponential function (boxes with too low a score are filtered out to avoid duplicate counting). The number of remaining detection boxes after filtering is the actual number of seed bags in the current image. The final category identification result (e.g., tomato seeds, forage seeds); or the precise counting result (e.g., 2 bags, 3 bags).

[0113] Finally, the category and quantity verification results can be accurately compared with the order requirements (category name, required quantity) issued by the WMS system, with a comparison time of ≤0.3s; Verification passed (category and quantity match): A verification pass signal is sent to the packaging unit, and logistics information (delivery address and logistics code) is pushed simultaneously. The seed bags enter the automatic packaging station with the conveyor belt. Verification failure (product category mismatch / quantity deviation): Send a verification anomaly alarm to the WMS system and trigger the conveyor belt diversion mechanism to transport the seed bags to the anomaly handling station. After manual review, you can choose to resend the goods (return to the cargo channel positioning stage) or cancel the order. The verification results (qualified / abnormal), identification confidence, counting results, and detection box parameters are sent back to the WMS system and bound to the order number to establish a traceability link between the order, image, and verification results, supporting subsequent queries and model iteration optimization.

[0114] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. An automatic seed bag dispensing device, characterized in that, include: The container has multiple cargo units arranged in an array. Each cargo unit is equipped with a picking mechanism. The outlet of the picking mechanism is located on a designated side of the container. The picking mechanism is used to store seed bags. A conveying mechanism is provided on the designated side of the container, with the inlet of the conveying mechanism located at the bottom of the outlet, for receiving seed bags taken out from the picking mechanism; as well as A packaging mechanism is located at the shipping end of the conveying mechanism. The packaging mechanism includes an identification unit and a packaging unit. The packaging unit is used to package the verified seed bags. The identification unit is configured to perform the following visual verification steps: acquiring an image of the seed bag. The image is preprocessed using a multi-scale retinal contrast restoration algorithm to eliminate illumination and wrinkle interference by separating the illumination component and the reflection component. The preprocessed image is input into a deep learning model. Small target features are extracted through a backbone network that integrates channel attention and spatial attention. The adaptive spatial feature fusion module is used to process multi-scale features in occluded scenes to generate candidate bounding boxes. Finally, the cross-union ratio threshold is dynamically adjusted based on the width of the seed bag, and the candidate bounding boxes are filtered using an adaptive non-maximum suppression algorithm to count the number of seed bags. If the statistical results show that the type and quantity of seed bags are consistent with the order, the packaging unit performs the packaging operation; If there is a discrepancy, exception handling will be triggered.

2. The automatic seed bag dispensing device according to claim 1, characterized in that, The picking mechanism includes: a drive wheel, a driven wheel, and a first motor; The conveying mechanism has a vertical stacking groove inside, and one end of the stacking groove has an outlet. A discharge channel is formed between the outlet and the discharge port. The driving wheel and the driven wheel are spaced apart in the discharge channel. The driving wheel and the driven wheel are connected by a drive mechanism. The first motor is connected by a drive mechanism to the driving wheel. The first motor is used to drive the driven wheel to rotate through the driving wheel. The driving wheel and the driven wheel work together to drive the seed bag to move in the discharge channel.

3. The automatic seed bag dispensing device according to claim 2, characterized in that, The picking mechanism also includes: a photoelectric encoder and a photoelectric sensor; Both the photoelectric encoder and the photoelectric sensor are electrically connected to the first motor. The photoelectric encoder is located at the shaft end of the drive wheel and is used to detect the rotation angle of the drive wheel to calculate the conveying stroke of the seed bag. The photoelectric sensor is located at the outlet and is used to detect whether the seed bag has been successfully removed.

4. A method for automatically dispensing seed bags, characterized in that, The automatic seed bag dispensing device applied to any one of claims 1-3 includes the following steps: Receive order information, analyze the seed type and quantity, and locate the corresponding cargo unit in the container; The picking mechanism within the cargo unit removes the seed bags one by one according to instructions. The seed bags fall into the conveying mechanism and are then transported to the packing mechanism. When a seed bag reaches the recognition unit, an image of the seed bag is acquired. The image is preprocessed using a multi-scale retinal contrast restoration algorithm to eliminate interference from illumination and wrinkles by separating the illumination component and the reflection component. The preprocessed image is then input into a deep learning model. Small target features are extracted through a backbone network that integrates channel attention and spatial attention. An adaptive spatial feature fusion module is used to process multi-scale features in occluded scenes to generate candidate bounding boxes. Finally, the intersection-union ratio (IUU) threshold is dynamically adjusted based on the seed bag width, and an adaptive non-maximum suppression algorithm is used to filter candidate bounding boxes for seed bag count. If the statistical results show that the type and quantity of seed bags are consistent with the order, the packaging unit will perform the packaging operation; otherwise, an exception will be triggered.

5. The automatic seed bag delivery method according to claim 4, characterized in that, The specific calculation process for image preprocessing using the multi-scale retinal contrast restoration algorithm is as follows: The captured images Decomposed into reflection components With light component Through multiple Gaussian filters G of different scales k k Convolve the image to estimate the illumination components. ; Represents the spatial coordinates of a specific pixel in an image; Calculating multiscale retinal contrast The illumination components are separated by logarithmic operations: The corrected image is obtained through contrast stretching. As input to deep learning models : This represents the minimum value among the multi-scale retinal contrast results. This represents the maximum value in the multi-scale retinal contrast results. This indicates that the result is normalized to a pixel value range of 0-255.

6. The automatic seed bag delivery method according to claim 4, characterized in that, The steps in deep learning models for extracting features from small targets include: For feature map F, Perform channel attention calculation to obtain channel weights. ; ; in, Represents the set of real numbers; For global average pooling, the spatial region of each channel ( ) average, and Feature map compression The vector captures global information for each channel, where C represents the number of channels, and H and W represent the height and width of the feature map; It is a multi-layer fully connected layer; first, the channel dimension is compressed, and then the channel information is reconstructed. For activation functions; Spatial attention is calculated on the feature map F to obtain the spatial weights. ; ; in, It is spatial pooling splicing; It is a convolution operation; Final feature map .

7. The automatic seed bag delivery method according to claim 4, characterized in that, The steps for processing multi-scale features in occluded scenes using an adaptive spatial feature fusion module include: Feature maps at different scales All should be of the same size; Calculate the fusion weights for feature maps at each scale. ;in The mean of multi-scale features, for convolution; For activation functions; The feature maps at different scales are summed by dynamic weights to obtain the fused features. .

8. The automatic seed bag delivery method according to claim 4, characterized in that, The deep learning model is trained using a dynamic effective focus loss function to adapt to seed categories with different sample sizes. The calculation of this loss function includes: Calculate the dynamic gamma value based on the product category sample size. ;in This represents the sample size for this product category. and These are the maximum and minimum sample size thresholds, respectively; based on Calculate the loss value ; in This represents the model's predicted probability for the current product category. For parameters.

9. The automatic seed bag delivery method according to claim 4, characterized in that, The steps for seed bag count using the adaptive nonmaximum suppression algorithm include: Get the width of the seed bag Calculate the dynamic intersection-union ratio threshold. ; Calculate the current detection box With the highest-scoring detection box intersection ratio ; like Then retain the score of the current detection box. ; like The score of the current detection box is then decayed using a Gaussian function. ;in This is the attenuation parameter.

10. The automatic seed bag delivery method according to claim 4, characterized in that, During automated picking and conveying, the picking mechanism performs the following actions: Get the width information of the seed bags in the order; Based on this width information, the stacking slot inside the picking mechanism drives the two side uprights to move, adjusting the width of the stacking slot to the reserved gap value for the width of the seed bag; The roller assembly at the outlet of the picking mechanism rotates, driving the bottom seed bag to separate and slide out of the outlet through friction.