A method for measuring the volume of liquid contraband based on X-ray images.
The method for measuring the volume of liquid contraband based on X-ray images solves the problem of the inability to measure the volume of liquids in existing technologies, enabling accurate measurement of the volume of liquid contraband and improving the security and efficiency of security checks.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BEIJING TELESOUND ELECTRONICS
- Filing Date
- 2024-09-19
- Publication Date
- 2026-07-03
AI Technical Summary
Existing liquid detection instruments cannot effectively measure the volume of liquid stored in containers, resulting in low security of security checks and an inability to accurately assess the hazards of liquid contraband.
The method for measuring the volume of liquid contraband based on X-ray images determines the type of the target liquid, calculates the actual height, horizontal and vertical distance of each pixel, and then calculates the liquid volume. It utilizes the relationship between X-ray intensity and medium attenuation coefficient to achieve accurate measurement of liquid volume.
It improves security check efficiency, reduces safety hazards during the security check process, and can accurately assess the hazards of liquid contraband.
Smart Images

Figure CN119354107B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of security inspection technology, and in particular to a method for measuring the volume of liquid contraband based on X-ray images. Background Technology
[0002] For the sake of reliable public safety, security checks are required on passengers' personal belongings in certain special occasions, such as meetings with large gatherings, and in certain specific scenarios, such as when traveling by subway, high-speed rail or other rail transit or by air.
[0003] When testing containers containing liquids, it is usually necessary to place the containers on specialized liquid testing instruments to determine whether they contain prohibited liquid substances such as sulfuric acid, alcohol, or gasoline. However, existing liquid testing instruments cannot effectively measure the exact volume of the liquid stored in the container. Therefore, even if prohibited liquid substances are detected, it is impossible to assess their specific properties and quantity to determine their potential hazards, leaving public safety risks unresolved. Summary of the Invention
[0004] This invention provides a method for measuring the volume of liquid contraband based on X-ray images, which solves the problem that the existing technology cannot determine the specific volume of the liquid stored in the container, resulting in low security of security checks. This method enables accurate determination of the volume of the liquid stored in the container, thereby improving the security of security checks.
[0005] This invention provides a method for measuring the volume of liquid contraband based on X-ray images, comprising:
[0006] If it is determined that a liquid to be detected is present in the package to be detected based on an X-ray image including the package to be detected, the target liquid type of the liquid to be detected is determined based on the X-ray image;
[0007] If the liquid to be detected is determined to be a liquid contraband based on the target liquid type, the actual height distance in the height direction represented by each pixel point corresponding to the liquid to be detected in the X-ray image is determined;
[0008] The volume of the liquid to be detected is determined based on the actual height distance corresponding to each pixel, the actual horizontal distance represented by each pixel in the horizontal direction, and the actual vertical distance represented by each pixel in the vertical direction.
[0009] According to the present invention, a method for measuring the volume of liquid contraband based on X-ray images, wherein determining the actual height distance in the height direction represented by each pixel point corresponding to the liquid to be detected in the X-ray image includes:
[0010] For each pixel in the X-ray image corresponding to the liquid to be detected, the initial high-energy X-ray intensity of the pixel in the high-energy sub-image corresponding to the liquid to be detected, and the attenuated high-energy X-ray intensity of the pixel are obtained.
[0011] The initial low-energy X-ray intensity of the pixel in the low-energy sub-image corresponding to the liquid to be detected, and the attenuated low-energy X-ray intensity of the pixel are obtained.
[0012] Based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, and the attenuated low-energy X-ray intensity, the actual height distance represented by the pixel in the height direction is determined.
[0013] According to the present invention, a method for measuring the volume of liquid contraband based on X-ray images, wherein determining the actual height distance in the height direction represented by the pixel point based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, and the attenuated low-energy X-ray intensity includes:
[0014] Based on the correspondence between liquid type, X-ray energy value and medium attenuation coefficient, the first medium attenuation coefficient corresponding to the target liquid type under high X-ray energy value and the second medium attenuation coefficient corresponding to the target liquid type under low X-ray energy value are determined.
[0015] Based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, the attenuated low-energy X-ray intensity, the first medium attenuation coefficient, and the second medium attenuation coefficient, the actual height distance represented by the pixel in the height direction is determined.
[0016] According to the present invention, a method for measuring the volume of liquid contraband based on X-ray images, wherein determining the actual height distance in the height direction represented by the pixel point based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, the attenuated low-energy X-ray intensity, the first medium attenuation coefficient, and the second medium attenuation coefficient includes:
[0017] The actual height distance in the height direction represented by the pixel is determined based on formula (1):
[0018] (1)
[0019] in, Represents pixels The actual height distance in the vertical direction is represented. Represents the attenuation coefficient of the first medium. This represents the attenuation coefficient of the second medium. Represents the pixels in the low-energy sub-image The initial low-energy X-ray intensity at that location, Represents the pixels in the low-energy sub-image The intensity of low-energy X-rays after attenuation Represents the pixels in the high-energy sub-image The initial high-energy X-ray intensity at that location, Represents the pixels in the high-energy sub-image The intensity of high-energy X-rays after attenuation.
[0020] According to the present invention, a method for measuring the volume of liquid contraband based on X-ray images, wherein the volume of the liquid to be detected is determined based on the actual height distance corresponding to each pixel, the actual horizontal distance represented by each pixel in the horizontal direction, and the actual vertical distance represented by each pixel in the vertical direction, the method includes:
[0021] For each pixel, the volume of the liquid to be detected corresponding to the pixel is determined based on the actual height distance corresponding to the pixel, the actual horizontal distance represented by the pixel in the horizontal direction, and the actual vertical distance represented by the pixel in the vertical direction.
[0022] The sum of the volumes of the liquid to be detected corresponding to all pixels is determined as the volume of the liquid to be detected.
[0023] According to the present invention, a method for measuring the volume of liquid contraband based on X-ray images is provided, the method further comprising:
[0024] Obtain at least one reference X-ray image for the standard part;
[0025] For each of the aforementioned reference X-ray images, the first pixel length of the standard component in the horizontal direction in the reference X-ray image is obtained;
[0026] Based on the first pixel length and the first actual length of the standard component in the horizontal direction, the horizontal distance represented by each pixel in the reference X-ray image in the horizontal direction is determined.
[0027] The average horizontal distance represented by each pixel in all reference X-ray images is determined as the actual horizontal distance.
[0028] According to the present invention, a method for measuring the volume of liquid contraband based on X-ray images is provided, the method further comprising:
[0029] For each of the aforementioned reference X-ray images, the second pixel length of the standard component in the vertical direction in the reference X-ray image is obtained;
[0030] Based on the second pixel length and the second actual length of the standard in the vertical direction, the vertical distance represented by each pixel in the reference X-ray image in the vertical direction is determined;
[0031] The average value of the vertical distances represented by each pixel in the vertical direction in all reference X-ray images is determined as the actual vertical distance.
[0032] According to the present invention, a method for measuring the volume of liquid contraband based on X-ray images is provided, wherein determining the target liquid type of the liquid to be detected based on the X-ray image includes:
[0033] Based on the initial high-energy X-ray intensity, attenuated high-energy X-ray intensity, initial low-energy X-ray intensity, and attenuated low-energy X-ray intensity of the target pixel, the feature value of the liquid to be detected is determined. The target pixel is any pixel in the X-ray image corresponding to the liquid to be detected. The feature value is a value used to characterize the material properties.
[0034] Based on the characteristic values of the liquid to be tested, the target liquid type of the liquid to be tested is determined.
[0035] According to the present invention, a method for measuring the volume of liquid contraband based on X-ray images, wherein determining the target liquid type of the liquid to be detected based on the feature values of the liquid to be detected includes:
[0036] Based on the characteristic values of the liquid to be tested, the relative atomic numbers of the components of the liquid to be tested are determined;
[0037] Based on the correspondence between liquid type and relative atomic number range, the liquid type corresponding to the target relative atomic number range to which the relative atomic number belongs is determined as the target liquid type.
[0038] According to the present invention, a method for measuring the volume of liquid contraband based on X-ray images, wherein the characteristic values of the liquid to be detected are determined based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, and the attenuated low-energy X-ray intensity of a target pixel, including:
[0039] The characteristic value of the liquid to be detected is determined based on formula (2):
[0040] (2)
[0041] Wherein, R represents the characteristic value of the liquid to be detected. Represents the pixels in the low-energy sub-image The initial low-energy X-ray intensity at that location, Represents the pixels in the low-energy sub-image The intensity of low-energy X-rays after attenuation Represents the pixels in the high-energy sub-image The initial high-energy X-ray intensity at that location, Represents the pixels in the high-energy sub-image The intensity of high-energy X-rays after attenuation.
[0042] The present invention also provides a liquid contraband volume measuring device based on X-ray images, comprising:
[0043] The determination module is used to determine the target liquid type of the liquid to be detected based on the X-ray image, provided that the presence of the liquid to be detected is determined in the package to be detected based on the X-ray image.
[0044] The determining module is further configured to, when the liquid to be detected is determined to be a liquid contraband based on the target liquid type, determine the actual height distance in the height direction represented by each pixel point corresponding to the liquid to be detected in the X-ray image;
[0045] The determining module is further configured to determine the volume of the liquid to be detected based on the actual height distance corresponding to each pixel, the actual horizontal distance represented by each pixel in the horizontal direction, and the actual vertical distance represented by each pixel in the vertical direction.
[0046] The present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the liquid contraband volume measurement method based on X-ray images as described above.
[0047] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the liquid contraband volume measurement method based on X-ray images as described above.
[0048] The present invention also provides a computer program product, including a computer program that, when executed by a processor, implements the above-described method for measuring the volume of liquid contraband based on X-ray images.
[0049] The present invention provides a method for measuring the volume of liquid contraband based on X-ray images. When it is determined that a liquid to be detected exists in the package under inspection based on an X-ray image including the package, the method determines the target liquid type based on the X-ray image. If the target liquid type determines that the liquid to be detected is a liquid contraband, the method determines the actual height distance represented by each pixel in the X-ray image corresponding to the liquid to be detected in the vertical direction. Based on the actual height distance, the actual horizontal distance, and the actual vertical distance represented by each pixel in the vertical direction, the volume of the liquid to be detected is determined. On one hand, when it is determined that a liquid to be detected exists in the package, the target liquid type can be directly determined based on the X-ray image, thereby simplifying the liquid detection process and improving security inspection efficiency. On the other hand, when the target liquid type determines that the liquid to be detected is a liquid contraband, the volume of the liquid contraband corresponding to each pixel is calculated, and the volume of the liquid to be detected is obtained based on the volume corresponding to each pixel. Based on this volume, the harmfulness of liquid contraband can be estimated, reducing safety hazards during security checks and improving security. Attached Figure Description
[0050] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0051] Figure 1 This is a schematic flowchart of a method for measuring the volume of liquid contraband based on X-ray images, provided in an embodiment of the present invention.
[0052] Figure 2 This is a schematic diagram of an X-ray image provided in an embodiment of the present invention.
[0053] Figure 3 The image obtained by segmenting an X-ray image is provided in an embodiment of the present invention.
[0054] Figure 4 An X-ray image of a liquid region provided in an embodiment of the present invention.
[0055] Figure 5 This is a high-energy image corresponding to the X-ray image provided in the embodiments of the present invention.
[0056] Figure 6 This is a low-energy image corresponding to the X-ray image provided in the embodiments of the present invention.
[0057] Figure 7 Reference X-ray image of a standard component provided for an embodiment of the present invention.
[0058] Figure 8 This is a schematic diagram of the structure of the liquid contraband volume measuring device based on X-ray images provided in an embodiment of the present invention.
[0059] Figure 9 This is a schematic diagram of the physical structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation
[0060] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.
[0061] Currently, when inspecting containers containing liquids, the containers are typically placed on specialized liquid detectors to determine if they contain prohibited liquid substances. Therefore, the existing liquid inspection process is cumbersome, directly impacting security inspection efficiency. Furthermore, existing liquid detection instruments cannot effectively measure the exact volume of liquid stored in the container, making it impossible to assess the harmfulness of prohibited liquid substances and resulting in low security levels during security checks.
[0062] To address the aforementioned problems, this invention provides a method for measuring the volume of liquid contraband based on X-ray images. In this method, when the presence of a liquid to be detected in a package is determined, the target liquid type can be directly determined based on the X-ray image. This allows for the determination of whether the liquid is a liquid contraband, simplifying the liquid detection process and improving security inspection efficiency. When the target liquid type determines the liquid to be a liquid contraband, the thickness of the liquid contraband at each planar pixel can be calculated, and the volume of each planar pixel can be determined based on this thickness. The volumes of all planar pixels in the X-ray image are then summed to calculate the final volume of the liquid contraband contained in the container. Based on this volume, the hazard of the liquid contraband can be estimated, reducing security risks during security checks and improving overall security.
[0063] The following is combined with Figures 1 to 7This invention describes a method for measuring the volume of liquid contraband based on X-ray images, as provided in an embodiment of the invention. The execution subject of this method can be an electronic device such as a security screening machine, computer, or server, or a specially designed intelligent device. Alternatively, it can be an X-ray image-based liquid contraband volume measuring device installed within the electronic or intelligent device. This X-ray image-based liquid contraband volume measuring device can be implemented through software, hardware, or a combination of both. This method can be applied to various scenarios requiring security checks, such as bus stations, train stations, subway stations, or high-speed rail stations.
[0064] Figure 1 This is a flowchart illustrating the method for measuring the volume of liquid contraband based on X-ray images provided in an embodiment of the present invention, as shown below. Figure 1 As shown, the method includes:
[0065] Step 101: If it is determined that the liquid to be detected is present in the package to be detected based on the X-ray image including the package to be detected, determine the target liquid type of the liquid to be detected based on the X-ray image.
[0066] In this step, since passengers' carry-on luggage may contain containers for holding liquids, it is necessary to determine whether the containers in the luggage to be inspected contain liquids during security checks.
[0067] Specifically, Figure 2 A schematic diagram of an X-ray image provided in an embodiment of the present invention, as shown below. Figure 2 As shown, during security checks, a dual-X-ray source X-ray scanner can be used to scan each piece of luggage to obtain X-ray images. It should be noted that these X-ray images must be obtained from a main-view X-ray image with the direction of gravity of the luggage as the scanning direction (Z-direction).
[0068] When an X-ray image of a package to be inspected contains an object with a clear container-shaped outline, the color of its internal area can be used to determine whether it contains liquid. When the color of the internal area of the container is very light, close to white, it indicates that the container contains air and no liquid.
[0069] in addition, Figure 3 This is an image obtained by segmenting an X-ray image, as provided in an embodiment of the present invention. Figure 4 X-ray images of liquid regions provided in embodiments of the present invention, such as Figure 3 and Figure 4As shown, the X-ray image can also be segmented, and the liquid region portion can be extracted from the segmented image as a sub-image for identifying the liquid to be detected. It should be noted that during image segmentation, the container wall portion can be removed, retaining only the area where the liquid to be detected exists. This avoids the container wall being too thick, which could affect the accuracy of subsequent identification of the liquid within the container using the sub-image for identifying the liquid to be detected.
[0070] When it is determined that the package to be tested contains the liquid to be tested, the target liquid type can be determined based on the X-ray image. The liquid type includes water, alcohol, gasoline, thinner, acetone, sulfuric acid, or diesel, etc.
[0071] Step 102: If the liquid to be detected is determined to be a liquid contraband based on the target liquid type, determine the actual height distance in the height direction represented by each pixel point corresponding to the liquid to be detected in the X-ray image.
[0072] In this step, prohibited liquids may include, for example, any liquid that is not permitted to be carried in a vehicle or in a crowded setting, such as alcohol, gasoline, thinner, acetone, sulfuric acid, or diesel. The actual height distance represented by each pixel in the vertical direction can be understood as the actual total thickness in the Z-direction of the liquid region at each pixel in the X-ray image within the XY Cartesian coordinate system plane. Among them, the Z-direction can be understood as... Figure 3 or Figure 4 The direction perpendicular to the paper is the direction of gravity of the package to be tested.
[0073] After determining the target liquid type, if the target liquid type indicates that the liquid is a contraband, the actual height distance of each pixel within the liquid region of the liquid in the X-ray image in the vertical direction will be determined, which is the actual total thickness in the Z-axis. .
[0074] Step 103: Determine the volume of the liquid to be detected based on the actual height distance corresponding to each pixel, the actual horizontal distance represented by each pixel in the horizontal direction, and the actual vertical distance represented by each pixel in the vertical direction.
[0075] In this step, the actual horizontal distance represented by each pixel in the horizontal direction can be understood as the actual physical length that can be represented in the horizontal direction after mapping the pixel length of each pixel to the actual world coordinate system. The actual vertical distance represented by each pixel in the vertical direction can be understood as the actual physical length that can be represented in the vertical direction after mapping the pixel length of each pixel to the actual world coordinate system.
[0076] Based on the actual height distance corresponding to each pixel, the actual horizontal distance represented by each pixel in the horizontal direction, and the actual vertical distance represented by each pixel in the vertical direction, the volume of the liquid contraband corresponding to each pixel can be determined, and thus the volume of the entire liquid to be detected can be determined based on the volume corresponding to each pixel.
[0077] By calculating the volume of the liquid contraband corresponding to each pixel and summing the volumes of each pixel, the volume of the liquid to be detected can be obtained. This method can effectively overcome the error caused by the calculation of liquid volume when using irregularly shaped containers to hold liquids, making the volume detection results of liquid contraband more accurate. This helps to estimate the hazards caused by liquid contraband and quickly obtain a reliable solution for handling liquid contraband.
[0078] The present invention provides a method for measuring the volume of liquid contraband based on X-ray images. When it is determined that a liquid to be detected exists in the package under inspection based on an X-ray image including the package, the method determines the target liquid type based on the X-ray image. If the target liquid type determines that the liquid to be detected is a liquid contraband, the method determines the actual height distance represented by each pixel in the X-ray image corresponding to the liquid to be detected in the vertical direction. Based on the actual height distance, the actual horizontal distance, and the actual vertical distance represented by each pixel in the vertical direction, the volume of the liquid to be detected is determined. On one hand, when it is determined that a liquid to be detected exists in the package, the target liquid type can be directly determined based on the X-ray image, thereby simplifying the liquid detection process and improving security inspection efficiency. On the other hand, when the target liquid type determines that the liquid to be detected is a liquid contraband, the volume of the liquid contraband corresponding to each pixel is calculated, and the volume of the liquid to be detected is obtained based on the volume corresponding to each pixel. Based on this volume, the harmfulness of liquid contraband can be estimated, reducing safety hazards during security checks and improving security.
[0079] For example, based on the above embodiments, when determining the actual height distance in the height direction represented by each pixel point corresponding to the liquid to be detected in the X-ray image, it can be done in the following way:
[0080] For each pixel in the X-ray image corresponding to the liquid to be detected, the initial high-energy X-ray intensity and the attenuated high-energy X-ray intensity of the pixel in the high-energy sub-image of the liquid to be detected are obtained. The initial low-energy X-ray intensity and the attenuated low-energy X-ray intensity of the pixel in the low-energy sub-image of the liquid to be detected are also obtained. Based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, and the attenuated low-energy X-ray intensity, the actual height distance represented by the pixel in the height direction is determined.
[0081] Specifically, Figure 5 This is a high-energy image corresponding to the X-ray image provided in the embodiments of the present invention. Figure 6 The low-energy image corresponding to the X-ray image provided in the embodiments of the present invention, such as Figure 5 and Figure 6 As shown, after scanning the package to be inspected, the X-ray security inspection machine with dual X-ray sources will not only output the corresponding X-ray image of the package to be inspected, but also the corresponding high-energy image and low-energy image. The high-energy image is formed by the attenuation of high-energy X-rays after penetrating the object, and the image formed by the attenuated X-rays after being received. The low-energy image is formed by the attenuation of low-energy X-rays after penetrating the object, and the image formed by the attenuated X-rays after being received.
[0082] Furthermore, it can be based on Figure 3 The liquid contour region in the X-ray image is used to pick the corresponding high-energy sub-image and low-energy sub-image of the liquid to be detected in the high-energy image and low-energy image, respectively.
[0083] For each pixel in an X-ray image corresponding to the liquid to be detected, the initial high-energy X-ray intensity and the attenuated high-energy X-ray intensity of that pixel can be obtained in the high-energy sub-image. The initial high-energy X-ray intensity is the X-ray intensity value (unit: W / m²) read from the high-energy sub-image obtained during the dry scan of an X-ray security inspection machine with dual X-ray sources. 2 The initial high-energy X-ray intensity can be set to 100 keV. The attenuated high-energy X-ray intensity is the output data of the high-energy sub-image corresponding to the liquid to be detected.
[0084] For each pixel corresponding to the liquid to be detected in the X-ray image, it is also necessary to obtain the initial low-energy X-ray intensity and the attenuated low-energy X-ray intensity of that pixel in the low-energy sub-image. The initial low-energy X-ray intensity is the X-ray intensity value (unit: W / m²) read from the low-energy sub-image acquired during the dry scan of the dual-X-ray source X-ray security inspection machine. 2 The initial low-energy X-ray intensity can be set to 20 keV. The attenuated low-energy X-ray intensity is the output data of the low-energy sub-image corresponding to the liquid to be detected.
[0085] Furthermore, the actual height distance represented by a pixel in the height direction can be determined based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, and the attenuated low-energy X-ray intensity. This method allows for the rapid determination of the actual height distance represented by a pixel in the height direction, improving the efficiency of determining the actual height distance for each pixel.
[0086] For example, when determining the actual height distance in the height direction represented by a pixel based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, and the attenuated low-energy X-ray intensity, the first medium attenuation coefficient corresponding to the target liquid type at high X-ray energy value and the second medium attenuation coefficient corresponding to the target liquid type at low X-ray energy value can be determined based on the correspondence between liquid type, X-ray energy value, and medium attenuation coefficient. And based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, the attenuated low-energy X-ray intensity, the first medium attenuation coefficient, and the second medium attenuation coefficient, the actual height distance in the height direction represented by the pixel can be determined.
[0087] Specifically, the dielectric attenuation coefficient of the required liquid contraband can be extracted from the NIST physical database to construct a correspondence between liquid type, X-ray energy value, and dielectric attenuation coefficient. This correspondence can be illustrated in Table 1, for example.
[0088] Table 1
[0089]
[0090] By consulting Table 1 above, we can obtain the first medium attenuation coefficient corresponding to the target liquid type at high X-ray energy values, and the second medium attenuation coefficient corresponding to the target liquid type at low X-ray energy values. For example, assuming the target liquid type is sulfuric acid, we can find from Table 1 that the first medium attenuation coefficient is 0.0278 and the second medium attenuation coefficient is 0.1205.
[0091] Furthermore, the actual height distance represented by a pixel in the height direction can be determined based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, the attenuated low-energy X-ray intensity, the first dielectric attenuation coefficient, and the second dielectric attenuation coefficient. By incorporating the first dielectric attenuation coefficient and the second dielectric attenuation coefficient, the accuracy of the actual height distance corresponding to each pixel can be further improved.
[0092] For example, when determining the actual height distance in the height direction represented by a pixel based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, the attenuated low-energy X-ray intensity, the first dielectric attenuation coefficient, and the second dielectric attenuation coefficient, the actual height distance in the height direction represented by the pixel can be determined based on formula (1):
[0093] (1)
[0094] in, Represents pixels The actual height distance in the vertical direction is represented. Represents the attenuation coefficient of the first medium. This represents the attenuation coefficient of the second medium. Represents pixels in a low-energy sub-image The initial low-energy X-ray intensity at that location, Represents pixels in a low-energy sub-image The intensity of low-energy X-rays after attenuation Represents pixels in a high-energy sub-image The initial high-energy X-ray intensity at that location, Represents pixels in a high-energy sub-image The intensity of high-energy X-rays after attenuation.
[0095] In this embodiment, the actual height distance represented by each pixel in the height direction can be quickly and accurately determined by the above formula (1).
[0096] For example, based on the above embodiments, when determining the volume of the liquid to be detected based on the actual height distance corresponding to each pixel, the actual horizontal distance represented by each pixel in the horizontal direction, and the actual vertical distance represented by each pixel in the vertical direction, the volume of the liquid to be detected corresponding to each pixel can be determined for each pixel based on the actual height distance corresponding to the pixel, the actual horizontal distance represented by the pixel in the horizontal direction, and the actual vertical distance represented by the pixel in the vertical direction, and the sum of the volumes of the liquid to be detected corresponding to all pixels is determined as the volume of the liquid to be detected.
[0097] Specifically, the pixel can be determined based on formula (3). The corresponding volume of the liquid to be tested :
[0098] (3)
[0099] in, This represents the actual horizontal distance of a pixel in the horizontal direction. This represents the actual vertical distance of a pixel in the vertical direction.
[0100] By traversing as Figure 4 All pixels in the XY Cartesian coordinate system plane shown can be used to determine the volume of the liquid to be detected based on the following formula (4). :
[0101] (4)
[0102] In this embodiment, by determining the volume of the liquid to be detected corresponding to each pixel and summing the volumes of the liquid to be detected corresponding to all pixels, the volume of the liquid to be detected is determined. This method refines the determination of the volume of the liquid to be detected to the determination of the volume of the liquid to be detected corresponding to each pixel. Therefore, it can effectively overcome the error caused by the calculation of the liquid volume when using irregularly shaped containers to hold liquid, making the final determined volume detection result of the liquid to be detected more accurate.
[0103] For example, based on the above embodiments, the actual horizontal distance represented by the pixel in the horizontal direction mentioned in the foregoing embodiments can be determined in the following way:
[0104] At least one reference X-ray image for the standard part is obtained. For each reference X-ray image, the first pixel length of the standard part in the horizontal direction in the reference X-ray image is obtained. Based on the first pixel length and the first actual length of the standard part in the horizontal direction, the horizontal distance represented by each pixel in the reference X-ray image in the horizontal direction is determined. Thus, the average value of the horizontal distances represented by each pixel in the horizontal direction in all reference X-ray images is determined as the actual horizontal distance.
[0105] Specifically, Figure 7 Reference X-ray images of standard parts provided for embodiments of the present invention, such as Figure 7 As shown, an item with preset length, width, and height dimensions can be selected as a standard part. A dual-X-ray source X-ray security inspection machine is used to obtain a reference X-ray image of the standard part by scanning along its direction of gravity (i.e., the vertical Z-direction). It should be noted that the standard part must have clear boundaries under X-rays, meaning the resulting reference X-ray image must have a clear outline for easy identification. Typically, materials with X-ray absorption between 20% and 70% are selected. In this embodiment, a cubic object made of polyester with actual physical dimensions of (100mm × 100mm × 100mm) is selected as the standard part.
[0106] The standard component is placed in the inspection area of an X-ray security inspection machine with dual X-ray sources, ensuring its stability. The standard component is scanned N times using the X-ray security inspection machine. During the N scans, the position of the standard component in the inspection area is usually adjusted or the component is rotated by an angle in the XY Cartesian coordinate system plane, thereby obtaining N reference X-ray images of the standard component, where N is a positive integer greater than or equal to 1.
[0107] For each reference X-ray image, Figure 7 The reference X-ray image shown in the main viewpoint is used for calibration in the X and Y directions, where the X direction is the horizontal direction and the Y direction is the vertical direction. The length of the first pixel of the standard component in the reference X-ray image in the X direction is measured and denoted as . .
[0108] Since the first actual length of the standard part in the X direction is known, it is denoted as... Therefore, the horizontal distance represented by each pixel in the reference X-ray image in the horizontal direction can be determined based on formula (5). The first actual length can also be understood as the actual physical length of the standard part in the horizontal direction (in millimeters).
[0109] (5)
[0110] Furthermore, to improve the accuracy of the actual horizontal distance, error optimization can be performed. By traversing N reference X-ray images of the standard part, the average horizontal distance represented by each pixel in the horizontal direction in all reference X-ray images is calculated based on formula (6). :
[0111] (6)
[0112] in, This represents the horizontal distance of a pixel in the i-th reference X-ray image in the horizontal direction.
[0113] By calculating the average value as described above, errors can be reduced, and the average actual horizontal distance corresponding to each pixel in the X direction can be obtained.
[0114] In this embodiment, the actual horizontal distance is determined by the average of the horizontal distances represented by each pixel in all reference X-ray images in the horizontal direction, thereby reducing errors and improving the accuracy of the determined actual horizontal distance.
[0115] For example, based on the above embodiments, the actual vertical distance represented by the pixel points in the vertical direction mentioned in the foregoing embodiments can be determined in the following way:
[0116] For each reference X-ray image, the second pixel length of the standard part in the vertical direction in the reference X-ray image is obtained. Based on the second pixel length and the second actual length of the standard part in the vertical direction, the vertical distance represented by each pixel in the reference X-ray image in the vertical direction is determined. The average value of the vertical distances represented by each pixel in the vertical direction in all reference X-ray images is determined as the actual vertical distance.
[0117] Specifically, for each reference X-ray image, for Figure 7 The reference X-ray image shown in the main viewpoint, after calibration in the X and Y directions, will have its second pixel length in the Y direction (i.e., its second pixel length in the vertical direction) of the standard component in the reference X-ray image measured and denoted as... .
[0118] Since the second actual length of the standard part in the Y direction is known, it is denoted as... Therefore, the vertical distance represented by each pixel in the reference X-ray image in the vertical direction can be determined based on formula (7). The second actual length can also be understood as the actual physical length of the standard part in the vertical direction (in millimeters).
[0119] (7)
[0120] Furthermore, to improve the accuracy of the actual vertical distance, error optimization can be performed. By traversing N reference X-ray images of the standard part, the average value of the vertical distance represented by each pixel in the vertical direction in all reference X-ray images is calculated based on formula (8). :
[0121] (8)
[0122] in, This represents the vertical distance of a pixel in the i-th reference X-ray image in the vertical direction.
[0123] By calculating the average value as described above, errors can be reduced, and the average actual vertical distance corresponding to each pixel in the Y direction can be obtained.
[0124] In this embodiment, the actual vertical distance is determined by averaging the vertical distances represented by each pixel in all reference X-ray images in the vertical direction, thereby reducing errors and improving the accuracy of the determined actual vertical distance.
[0125] For example, based on the above embodiments, when determining the target liquid type of the liquid to be detected based on an X-ray image, the feature value of the liquid to be detected can be determined based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, and the attenuated low-energy X-ray intensity of the target pixel. The target pixel is any pixel in the X-ray image corresponding to the liquid to be detected, and the feature value is a value used to characterize the material properties. Based on the feature value of the liquid to be detected, the target liquid type of the liquid to be detected is determined.
[0126] Specifically, the R value of the liquid component of the liquid to be detected can be calculated using the data information of the low-energy and high-energy sub-images corresponding to the liquid to be detected. This R value is a characteristic value of the substance's properties and can be calculated from the acquired low-energy and high-energy sub-images. For example, it can be determined based on the initial high-energy X-ray intensity, attenuated high-energy X-ray intensity, initial low-energy X-ray intensity, and attenuated low-energy X-ray intensity of any target pixel point corresponding to the liquid to be detected in the X-ray image. In one possible implementation, the characteristic value of the liquid to be detected can be determined quickly and accurately based on formula (2):
[0127] (2)
[0128] Where R represents the characteristic value of the liquid to be detected. Represents pixels in a low-energy sub-image The initial low-energy X-ray intensity at that location, Represents pixels in a low-energy sub-image The intensity of low-energy X-rays after attenuation Represents pixels in a high-energy sub-image The initial high-energy X-ray intensity at that location, Represents pixels in a high-energy sub-image The intensity of high-energy X-rays after attenuation.
[0129] After determining the characteristic value of the liquid to be tested, since the characteristic value can reflect the material properties, the target liquid type of the liquid to be tested can be accurately determined based on the characteristic value.
[0130] For example, when determining the target liquid type based on the characteristic values of the liquid to be tested, the relative atomic number of the components of the liquid to be tested can be determined based on the characteristic values of the liquid to be tested. Based on the correspondence between liquid type and relative atomic number intervals, the liquid type corresponding to the target relative atomic number interval to which the relative atomic number belongs can be determined as the target liquid type.
[0131] Specifically, the relative atomic number Z of the liquid component of the liquid to be tested can be determined according to formula (9):
[0132] (9)
[0133] In addition, the correspondence between liquid type and relative atomic number range can be established in advance, as shown in Table 2:
[0134] Table 2
[0135]
[0136] By querying the above correspondence, it can be determined which relative atomic number Z of the component of the liquid to be tested falls into which liquid type's relative atomic number interval. The liquid type corresponding to the target relative atomic number interval to which the relative atomic number belongs is determined as the target liquid type of the liquid to be tested, thereby completing the determination of the material properties of the component of the liquid to be tested.
[0137] When the target liquid is water, it is considered safe and the package to be inspected can pass through security. When the target liquid is a liquid contraband, the volume of the liquid to be inspected can be determined in accordance with the method described in any of the aforementioned embodiments.
[0138] In this embodiment, by determining the relative atomic number of the components of the liquid to be detected, the target liquid type of the liquid to be detected can be determined simply and quickly based on the relative atomic number, which improves the efficiency of determining the target liquid type and thus increases the speed of security inspection.
[0139] The following describes the liquid contraband volume measurement device based on X-ray images provided by the present invention. The liquid contraband volume measurement device based on X-ray images described below can be referred to in correspondence with the liquid contraband volume measurement method based on X-ray images described above.
[0140] Figure 8 This is a schematic diagram of the structure of the liquid contraband volume measuring device based on X-ray images provided in an embodiment of the present invention, with reference to... Figure 8 As shown, the liquid contraband volume measuring device 800 based on X-ray images includes:
[0141] The first determining module 11 is used to determine the target liquid type of the liquid to be detected based on the X-ray image when it is determined that there is a liquid to be detected in the package to be detected based on the X-ray image including the package to be detected.
[0142] The second determining module 12 is used to determine the actual height distance in the height direction represented by each pixel point corresponding to the liquid to be detected in the X-ray image when the liquid to be detected is determined to be a liquid contraband based on the target liquid type.
[0143] The third determining module 13 is used to determine the volume of the liquid to be detected based on the actual height distance corresponding to each pixel, the actual horizontal distance represented by each pixel in the horizontal direction, and the actual vertical distance represented by each pixel in the vertical direction.
[0144] In one example embodiment, the second determining module 12 is specifically used for:
[0145] For each pixel in the X-ray image corresponding to the liquid to be detected, the initial high-energy X-ray intensity of the pixel in the high-energy sub-image corresponding to the liquid to be detected, and the attenuated high-energy X-ray intensity of the pixel are obtained.
[0146] The initial low-energy X-ray intensity of the pixel in the low-energy sub-image corresponding to the liquid to be detected, and the attenuated low-energy X-ray intensity of the pixel are obtained.
[0147] Based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, and the attenuated low-energy X-ray intensity, the actual height distance represented by the pixel in the height direction is determined.
[0148] In one example embodiment, the second determining module 12 is specifically used for:
[0149] Based on the correspondence between liquid type, X-ray energy value and medium attenuation coefficient, the first medium attenuation coefficient corresponding to the target liquid type under high X-ray energy value and the second medium attenuation coefficient corresponding to the target liquid type under low X-ray energy value are determined.
[0150] Based on the initial high-energy X-ray intensity, the attenuated high-energy X-ray intensity, the initial low-energy X-ray intensity, the attenuated low-energy X-ray intensity, the first medium attenuation coefficient, and the second medium attenuation coefficient, the actual height distance represented by the pixel in the height direction is determined.
[0151] In one example embodiment, the second determining module 12 is specifically used for:
[0152] The actual height distance in the height direction represented by the pixel is determined based on formula (1):
[0153] (1)
[0154] in, Represents pixels The actual height distance in the vertical direction is represented. Represents the attenuation coefficient of the first medium. This represents the attenuation coefficient of the second medium. Represents the pixels in the low-energy sub-image The initial low-energy X-ray intensity at that location, Represents the pixels in the low-energy sub-image The intensity of low-energy X-rays after attenuation Represents the pixels in the high-energy sub-image The initial high-energy X-ray intensity at that location, Represents the pixels in the high-energy sub-image The intensity of high-energy X-rays after attenuation.
[0155] In one example embodiment, the third determining module 13 is specifically used for:
[0156] For each pixel, the volume of the liquid to be detected corresponding to the pixel is determined based on the actual height distance corresponding to the pixel, the actual horizontal distance represented by the pixel in the horizontal direction, and the actual vertical distance represented by the pixel in the vertical direction.
[0157] The sum of the volumes of the liquid to be detected corresponding to all pixels is determined as the volume of the liquid to be detected.
[0158] In one example embodiment, the device further includes:
[0159] The acquisition module is used to acquire at least one reference X-ray image of the standard part;
[0160] The acquisition module is further configured to acquire, for each of the reference X-ray images, the first pixel length of the standard component in the horizontal direction in the reference X-ray image;
[0161] The fourth determining module is used to determine the horizontal distance represented by each pixel in the reference X-ray image in the horizontal direction based on the first pixel length and the first actual length of the standard part in the horizontal direction;
[0162] The fifth determining module is used to determine the actual horizontal distance as the average value of the horizontal distance represented by each pixel in the horizontal direction in all reference X-ray images.
[0163] In one example embodiment, the acquisition module is further configured to acquire, for each of the reference X-ray images, the second pixel length of the standard in the vertical direction in the reference X-ray image;
[0164] The sixth determining module is used to determine the vertical distance represented by each pixel in the reference X-ray image in the vertical direction based on the second pixel length and the second actual length of the standard in the vertical direction;
[0165] The seventh determining module is used to determine the average value of the vertical distances represented by each pixel in the vertical direction in all reference X-ray images as the actual vertical distance.
[0166] In one example embodiment, the third determining module 13 is specifically used for:
[0167] Based on the initial high-energy X-ray intensity, attenuated high-energy X-ray intensity, initial low-energy X-ray intensity, and attenuated low-energy X-ray intensity of the target pixel, the feature value of the liquid to be detected is determined. The target pixel is any pixel in the X-ray image corresponding to the liquid to be detected. The feature value is a value used to characterize the material properties.
[0168] Based on the characteristic values of the liquid to be tested, the target liquid type of the liquid to be tested is determined.
[0169] In one example embodiment, the third determining module 13 is specifically used for:
[0170] Based on the characteristic values of the liquid to be tested, the relative atomic numbers of the components of the liquid to be tested are determined;
[0171] Based on the correspondence between liquid type and relative atomic number range, the liquid type corresponding to the target relative atomic number range to which the relative atomic number belongs is determined as the target liquid type.
[0172] In one example embodiment, the third determining module 13 is specifically used for:
[0173] The characteristic value of the liquid to be detected is determined based on formula (2):
[0174] (2)
[0175] Wherein, R represents the characteristic value of the liquid to be detected. Represents the pixels in the low-energy sub-image The initial low-energy X-ray intensity at that location, Represents the pixels in the low-energy sub-image The intensity of low-energy X-rays after attenuation Represents the pixels in the high-energy sub-image The initial high-energy X-ray intensity at that location, Represents the pixels in the high-energy sub-image The intensity of high-energy X-rays after attenuation.
[0176] The apparatus of this embodiment can be used to execute the method of any embodiment in the side embodiment of the method for measuring the volume of liquid contraband based on X-ray images. Its specific implementation process and technical effects are similar to those in the side embodiment of the method for measuring the volume of liquid contraband based on X-ray images. For details, please refer to the detailed description in the side embodiment of the method for measuring the volume of liquid contraband based on X-ray images, which will not be repeated here.
[0177] Figure 9 This is a schematic diagram of the physical structure of an electronic device provided in an embodiment of the present invention, such as... Figure 9 As shown, the electronic device may include a processor 910, a communications interface 920, a memory 930, and a communication bus 940, wherein the processor 910, the communications interface 920, and the memory 930 communicate with each other via the communication bus 940. The processor 910 can call logical instructions in the memory 930 to execute a method for measuring the volume of liquid contraband based on X-ray images. This method includes: if it is determined that a liquid to be detected exists in the package to be detected based on an X-ray image including the package to be detected, determining the target liquid type of the liquid to be detected based on the X-ray image; if it is determined that the liquid to be detected is a liquid contraband based on the target liquid type, determining the actual height distance represented by each pixel point corresponding to the liquid to be detected in the height direction; and determining the volume of the liquid to be detected based on the actual height distance corresponding to each pixel point, the actual horizontal distance represented by each pixel point in the horizontal direction, and the actual vertical distance represented by each pixel point in the vertical direction.
[0178] Furthermore, the logical instructions in the aforementioned memory 930 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0179] On the other hand, the present invention also provides a computer program product, which includes a computer program that can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer is able to execute the liquid contraband volume measurement method based on X-ray images provided by the methods described above. The method includes: determining the target liquid type of the liquid to be detected based on the X-ray image when it is determined that the package to be detected contains a liquid to be detected based on the X-ray image; determining the actual height distance in the height direction represented by each pixel point corresponding to the liquid to be detected in the X-ray image when it is determined that the liquid to be detected is a liquid contraband based on the target liquid type; and determining the volume of the liquid to be detected based on the actual height distance corresponding to each pixel point, the actual horizontal distance represented by each pixel point in the horizontal direction, and the actual vertical distance represented by each pixel point in the vertical direction.
[0180] In another aspect, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon. When executed by a processor, the computer program performs the above-described method for measuring the volume of liquid contraband based on an X-ray image. The method includes: determining, based on the X-ray image, the target liquid type of the liquid to be detected if it is determined that the package to be detected contains a liquid to be detected; determining, based on the target liquid type, the actual height distance in the height direction represented by each pixel point corresponding to the liquid to be detected in the X-ray image if it is determined that the liquid to be detected is a liquid contraband; and determining the volume of the liquid to be detected based on the actual height distance corresponding to each pixel point, the actual horizontal distance represented by each pixel point in the horizontal direction, and the actual vertical distance represented by each pixel point in the vertical direction.
[0181] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0182] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.
[0183] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for measuring the volume of liquid contraband based on X-ray images, characterized in that, include: If it is determined that a liquid to be detected is present in the package to be detected based on an X-ray image including the package to be detected, the target liquid type of the liquid to be detected is determined based on the X-ray image; If the liquid to be detected is determined to be a liquid contraband based on the target liquid type, the actual height distance in the height direction represented by each pixel point corresponding to the liquid to be detected in the X-ray image is determined; The volume of the liquid to be detected is determined based on the actual height distance corresponding to each pixel, the actual horizontal distance represented by each pixel in the horizontal direction, and the actual vertical distance represented by each pixel in the vertical direction. Determining the actual height distance in the height direction represented by each pixel point corresponding to the liquid to be detected in the X-ray image includes: For each pixel in the X-ray image corresponding to the liquid to be detected, the initial high-energy X-ray intensity of the pixel in the high-energy sub-image corresponding to the liquid to be detected, and the attenuated high-energy X-ray intensity of the pixel are obtained. The initial low-energy X-ray intensity of the pixel in the low-energy sub-image corresponding to the liquid to be detected, and the attenuated low-energy X-ray intensity of the pixel are obtained. Based on the pre-established correspondence between liquid type, X-ray energy value and medium attenuation coefficient, the first medium attenuation coefficient corresponding to the target liquid type under high X-ray energy value and the second medium attenuation coefficient corresponding to the target liquid type under low X-ray energy value are determined. The actual height distance in the height direction represented by the pixel is determined based on formula (1): (1) in, Represents pixels The actual height distance in the vertical direction is represented. Represents the attenuation coefficient of the first medium. This represents the attenuation coefficient of the second medium. Represents the pixels in the low-energy sub-image The initial low-energy X-ray intensity at that location, Represents the pixels in the low-energy sub-image The intensity of low-energy X-rays after attenuation Represents the pixels in the high-energy sub-image The initial high-energy X-ray intensity at that location, Represents the pixels in the high-energy sub-image The intensity of high-energy X-rays after attenuation; The method further includes: Obtain at least one reference X-ray image for the standard part; For each of the aforementioned reference X-ray images, the first pixel length of the standard component in the horizontal direction in the reference X-ray image is obtained; Based on the first pixel length and the first actual length of the standard component in the horizontal direction, the horizontal distance represented by each pixel in the reference X-ray image in the horizontal direction is determined. The average horizontal distance represented by each pixel in all reference X-ray images is determined as the actual horizontal distance.
2. The method for measuring the volume of liquid contraband based on X-ray images according to claim 1, characterized in that, The determination of the volume of the liquid to be detected based on the actual height distance corresponding to each pixel, the actual horizontal distance represented by each pixel in the horizontal direction, and the actual vertical distance represented by each pixel in the vertical direction includes: For each pixel, the volume of the liquid to be detected corresponding to the pixel is determined based on the actual height distance corresponding to the pixel, the actual horizontal distance represented by the pixel in the horizontal direction, and the actual vertical distance represented by the pixel in the vertical direction. The sum of the volumes of the liquid to be detected corresponding to all pixels is determined as the volume of the liquid to be detected.
3. The method for measuring the volume of liquid contraband based on X-ray images according to claim 1, characterized in that, The method further includes: For each of the aforementioned reference X-ray images, the second pixel length of the standard component in the vertical direction in the reference X-ray image is obtained; Based on the second pixel length and the second actual length of the standard in the vertical direction, the vertical distance represented by each pixel in the reference X-ray image in the vertical direction is determined; The average vertical distance represented by each pixel in all reference X-ray images in the vertical direction is determined as the actual vertical distance.
4. The method for measuring the volume of liquid contraband based on X-ray images according to claim 1, characterized in that, Determining the target liquid type of the liquid to be detected based on the X-ray image includes: Based on the initial high-energy X-ray intensity, attenuated high-energy X-ray intensity, initial low-energy X-ray intensity, and attenuated low-energy X-ray intensity of the target pixel, the feature value of the liquid to be detected is determined. The target pixel is any pixel in the X-ray image corresponding to the liquid to be detected. The feature value is a value used to characterize the material properties. Based on the characteristic values of the liquid to be tested, the target liquid type of the liquid to be tested is determined.
5. The method for measuring the volume of liquid contraband based on X-ray images according to claim 4, characterized in that, Determining the target liquid type of the liquid to be detected based on its feature values includes: Based on the characteristic values of the liquid to be tested, the relative atomic numbers of the components of the liquid to be tested are determined; Based on the correspondence between liquid type and relative atomic number range, the liquid type corresponding to the target relative atomic number range to which the relative atomic number belongs is determined as the target liquid type.
6. The method for measuring the volume of liquid contraband based on X-ray images according to claim 4, characterized in that, The determination of the feature values of the liquid to be detected based on the initial high-energy X-ray intensity, attenuated high-energy X-ray intensity, initial low-energy X-ray intensity, and attenuated low-energy X-ray intensity of the target pixel includes: The characteristic value of the liquid to be detected is determined based on formula (2): (2) Wherein, R represents the characteristic value of the liquid to be detected. Represents the pixels in the low-energy sub-image The initial low-energy X-ray intensity at that location, Represents the pixels in the low-energy sub-image The intensity of low-energy X-rays after attenuation Represents the pixels in the high-energy sub-image The initial high-energy X-ray intensity at that location, Represents the pixels in the high-energy sub-image The intensity of high-energy X-rays after attenuation.