A system and method for detecting the appearance of a green leafy vegetable before preservation packaging

CN122591672APending Publication Date: 2026-08-18ZHONGKAI UNIV OF AGRI & ENG
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202610726891.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-05-25
Publication Date
2026-08-18

AI Technical Summary

Technical Problem

[0002]现有绿叶蔬菜保鲜包装前的外观检测装置多采用固定视角扫描方式,如公开号CN221472644U的实用新型专利所公开的方案,仅能对蔬菜单一平面进行图像采集,无法覆盖蔬菜侧面及根蒂端部等盲区,导致虫咬、机械损伤或早期黄化等缺陷极易因遮挡或角度偏差而被漏检,检测准确率难以满足高端生鲜供应链的品质管控需求,且现有设备往往依赖多组独立驱动的摄像头与翻转机构,机械结构复杂,制造成本与能耗较高,难以适配高速流转的自动化产线

Benefits of technology

实现蔬菜多角度全方位自动检测,显著提升检测准确性,通过设置升降式翻面机构,在扫描装置下方配置主动筒、从动筒以及与其联动的直齿轮二、传动轮三、传动带二、传动轮四等传动部件,利用电机作为唯一动力源,在蔬菜被传输带本体输送至扫描装置下方后,通过电动推杆推动辅助箱上升,使直齿轮二与直齿轮一啮合,从而带动主动筒转动,使蔬菜在扫描装置下方自动旋转;相比传统仅能单面检测的设备,本发明能够使扫描装置获取蔬菜多个角度的图像数据,极大提高了蔬菜外观缺陷检测准确率。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122591672A_ABST
    Figure CN122591672A_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of vegetable detection, and provides a system and method for appearance detection of green leaf vegetables before preservation packaging. The system comprises a support, a double transmission belt device and a lifting type turnover mechanism driven by a single motor. By integrating a telescopic mirror assembly in an auxiliary box, the blind area problem of vegetable end detection is solved by using the mirror reflection principle. In particular, the image recognition system of the present application introduces an adaptive threshold segmentation algorithm with end compensation. By dynamically adjusting the compensation coefficient, the difference between mirror reflection and illumination is eliminated. The present application realizes automatic turnover and multi-angle imaging of vegetables under a single power source, simplifies the mechanical structure while ensuring detection accuracy, and effectively improves the detection accuracy and packaging efficiency of green leaf vegetable appearance defects.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of vegetable testing technology, specifically to an appearance inspection system and method for leafy green vegetables before packaging for preservation. Background Technology

[0002] Existing appearance inspection devices for leafy green vegetables before packaging often use a fixed-view scanning method, such as the solution disclosed in utility model patent CN221472644U. This method can only collect images of a single plane of the vegetable and cannot cover blind spots such as the sides and stem ends of the vegetable. As a result, defects such as insect bites, mechanical damage, or early yellowing are easily missed due to obstruction or angle deviation. The detection accuracy is difficult to meet the quality control requirements of the high-end fresh food supply chain. Moreover, existing equipment often relies on multiple independently driven cameras and flipping mechanisms, which have complex mechanical structures, high manufacturing costs and energy consumption, and are difficult to adapt to high-speed automated production lines.

[0003] Traditional visual algorithms are mostly based on fixed thresholds to extract geometric features from binary images. They are easily affected by the shadows of vegetable leaf veins, surface water stains and changes in ambient light, resulting in a high rate of missed detection and false positives for defects such as early yellowing and minor insect bites. Summary of the Invention

[0004] To address the aforementioned technical problems, this invention aims to provide an appearance inspection system and method for leafy green vegetables before packaging for preservation. To solve these problems, this invention employs the following technical solution: A visual inspection system for leafy green vegetables before packaging includes a support, a conveyor belt device, rotating rollers, a scanning device, and a motor. The conveyor belt device is fixedly connected to the support, and the motor and the scanning device are both fixedly connected to the conveyor belt device. The motor output shaft is fixedly connected to one of the rotating rollers, and the two rotating rollers are rotatably connected to the conveyor belt device. The two conveyor belt bodies are connected between the two rotating rollers, and there is a gap between the two conveyor belt bodies. A lifting flipping mechanism is connected to the support. The scanning device is equipped with an image recognition system, and the support is equipped with a processing module.

[0005] Optionally, the lifting flipping mechanism includes an auxiliary box, an electric push rod, and a fixed trapezoidal component. The electric push rod and the fixed trapezoidal component are both fixed to the support. The auxiliary box is fixed to the electric push rod. The auxiliary box has an open structure at the top and bottom and is equipped with a photoelectric sensor. The auxiliary box is rotatably connected to spur gear two, transmission wheel three, transmission wheel four, driving cylinder and driven cylinder. The driving cylinder and transmission wheel four are fixedly connected and rotate coaxially. Spur gear two and transmission wheel three are fixedly connected and rotate coaxially. Transmission wheel three is connected to transmission wheel four through transmission belt two. The driving cylinder and driven cylinder extend to the top of the auxiliary box. Two bent movable rods are slidably connected inside the auxiliary box. Movable trapezoidal parts are fixedly connected to the bent movable rods. The bent movable rods are connected to the inner wall of the auxiliary box through springs. A mirror is connected to the bent movable rods. A transmission wheel is fixedly connected to the output shaft of the motor. A transmission rod is rotatably connected to the transmission belt device. A transmission wheel and a spur gear are fixedly connected to the transmission rod. The transmission wheel is connected to the transmission wheel via the transmission belt.

[0006] Optionally, the fixed trapezoidal member is located above the two movable trapezoidal members.

[0007] Optionally, the mirror is connected to the bending movable rod via an angle adjustment mechanism.

[0008] Optionally, the inner wall of the auxiliary box is connected to the outer wall of the auxiliary box through two lens outlets.

[0009] Optionally, the two mirrors and the two mirror outlets are located on the same horizontal plane.

[0010] Optionally, the second spur gear extends outside the auxiliary box.

[0011] Optionally, the fixed trapezoidal member is fixed to the support by a support rod.

[0012] A method for processing appearance inspection data before preserving and packaging leafy green vegetables, applied to the aforementioned appearance inspection system for preserving and packaging leafy green vegetables, includes the following steps: Step 1: Receive the main image of the vegetable and the image of the vegetable end reflected by the mirror from the scanning device, and use the mirror transformation matrix to perform coordinate flip correction on the end image; Step 2: The corrected image is processed using an adaptive threshold segmentation algorithm with end compensation. The algorithm dynamically adjusts the end image compensation coefficient to extract the complete contour region of the vegetable. Step 3: When real-time and fast processing is required, the contour region is converted into a binary image, color features, texture features and shape features are extracted, and compared with a preset standard feature library; when fine recognition is required, the contour region is kept as a 0-255 grayscale image, input into a pre-trained lightweight convolutional neural network to extract deep feature vectors, and the cosine similarity between the feature vectors and the preset standard feature library is calculated. Step 4: When the comparison result or cosine similarity is lower than the preset threshold, a defect alarm signal is generated.

[0013] A method for visual inspection of leafy green vegetables before packaging for preservation, comprising the following steps: The method utilizes a visual inspection system for leafy green vegetables before packaging to perform multi-angle scanning inspection of the vegetables. Step 1: Place the vegetables on the two conveyor belts, with the vegetables spanning the gap between the two conveyor belts; Step 2: Turn on the motor. The motor output shaft drives the rotating rollers and the conveyor belt to rotate, thereby causing the conveyor belt to transport the vegetables to the area below the scanning device. Step 3: Use the lifting and flipping mechanism to lift the vegetables and flip them over. The vegetables are temporarily removed from the conveyor belt body, and the scanning device acquires image data of the vegetables from multiple angles. Step 4: Use the lifting and flipping mechanism to bring the vegetables back into contact with the conveyor belt body, and the conveyor belt body will send the vegetables away from below the scanning device to enter the subsequent process.

[0014] The present invention has the following beneficial effects: This invention enables multi-angle, all-around automatic detection of vegetables, significantly improving detection accuracy. It employs a lifting and flipping mechanism, with a driving cylinder, a driven cylinder, and linked transmission components such as a second spur gear, a third transmission wheel, a second transmission belt, and a fourth transmission wheel located below the scanning device. Using a motor as the sole power source, after the vegetables are conveyed to the area below the scanning device by the conveyor belt, an electric push rod pushes the auxiliary box upwards, causing the second spur gear to mesh with the first spur gear, thereby rotating the driving cylinder and causing the vegetables to rotate automatically below the scanning device. Compared to traditional devices that can only detect one side, this invention allows the scanning device to acquire image data from multiple angles of the vegetables, greatly improving the accuracy of detecting vegetable appearance defects. Attached Figure Description

[0015] The present invention will be further described with reference to the accompanying drawings, but the embodiments in the drawings do not constitute any limitation on the present invention. For those skilled in the art, other drawings can be obtained based on the following drawings without creative effort.

[0016] Figure 1 This is a flowchart of a method for visual inspection of leafy green vegetables before packaging for preservation, according to the present invention; Figure 2 This is a schematic diagram of the appearance inspection device for leafy green vegetables before packaging for preservation, according to the present invention. Figure 3 This is a schematic diagram of the auxiliary box, transmission rod, spur gear 1, and motor in this invention; Figure 4 This is a cross-sectional view of the auxiliary box in this invention.

[0017] Reference numerals: 1. Support; 2. Conveyor belt device; 3. Conveyor belt body; 4. Rotating roller; 5. Scanning device; 6. Motor; 7. Transmission wheel one; 8. Transmission belt one; 9. Transmission wheel two; 10. Transmission rod; 11. Spur gear one; 12. Auxiliary box; 13. Electric push rod; 14. Spur gear two; 15. Transmission wheel three; 16. Transmission belt two; 17. Transmission wheel four; 18. Driving cylinder; 19. Driven cylinder; 20. Fixed trapezoidal component; 21. Movable trapezoidal component; 22. Bending movable rod; 23. Mirror; 24. Spring; 25. Mirror outlet. Detailed Implementation

[0018] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0019] In the description of this invention, it should be noted that the terms "vertical," "upper," "lower," and "horizontal," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are used only for the convenience of describing the invention and for simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on the invention. Furthermore, "first," "second," "third," and "fourth" are used for descriptive purposes only and should not be construed as indicating or implying relative importance.

[0020] In the description of this invention, it should also be noted that, unless otherwise explicitly specified and limited, the terms "set," "install," "connect," and "link" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or a connection through an intermediate medium; and they can refer to the internal communication between two components. Those skilled in the art can understand the specific meaning of the above terms in this invention according to the specific circumstances.

[0021] Example 1: Mechanical structure and basic workflow of the detection system: like Figures 2-4As shown, an appearance inspection system for leafy green vegetables before packaging includes a support 1, a conveyor belt device 2, rotating rollers 4, a scanning device 5, and a motor 6. The conveyor belt device 2 is fixedly connected to the support 1. The motor 6 and the scanning device 5 are both fixedly connected to the conveyor belt device 2. The output shaft of the motor 6 is fixedly connected to one of the rotating rollers 4. The two rotating rollers 4 are rotatably connected to the conveyor belt device 2. The two conveyor belt bodies 3 are connected between the two rotating rollers 4. There is a gap between the two conveyor belt bodies 3. A lifting flipping mechanism is connected to the support 1.

[0022] Support 1 is used to support and fix the entire detection system, and conveyor belt body 3 is used to carry and transport vegetables. The gap between the two conveyor belt bodies 3 provides lifting space for the lifting flipping mechanism.

[0023] Based on the above scheme, in some embodiments, the lifting flipping mechanism includes an auxiliary box 12, an electric push rod 13 and a fixed trapezoidal component 20. The electric push rod 13 and the fixed trapezoidal component 20 are both fixedly connected to the support 1. The auxiliary box 12 is fixedly connected to the electric push rod 13. The auxiliary box 12 has an open structure at the top and bottom. A photoelectric sensor (not shown in the figure) is provided on the auxiliary box 12. The electric push rod 13 is used to drive the auxiliary box 12 to move up and down, and the photoelectric sensor is used to detect whether the vegetables have been delivered to the correct position to trigger the lifting action.

[0024] A spur gear 14, a transmission wheel 15, a transmission wheel 17, a drive cylinder 18, and a driven cylinder 19 are rotatably connected to the auxiliary box 12. The drive cylinder 18 and the transmission wheel 17 are fixedly connected and rotate coaxially. The spur gear 14 and the transmission wheel 15 are fixedly connected and rotate coaxially. The transmission wheel 15 is connected to the transmission wheel 17 via a transmission belt 16. The drive cylinder 18 and the driven cylinder 19 extend to the top of the auxiliary box 12. Two bent movable rods 22 are slidably connected inside the auxiliary box 12. A movable trapezoidal part 21 is fixedly connected to the bent movable rod 22. The bent movable rod 22 is connected to the inner wall of the auxiliary box 12 via a spring 24. A mirror 23 is connected to the bent movable rod 22. The active cylinder 18 is used to drive the vegetables to rotate so as to achieve multi-angle detection, and the mirror 23 is used to reflect the images at both ends of the vegetables for the scanning device 5 to collect.

[0025] A transmission wheel 7 is fixedly connected to the output shaft of the motor 6. A transmission rod 10 is rotatably connected to the transmission belt device 2. A transmission wheel 9 and a spur gear 11 are fixedly connected to the transmission rod 10. The transmission wheel 9 is connected to the transmission wheel 7 through a transmission belt 8.

[0026] In an optional embodiment of the invention, the fixed trapezoidal member 20 is located above the two movable trapezoidal members 21.

[0027] The fixed trapezoidal member 20 is used to push the movable trapezoidal member 21 when the auxiliary box 12 rises, thereby driving the mirror 23 to extend.

[0028] In an optional embodiment, the mirror 23 is connected to the bent movable rod 22 via an angle adjustment mechanism. The angle adjustment mechanism is used to adjust the tilt angle of the mirror 23 to accommodate different types and sizes of vegetables.

[0029] In some embodiments, the inner wall of the auxiliary box 12 is connected to the outer wall of the auxiliary box 12 through two lens exit ports 25.

[0030] It is worth noting that the two mirrors 23 and the two mirror outlets 25 are located on the same horizontal plane. The mirror outlets 25 are used to provide a channel for the mirrors 23 to extend out of the auxiliary box 12.

[0031] Additionally, the second spur gear 14 extends to the outside of the auxiliary housing 12. The second spur gear 14 extends to the outside so that it can mesh with the first spur gear 11 after the auxiliary housing 12 is raised, thereby obtaining rotational power.

[0032] Optionally, the fixed trapezoidal member 20 is fixed to the support 1 by a support rod.

[0033] Furthermore, the scanning device 4 is equipped with an image recognition system, and the support 1 is equipped with a processing module. The processing module is capable of component control and data analysis, thereby automating the detection process.

[0034] The image recognition system includes an image acquisition module, an image distortion correction module, an image enhancement module, an image segmentation module, and a feature extraction module; The image acquisition module is used to receive vegetable images directly acquired by the scanning device 5 and images of both ends of the vegetable acquired by reflection through the mirror 23; The image distortion correction module corrects distortion in the acquired images. For barrel distortion caused by wide-angle lenses, the system uses pre-stored camera calibration parameters to correct the distortion and restore the true proportions of the vegetables. To address the left-right mirroring issue caused by mirror 23, the system performs a mirror flip operation on the end-reflected image to ensure its coordinate system is consistent with the front view of the vegetables. The processed image eliminates optical errors and viewing angle differences, providing an accurate input source for subsequent adaptive thresholding segmentation with end compensation.

[0035] The image enhancement module performs denoising, contrast enhancement, and edge sharpening on the corrected image. The denoising process uses a median filtering algorithm to eliminate salt-and-pepper noise in the image, and the contrast enhancement uses a histogram equalization algorithm to stretch the grayscale range of the image.

[0036] The image segmentation module uses an adaptive threshold segmentation algorithm to separate the vegetable region from the background region in the enhanced image and extract the complete vegetable outline; Optionally, the threshold segmentation algorithm includes adaptive threshold segmentation with end compensation, the specific formula of which is:

[0037] Coordinates in the segmented binary image Pixel value at; Coordinates in the enhanced image The grayscale value at that location; In pixels Centered on r It is the Gaussian weighted average value within the radius neighborhood, i.e., the dynamic threshold; W End image compensation coefficient, used to dynamically adjust the threshold according to the brightness difference of the reflection area of ​​mirror 23; C : An empirical constant, with a value of 10~15, used to control segmentation sensitivity; 1: This indicates that the pixel belongs to the vegetable area; 0: This indicates that the pixel belongs to the background area.

[0038] This formula uses a dynamic threshold. Apply compensation coefficient W Segmentation is performed by setting the end image compensation coefficient. W This formula can perform threshold correction on the mirror reflection area, reducing missegmentation problems caused by reflection angle, light attenuation, or differences in end brightness, so that both the front and end areas of the vegetable can be extracted more accurately. Its effect is to improve the integrity and stability of vegetable contour extraction, providing a more accurate image basis for subsequent extraction of color, texture, and shape features, as well as defect area identification.

[0039] The feature extraction module extracts color, texture, and shape features from the segmented vegetable regions and compares them with a preset standard vegetable feature library to identify defective areas on the vegetable surface.

[0040] like Figure 1 As shown, a method for visual inspection of leafy green vegetables before packaging for preservation involves using a visual inspection system for leafy green vegetables to perform multi-angle scanning inspection of the vegetables, including the following steps: Step 1: Place the vegetables on the two conveyor belt bodies 3, with the vegetables spanning the gap between the two conveyor belt bodies 3; Step 2: Turn on motor 6. The output shaft of motor 6 drives the rotating roller 4 and the conveyor belt body 3 to rotate, thereby causing the conveyor belt body 3 to transport the vegetables to the area below the scanning device 5. Step 3: Use the lifting and flipping mechanism to lift the vegetables and flip them over. The vegetables are temporarily separated from the conveyor belt body 3, and the scanning device 5 acquires image data of the vegetables from multiple angles. Step 4: Use the lifting and flipping mechanism to make the vegetables come into contact with the conveyor belt body 3 again, and the conveyor belt body 3 will send the vegetables away from the scanning device 5 to enter the subsequent process.

[0041] Working principle: In the initial state, mirror 23 is retracted into auxiliary box 12, and the driving cylinder 18, driven cylinder 19, and auxiliary box 12 are all lower than the top wall of the conveyor belt body 3. Spur gear 24 is not meshed with spur gear 11. The angle of mirror 23 is adjusted by the angle adjustment mechanism to slightly tilt the mirror 23, so as to reflect the appearance of both ends of the vegetables.

[0042] refer to Figure 2 The direction is such that the vegetables are placed on the front side of the top wall of the two conveyor belt bodies 3. The method of placing the vegetables can be completed by existing automatic feeding mechanisms or manual feeding, which is not limited here.

[0043] The vegetables span the gap between the two conveyor belt bodies 3. The motor 6 is turned on, and the output shaft drives the rotating roller 4 and the conveyor belt body 3 to rotate, so that the conveyor belt body 3 transports the vegetables to the area below the scanning device 5. At this time, the vegetables are located above the active cylinder 18 and the driven cylinder 19. After the photoelectric sensor detects that the vegetables are in place, the processing module controls the electric push rod 13 to move upward, so that the active cylinder 18 and the driven cylinder 19 lift the vegetables. The vegetables are temporarily separated from the conveyor belt body 3. When the exit port 25 moves above the conveyor belt body 3, the movable trapezoidal part 21 and the fixed trapezoidal part 20 abut against each other. The inclined surface of the movable trapezoidal part 21 is pushed by the inclined surface of the fixed trapezoidal part 20. The two movable trapezoidal parts 21 and the mirror 23 overcome the elastic force of the spring 24 and move away from each other. The mirror 23 extends through the exit port 25 to the outside of the auxiliary box 12 so that the mirror 23 can reflect the appearance of both ends of the vegetables, so that the scanning device 5 can obtain the image data of both ends of the vegetables through the mirror 23.

[0044] The auxiliary box 12 continues to move upward, and the second spur gear 14 and the first spur gear 11 mesh. The output shaft of the motor 6 drives the first transmission wheel 7, the first transmission belt 8, the second transmission wheel 9, the transmission rod 10, the first spur gear 11, the second spur gear 14, the third transmission wheel 15, the second transmission belt 16, the fourth transmission wheel 17, and the active cylinder 18 to rotate. This causes the active cylinder 18 to drive the vegetable to rotate, and the driven cylinder 19 rotates together with the vegetable. This allows the scanning device 5 to acquire image data of the vegetable from different angles. The image data is transmitted to the image recognition system for recognition, thereby obtaining multi-angle and accurate detection of the vegetable's appearance.

[0045] After the vegetables rotate several times, the processing module controls the electric push rod 13 to move down, the second spur gear 14 disengages and engages with the first spur gear 11, and the active cylinder 18, the second spur gear 14 and other components stop rotating to reduce wear and extend the service life of the components. Then the movable trapezoidal part 21 disengages and engages with the fixed trapezoidal part 20. The two mirrors 23 move closer to each other and retract into the auxiliary box 12 under the elastic force of the spring 24 to prevent the mirrors 23 from colliding with the conveyor belt body 3 and to avoid interfering with the lifting and lowering of the auxiliary box 12. The active cylinder 18 and the driven cylinder 19 move back to below the top wall of the conveyor belt body 3, and the vegetables engage with the conveyor belt body 3 again. The conveyor belt body 3 transports the vegetables. Subsequently, the vegetables can be screened according to the test results. Unqualified vegetables are put into one box and qualified vegetables are put into another box. The qualified vegetables are then packaged and stored.

[0046] Example 2: A method for identifying vegetable appearance defects based on multidimensional vision: A method for processing appearance inspection data before preserving and packaging leafy green vegetables, applied to the aforementioned appearance inspection system for preserving and packaging leafy green vegetables, includes the following steps: Step 1: Receive the main image of the vegetable and the end image of the vegetable reflected by the mirror 23 from the scanning device 5, and perform coordinate flipping correction on the end image using the mirror transformation matrix; Step 2: The corrected image is processed using an adaptive threshold segmentation algorithm with end compensation. The algorithm dynamically adjusts the end image compensation coefficient to extract the complete contour region of the vegetable. Step 3: When real-time and fast processing is required, the contour region is converted into a binary image, color features, texture features and shape features are extracted, and compared with a preset standard feature library; when fine recognition is required, the contour region is kept as a 0-255 grayscale image, input into a pre-trained lightweight convolutional neural network to extract deep feature vectors, and the cosine similarity between the feature vectors and the preset standard feature library is calculated. Step 4: When the comparison result or cosine similarity is lower than the preset threshold, a defect alarm signal is generated.

[0047] It should be noted that this embodiment uses the same image processing logic as Embodiment 1 above. Both use an adaptive threshold segmentation algorithm with end-point compensation as the front-end preprocessing to ensure adaptability to the reflection area of ​​mirror 23. The core difference between the two lies in the depth of the feature extraction dimension. This embodiment focuses on the integrity verification of the basic contour, using the segmented binary image, i.e., pixel values ​​0 and 1, for fast processing. Since the binary image only retains the edge information of the object, the system can only extract color statistics and basic geometric features, which is suitable for removing severely damaged or obviously foreign objects.

[0048] This second embodiment focuses on the refined identification of microscopic defects. Since lightweight convolutional neural networks need to extract deep texture features from pixel grayscale variations, this step directly extracts feature vectors based on the segmented grayscale image, i.e., pixel values ​​from 0 to 255. Compared to binary images, grayscale images preserve the light and shadow variations and texture details on the vegetable surface, enabling the neural network to accurately distinguish between minute insect bites, early yellowing, and normal leaf vein wrinkles. This architecture fundamentally solves the problem of high false negative rates in complex backgrounds with single algorithms, achieving a substantial improvement in detection accuracy.

[0049] like Figure 1 and Figure 4 As shown, after the scanning device 5 acquires the front view image of the vegetable body and the end reflection image acquired through the mirror 23, it transmits them to the processing module in the support 1 for the following processing: Step 1: Specular Reflection Correction and Preprocessing Due to the reflection effect of mirror 23, the end image is mirrored horizontally. The processing module first performs coordinate normalization on the reflected image to eliminate the mirror difference. Let the homogeneous coordinates of a pixel in the original reflected image be... Transformation matrix via mirror M flip Map it to correction coordinates :

[0050] in D The image width is defined as [value]. Subsequently, a median filtering algorithm is used to denoise the corrected image, eliminating salt-and-pepper noise caused by conveyor belt vibration.

[0051] Step 2: Adaptive Threshold Segmentation Using the adaptive threshold segmentation algorithm with end-compensation described in Example 1, the corrected image is preprocessed to accurately extract the complete contour region of the vegetables. R obj Unlike Example 1, which directly outputs 0 and 1, this example preserves the grayscale information of the image. The specific formula is as follows:

[0052] Step 3: Defect Classification Based on Deep Feature Vectors The processing module calls a pre-built lightweight convolutional neural network, preferably MobileNet-V3, to process the grayscale image regions generated in step two. R obj Feature extraction is performed to obtain feature vectors. V test .calculate V test With standard healthy vegetable characteristic libraryV std Cosine similarity:

[0053] when , When the value is preferably 0.88, the vegetable is determined to have an appearance defect, and a rejection signal is triggered by the subsequent sorting mechanism.

[0054] Beneficial effects of this invention: This invention enables automatic multi-angle and all-around detection of vegetables, significantly improving detection accuracy. By incorporating a lifting and flipping mechanism, a drive cylinder 18, a driven cylinder 19, and linked transmission components such as a second spur gear 14, a third transmission wheel 15, a second transmission belt 16, and a fourth transmission wheel 17 are arranged below the scanning device 5. Using a motor 6 as the sole power source, after the vegetables are conveyed to the area below the scanning device 5 by the conveyor belt body 3, an electric push rod 13 pushes the auxiliary box 12 upward, causing the second spur gear 14 to mesh with the first spur gear 11, thereby rotating the drive cylinder 18 and causing the vegetables to rotate automatically below the scanning device 5. Compared to traditional devices that can only detect one side, this invention enables the scanning device 5 to acquire image data of vegetables from multiple angles, greatly improving the accuracy of vegetable appearance defect detection. The unique telescopic avoidance structure of the mirror 23 enables automatic imaging of the vegetable ends. Two bent movable rods 22 are slidably connected inside the auxiliary box 12. Movable trapezoidal components 21 are fixed to the bent movable rods 22 and connected to the mirror 23. The inner wall of the auxiliary box 12 communicates with the outside through two mirror outlets 25. When the auxiliary box 12 rises until the mirror outlets 25 are higher than the top wall of the conveyor belt body 3, the movable trapezoidal component 21 abuts against the fixed trapezoidal component 20. Under the action of the inclined plane, the two movable trapezoidal components 21 overcome the elastic force of the spring 24 and move away from each other, causing the mirror 23 to extend through the mirror outlets 25. At this time, the mirror 23 can reflect the images of both ends of the vegetable, allowing the scanning device 5 to simultaneously acquire complete appearance data of the vegetable body and both ends without increasing the number of cameras. After the detection is completed, the auxiliary box 12 descends, and the two mirrors 23 automatically retract into the auxiliary box 12 under the elastic force of the spring 24, effectively avoiding collisions with the conveyor belt body 3. The structure is compact and the operation is reliable. With high interconnectivity and reduced need for electric drive sources, this invention allows the output shaft of motor 6 to simultaneously drive transmission wheel 7, transmission belt 8, transmission wheel 9, transmission rod 10, and spur gear 11. In turn, spur gear 14, transmission wheel 15, transmission belt 16, and transmission wheel 17 drive the active cylinder 18 to rotate. The same motor 6 also drives the rotating roller 4 and the conveyor belt body 3 to transport vegetables. The entire detection process only requires one motor 6 and one electric push rod 13 to complete multiple actions such as conveying, lifting, flipping, and scanning. There is no need to configure multiple drive units, which reduces the equipment manufacturing cost and operating energy consumption, and also facilitates maintenance.

[0055] The components, modules, mechanisms, and devices in this invention that are not described in detail are all general standard parts or components known to those skilled in the art. Their structures and principles can be learned by those skilled in the art through technical manuals or conventional experimental methods.

[0056] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit the scope of protection of the present invention. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the essence and scope of the technical solutions of the present invention.

Claims

1. A visual inspection system for leafy green vegetables before packaging for preservation, characterized in that, Includes a support (1), a conveyor belt device (2), a rotating roller (4), a scanning device (5), and a motor (6). The conveyor belt device (2) is fixed to the support (1). The motor (6) and the scanning device (5) are both fixed to the conveyor belt device (2). The output shaft of the motor (6) is fixed to one of the rotating rollers (4). The two rotating rollers (4) are rotatably connected to the conveyor belt device (2). The two conveyor belt bodies (3) are connected between the two rotating rollers (4). There is a gap between the two conveyor belt bodies (3). A lifting flipping mechanism is connected to the support (1). The scanning device (4) is equipped with an image recognition system, and the support (1) is equipped with a processing module.

2. The appearance inspection system for leafy green vegetables before packaging for preservation, as described in claim 1, is characterized in that, The lifting flipping mechanism includes an auxiliary box (12), an electric push rod (13) and a fixed trapezoidal component (20). The electric push rod (13) and the fixed trapezoidal component (20) are both fixed to the support (1). The auxiliary box (12) is fixed to the electric push rod (13). The auxiliary box (12) has an open structure at the top and bottom. A photoelectric sensor is provided on the auxiliary box (12). A spur gear two (14), a transmission wheel three (15), a transmission wheel four (17), an active cylinder (18), and a driven cylinder (19) are rotatably connected to the auxiliary box (12). The active cylinder (18) and the transmission wheel four (17) are fixedly connected and rotate coaxially. The spur gear two (14) and the transmission wheel three (15) are fixedly connected and rotate coaxially. The transmission wheel three (15) is connected to the transmission wheel four (17) through the transmission belt two (16). The active cylinder (18) and the driven cylinder (19) extend to the top of the auxiliary box (12). Two bent movable rods (22) are slidably connected inside the auxiliary box (12). A movable trapezoidal part (21) is fixedly connected to the bent movable rod (22). The bent movable rod (22) is connected to the inner wall of the auxiliary box (12) through the spring (24). A mirror (23) is connected to the bent movable rod (22). A transmission wheel (7) is fixedly connected to the output shaft of the motor (6), and a transmission rod (10) is rotatably connected to the transmission belt device (2). A transmission wheel (9) and a spur gear (11) are fixedly connected to the transmission rod (10). The transmission wheel (9) is connected to the transmission wheel (7) through the transmission belt (8).

3. The appearance inspection system for leafy green vegetables before packaging for preservation, as described in claim 2, is characterized in that... The fixed trapezoidal member (20) is located above the two movable trapezoidal members (21).

4. The appearance inspection system for leafy green vegetables before packaging for preservation, as described in claim 3, is characterized in that... The mirror (23) is connected to the bending movable rod (22) via an angle adjustment mechanism.

5. The appearance inspection system for leafy green vegetables before packaging according to claim 4, characterized in that, The inner wall of the auxiliary box (12) is connected to the outer wall of the auxiliary box (12) through two lens outlets (25).

6. The appearance inspection system for leafy green vegetables before packaging for preservation, as described in claim 5, is characterized in that... The two mirrors (23) and the two mirror outlets (25) are located on the same horizontal plane.

7. The appearance inspection system for leafy green vegetables before packaging according to claim 6, characterized in that, The second spur gear (14) extends to the outside of the auxiliary box (12).

8. The appearance inspection system for leafy green vegetables before packaging for preservation, as described in claim 7, is characterized in that... The fixed trapezoidal member (20) is fixed to the support (1) by a support rod.

9. A method for processing appearance inspection data of leafy green vegetables before preservation packaging, characterized in that, An appearance inspection system for leafy green vegetables before preservation packaging, as described in any one of claims 1-8, comprises the following steps: Step 1: Receive the main image of the vegetable and the end image of the vegetable reflected by the mirror (23) collected by the scanning device (5), and perform coordinate flip correction on the end image using the mirror transformation matrix; Step 2: The corrected image is processed using an adaptive threshold segmentation algorithm with end compensation. The algorithm dynamically adjusts the end image compensation coefficient to extract the complete contour region of the vegetable. Step 3: When real-time and fast processing is required, the contour region is converted into a binary image, color features, texture features and shape features are extracted, and compared with a preset standard feature library; when fine recognition is required, the contour region is kept as a 0-255 grayscale image, input into a pre-trained lightweight convolutional neural network to extract deep feature vectors, and the cosine similarity between the feature vectors and the preset standard feature library is calculated. Step 4: When the comparison result or cosine similarity is lower than the preset threshold, a defect alarm signal is generated.

10. A method for visual inspection of leafy green vegetables before packaging for preservation, characterized in that, The method of performing multi-angle scanning inspection on leafy green vegetables using the appearance inspection system described in any one of claims 1-8 before packaging includes the following steps: Step 1: Place the vegetables on the two conveyor belt bodies (3), with the vegetables spanning the gap between the two conveyor belt bodies (3); Step 2: Turn on the motor (6). The output shaft of the motor (6) drives the rotating roller (4) and the conveyor belt body (3) to rotate, so that the conveyor belt body (3) transports the vegetables to the bottom of the scanning device (5). Step 3: Use the lifting and flipping mechanism to lift the vegetables and flip them over. The vegetables are temporarily separated from the conveyor belt body (3), and the scanning device (5) acquires image data of the vegetables from multiple angles. Step 4: Use the lifting flipping mechanism to make the vegetables come into contact with the conveyor belt body (3) again, and the conveyor belt body (3) sends the vegetables away from the scanning device (5) to enter the subsequent process.

Citation Information

Patent Citations

  • Nondestructive testing device for packaged fresh vegetables

    CN221472644U