Image detection method and computer program product
By automatically detecting the images of security inspection equipment, identifying and evaluating various performance indicators, the problems of degradation in the imaging quality of security inspection equipment and inconvenience in existing testing devices are solved, and efficient and accurate detection results are achieved.
Patent Information
- Application Number
- CN202411920998.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-24
- Publication Date
- 2025-04-04
- Estimated Expiration
- 2044-12-24
AI Technical Summary
The imaging quality of existing security inspection equipment has decreased during use, resulting in misjudgment or misjudgment of contraband. The existing testing equipment cannot fully cover the performance indicators of security inspection equipment, and it is large in volume and weight, and is inconvenient to use.
An image detection method is provided, by acquiring security images, identifying the image area corresponding to the test component, and automatically detecting various performance indicators based on preset detection strategies to achieve automated detection.
It realizes automated inspection and unified inspection standards, improves the accuracy of inspection results, saves manpower, improves detection efficiency, and reduces the volume and weight of the test device.
Smart Images

Figure CN119379669B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of security inspection technology, and in particular to an image detection method, a computer program product, a device and a storage medium. Background Art
[0002] The security inspection equipment may cause structural changes during the disassembly, transportation and assembly process, or the performance of the components inside the security inspection equipment may degrade as the service life increases. For example, the degradation of the X-ray tube may lead to insufficient X-ray doses. These factors will cause the imaging quality of the security inspection equipment to decline to varying degrees compared to when it leaves the factory, which may cause misjudgment or omission of contraband, posing a major safety hazard. Some test devices can be used to test the imaging quality of the security inspection equipment to detect whether the various performance indicators of the security inspection equipment meet the standards. However, the current test devices either cannot cover the various performance indicators that need to be tested, or are large in size and weight, inconvenient to use, and make the testing process more cumbersome. In addition, when evaluating the imaging quality of the security inspection equipment based on the images collected by the test device of the security inspection equipment, the evaluation results are obtained by observing the images with the naked eye of the test personnel. The evaluation results are relatively subjective, lack a unified standard, and are relatively time-consuming and labor-intensive. Summary of the invention
[0003] In view of this, the present application provides an image detection method, a computer program product, a device and a storage medium.
[0004] According to a first aspect of the present application, a method for detecting a security inspection image is provided, wherein the security inspection image is obtained by a security inspection device performing image acquisition on a test device, wherein the test device comprises a base plate, and a plurality of test components arranged on the base plate, wherein the plurality of test components at least comprise: an effective material resolution and material resolution test component, a spatial resolution and image distortion test component, a mixture and inorganic matter resolution test component, a penetration test component, and a penetration resolution test component;
[0005] The method comprises:
[0006] Acquiring the security inspection image;
[0007] Identifying, from the security inspection image, image regions corresponding to each of the plurality of test components;
[0008] For the image area corresponding to each test component, the image area is detected based on the pre-set detection strategy corresponding to the test component to obtain an evaluation result of the performance index of the security inspection device tested by the test component, wherein the detection strategy corresponding to each test component is determined based on the imaging characteristics of the test component in the security inspection device.
[0009] According to a second aspect of the present application, a computer program product is provided, wherein the computer program product comprises a computer program, and when the computer program is executed, the method mentioned in the first aspect is implemented.
[0010] According to a third aspect of the present application, an electronic device is provided, comprising a processor, a memory, and a computer program stored in the memory and executable by the processor, wherein the processor implements the method mentioned in the first aspect when executing the computer program.
[0011] According to a fourth aspect of the present application, a computer-readable storage medium is provided, on which a computer program is stored, and when the computer program is executed, the method mentioned in the first aspect is implemented.
[0012] By applying the solution provided by the present application, in order to realize automatic detection of security inspection images collected by the security inspection equipment for the test device, for each test component on the test device, a detection strategy for detecting the image area corresponding to the test component can be pre-designed based on the imaging characteristics of the test component, so that after obtaining the security inspection image, the image area corresponding to each test component can be automatically detected based on the pre-set detection strategy, and the evaluation results of the corresponding performance indicators can be obtained. Through the image detection method provided by the embodiment of the present application, it is possible to realize automatic detection of security inspection images collected by security inspection equipment, and obtain the evaluation results of various performance indicators of security inspection equipment. Compared with manual detection, this method can unify the detection standards, make the detection results more accurate, save manpower, and improve detection efficiency.
[0013] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present specification. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0015] Figure 1 It is a structural diagram of the national standard test body A.
[0016] Figure 2 It is a structural diagram of the national standard test body B.
[0017] Figure 3 , Figure 4 , Figure 5 , Figure 6 , Figure 7, Figure 8 , Fig. 9 Schematic diagram of a testing device according to multiple embodiments of the present application.
[0018] Fig.10 It is a flow chart of a security inspection image detection method according to an embodiment of the present application.
[0019] Fig.11 It is a schematic diagram of the imaging area corresponding to the mixture and inorganic substance discrimination test assembly of one embodiment of the present application.
[0020] Fig.12 It is a schematic diagram of the imaging area corresponding to the effective material resolution and material resolution test component of one embodiment of the present application.
[0021] Fig.13 It is a schematic diagram of the imaging area corresponding to the penetration testing component of one embodiment of the present application.
[0022] Fig.14 It is a schematic diagram of determining valid line pairs from a security inspection image according to an embodiment of the present application.
[0023] Fig.15 It is a schematic diagram of the structure of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION
[0024] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0025] Security inspection equipment generally includes an X-ray security inspection machine and a display device used in conjunction with it. When the passenger's luggage enters the X-ray security inspection machine, the X-ray security inspection machine will emit X-rays to scan and image it, and obtain a security inspection image of the luggage. The security inspection image can be presented on the display device, and the security inspector can judge the security inspection image to determine whether there are any prohibited items in the passenger's luggage.
[0026] The security equipment may undergo structural changes during the disassembly, transportation and assembly process, or the performance of the components inside the security equipment may degrade as the equipment ages. For example, degradation of the X-ray tube may lead to insufficient X-ray dose emitted. These factors will cause the imaging quality of the security equipment to decline to varying degrees compared to when it leaves the factory, which may result in the misjudgment or omission of prohibited items, posing a major safety hazard.
[0027] In order to evaluate the imaging quality of security inspection equipment, some pre-designed test devices are usually used to test the various performance indicators of security inspection equipment (such as spatial resolution, penetration, material resolution, etc.). During the test, the security inspection equipment can be used to collect images of the test device to obtain the corresponding security inspection image, and then the security inspection image is used to evaluate whether the various performance indicators of the security inspection equipment meet the standards. For example, the spatial resolution of the security inspection equipment can be determined by whether the line pairs in the security inspection image are clearly visible.
[0028] The test devices provided in the related art either cannot cover the various performance indicators that need to be tested, or are large in size and weight, making them inconvenient to use. For example, the commonly used test devices include national standard test body A and national standard test body B. National standard test body A is mainly used to test the resolution of security inspection images collected by security inspection equipment, and national standard test body B is mainly used to test the material resolution ability of security inspection equipment. Figure 1 As shown in the figure, it is a schematic diagram of the national standard test body A. The national standard test body A is divided into four test areas, each of which is equipped with corresponding test components, which are used to test the performance indicators of the security inspection equipment such as line resolution (TEST1), penetration resolution (TEST2), spatial resolution (TEST3) and penetration (TEST4). Figure 2 As shown in the figure, it is a schematic diagram of the national standard test body B. The national standard test body B is also divided into four test areas, which are used to test the performance indicators of the security inspection equipment such as organic matter resolution (TEST5 and TEST6), mixture resolution (TEST7), inorganic matter resolution (TEST8), material resolution and effective material resolution (TEST9 and TEST10).
[0029] It can be seen that in order to cover various performance indicators of security inspection equipment, two test bodies need to be used when using the national standard test body to test the security inspection equipment. The test body needs to be replaced during the test, which is cumbersome, and the volume and weight of the two test bodies are relatively large, which makes the test process inconvenient. The national standard test body is designed as two test bodies because some test components in the test body are large in volume and heavy in weight. If these test components are integrated into one test body, the volume and weight of the test body will be very large, which is inconvenient to use.
[0030] For example, taking the test component used to detect the resolution of security inspection equipment for mixtures and inorganic substances in the national standard test body B as an example, the mixture resolution test component in the national standard test body B (such as Figure 2Test 7 in the National Standard Test Body includes a thin strip of aluminum alloy steps and a thick strip of aluminum alloy steps. Different types of mixtures are simulated by aluminum alloys of different thicknesses. In order to simulate as many types of mixtures as possible, the number of steps is often set to be large, resulting in the two long strips of steps being long, basically occupying the entire length of the bottom plate. The inorganic substance discrimination test component in the national standard test body B (such as Figure 2 Test 8) in the test includes long steel plate steps. Similarly, different types of inorganic substances are simulated by steel plates of different thicknesses. In order to simulate as many types of inorganic substances as possible, the number of steps is often set to be large, resulting in a long length of the long steel step, which basically occupies the entire length of the bottom plate. Figure 2 It can be seen that the mixture resolution test component and the inorganic substance resolution test component in the national standard test body B basically occupy half of the volume of the entire test body. Due to the large volume of the test component, the test device cannot accommodate more test components. In addition, due to the large volume of the test component and the use of steel structure material, the weight of the test device is also large.
[0031] Based on this, the embodiment of the present application improves the structure of the mixture and inorganic substance discrimination test component in the test device, so that the volume and weight of the test component are as small as possible while ensuring the test accuracy, thereby reducing the volume and weight of the entire test device, making the test device lighter and more convenient to use.
[0032] like Figure 3 As shown, it is a schematic diagram of the test device 10 in the embodiment of the present application, the test device includes a base plate 110, and a plurality of test components arranged on the base plate 110, the plurality of test components at least including a mixture and inorganic substance discrimination test component 120, in order to reduce the volume of the test component, the mixture and inorganic substance discrimination test component 120 may include two annular steps, one of which is an annular step of a mixture material, used to detect the discrimination ability of the security inspection equipment to the mixture, and the other annular step is an annular step of an inorganic material, used to detect the discrimination ability of the security inspection equipment to the inorganic substance. Compared with the long strip-shaped steps, by designing the mixture and inorganic substance discrimination test component 120 into an annular step shape, the space occupied by the test component can be as small as possible while ensuring that the number of steps is sufficient (that is, the simulated mixture and inorganic substance categories are sufficient), and the weight of the test component is also lighter, thereby reducing the volume and weight of the entire test device, so that the test device can integrate more test components and achieve lightweight.
[0033] In some embodiments, Figure 4As shown, the two annular steps can be two semi-circular steps of the same size, and the two semi-circular steps are fixed on the base plate 110 and combined into a circular ring, wherein one of the semi-circular steps is a semi-circular step 120a made of a mixture material, which is used to detect the resolution capability of the security inspection equipment for the mixture, and the other semi-circular step is a semi-circular step 120b made of an inorganic material, which is used to detect the resolution capability of the security inspection equipment for inorganics. By designing the mixture and inorganic discrimination test component 120 into a semi-circular step shape, and then the two form a circular ring fixed in the base plate 110, the space occupied by the test component can be greatly reduced, the weight of the test component can be reduced, and then the volume and weight of the entire test device can be reduced, thereby achieving lightweight. Of course, in some scenarios, the two annular steps can also be combined into an elliptical ring, which can be specifically set based on actual needs.
[0034] Among them, the size, thickness, number of steps, and arrangement positions of the two semi-circular steps in the base plate 110 can be set based on actual needs, and the embodiments of the present application are not limited thereto.
[0035] In some embodiments, the semicircular step 120a of the mixture material is an aluminum alloy semicircular step, and the semicircular step 120a of the inorganic material is a carbon steel semicircular step. Different types of mixtures are simulated by using aluminum alloys of different thicknesses, and different types of inorganics are simulated by using carbon steels of different thicknesses.
[0036] In some embodiments, Figure 4 As shown, the multiple test components also include a spatial resolution and image distortion test component 130. The spatial resolution test component in the national standard test body A (such as Figure 1 Test 3) consists of 4 groups of wire pairs made of single solid copper wires of 4 different diameters directly mounted on the base plate 110, which are used to test the security inspection equipment's ability to resolve wire pairs. In this design structure, the copper wire is easily deformed and its position is easily changed, resulting in the test component being unstable, which affects the accuracy of the test results. In addition, there is no test component specifically designed for detecting image distortion in the national standard test body. Usually, the test personnel only make subjective judgments on the collected images with their naked eyes, and lack accurate measurement indicators. Based on this, the present application designs a spatial resolution and image distortion test component, such as Figure 4As shown, the test assembly includes an object 130a of regular shape, and the surface of the object is provided with a plurality of groups of linear holes 130b in the horizontal direction, and a plurality of groups of linear holes 130c in the vertical direction, wherein the widths of the plurality of groups of linear holes 130b in the horizontal direction are different, and the widths of the plurality of groups of linear holes 130c in the vertical direction are different. The outer contour of the object 130a of regular shape can be used to test the distortion ratio of the image in the vertical and horizontal directions, and the linear holes can be used to test the spatial resolution of the security inspection equipment. The object of regular shape can be a square object, a rectangular object, etc., which is not limited in the embodiment of the present application.
[0037] In some embodiments, the regular-shaped object 130 may be a square copper plate, steel plate, etc., and the linear holes may be holes cut on the surface of the copper plate or steel plate. Compared with the method of directly using solid copper wire, the wire pairs obtained by cutting linear holes on the surface of the object are more stable and less prone to deformation. At the same time, by adopting a regular shape structure, the distortion can be determined based on the ratio of the horizontal and vertical dimensions of the regular-shaped object in the collected security inspection image (for example, the length-to-width ratio), and one test component can test two indicators at the same time, so that the test device has a more compact structure and a smaller volume while covering as many test indicators as possible.
[0038] In some embodiments, Figure 5 As shown, the multiple test assemblies also include an effective material discrimination and material discrimination test assembly 140, which includes a steel step 140b and at least two test plates 140a stacked on the steel step 140b, and a partial area of each test plate 140a overlaps with the steel step 140b, wherein the equivalent atomic numbers of the at least two test plates 140a are different, and the equivalent atomic numbers of the at least two test plates 140a are less than the equivalent atomic number of the steel step 140b.
[0039] When X-rays pass through different materials, they are absorbed to different degrees, and the absorption capacity of a material (i.e., the attenuation of X-rays) is usually related to its atomic number (Z). The higher the atomic number, the stronger the material's ability to absorb X-rays. The effective atomic number (Z_eff) refers to the average atomic number exhibited by a material during the X-ray attenuation process. It comprehensively considers the atomic numbers of different elements in the material and their ratios, and can be used to describe the X-ray attenuation characteristics of a material. In order to detect the security inspection equipment's ability to distinguish different materials, and its ability to distinguish materials after penetrating the steel step 140b (i.e., effective material resolution), at least two test plates with different equivalent atomic numbers can be set. At the same time, the test plates can be covered on the steel step, with a portion of each test plate 140a overlapping with the steel step 140b, and the other portion not overlapping, i.e., the steel step only covers a portion of each test plate, so that the unobstructed area of the test plate can be used to detect the material resolution of the security inspection equipment, while the area of the test plate obstructed by the steel step can be used to detect the effective material resolution. The at least two test plates 140a can be made of different materials to achieve different equivalent atomic numbers, and the equivalent atomic sequence of the at least two test plates 140a is smaller than the equivalent atomic sequence of the steel step 140b. In some embodiments, the shape of the at least two test plates 140 can be a rectangular parallelepiped.
[0040] Among them, the material, size, quantity of the at least two test plates 140a, and the number of steps and step thickness of the steel steps 140b can be flexibly set based on actual needs. For example, in some embodiments, the test plate can include a PVC board, a polytetrafluoroethylene board and a polyethylene board, and the number of steps of the steel step is 2.
[0041] In some embodiments, Figure 6 As shown, the plurality of test components also include a penetration test component 150. The penetration test component in the national standard test body A (such as Figure 1 Test 4) in the figure is composed of 3 carbon steel steps of different thicknesses, and a three-quarter round lead block with a thickness of 5 mm and a diameter of 25 mm is glued on the surface of the step. If the vast majority of the three-quarter round lead block blocked by the steel plate can be seen in the image collected by the security inspection equipment and the direction of the gap of the three-quarter round lead block can be distinguished, it can be considered that the security inspection equipment can penetrate this steel step, and the maximum thickness value of the steel step corresponding to the distinguishable three-quarter round lead block is used as the thickness value of the steel plate that the security inspection equipment can penetrate. Obviously, if this step-shaped structure design is used to cover different thicknesses, a large number of steel steps need to be set, resulting in the penetration test component 150 occupying a large space and being heavy. In addition, due to the discontinuous thickness of this step-shaped design, the thickness value of the steel plate that the security inspection equipment can penetrate is not accurate enough.
[0042] Based on this, Figure 6 As shown, the embodiment of the present application designs a penetration test assembly 150, which includes a lead strip 150a and a first cover 150b covering the lead strip, and the thickness of the first cover changes in a continuous gradient, so that the X-rays of the security inspection equipment penetrate the first covers 150b of different thicknesses to reach the lead strip 150a. By designing the penetration test assembly 150 into the above structure, it is possible to achieve a gradual change in the thickness of the object penetrated by the security inspection equipment, simulate the penetration ability of the security inspection equipment when facing objects of different thicknesses, and also reduce the space occupied by the test assembly while covering as much thickness as possible. At the same time, similar to the national standard test body A for detecting whether the security inspection equipment can distinguish the opening direction of the three-quarter round lead block, the embodiment of the present application can determine the maximum steel plate thickness that can distinguish the shape of the lead strip by adding the lead strip to the test assembly, and then use this thickness as the maximum penetration thickness.
[0043] The size of the lead strip 150a, the size and material of the first cover 150b, etc. can be set based on actual needs, and are not limited in the embodiment of the present application.
[0044] In some embodiments, the first cover 150b may be a wedge-shaped carbon steel block, and the lead strip 150a may be placed at the bottom center of the wedge-shaped carbon structure.
[0045] In some embodiments, Figure 7 As shown, the multiple test components also include a penetration resolution test component 160. The penetration resolution test component in the national standard test body A (such as Figure 1 Test 2) in the test consists of a set of sinusoidal single solid copper wires and alloy aluminum steps covering the single solid copper wire, so as to test the ability of the security inspection equipment to resolve the single solid copper wire after penetrating the alloy aluminum steps. Since the size of the solid copper wires is consistent, it is impossible to test the ability of the security inspection equipment to resolve objects of different sizes after penetrating the alloy aluminum steps. In addition, since the alloy aluminum covering the solid copper wire adopts a stepped structure, if more thickness needs to be covered, a larger number of steps need to be set, resulting in a large space occupied by the penetration resolution test component 160. Based on this, the embodiment of the present application designs a penetration resolution test component 160, such as Figure 7As shown, the penetration resolution test assembly 160 includes a substrate 160a, a plurality of circular rings 160b formed by winding metal wires arranged on the substrate 160a, and a second cover 160c covering the plurality of circular rings 160b formed by winding metal wires. The diameters of the metal wires in the plurality of circular rings 160b formed by winding metal wires are different, and the thickness of the second cover 160c changes continuously in a gradient, so that the X-rays emitted by the security inspection equipment penetrate the second cover 160c of different thicknesses to reach the plurality of circular rings 160b formed by winding metal wires. By combining the circular rings 160b formed by winding metal wires of different diameters with the second cover 160c of continuously changing thickness, the resolution of the security inspection equipment for objects of different sizes when penetrating objects of different thicknesses can be effectively evaluated, and the penetration resolution of the security inspection equipment can be evaluated more comprehensively and accurately.
[0046] The size, quantity, material of the ring 160b formed by winding the metal wire, and the size, material, and shape of the second cover 160c can be set based on actual needs, and the embodiment of the present application is not limited. In some embodiments, the multiple rings 160b formed by winding the metal wire can be rings formed by winding copper wires of different diameters. In some embodiments, the multiple rings 160b formed by winding the metal wire can also be rings formed by winding lead wires of different diameters.
[0047] In some embodiments, the second cover 160c is a triangular prism-shaped aluminum block, for example, a right-angled triangular prism-shaped aluminum block, which is placed on the side of a plurality of 160b formed by winding metal wires.
[0048] In addition, the national standard test body cannot detect the imaging quality of some customized dangerous goods (such as lighters, lithium batteries, flammable liquids, etc.) by security inspection equipment. Considering that dangerous goods test components are usually set up based on different scenarios, they do not need to occupy an area in the test device alone. In order to allow the test device to detect dangerous goods while being as lightweight as possible, in some embodiments, the multiple test components include at least one detachable test component. Which specific test components are detachable and which are the designated areas for installing detachable test components (such as one area or multiple areas, etc.) can all be determined according to test and evaluation requirements.
[0049] In some embodiments, Figure 8 As shown, one of the at least one detachable test components is installed in a designated area of the base plate 110, and an opening 110a is provided in the designated area. When the detachable test component is in a detached state, the opening 110a can be used to fix the dangerous goods test component.
[0050] The opening 110a provided on the base plate 110 for placing or fixing the dangerous goods test component can be a regular circular hole or an elliptical hole. The number and size of the opening 110a can be set based on actual needs, and the present application does not impose any restrictions. In an optional embodiment, for example, the above-mentioned one or more detachable test components can be installed in a designated area. When a dangerous goods test is required, the above-mentioned one or more detachable test components can be removed, and the dangerous goods component to be tested (for example, lithium batteries, lighters, flammable and explosive liquids, etc.) can be fixed through the opening 110a, for example, by a nylon lock or a cable tie on the base plate 110. The dangerous goods test component can share an area of the base plate 110 with one or more test components in the test device, wherein the test component that shares the area of the base plate 110 with the dangerous goods test component can be a test component that is easy to disassemble.
[0051] In some embodiments, the openings 110a provided in the designated area may be a plurality of circular holes arranged at equal intervals. In some embodiments, since the penetration resolution test assembly 160 is a long strip test assembly, its corresponding bottom plate area is convenient for opening a hole to fix the dangerous goods assembly, and thus, it can be designed to share an area of the bottom plate 110 with the dangerous goods test assembly, thereby achieving effective use of space. The penetration resolution test assembly 160 may be designed as a detachable structure, for example, its base plate 160a may be fixed to the bottom plate 110 by screws.
[0052] In some embodiments, the test device further includes a cover plate, the multiple test components are located between the bottom plate 110 and the cover plate, and the cover plate is detachably connected to the bottom plate 110 to protect the multiple test components. For example, the bottom plate 110 and the cover plate substrate 160a can both be made of PMMA (polymethyl methacrylate) and can be connected in the middle with aluminum alloy sleeve screws.
[0053] like Fig. 9As shown, it is a schematic diagram of a test device provided by an embodiment of the present application. The test device includes a base plate 110, a cover plate (not shown in the figure), and five test components located between the base plate 110 and the cover plate. The materials of the base plate 110 and the cover plate are PMMA acrylic, and they are connected in the middle with aluminum alloy sleeve screws for easy disassembly and replacement. The five test components can be divided into an effective material and material resolution test component located in the upper left corner, a spatial resolution and image distortion test component 130 located in the upper middle position, a mixture and inorganic matter resolution test component 120 located in the upper right corner, a device penetration test component 150 located in the lower left corner, and a penetration resolution test component located in the lower right corner. Among them, the penetration resolution test component is designed to be a detachable structure, for example, it can be fixed to the base plate 110 by screws. The bottom plate area where the penetration resolution test component is installed is provided with parallel and equally spaced elliptical holes 110a. When the penetration resolution test component is in a disassembled state, the elliptical holes 110a can be used with cable ties or nylon locks to fix controlled knives, dangerous liquids, lithium batteries and other dangerous goods set based on actual scene changes.
[0054] The effective material resolution and material resolution test assembly 140 is a combined assembly, which includes a material resolution test assembly and an effective material resolution test assembly. The material resolution test assembly consists of horizontally placed PVC plates, polytetrafluoroethylene plates and polyethylene plates with different equivalent atomic numbers and a length of 60 mm and a width of 30 mm, which are used to test the material resolution capability of the security inspection equipment. The thickness of the PVC plate is 9 mm, and the equivalent atomic number is 14.3; the thickness of the polytetrafluoroethylene plate is 22 mm, and the equivalent atomic number is 8.5; the thickness of the polyethylene plate is 25 mm, and the equivalent atomic number is 5.53. The effective material resolution test assembly consists of stainless steel SUS304 and the above-mentioned material resolution test assembly, that is, steel steps with a length of 20 mm, a width of 100 mm, and a thickness of 2 mm and 1 mm are vertically stacked on the material resolution test assembly to test the ability of the security inspection equipment to distinguish materials after the X-ray passes through the thin steel steps.
[0055] The spatial resolution and image distortion test component 130 is composed of a square copper plate with a side length of 100 mm and a thickness of 2 mm. Four groups of linear holes of different widths are cut on the square copper plate, and each group of linear holes is divided into two groups in the horizontal and vertical directions. There are four groups of linear holes of different widths in the horizontal and vertical directions, and the widths are 2 mm, 1.5 mm, 1 mm and 0.8 mm respectively. The outer contour of the square copper plate is used to test the distortion ratio of the image in the horizontal and vertical directions, and the linear holes are used to test the spatial resolution of the device in the horizontal and vertical directions.
[0056] The mixture and inorganic substance discrimination test assembly 120 is composed of an aluminum alloy semi-circular ring ladder and a carbon structural steel Q235 semi-circular ring ladder. The two semi-circular ring ladders have the same size and are combined into a ring fixed on the bottom plate 110. The inner diameter of the aluminum semi-circular ring ladder is 40mm, the outer diameter is 100mm, and the thickness is 1mm, 2mm, 4mm, 6mm, 8mm, 10mm, 12mm, 14mm and 16mm, a total of eight areas, which are used to test the discrimination ability of the security inspection equipment to the mixture; the inner diameter of the carbon structural steel Q235 semi-circular ring ladder is 40mm, the outer diameter is 100mm, and the thickness is 0.5mm, 0.8mm, 1mm, 2mm, 3mm, 4mm, 6mm and 8mm, a total of eight areas, which are used to test the discrimination ability of the security inspection equipment to the inorganic substance.
[0057] The penetration test assembly 150 consists of a carbon structural steel Q235 wedge block and a lead strip 150a. The wedge block is 120 mm long, 55 mm wide, 45 mm thick at the thickest point and 20 mm thick at the thinnest point. The lead strip 150a is located at the center of the bottom of the wedge block, with a length of 120 mm, a width of 10.4 mm and a height of 5 mm. The equivalent penetration of the security inspection equipment is evaluated by calculating the half-value layer thickness of the carbon structural steel of the equipment and the clarity of the lead strip 150a.
[0058] The penetration resolution test assembly 160 includes a substrate 160a, five copper wire rings arranged on the substrate 160a, and an aluminum right-angled triangular prism placed above the copper wire rings. The right-angled triangular prism is placed sideways above the copper wire rings so that the X-ray needs to penetrate a continuously changing thickness to reach the lead strip 150a. The substrate 160a is a PMMA acrylic plate with a length of 160mm, a width of 55mm, and a height of 4mm. The inner diameter of the copper wire ring is 25mm, and the diameters of the inner copper wires are 0.511mm, 0.320mm, 0.203mm, 0.127mm, and 0.0787mm from left to right. The length of the aluminum triangular prism is 160mm, the width is 27.5mm, and the height is 20mm. The penetration resolution of the security inspection equipment is evaluated by testing the wire resolution of the X-ray of the security inspection equipment passing through the aluminum block.
[0059] The test device provided in the embodiment of the present application can cover the detection of various performance indicators of the security inspection equipment, has a high degree of integration, and by optimizing the structure of each test component, the test device has a smaller volume and weight while ensuring the test accuracy of each performance indicator, can be lightweight, and is more convenient for users to use. At present, when evaluating the imaging quality of the security inspection equipment based on the image of the test device collected by the security inspection equipment, the evaluation results are obtained by observing the image with the naked eye of the test personnel. The evaluation results are relatively subjective and lack a unified standard. Moreover, when there are many test components covered in the test device, since the image collected by the security inspection equipment includes multiple test components, the performance indicators of each test component are determined one by one by manually observing the image. The test efficiency is low, time-consuming and labor-intensive.
[0060] Based on this, the embodiment of the present application provides a security inspection image detection method, which can detect the security inspection image collected by the security inspection device for the test device to evaluate whether the imaging quality of the security inspection device meets the requirements. Among them, the test device includes a base plate and a plurality of test components arranged on the base plate. In order to cover various common performance indicators of the security inspection device, the plurality of test components at least include: effective material resolution and material resolution test components, spatial resolution and image distortion test components, mixture and inorganic matter resolution test components, penetration test components, and penetration resolution test components. After the security inspection device acquires the image for the test device to obtain the security inspection image, in order to realize automatic detection of the security inspection image, for each of the above test components, a detection strategy for detecting the image area corresponding to the test component can be pre-designed based on the imaging characteristics of the test component, so that after obtaining the security inspection image, the image area corresponding to each test component can be automatically detected based on the pre-set detection strategy, and the evaluation results of the corresponding performance indicators can be obtained.
[0061] The image processing method in the embodiment of the present application can be executed by the security inspection device. For example, after the security inspection device collects the security inspection image, it can automatically detect the security inspection image based on the preset detection strategy and output the evaluation results of various performance indicators. Of course, in some scenarios, the method can also be executed by other devices that are connected to the security inspection device. For example, considering that image detection requires a relatively high computing power of the device, the security inspection image can be sent to a cloud server, which completes the image detection and returns the result.
[0062] like Fig.10 As shown, the method may include the following steps:
[0063] S102, acquiring the security inspection image;
[0064] In step S102, a security inspection image obtained by the security inspection device through image acquisition on the above-mentioned test device may be obtained.
[0065] S104, identifying image areas corresponding to each of the plurality of test components from the security inspection image;
[0066] In step S104, the image regions corresponding to each of the above-mentioned multiple test components can be identified from the security inspection image. For example, the identification strategy can be determined based on the appearance characteristics of each test component, and then the image region corresponding to each test component can be identified from the image. In some scenarios, a neural network model can also be pre-trained to identify each test component from the security inspection image through the pre-trained neural network model to determine the image region corresponding to each test component.
[0067] S106. For each image area corresponding to a test component, the image area corresponding to the test component is detected based on a pre-set detection strategy corresponding to the test component to obtain an evaluation result of the performance index of the security inspection device tested by the test component; wherein the detection strategy corresponding to each test component is determined based on the imaging characteristics of the test component in the security inspection device.
[0068] Taking into account that the performance indicators of the security inspection equipment to be tested by each test component are different, and the imaging characteristics of each test component are also different, therefore, for each of the above-mentioned test components, a set of detection strategies matching the test component can be pre-designed, wherein the detection strategy corresponding to each test component is determined based on the imaging characteristics of the test component in the security inspection equipment. For example, the detection strategy can be determined based on the color characteristics, shape characteristics, etc. of the imaging of the test component under X-rays, so that after obtaining the image area corresponding to the test component, the pre-designed detection strategy can be used to directly detect the image area to obtain the evaluation result of the performance indicator of the security inspection equipment tested by the test component.
[0069] Through the image detection method provided in the embodiment of the present application, it is possible to automatically detect security inspection images collected by security inspection equipment and obtain evaluation results of various performance indicators of the security inspection equipment. Compared with manual inspection, this method can unify the inspection standards, make the inspection results more accurate, save manpower and improve inspection efficiency.
[0070] In some embodiments, the mixture and inorganic substance discrimination test assembly includes two annular steps, one of which is a annular step made of a mixture material, used to detect the security inspection equipment's ability to discriminate the mixture, and the other is a annular step made of an inorganic material, used to detect the security inspection equipment's ability to discriminate inorganic substances.
[0071] The specific structure, size, material, etc. of the mixture and inorganic substance discrimination test assembly can be found in the description of the above embodiments and will not be repeated here.
[0072] Considering that when the security inspection equipment images mixtures and inorganic substances, different saturation green can be given to mixtures of different thicknesses, and different saturation blue can be given to inorganic substances of different thicknesses. Fig.11 As shown, it is a schematic diagram of the imaging of the above-mentioned mixture and inorganic substance discrimination test component by the security inspection equipment in one embodiment. It can be seen from the figure that the imaging of the test component is a circular ring area, the green circular ring area represents the mixture, the blue circular ring area represents the inorganic substance, and the circular ring area includes multiple sub-areas, and different sub-areas are distinguished by dividing lines, wherein each sub-area represents a step, and the dividing lines between different sub-areas are the dividing lines between different steps. Detecting the mixture and inorganic substance discrimination ability of the security inspection equipment is actually to detect whether the various categories of mixtures and inorganic substances can be accurately distinguished in the security inspection image collected by the security inspection equipment, that is, whether the number of steps of the green sub-area (blue sub-area) and the semi-circular steps of the mixture material (semi-circular steps of the inorganic material) identified from the image is consistent.
[0073] Therefore, after obtaining the image area corresponding to the mixture and inorganic substance discrimination test component, the image area can be firstly detected based on the brightness component of the pixel points in the image area, and multiple sub-areas can be determined from the image area using the detected straight line as the dividing line. Among them, since the brightness at the boundary between different steps is greater and the dividing lines are all straight lines, the image area can be firstly detected based on the brightness component of the pixel points to obtain multiple dividing lines, and then the sub-areas in the circular ring can be determined based on the detected dividing lines.
[0074] Considering that if the security inspection equipment can accurately identify a mixture (inorganic substance), the area corresponding to the mixture (inorganic substance) should be assigned green (blue). Of course, considering the existence of noise and misidentification, it is impossible for all pixels in the imaging area of the mixture (inorganic substance) to be green (blue), but at least most of the pixels should be green (blue) to be considered that the security inspection equipment can identify the mixture (inorganic substance). Therefore, after determining multiple sub-areas, a target sub-area can be determined from the multiple sub-areas, and the number of pixels in the target sub-area whose hue component is the target color (green or blue) accounts for more than the preset number of pixels in the total number of pixels in the image area, wherein the preset number of pixels can be flexibly set based on actual needs. Among them, the target color is related to the material of the annular step represented by the target sub-area. For example, X-rays will give different colors to objects of different materials, so the target color can be determined based on the material of the annular step represented by the target sub-area.
[0075] For example, in some embodiments, for a mixture, the target color is green, that is, the number of target sub-areas determined therefrom is the number of categories of the mixture identified by the security inspection device. Then, it can be determined whether the number of the target sub-areas matches the set number (that is, whether they are consistent, or the difference is not large), and then, based on the matching of the two, the evaluation result of the security inspection device's ability to distinguish the mixture can be determined. Among them, for a mixture, the set number is the number of steps of the semicircular steps of the mixture material in the above-mentioned test component. For example, if the number of steps of the semicircular steps of the mixture material is 6, that is, the number of categories of the mixture included in the test component is 6, then, based on whether the number of detected green target sub-areas is 6, it can be determined whether the security inspection device can accurately identify various mixtures.
[0076] Similarly, in some embodiments, for inorganic substances, the target color is blue, that is, the number of target sub-areas determined therefrom is the number of categories of inorganic substances identified by the security inspection device. Then, based on the matching of the number of target sub-areas and the set number, the evaluation result of the resolution ability of the security inspection device for the mixture can be determined. Among them, for inorganic substances, the set number is the number of steps of the semicircular steps of the inorganic material in the above-mentioned test component.
[0077] In some embodiments, in addition to determining the ability of the security inspection device to distinguish mixtures (inorganic substances) based on the number of categories of the mixtures (inorganic substances) identified from the image and the matching of the set number, some other indicators may also be combined for determination. For example, the ability of the security inspection device to distinguish mixtures (inorganic substances) may be determined based on indicators such as the signal-to-noise ratio in the image area and the clarity of the image area.
[0078] For example, in some embodiments, after determining multiple sub-regions from the image region, the signal-to-noise ratio corresponding to each sub-region can also be determined, and the signal-to-noise ratio is the ratio of the pixel mean of the pixel points whose hue component of the sub-region is the target color to the standard deviation of the pixel values of each pixel point in the sub-region, and then the resolution of the security inspection equipment for mixtures or inorganic substances is determined in combination with the signal-to-noise ratio. Among them, the target color is related to the material of the annular step represented by the target sub-region. For example, if the sub-region is an area corresponding to a semi-circular step of a mixture material, the target color is green, so that the resolution of the security inspection equipment for the mixture is determined based on the signal-to-noise ratio. If the sub-region is an area corresponding to a semi-circular step of an inorganic material, the target color is blue, so that the resolution of the security inspection equipment for inorganic substances is determined based on the signal-to-noise ratio.
[0079] Of course, in some embodiments, the ability of the security inspection equipment to resolve mixtures (inorganic substances) may also be evaluated in combination with the clarity index of each sub-area, wherein the clarity index may be a Brenner gradient, Lapacian gradient, variance, energy gradient, or other index for evaluating image clarity.
[0080] In some embodiments, the effective material discrimination and material discrimination test assembly includes a steel step, and at least two test plates stacked on the steel step, a partial area of each test plate overlapping with the steel step, wherein the equivalent atomic numbers of the at least two test plates are different, and the equivalent atomic numbers of the at least two test plates are smaller than the equivalent atomic number of the steel step.
[0081] Since the steel steps only cover a portion of each test plate, the unshielded area of the test plate can be used to test the material resolution capability of the security inspection equipment, while the area of the test plate shielded by the steel steps can be used to test the effective material resolution capability.
[0082] Among them, the specific structure, size, material, etc. of the effective material resolution and material resolution test components can refer to the description in the above embodiments and will not be repeated here.
[0083] The material resolution of security inspection equipment refers to the ability of security inspection equipment to distinguish materials with different atomic numbers, while the effective material resolution refers to the ability of security inspection equipment to distinguish materials with different atomic numbers after penetrating steel plates of different thicknesses. Among them, test plates of different materials can be used to obtain materials with different atomic sequences. For test plates of different materials, security inspection equipment can give them different colors. For example, Fig.12 As shown, assuming that the at least two test plates are PVC plates, polytetrafluoroethylene plates and polyethylene plates, respectively, and the steel steps include two thicknesses, the security inspection equipment can give the PVC plate green, give the polytetrafluoroethylene plates and polyethylene plates orange with different saturations, and after the test plates are covered with steel plates of different thicknesses, the security inspection equipment can give the test plates blue with different saturations. For the part of the test plate not covered by the steel steps, it includes three categories of materials, and the colors of the three materials are green and orange with different saturations. For the part of the test plate covered by the steel steps, since the steel steps have two thicknesses, the steel steps of different thicknesses and the test plates of the above three materials are combined respectively, that is, 6 different categories of materials can be obtained, and these 6 materials are blue with different saturations. Detect the material resolution of the security inspection equipment, that is, detect whether the above three categories of materials can be accurately identified from the security inspection image. Detect the effective material resolution of the security inspection equipment, that is, detect whether the above 6 categories of materials can be accurately identified from the security inspection image.
[0084] Based on this, after obtaining the image area corresponding to the effective material discrimination and the material discrimination test component, the pixel points in the image area can be clustered based on the hue component of the pixel points in the image area to obtain multiple categories. Considering that the security inspection equipment may have misidentification, or the clustering process may have certain errors, some noise pixels in the image may also be clustered into one category. In order to accurately determine the material category that the security inspection equipment can identify, the effective category can be determined from the multiple categories obtained by clustering, wherein the area of the pixel area composed of the pixel points in the effective category and the area of the image area account for more than the preset area ratio. Considering that if the image area represented by the pixel points of a certain category is the image area corresponding to a certain category of material and can be accurately identified by the security inspection equipment, then the pixel area composed of the pixel points of the category in the image area should account for a ratio close to the area of the material of the category in the test component. Therefore, for each category of material, its approximate area ratio can be determined based on the size of the material as the above-mentioned preset area ratio. Then, for each valid category determined, the color represented by the valid category can be determined, and based on the matching of the number of valid categories representing the specified color and the set number of material categories, the evaluation result of the material resolution and / or effective material resolution capability of the security inspection equipment can be obtained.
[0085] For example, taking at least two test plates as PVC plates, polytetrafluoroethylene plates and polyethylene plates, the number of valid categories representing orange and green can be determined for material resolution. If it is 3, it means that the three materials can be accurately distinguished in the security inspection images collected by the security inspection equipment. And the number of valid categories representing blue can be determined for effective material resolution. If it is 6, it means that the 6 materials obtained by combining steel steps and the above three materials can be accurately distinguished in the security inspection images collected by the security inspection equipment.
[0086] In some embodiments, in order to more accurately determine the number of valid categories, after determining the valid categories from multiple categories, the pixels in the image area may be clustered based on the brightness component and / or saturation component of the pixels in the image area to obtain a clustering result, and then the clustering result is used to verify the accuracy of the number of valid categories determined. Considering that for different materials, the color, saturation, and brightness of the imaging area may be different after the security inspection device images them, after the number of valid categories is obtained by clustering the pixels based on color, the number of valid categories may be further verified based on the clustering results of saturation and / or brightness to ensure that the number of valid categories finally determined is relatively accurate, and the evaluation result of the effective material resolution (material resolution) of the security inspection device is also relatively accurate.
[0087] In some embodiments, the penetration test assembly includes a lead bar and a first covering covering the lead bar, and the thickness of the first covering varies in a continuous gradient, so that the X-rays of the security inspection equipment penetrate the first coverings of different thicknesses to reach the lead bar.
[0088] Among them, the specific structural material of the penetration test component can refer to the description in the above embodiment, and will not be repeated here.
[0089] Considering the penetration test assembly for the above structure, the half-value layer thickness of the security inspection device relative to the first cover can be used to evaluate the penetration ability of the security inspection device on the object. When the X-rays of the security inspection device penetrate the object, they will be absorbed by the object, that is, the X-rays will attenuate. The half-value layer thickness (HVL) indicates the thickness of the object required for the X-ray intensity to drop to 50% of the initial intensity after the X-rays penetrate a certain object.
[0090] The imaging principle of security inspection equipment is: security inspection equipment can emit X-rays to objects. After the X-rays penetrate the object, detectors (such as X-ray film, digital detectors, etc.) can be used to receive the intensity of the X-rays that penetrate the object. The detector records the X-ray intensity at each point, and this intensity is related to the density, thickness and composition of the material. The more X-rays penetrate, the stronger the rays received by the detector, and the brighter the image (higher grayscale value); the areas that penetrate less, the weaker the rays received by the detector, and the darker the image (lower grayscale value). Fig.13 As shown, considering that the size of the first cover in the X-ray emission direction changes in a continuous gradient, the grayscale of the imaging area of the first cover is also gradually changing. The thickness of the first cover when the X-ray is attenuated by half is the corresponding depth of the pixel point whose grayscale value is the median value in the imaging area of the first cover. In addition, due to the high density of the lead bar, the grayscale value of the imaging area of the lead bar should be low, that is, there is an area in the image area that is consistent with the shape of the lead bar and has a darker grayscale.
[0091] Based on this, Fig.13As shown, after obtaining the image area corresponding to the penetration test component, the average value of the grayscale value of the pixel points in each pixel column or pixel row in the image area can be determined to obtain a set of average value sequences, wherein the pixel column or pixel row is perpendicular to the grayscale gradient direction in the image area. For example, assuming that the grayscale gradient direction in the image area is the direction of the pixel row in the image area, the average value of the grayscale value of the pixel points in each pixel column can be counted to obtain a set of average value sequences. Similarly, assuming that the grayscale gradient direction in the image area is the direction of the pixel column in the image area, the average value of the grayscale value of the pixel points in each pixel row can be counted to obtain a set of average value sequences. Then the median in the average value sequence can be determined, and the depth information of the pixel column or pixel row corresponding to the median is used as the half-value layer thickness of the first covering, which is used to evaluate the X-ray penetration ability of the security inspection device.
[0092] In addition, in some embodiments, in order to evaluate the penetration ability of the X-rays of the security inspection equipment on some materials with higher density, the penetration of the security inspection equipment can also be evaluated based on the clarity of the lead bar in the image area. Considering that the grayscale value of the image area corresponding to the lead bar is the lowest, the image area corresponding to the lead bar can be determined from the image area based on the grayscale value to determine whether the image of the lead bar is clear. Then, based on the clarity of the image corresponding to the lead bar, the evaluation result of the penetration of the security inspection equipment can be obtained. For example, the thickness of the first covering material penetrated by the X-ray when the shape of the lead bar can be accurately identified can be determined as the maximum penetration thickness.
[0093] The penetration capability of the security inspection equipment may be evaluated based on one or more of the maximum penetration thickness and the half-value layer thickness.
[0094] In some embodiments, the penetration resolution test assembly includes a substrate, a plurality of circular rings formed by winding metal wires disposed on the substrate, and a second covering covering the plurality of circular rings formed by winding metal wires, wherein the diameters of the metal wires in the plurality of circular rings formed by winding metal wires are different, and the thickness of the second covering varies in a continuous gradient, so that the X-rays of the security inspection equipment penetrate the second coverings of different thicknesses to reach the plurality of circular rings formed by winding metal wires.
[0095] Among them, the penetration resolution test component is mainly used to test the security inspection equipment's ability to resolve circles formed by metal wires of different diameters after penetrating the second cover. Therefore, after acquiring the image area corresponding to the penetration resolution test component, the number of circles formed by metal wires of different diameters can be identified from the image area, and the evaluation result of the penetration resolution of the security inspection equipment can be obtained based on the matching of the number of identified circles and the set number. Of course, in some embodiments, the penetration resolution of the security inspection equipment can also be evaluated based on the clarity of the circles formed by the metal wires in the image area. Among them, the evaluation result of the penetration resolution can be determined based on one or more indicators of the matching of the number of identified circles and the set number and the clarity of the circles formed by the metal wires in the image area, which can be set based on actual needs.
[0096] In some embodiments, the surface of the spatial resolution and image distortion testing component is provided with multiple groups of horizontal linear holes and multiple groups of vertical linear holes, wherein the widths of the multiple groups of horizontal linear holes are different, and the widths of the multiple groups of vertical linear holes are different, wherein the linear holes can be used to detect the spatial resolution of the security inspection equipment.
[0097] Among them, the specific structure, material, size, etc. of the spatial resolution and image distortion test component can refer to the description in the above embodiment, and will not be repeated here.
[0098] The spatial resolution of the security inspection equipment refers to its ability to distinguish line pairs. Usually, the minimum size of the line pairs that the security inspection equipment can distinguish can be used to measure its spatial resolution. Therefore, after obtaining the image area corresponding to the spatial resolution and image distortion test component, the valid line pairs can be identified from the image area first. Considering the existence of noise in the image, or the possibility of some bumpy areas on the surface of the test component, which are easily misidentified as line pair areas, or for some small-sized line pairs, the image in the security inspection image is blurred and cannot be identified. Therefore, if Fig.14As shown, in order to determine the line pairs with clear imaging in the security inspection image, for each image area that may be a line pair area in the security inspection image, for each pixel row or pixel column perpendicular to the long side direction of the line pair in the image area, it is possible to determine whether each pixel point in the pixel row or pixel column is a peak or a trough, and then count the number of pixel points determined as peaks or troughs in the pixel column. If the number is greater than a preset number threshold, the pixel column or pixel row is determined as a valid pixel column or pixel row. Then, it is counted whether the proportion of the number of valid pixel columns or pixel rows in the image area corresponding to the line pair to the total number of pixel columns or pixel columns in the image area is greater than a preset proportion. If so, the line pair is considered to be a valid line pair. Then, the evaluation result of the spatial resolution of the security inspection equipment can be determined based on the minimum line pair size in the identified valid line pairs. Of course, the spatial resolution of the security inspection equipment can also be evaluated in combination with the clarity of the line pairs in the image area.
[0099] In addition, in order to evaluate the distortion of the security inspection image, in some embodiments, the shape of the spatial resolution and image distortion test component can be a rectangle, so that the distortion of the security inspection image collected by the security inspection equipment can be obtained based on the length-to-width ratio of the spatial resolution and image distortion test component.
[0100] Among them, the solutions of the above-mentioned embodiments can be freely combined to obtain new solutions when there is no conflict. Due to space constraints, they will not be listed one by one here.
[0101] In addition, an embodiment of the present application further provides a computer program product, which includes a computer program, and when the computer program is executed, the method mentioned in any of the above embodiments is implemented.
[0102] Furthermore, the present application also provides an electronic device, such as Fig.15 FIG. 1 is a hardware structure diagram of an electronic device according to an embodiment of the present application, except Fig.15 In addition to the processor 151 and memory 152 shown, the device may also generally include other hardware, such as a forwarding processing unit responsible for processing messages; from the perspective of hardware structure, the device may also be a distributed device, which may include multiple interface cards to expand message processing at the hardware level. The memory 152 stores computer instructions, and the processor 151 implements the method mentioned in any of the above embodiments when executing the computer instructions. Accordingly, an embodiment of this specification also provides a computer storage medium, in which a program is stored, and when the program is executed by the processor, the method in any of the above embodiments is implemented.
[0103] The embodiments of this specification may take the form of a computer program product implemented on one or more storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing program code. Computer-usable storage media include permanent and non-permanent, removable and non-removable media, and information storage can be implemented by any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include but are not limited to: phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, read-only compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device.
[0104] For the device embodiment, since it basically corresponds to the method embodiment, the relevant parts can refer to the partial description of the method embodiment. The device embodiment described above is only schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative work.
[0105] The user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with the relevant laws, regulations and standards of relevant countries and regions, and provide corresponding operation entrances for users to choose to authorize or refuse.
[0106] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. The terms "include", "comprises" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the statement "comprises a ..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.
[0107] The method and device provided in the embodiments of the present invention are introduced in detail above. Specific examples are used in this article to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. At the same time, for those skilled in the art, according to the idea of the present invention, there will be changes in the specific implementation methods and application scopes. In summary, the content of this specification should not be understood as limiting the present invention.
Claims
1. A method for detecting security inspection images, characterized in that: The security inspection image is obtained by the security inspection equipment collecting images of the test device, the test device includes a base plate, and a plurality of test components arranged on the base plate, the plurality of test components at least including a mixture and an inorganic substance discrimination test component; the method includes: Acquiring the security inspection image; Identifying, from the security inspection image, image regions corresponding to each of the plurality of test components; For each image area corresponding to the test component, the image area is detected based on a pre-set detection strategy corresponding to the test component to obtain an evaluation result of the performance index of the security inspection device tested by the test component, wherein the detection strategy corresponding to each test component is determined based on the imaging characteristics of the test component in the security inspection device; The mixture and inorganic substance discrimination test assembly includes two annular steps, one of which is a mixture material annular step for detecting the discrimination capability of the security inspection equipment for the mixture, and the other annular step is an inorganic material annular step for detecting the discrimination capability of the security inspection equipment for the inorganic substance; For the image area corresponding to the mixture and inorganic substance discrimination test component, the detecting of the image area based on a pre-set detection strategy corresponding to the test component includes: Performing straight line detection on the image region based on brightness components of pixels in the image region, and determining a plurality of sub-regions from the image region using the detected straight lines as dividing lines; Determine a target sub-region from the multiple sub-regions, wherein the ratio of the number of pixels whose hue components are the target color in the target sub-region to the total number of pixels in the image region is greater than a preset ratio; wherein the target color is related to the material of the annular step represented by the target sub-region; Based on the matching of the number of the target sub-areas with the set number, an evaluation result of the resolution capability of the security inspection device for the mixture and / or inorganic matter is determined.
2. The method according to claim 1, characterized in that: If the target color is green, the set number is the number of steps of the annular steps of the mixed material; if the target color is blue, the set number is the number of steps of the annular steps of the inorganic material.
3. The method according to claim 1, characterized in that After performing straight line detection on the image area based on the brightness components of the pixels in the image area and determining a plurality of sub-areas from the image area using the detected straight lines as dividing lines, the method further comprises: Determine a signal-to-noise ratio corresponding to each sub-region, the signal-to-noise ratio being a ratio of a pixel mean of a pixel point whose hue component is a target color in the sub-region to a standard deviation of a pixel value of the pixel point in the sub-region, wherein the target color is related to a material of the annular step represented by the sub-region; An evaluation result of the security inspection device's ability to resolve mixtures and / or inorganic substances is determined based on the signal-to-noise ratio.
4. The method according to claim 1, characterized in that The plurality of test assemblies further include an effective material discrimination and material discrimination test assembly, the effective material discrimination and material discrimination test assembly including a steel step, and at least two test plates stacked on the steel step, a partial area of each test plate overlapping the steel step, wherein the equivalent atomic numbers of the at least two test plates are different from each other, and the equivalent atomic numbers of the at least two test plates are less than the equivalent atomic number of the steel step; For the image area corresponding to the effective material resolution and material resolution test component, the detecting of the image area based on the pre-set detection strategy corresponding to the test component includes: Clustering the pixels in the image area based on the hue components of the pixels in the image area to obtain multiple categories; Determining a valid category from the multiple categories, and determining a color represented by each valid category, wherein a ratio of an area of a pixel region constituted by pixels in the valid category to an area of the image region is greater than a preset area ratio; Based on the matching of the number of valid categories representing the specified color and the set number of material categories, an evaluation result of the material resolution capability and / or the effective material resolution capability of the security inspection device is obtained.
5. The method according to claim 4, characterized in that After determining a valid category from the plurality of categories, the method further comprises: Performing clustering processing on the pixel points in the image area based on the brightness component and / or saturation component of the pixel points in the image area to obtain a clustering result; The clustering result is used to verify the accuracy of the number of determined effective categories.
6. The method according to claim 1, characterized in that The multiple test assemblies further include a penetration test assembly, the penetration test assembly including a lead bar and a first cover covering the lead bar, the thickness of the first cover changing in a continuous gradient, so that the X-ray of the security inspection device penetrates the first covers of different thicknesses to reach the lead bar; For the image area corresponding to the penetration test component, the detecting of the image area based on the detection strategy corresponding to the test component which is preset includes: Determine the average value of the grayscale value of the pixel points in each pixel column or pixel row in the image area to obtain a set of average value sequences, wherein the pixel column or pixel row is perpendicular to the grayscale gradient direction in the image area; use the depth information of the pixel column or pixel row corresponding to the median value in the average value sequence as the half-value layer thickness of the first covering; and obtain the evaluation result of the penetration of the security inspection device based on the half-value layer thickness; and / or, Based on the grayscale value of the image area, the area corresponding to the lead bar is identified from the image area; based on the clarity of the area corresponding to the lead bar, the evaluation result of the penetration force of the security inspection equipment is obtained.
7. The method according to claim 1, characterized in that The multiple test components further include a penetration resolution test component, which includes a substrate, a plurality of circular rings formed by winding metal wires and arranged on the substrate, and a second cover covering the plurality of circular rings, wherein the diameters of the metal wires forming the plurality of circular rings are different, and the thickness of the second cover changes in a continuous gradient, so that the X-rays of the security inspection device penetrate the second covers of different thicknesses to reach the plurality of circular rings; For the image area corresponding to the penetration resolution test component, the detecting of the image area based on the detection strategy corresponding to the test component which is preset includes: Identify the number of rings formed by winding wires of different diameters from the image region; Based on the matching of the number of recognized circular rings and the set number, and / or the clarity of the circular rings, an evaluation result of the penetration resolution of the security inspection equipment is obtained.
8. The method according to claim 1, characterized in that: The multiple test components further include a spatial resolution and image distortion test component, a surface of which is provided with a plurality of groups of linear holes in the horizontal direction and / or a plurality of groups of linear holes in the vertical direction, wherein the widths of the plurality of groups of linear holes in the horizontal direction are different, the widths of the plurality of groups of linear holes in the vertical direction are different, and the linear holes are used to detect the spatial resolution of the security inspection equipment; For the image area corresponding to the spatial resolution and image distortion test component, the detecting of the image area based on a pre-set detection strategy corresponding to the test component includes: Identify a valid line pair from the image area, wherein a proportion of a valid pixel column or a valid pixel row in the image area corresponding to the valid line is greater than a preset proportion, and a number of pixel points in the valid pixel column or the valid pixel row that are determined to be a peak or a trough is greater than a preset number threshold; and the valid pixel column or the valid pixel row is perpendicular to a long side direction of the valid line pair; Based on the minimum line pair size among the effective line pairs, an evaluation result of the spatial resolution of the security inspection equipment is determined.
9. The method according to claim 8, characterized in that The shape of the spatial resolution and image distortion test component is a rectangle, and the method further comprises: Based on the spatial resolution and the aspect ratio of the image distortion test component, an evaluation result of the distortion of the security inspection image collected by the security inspection device is obtained.
10. A computer program product, characterized in that The computer program product comprises a computer program, and when the computer program is executed, the method according to any one of claims 1 to 9 is implemented.
Citation Information
Patent Citations
Method and system for regularly detecting X-ray machine image resolution testing body
CN109870730A