Laser targeting and judging method, system and artificial intelligence camera suitable for complex background
By combining grayscale and median filtering with calculation of physical parameters, the problem of insufficient spot positioning and target identification accuracy in laser target shooting technology under complex backgrounds is solved, realizing sub-pixel-level spot positioning and adaptive target identification, thereby improving target identification accuracy and system adaptability.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Filing Date
- 2026-04-21
- Publication Date
- 2026-07-14
AI Technical Summary
Existing laser target shooting technology has difficulty accurately detecting the position of the laser spot and determining the hit ring value in complex backgrounds. Especially in strong light, weak light or complex background environments, image noise and background interference make it difficult to extract the edge and spot features of the target ring, resulting in poor target judgment accuracy and adaptability.
The target image is processed by grayscale and median filtering. The center coordinates and radius of the target ring are calculated by combining the diameter of the actual target, the focal length of the camera and the distance. The spot area is extracted by binary difference image and the center coordinates of the spot are calculated. The hit value is determined by comparing Euclidean distance with the target ring radius.
It achieves sub-pixel-level spot localization and adaptive target identification under complex backgrounds, improving target identification accuracy and system adaptability. It can accurately extract spots and determine hit ring values under strong light, weak light and complex backgrounds.
Smart Images

Figure CN122391359A_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of image processing and machine vision technology, and in particular relates to a laser target shooting and identification method, system and artificial intelligence camera suitable for complex backgrounds. Background Technology
[0002] In laser-simulated target shooting systems, the key to automatic target identification lies in accurately detecting the position of the laser spot and determining the hit ring value from the acquired target surface image. Existing pulse spot detection and localization technologies mainly fall into two categories: one is detection schemes based on traditional image processing algorithms, such as grayscale threshold segmentation, median filtering, and centroid localization; the other is detection schemes based on general artificial intelligence image recognition models. These existing technologies have some shortcomings in practical applications. For example, in strong light, weak light, or complex background environments, the images captured by the camera are prone to noise and insufficient contrast, making it difficult to accurately extract the target ring edge and spot features, directly affecting the accuracy of the judgment. Furthermore, the acquisition of target ring geometric parameters relies on manual calibration or fixed templates, which cannot adapt to changes in camera position or target surface angle. Once deployment conditions change (such as adjusting the distance or angle between the camera and the target surface), it is necessary to recalibrate the target ring center and the radius of each ring, which is cumbersome and lacks adaptability. In addition, traditional methods for spot extraction often use fixed threshold segmentation or simple background subtraction, which are not sensitive to spot energy distribution and have limited positioning accuracy; ring value determination is usually separated from the target ring geometric parameters and lacks accurate calculation based on actual physical distance, resulting in large target judgment error. Summary of the Invention
[0003] The purpose of this application is to provide a laser target identification method, system, and artificial intelligence camera suitable for complex backgrounds, aiming to at least solve the problems described in the background art.
[0004] In a first aspect, this application provides a laser target identification method, the method comprising: acquiring a first target surface image without pulsed light spots and a second target surface image containing pulsed light spots; preprocessing the first target surface image to obtain a background grayscale image; preprocessing the second target surface image to obtain a target grayscale image; the preprocessing includes grayscale processing and median filtering processing; extracting the target ring center coordinates and the radii of multiple target rings from the background grayscale image based on the diameter of the actual target, the focal length of the camera, and the distance from the camera to the actual target surface; comparing the target grayscale image and the background grayscale image pixel by pixel; if the current pixel value is equal, setting the pixel value at the corresponding position in the result image to a first value; if the current pixel value is not equal, setting the pixel value at the corresponding position in the result image to a second value, obtaining a binary difference image; the first value and the second value are not equal; extracting the spot region in the binary difference image, calculating the center coordinates of the spot region based on the grayscale values of each pixel in the spot region, and using them as the center coordinates of the spot; determining the hit ring value based on the target ring center coordinates, the radii of each target ring, and the spot center coordinates.
[0005] In a further technical solution, the steps of extracting the target ring center coordinates and the radii of multiple target rings from the background grayscale image based on the diameter of the physical target, the focal length of the camera, and the distance from the camera to the physical target surface include: locating the small white circle region at the center of the 10 rings of the target surface in the background grayscale image; obtaining the row and column coordinates of all pixels within the small white circle region, calculating the average value of the row coordinates and the average value of the column coordinates respectively, using the average value of the row coordinates as the row coordinate of the target ring center, and using the average value of the column coordinates as the column coordinate of the target ring center; calculating the target surface image width based on the diameter of the physical target, the focal length of the camera, and the distance from the camera to the physical target surface; dividing the target surface image width by the total number of target rings to obtain the target ring spacing; and determining the radius of each target ring based on the target ring spacing.
[0006] In a further technical solution, the step of calculating the center coordinates of the spot region based on the gray values of each pixel in the spot region includes: calculating the product of the column index of each pixel in the spot region and the gray value of that pixel, summing the products of all pixels, and then dividing by the sum of the gray values of all pixels in the spot region to obtain the center column coordinates of the spot region; calculating the product of the row index of each pixel in the spot region and the gray value of that pixel, summing the products of all pixels, and then dividing by the sum of the gray values of all pixels in the spot region to obtain the center row coordinates of the spot region.
[0007] In a further technical solution, the step of determining the hit ring value based on the target ring center coordinates, the radius of each target ring, and the spot center coordinates includes: calculating the Euclidean distance from the spot center to the target ring center based on the target ring center coordinates and the spot center coordinates; comparing the Euclidean distance with the radius of each target ring; and determining the hit ring value based on the comparison result.
[0008] In a further technical solution, the step of comparing the Euclidean distance with the radius of each target ring and determining the hit ring value based on the comparison result includes: if the Euclidean distance is greater than or equal to 0 and less than the target ring spacing, the hit ring value is determined to be 10 rings; if the Euclidean distance is greater than or equal to the target ring spacing and less than twice the target ring spacing, the hit ring value is determined to be 9 rings; if the Euclidean distance is greater than or equal to twice the target ring spacing and less than three times the target ring spacing, the hit ring value is determined to be 8 rings; if the Euclidean distance is greater than or equal to three times the target ring spacing and less than four times the target ring spacing, the hit ring value is determined to be 7 rings; if the Euclidean distance is greater than or equal to four times the target ring spacing and less than five times the target ring spacing, the hit ring value is determined to be 6 rings.
[0009] In a further technical solution, the step of extracting the spot region in the binary difference image includes: extracting candidate spot regions from the binary difference image; calculating the circularity and area of the candidate spot regions; and selecting candidate spot regions with a circularity greater than a preset circularity threshold and an area within a preset area range as spot regions.
[0010] In a further technical solution, the median filtering process includes: obtaining the grayscale value of the pixel to be filtered; comparing the grayscale value with a preset adaptive switching threshold; if the grayscale value is greater than the adaptive switching threshold, then performing median filtering using a first filtering window size; if the grayscale value is less than or equal to the adaptive switching threshold, then performing median filtering using a second filtering window size.
[0011] Secondly, this application provides an artificial intelligence camera, including a printed circuit board, an image acquisition module, an artificial intelligence processing module, a communication module, and a power supply module all integrated on the printed circuit board; the image acquisition module is used to acquire target images; the image acquisition module includes a visible light CMOS sensor mounted at the center of the printed circuit board and an 825 nm narrowband filter mounted at the front of the lens; the artificial intelligence processing module includes a processor and a memory, the memory storing a computer program, and the processor executing the computer program to implement the method as described in any of the technical solutions of the first aspect; the communication module is used to send the hit ring value output by the artificial intelligence processing module to an external device via wired or wireless communication; the external device includes a shooter display terminal and a back-end main control device; the power supply module is used to supply power to the modules integrated on the printed circuit board.
[0012] In a further technical solution, the printed circuit board also integrates auxiliary function modules; the auxiliary function modules include: an attitude correction module, used to collect the camera's installation attitude data and correct the camera's installation attitude based on the installation attitude data; and / or an image calibration module, used to perform lens focal length calibration operations through a resolution test card.
[0013] In a further technical solution, the printed circuit board also integrates an LED lighting module; the LED lighting module is used to adjust the lighting brightness according to the ambient light intensity.
[0014] In a further technical solution, the artificial intelligence processing module also includes: The image signal processor is used to perform noise reduction and white balance adjustment on the target surface image acquired by the image acquisition module.
[0015] Thirdly, this application provides a laser target shooting and judgment system, comprising: a laser simulation gun for emitting near-infrared pulsed laser in the 825 nm band to form a light spot on the surface of a physical target; the laser simulation gun being positioned at a preset distance in front of the target; an artificial intelligence camera as described in any of the technical solutions of the second aspect; the artificial intelligence camera being located in a direction deviating from the straight line connecting the target surface and the laser simulation gun; a shooter display terminal for receiving and displaying the hit ring value sent by the artificial intelligence camera; and a back-end main control device for receiving and managing target shooting results based on the hit ring value sent by the artificial intelligence camera.
[0016] The technical solution provided in this application can achieve sub-pixel-level spot positioning and adaptive target identification under complex backgrounds, thereby improving target identification accuracy and adaptability.
[0017] First, the target surface images, namely the first target surface image without pulsed light spots and the second target surface image with pulsed light spots, are processed into grayscale to convert the color images into single-channel grayscale data, reducing the computational complexity of subsequent processing. Then, median filtering is used to effectively remove pulse noise (such as sudden changes in ambient light or salt-and-pepper noise generated by the sensor) while protecting the target ring edge and light spot contour, providing high-quality image data for subsequent feature extraction.
[0018] Secondly, based on the actual target diameter, camera focal length, and measured distance from the camera to the target surface, the center coordinates of the target rings and the radius of each ring are calculated from the background grayscale image. This method does not require manual calibration and can adapt to changes in camera position and target angle, avoiding recalibration operations caused by changes in deployment conditions.
[0019] Furthermore, by comparing the target grayscale image with the background grayscale image pixel by pixel to obtain a binary difference image, dynamic light spots and static backgrounds can be effectively separated, eliminating interference from complex backgrounds (such as target textures, shadows, and ambient stray light). After extracting the light spot region from the binary difference image, the center coordinates of the light spot are calculated based on the grayscale value of each pixel (i.e., the energy distribution of the light spot). Compared with the geometric center method that relies solely on the binary shape, this method can achieve sub-pixel-level positioning accuracy and has stronger robustness to cases with uneven light spot energy distribution.
[0020] Finally, based on the coordinates of the target ring center, the radius of each target ring, and the coordinates of the light spot center, the Euclidean distance from the center of the light spot to the center of the target ring is calculated and compared with the radius of each ring, thus accurately determining the hit value. Attached Figure Description
[0021] Figure 1 This is a flowchart of a laser target identification method provided in an embodiment of this application; Figure 2-a This is an example image of a background grayscale image provided in an embodiment of this application; Figure 2-b This is an example image of a target grayscale image provided in an embodiment of this application; Figure 3 This is a flowchart of determining the radius of each target ring according to an embodiment of this application; Figure 4 This is a schematic diagram of a two-dimensional rectangular coordinate system established with the center of the target surface as the central coordinate, provided in an embodiment of this application; Figure 5-a This is an example image of a grayscale image without improved median filtering, provided in an embodiment of this application. Figure 5-b This is an example image of a grayscale image that has undergone improved median filtering processing, provided in an embodiment of this application; Figure 6 This is a schematic diagram showing the positional relationship between a camera and a laser gun according to an embodiment of this application. Detailed Implementation
[0022] To illustrate the technical solution of this application, specific embodiments are described below.
[0023] Firstly, this application provides a laser target identification method that can achieve sub-pixel-level spot positioning and adaptive target identification under complex backgrounds, thereby improving the accuracy and adaptability of target identification.
[0024] In some embodiments, the method includes steps that can be found in [reference needed]. Figure 1 The following are detailed instructions for each step.
[0025] S101. Obtain a first target surface image that does not contain a pulsed light spot and a second target surface image that contains a pulsed light spot.
[0026] The first target image refers to the target image without the pulsed laser spot, which can be called the background image (i.e., the target surface without laser firing). The second target image refers to the target image containing the pulsed laser spot, which can be called the target image (i.e., the target surface after laser firing). The pulsed laser spot refers to the spot formed on the target surface by an 825nm (nanometer) band near-infrared pulsed laser.
[0027] Specifically, this step involves using a camera (such as an AI camera) to capture target surface images under conditions of no laser firing and under conditions of laser firing, which will then be used as input for subsequent processing.
[0028] S102. Preprocess the first target image to obtain a background grayscale image; preprocess the second target image to obtain a target grayscale image.
[0029] Preprocessing includes grayscale conversion and median filtering. Grayscale conversion involves converting a color image to grayscale to reduce data volume while preserving brightness information. Median filtering is a non-linear filtering method that replaces a pixel value with the median of its grayscale values in its neighborhood, used to eliminate impulse noise (salt-and-pepper noise) and preserve edges.
[0030] Specifically, this step involves sequentially performing grayscale conversion and median filtering noise reduction on the first and second target surface images to obtain a background grayscale image (e.g., Figure 2-a (as shown) and target grayscale image (e.g.) Figure 2-b (As shown).
[0031] S103. Based on the diameter of the physical target, the focal length of the camera, and the distance from the camera to the physical target surface, extract the center coordinates of the target rings and the radii of multiple target rings from the background grayscale image.
[0032] The diameter of the physical target refers to the actual diameter of the target surface. The camera focal length refers to the focal length parameter of the camera lens. The distance from the camera to the physical target surface refers to the actual measured physical distance between the camera and the physical target surface. All of these data are acquired or measured in advance.
[0033] The target ring center coordinates refer to the pixel coordinates of the target's center in the image. The target ring radius refers to the pixel radius of each target ring (e.g., rings 6 to 10).
[0034] This step specifically uses the diameter of the physical target, the focal length of the camera, and the distance from the camera to the physical target surface to calculate the actual width of the target surface image through geometric proportions; then, based on the total number of target rings (e.g., 5 rings), the ring spacing is determined, and thus the radius of each ring is obtained; at the same time, the center of the target ring is located from the background grayscale image (for example, by identifying the small white circular area at the center of 10 rings and calculating the average pixel coordinates).
[0035] S104. Compare the target grayscale image with the background grayscale image pixel by pixel. If the current pixel value is equal, set the pixel value at the corresponding position in the result image to the first value. If the current pixel value is not equal, set the pixel value at the corresponding position in the result image to the second value to obtain a binary difference image. If the first value and the second value are not equal, extract the spot region from the binary difference image and calculate the center coordinates of the spot region based on the grayscale value of each pixel in the spot region, which are used as the center coordinates of the spot.
[0036] The first and second values are two different pixel values (e.g., 255 and 0) used for binarization, representing the unchanged region and the changed region (i.e., the spot region), respectively. A binary difference image is an image that retains only the spot region (foreground) while filtering out the background. The spot region is a connected region in the binary difference image where the pixel value equals the second value.
[0037] Specifically, this step involves comparing the target grayscale image with the background grayscale image pixel by pixel. Positions with equal pixel values are assigned a first value (representing the background), and positions with unequal values are assigned a second value (representing the spot), thus obtaining a binary difference image. Next, the spot region is extracted from the binary difference image, and the grayscale values of each pixel within the spot region are used for weighted calculation to obtain the sub-pixel coordinates of the spot center.
[0038] S105. Determine the hit ring value based on the target ring center coordinates, the radius of each target ring, and the spot center coordinates.
[0039] The hit ring value refers to the number of rings (such as 10 rings, 9 rings, etc.) corresponding to the distance between the spot landing point and the center of the target ring.
[0040] Specifically, this step can calculate the Euclidean distance based on the coordinates of the target ring center and the light spot center, compare this distance with the radius of each target ring (such as r, 2r, 3r, 4r, 5r), determine the corresponding ring value, and output it.
[0041] This technical solution removes impulse noise through median filtering, eliminates static background interference through background subtraction, and achieves sub-pixel-level positioning through the gray-scale centroid method. It can accurately extract light spots even in complex backgrounds such as strong light, weak light, and target surface texture. Furthermore, it automatically calculates the target ring geometry based on the physical target parameters, eliminating the need for manual calibration. It can accurately extract the target ring center and radius even when the camera position or target angle changes, demonstrating strong adaptability. By using pixel gray-scale value weighting to calculate the light spot center, sub-pixel accuracy (e.g., 0.1 pixels) can be achieved. Combined with physical scale conversion, the physical positioning accuracy is high, meeting the 0.1 ring target judgment requirement. In addition, this technical solution integrates image acquisition, background modeling, light spot extraction, and ring value calculation based on geometric relationships, avoiding the error accumulation caused by the separation of light spot positioning and ring value judgment in traditional methods.
[0042] In some technical solutions, the steps of extracting the center coordinates of the target rings and the radii of multiple target rings from the background grayscale image are based on the diameter of the physical target, the focal length of the camera, and the distance from the camera to the physical target surface. Figure 3 As shown, it includes: S201. Locate the small white circle area in the center of the 10-ring area of the target surface in the background grayscale image.
[0043] The small white circle in the center of the 10-ring refers to a small white circle pre-painted at the center of the 10-ring on the target surface. Its color contrasts sharply with the surrounding target rings (usually dark or black) and is used to help locate the center of the target ring.
[0044] In a grayscale image, all white pixel regions can be extracted using grayscale thresholding (e.g., classifying pixels with grayscale values greater than 200 as white). Since there is only one small white circle at the center of the 10-ring in the target surface, the remaining white regions (if any) can be excluded by filtering based on area or roundness. Finally, the set of coordinates of all pixels covered by this small white circle is obtained.
[0045] S202. Obtain the row and column coordinates of all pixels within the small white circle area, calculate the average value of the row coordinates and the average value of the column coordinates respectively, and use the average value of the row coordinates as the row coordinates of the target ring center and the average value of the column coordinates as the column coordinates of the target ring center.
[0046] The row and column coordinates of a pixel refer to the vertical position (row, i.e., y coordinate) and horizontal position (column, i.e., x coordinate) of a pixel in the image coordinate system.
[0047] This step utilizes the symmetry of the small white circle to calculate the center position with sub-pixel precision. Specifically, it iterates through every pixel within the small white circle, accumulating the row and column coordinates of all pixels to obtain the sum of the row and column coordinates respectively. Dividing the sum of the row coordinates by the total number of pixels yields the average row coordinate, which is used as the row coordinate of the target ring center, denoted as y0; the sum of the column coordinates is divided by the total number of pixels to obtain the average column coordinate, which is used as the column coordinate of the target ring center, denoted as x0.
[0048] S203. Calculate the target image width based on the actual target diameter, camera focal length, and the distance from the camera to the actual target surface. As mentioned above, the actual target diameter refers to the diameter of the physical target surface (in millimeters or meters); the camera focal length refers to the focal length of the camera lens (in millimeters); the distance from the camera to the actual target surface refers to the perpendicular distance from the optical center of the camera lens to the target surface plane (in millimeters or meters), which can be obtained through measurement or calibration. The target image width refers to the pixel width of the area occupied by the target surface in the target image captured by the camera (i.e., the number of pixels corresponding to the target diameter).
[0049] After determining the coordinates of the target ring center in the target image, a two-dimensional Cartesian coordinate system is established with these coordinates as the center, such as... Figure 4 As shown, the x-axis represents the horizontal coordinate, the y-axis represents the vertical coordinate, the center of the target ring is the origin o, point A is a boundary point of the 10-ring, and point B is the laser spot. By calculating the distance from the center of the laser spot to the center of the target ring, and comparing it with the radius of each target ring in the target image captured by the camera, the shooting score can be determined.
[0050] Since the actual target surface is a set of concentric circles with equal spacing, and the target surface image captured by the camera is a scaled-down image of the actual object, it is also a set of concentric circles with equal spacing (the spacing between the target rings in the target surface image can be denoted as r). Therefore, as long as the diameter of the target surface image captured by the camera (i.e., the width of the target surface image) is determined, the spacing between the target rings can be determined, and consequently, the radius of each target ring can also be determined. The width of the target surface image can be calculated using the following formula: Target image width = (actual target diameter / distance from camera to target) × camera focal length.
[0051] S204. Divide the target image width by the total number of target rings to obtain the target ring spacing.
[0052] The total number of target rings refers to the number of valid scoring rings on the target surface. In this technical solution, the total number of target rings is 5, corresponding to 6, 7, 8, 9, and 10 rings. The target ring spacing refers to the pixel distance between two adjacent target rings, denoted as r.
[0053] Since the total number of target rings is 5 (from 6 to 10 rings), the spacing between adjacent target rings is equal in the pixel domain. The target image width corresponds to 10 times the target ring spacing, that is, from the outer edge of the 6th ring to the outer edge of the opposite 6th ring passing through the center, the actual width is equal to 2 × 5r = 10r. Therefore, the target ring spacing r = target image width / 10r.
[0054] S205. Determine the radius of each target ring based on the target ring spacing.
[0055] Since the target surface consists of equally spaced concentric circles, the radius of each ring is r or an integer multiple of r. The radius of each target ring refers to the pixel distance from the center of the target ring to the boundary of that ring. For example, the radius of ring 10 is r, the radius of ring 9 is 2r, the radius of ring 8 is 3r, the radius of ring 7 is 4r, and the radius of ring 6 is 5r.
[0056] This technical solution automatically calculates the pixel radius of each target ring in the target image by combining the diameter of the physical target, the camera focal length, and the distance from the camera to the physical target surface, eliminating the need for manual ring-by-ring labeling or reliance on fixed templates. When the camera position or target angle changes, the parameters are automatically updated simply by remeasuring the distance from the camera to the physical target surface, greatly improving the system's deployment flexibility and adaptability. Utilizing the high contrast between the small white circle at the center of the 10 rings and the background, the center of the circle is calculated by averaging the pixel coordinates, eliminating the need for complex edge detection or circle fitting algorithms. This results in minimal computation and sub-pixel accuracy. Furthermore, this method is insensitive to the shape of the small white circle (even if the circle is not perfectly regular, its centroid still approximates the center), exhibiting strong noise resistance. In addition, the entire process of this technical solution involves only arithmetic averaging and multiplication / division operations, without iterative optimization or matrix inversion, making it highly suitable for real-time operation (frame rate ≥ 20fps) on low-power embedded AI chips. Simultaneously, the use of geometric proportion calculation based on physical parameters avoids nonlinear errors caused by image distortion or perspective projection, ensuring the accuracy of the radius calculation.
[0057] In some technical solutions, the step of calculating the center coordinates of the spot region based on the gray values of each pixel in the spot region includes: calculating the product of the column index of each pixel in the spot region and the gray value of that pixel, summing the products of all pixels, and then dividing by the sum of the gray values of all pixels in the spot region to obtain the center column coordinates of the spot region; calculating the product of the row index of each pixel in the spot region and the gray value of that pixel, summing the products of all pixels, and then dividing by the sum of the gray values of all pixels in the spot region to obtain the center row coordinates of the spot region.
[0058] The spot region refers to the connected region in the binary difference image where the pixel value equals the second value (such as 0 or 255), corresponding to the set of pixels occupied by the laser spot. This region has been filtered out of background noise and contains only the spot and a small number of surrounding interfering pixels. The column index refers to the horizontal position of the pixel in the image coordinate system, and the row index refers to the vertical position of the pixel. The grayscale value refers to the brightness value of each pixel within the spot region in the target grayscale image, ranging from 0 to 255 (i.e., 8-bit grayscale). This grayscale value represents the energy intensity of the laser spot at that pixel location. The center column coordinate refers to the horizontal energy centroid position of the spot region. The center row coordinate refers to the vertical energy centroid position of the spot region.
[0059] CMOS is an array image sensor device with pixels as its unit. In the captured light spot image, each pixel is not just a geometric point, but also has energy. The greater the amplitude of this energy signal, the greater the weight of the distance of that point from the starting point. The centroid is a weighted average of pixel values, which is used to calculate the centroid of light intensity. The calculation of the column and row coordinates of the center of the light spot region is explained below.
[0060] Regarding column coordinates, first, iterate through each pixel within the spot area, obtaining its column index (denoted as j) and its grayscale value in the target grayscale image. Then, multiply each pixel's column index by its grayscale value to obtain a product. Next, sum these products for all pixels within the spot area to obtain a first sum of products. Simultaneously, sum the grayscale values of all pixels within the area to obtain a total sum of grayscale values. Finally, divide the first sum of products by the total sum of grayscale values to obtain the center column coordinates of the spot area.
[0061] Similar to the calculation of the center column coordinates, the calculation of the center row coordinates involves first traversing each pixel within the spot area, obtaining its row index and grayscale value in the target grayscale image. Then, each pixel's row index is multiplied by its grayscale value to obtain a product. Next, these products of all pixels within the spot area are summed to obtain a second product sum. Finally, the second product sum is divided by the sum of the grayscale values to obtain the center row coordinates of the spot area.
[0062] Traditional geometric center methods calculate the average pixel coordinates of the binarized laser spot area (equivalent to equal weight for all pixels), limiting positioning accuracy to pixel resolution with a maximum error of 0.5 pixels. This technical solution employs a grayscale weighted centering method, using the grayscale value of each pixel within the laser spot area (i.e., laser energy distribution) as a weight. This allows the center coordinates to accurately reflect the energy center of the laser spot, achieving a measured accuracy of 0.1 pixels, meeting the requirements for high-ring target judgment (e.g., 0.1-ring resolution). Furthermore, when the laser spot is irregular in shape or asymmetrical in energy distribution due to target material, incident angle, or atmospheric scattering, the geometric center method tends to deviate from the "bullet center" position perceived by the human eye (usually based on the area of strongest energy). The grayscale weighted centering method, through grayscale weighting, naturally pulls the center towards the area of concentrated energy, better aligning with the "point of impact" judgment criteria in actual shooting training, effectively avoiding positioning deviations caused by laser spot deformation. The algorithm in this technical solution only involves multiplication, addition, and division operations, without the need for iteration or complex mathematical functions. For a single-core A7 800MHz embedded AI chip, it can complete the calculation of a single spot area in microseconds, supporting real-time processing of over 20fps. Compared with sub-pixel methods such as circle fitting and ellipse fitting, this technical solution reduces computational overhead while ensuring high accuracy.
[0063] In some technical solutions, the steps of determining the hit ring value according to the center coordinates of the target rings, the radii of each target ring, and the center coordinates of the light spot include: calculating the Euclidean distance from the center of the light spot to the center of the target ring according to the center coordinates of the target ring and the center coordinates of the light spot; comparing the Euclidean distance with the radii of each target ring, and determining the hit ring value based on the comparison result.
[0064] This step first calculates the Euclidean distance from the center of the light spot to the center of the target ring, and the operations include: Read the center coordinates of the target ring from the memory, denoted as (x0, y0), and the center coordinates of the light spot, denoted as (x spot , y spot ). Calculate the column coordinate difference (Δx = x spot −x0) and the row coordinate difference (Δy = y spot −y0) respectively. Square the column coordinate difference Δx and the row coordinate difference Δy and then add them together, and then take the square root of the sum value to obtain the Euclidean distance, denoted as R.
[0065] Next, compare the Euclidean distance with the radii of each target ring, and determine the hit ring value based on the comparison result. The specific operations include: if the Euclidean distance is greater than or equal to 0 and less than the target ring spacing, it is determined that the hit ring value is 10 rings; if the Euclidean distance is greater than or equal to the target ring spacing and less than twice the target ring spacing, it is determined that the hit ring value is 9 rings; if the Euclidean distance is greater than or equal to twice the target ring spacing and less than three times the target ring spacing, it is determined that the hit ring value is 8 rings; if the Euclidean distance is greater than or equal to three times the target ring spacing and less than four times the target ring spacing, it is determined that the hit ring value is 7 rings; if the Euclidean distance is greater than or equal to four times the target ring spacing and less than five times the target ring spacing, it is determined that the hit ring value is 6 rings.
[0066] For example, obtain the target ring spacing r. In ascending order, compare the Euclidean distance R with the boundary values of the radii of each target ring in turn: If 0 ≤ R < r0 ≤ R < r, the light spot falls within the 10-ring area, and it is determined that the hit is 10 rings; If r ≤ R < 2r r ≤ R < 2r, it is determined that the hit is 9 rings; If 2r ≤ R < 3r 2r ≤ R < 3r, it is determined that the hit is 8 rings; If 3r ≤ R < 4r 3r ≤ R < 4r, it is determined that the hit is 7 rings; If 4r ≤ R < 5r 4r ≤ R < 5r, it is determined that the hit is 6 rings.
[0067] If R ≥ 5r R ≥ 5r, the light spot falls outside the 6-ring (indicating a miss), and an invalid score or 0 rings can be output. The comparison operation only involves judging the numerical size, and the calculation amount is extremely small.
[0068] Finally, the hit ring value (such as 10 rings, 9 rings, etc.) obtained from the determination can be output in the form of numbers or characters for subsequent transmission to the shooter display terminal or the back-end main control device.
[0069] This technical solution directly compares the center coordinates of the light spot with the target ring radius calculated from the actual object parameters, rather than relying on visual inspection or pixel-level judgment based on the target ring lines drawn in the image. Since each ring radius is obtained based on the proportional conversion of the actual target diameter, focal length, and object distance, its accuracy is directly related to the camera's calibration parameters, avoiding misjudgments of ring values caused by image perspective distortion or target tilt, and achieving ring value correspondence in real physical space. Furthermore, traditional positioning methods based on integer pixel coordinates can have an error of up to 0.5 pixels, easily leading to misjudgments of 10 rings versus 9 rings. This technical solution uses sub-pixel precision light spot center coordinates to calculate Euclidean distance, achieving a distance resolution of 0.1 pixels, reliably distinguishing light spots falling on the inner and outer rings of the 10 rings, meeting the 0.1 ring accuracy requirement in air rifle and air pistol training. In addition, the entire judgment process requires only one square root operation (or comparing square values to avoid square root) and a number of value comparisons, without involving complex branch predictions or iterative loops. On an embedded AI chip (single-core A7, 800MHz), the process can be completed in microseconds, fully supporting real-time target assessment output of over 20fps without affecting the continuity and smoothness of shooting training.
[0070] In some technical solutions, the step of extracting spot regions in a binary difference image includes: extracting candidate spot regions from the binary difference image; calculating the circularity and area of the candidate spot regions; and selecting candidate spot regions with a circularity greater than a preset circularity threshold and an area within a preset area range as spot regions.
[0071] Candidate laser spot regions refer to all connected regions (i.e., connected components with pixel values as the second value) extracted from a binary difference image. Each connected region may be a real laser spot, or it may be residual noise points or interference (such as reflections, dust, etc.). Circularity is a quantitative indicator describing how closely a region's shape approximates a circle. A circle has a circularity of 1, and the more irregular the shape, the closer the circularity is to 0.
[0072] Area refers to the number of pixels contained in the candidate spot region. For laser spots, the area is usually within a certain range (e.g., 5-50 pixels). Areas that are too large or too small are generally not real spots. The preset circularity threshold is a pre-set minimum value for circularity, used to filter out areas with shapes close to circles. Only areas with a circularity greater than this threshold can be considered as spots. For example, this threshold is set to 0.8.
[0073] A preset area range refers to a pre-defined allowable area range; only areas within this range can be considered as light spots. For example, the area range is 5 pixels to 50 pixels.
[0074] The spot area refers to the candidate area that is retained after dual screening of circularity and area, which is the area that is finally identified as a valid laser spot.
[0075] In this technical solution, connected component analysis is first performed on the binary difference image. The operation includes: traversing each pixel in the image, using 4-connectivity or 8-connectivity rules, grouping adjacent pixels with the second value (representing the foreground) into the same connected region. A unique label is assigned to each connected region, and the coordinates of all pixels contained within that region are recorded. This yields several candidate spot regions, which may contain genuine laser spots or tiny connected regions generated by noise or interference.
[0076] Next, the circularity and area of each candidate spot region are calculated. The operation includes: For each candidate spot region, perform the following sub-operations in sequence: (1) Calculate the area: count the total number of pixels in the area, denoted as A; (2) Calculate the perimeter: count the number of pixels on the boundary contour of the region. An eight-neighbor boundary tracking algorithm can be used to take the number of pixels on the edge of the region as the perimeter P.
[0077] (3) Calculate the roundness using the following formula: Circularity = 4π × A / P 2 .
[0078] Then, the effective light spot area is selected, and the operation includes: A preset circularity threshold (e.g., 0.8) and a preset area range (e.g., 5 pixels to 50 pixels) are used as filtering criteria. For each candidate spot region, the following judgment is performed: If its circularity is greater than 0.8 and its area is greater than or equal to 5 and its area is less than or equal to 50, then the area is determined to be a valid spot area and is retained. If any of the above conditions are not met (circularity ≤ 0.8, or area < 5, or area > 50), the area is determined to be noise or interference and is discarded.
[0079] The one or more effective spot areas that are ultimately retained are the "spot areas" output by this technical solution. If multiple effective spot areas exist (e.g., multiple laser spots appear simultaneously), the main spot can be selected based on energy or position, or they can be processed separately.
[0080] In complex backgrounds (such as strong light, shadows, and target surface contamination), binary difference images often retain noise regions that are not light spots (e.g., reflective points, small insects, dust, etc.). This technical solution effectively filters out these interferences by introducing dual screening based on circularity and area, avoiding misclassification of non-light spot areas as laser spots and thus reducing the false alarm rate. Furthermore, without screening, binary difference images may contain numerous small, noisy connected components. Performing grayscale centroid calculations on each candidate region would waste the computational resources of the embedded chip. This technical solution can preemptively eliminate regions that do not conform to the morphological characteristics of the light spot, significantly reducing the number of regions participating in the centroid calculation (typically leaving only 1 to 2 true light spots), thereby improving the overall real-time performance of the algorithm and enabling the maintenance of a processing frame rate of over 20fps on a single-core A7, 800MHz embedded chip. Furthermore, due to fluctuations in laser pulse energy or changes in target distance, the pixel area of the laser spot may vary within a certain range (e.g., 5–50 pixels). This technical solution, by setting a reasonable area range, can accommodate various spot sizes under normal shooting conditions, while eliminating interference from spots that are too large (potentially reflective areas) or too small (potentially isolated noise points). The circularity threshold of 0.8 balances the fact that the laser spot is approximately circular with slight elliptical deformation caused by angle tilt, ensuring the effectiveness of the screening while avoiding missed detections due to over-screening.
[0081] In some technical solutions, median filtering includes: obtaining the grayscale value of the pixel to be filtered; comparing the grayscale value with a preset adaptive switching threshold; if the grayscale value is greater than the adaptive switching threshold, then performing median filtering using a first filtering window size; if the grayscale value is less than or equal to the adaptive switching threshold, then performing median filtering using a second filtering window size.
[0082] The pixel to be filtered refers to the pixel position currently undergoing median filtering. When traversing the grayscale image, each pixel is sequentially treated as a pixel to be filtered. The preset adaptive switching threshold is a pre-defined grayscale value boundary used to determine whether the current pixel belongs to a "high-brightness area" or a "low-brightness area." In this technical solution, this threshold is set to a grayscale value of 100. Pixels with a grayscale value greater than 100 typically correspond to areas such as light spots or bright reflections; pixels with a grayscale value less than or equal to 100 correspond to dark areas such as the target background or shadows. The first filtering window size refers to the size of the median filtering window used in high-brightness areas, for example, 5×5 pixels. A larger window can filter out noise more effectively but may blur edges. The second filtering window size refers to the size of the median filtering window used in low-brightness areas, for example, 3×3 pixels. A smaller window can better preserve details and edges but has weaker noise reduction capabilities.
[0083] This technical solution uses an improved median filter to process the grayscale image obtained by grayscale conversion of the target surface image.
[0084] First, for each pixel in the input grayscale image, its original grayscale value g(i,j) is read. The original grayscale value has not undergone any filtering processing and can reflect the original brightness information of the pixel.
[0085] Next, the read grayscale value g(i,j) is compared with the pre-stored adaptive switching threshold T (with a value of 100) to determine whether the pixel belongs to a high-brightness region or a low-brightness region: If g(i,j)>T, it is determined to be a high-brightness region (e.g., a spot or a high-brightness noise region). If g(i,j)≤T, it is determined to be a low-brightness area (e.g., background, shadow, dark texture area).
[0086] Then, based on the comparison results, the filter window size is selected. The operation includes: If g(i,j)>T, median filtering is performed using the first filtering window size (e.g., 5×5 pixels). During operation, a 5×5 neighborhood window (25 pixels in total) is extracted centered on the current pixel. The original grayscale values of all pixels within the window are read, sorted in ascending order, and the median value (the 13th value) is taken as the filtered grayscale value of the current pixel. A large window helps remove bright spot noise or salt-and-pepper noise that may be mixed into the bright spot area. If g(i,j)≤T, median filtering is performed using the second filtering window size (e.g., 3×3 pixels). A 3×3 neighborhood window (9 pixels in total) is extracted, sorted, and the median (the 5th value) is taken as the filtering result. The small window preserves texture details in the background area (such as target ring lines and numerical markers), avoiding excessive smoothing that could blur the target ring edges.
[0087] Finally, repeat the above steps to process each pixel in the image one by one, ultimately generating a new filtered grayscale image (i.e., the background grayscale image or the target grayscale image). If edge pixels cannot form a complete window, boundary padding (such as padding with zeros or mirroring) can be used.
[0088] The filtering effect can be referenced. Figure 5-a and Figure 5-b .
[0089] Traditional fixed-window mid-range filtering (such as using a uniform 3×3 or 5×5 window) presents a contradiction—large windows offer strong denoising but easily blur edges, while small windows preserve edges but offer weak denoising. This technical solution automatically switches the window size based on pixel grayscale values: a large window is used in bright areas such as laser spots (grayscale value > 100) to effectively filter out bright spot noise that may be introduced by the laser pulse; a small window is used in dark areas such as target rings and numbers (grayscale value ≤ 100) to protect the edges of the target ring and character details, avoiding blurring of the target ring boundary and subsequent radius measurement errors. This adaptive strategy improves both denoising and edge preservation capabilities without increasing computational complexity. Furthermore, laser spots are typically bright in images (grayscale value much greater than 100), while target ring lines and the background are low grayscale. This technical solution, by setting a threshold of 100, can clearly distinguish between candidate laser spot areas and non-laser spot areas. Using a large window filter in the spot area suppresses isolated bright spots (salt-and-pepper noise) caused by laser energy fluctuations or target surface reflection, resulting in a smoother spot energy distribution and improving the stability of subsequent gray-scale centroid method calculations of sub-pixel centers. A small window in the background area ensures the clarity of key geometric features such as the small white circle at the center of the target ring and the target ring lines, facilitating accurate extraction of the target ring center and radius. Furthermore, this technical solution only adds one numerical comparison operation (grayscale value vs. threshold comparison), and the standard median filtering algorithm is still used after window selection, requiring no additional iterations or floating-point operations. For a single-core A7, 800MHz embedded AI chip, the total processing time for a 720p image increases by less than 5%, fully meeting the 20fps real-time requirement. Compared to other adaptive filtering algorithms (such as adaptive weighted median, bilateral filtering, etc.), this technical solution is simple to implement and has low memory consumption.
[0090] Secondly, this application provides an artificial intelligence camera, including a printed circuit board, an image acquisition module, an artificial intelligence processing module, a communication module, and a power supply module all integrated on the printed circuit board. This technical solution integrates all modules on the same printed circuit board, resulting in a compact structure and small size, making it easy to install in a target box or on a tripod. The following is a detailed description of each module.
[0091] An image acquisition module is used to acquire images of the target surface. The image acquisition module includes a visible light CMOS sensor mounted at the center of the printed circuit board and an 825 nm narrowband filter mounted at the front of the lens.
[0092] Specifically, the image acquisition module includes a visible light CMOS image sensor and a lens. The visible light CMOS image sensor is mounted at the center of the printed circuit board to ensure optical path uniformity and image geometric symmetry. A narrowband filter with an 825nm wavelength is mounted at the front end of the lens. This narrowband filter has a center wavelength of 825nm and a half-bandwidth of typically 10-20nm, effectively allowing near-infrared laser light near 825nm to pass through while filtering out visible light and other stray light from the environment. When the laser simulation gun emits an 825nm near-infrared pulsed laser and forms a spot on the target surface, the image acquisition module can clearly acquire an image of the target surface containing the spot, while interference from sunlight, artificial light, etc., in the environment is significantly suppressed. The acquired image is an RGB three-channel color digital image with a resolution of no less than 1280×720 pixels.
[0093] The artificial intelligence processing module includes a processor and a memory. The memory stores a computer program, and when the processor executes the computer program, it implements the laser target shooting and judgment method as described in any of the technical solutions of the first aspect.
[0094] Specifically, the artificial intelligence processing module is the core computing unit of the camera, including a processor and a memory coupled to the processor. For example, the processor can be an embedded artificial intelligence chip with a single-core A7 architecture and a main frequency of 800MHz, which has 128MB of DDR memory and 64MB of Flash memory. The memory stores a computer program, which, when executed by the processor, implements the laser target shooting and judgment method as described in any of the technical solutions of the first aspect of this application. Specifically, the artificial intelligence processing module sequentially performs grayscale processing, improved median filtering noise reduction, background subtraction, spot region extraction, grayscale weighted centering subpixel localization, target ring geometric parameter calculation, and ring value determination on the target image output by the image acquisition module, finally outputting the hit ring value. This module is directly connected to the image acquisition module through a parallel data interface, reducing data transmission latency and enabling real-time image processing at a frame rate of no less than 20 frames per second, meeting the needs of dynamic shooting training.
[0095] The communication module is used to send the hit ring value output by the artificial intelligence processing module to external devices via wired or wireless communication methods; the external devices include the shooter display terminal and the back-end main control device.
[0096] Specifically, the communication module supports both wired and wireless communication methods. Wireless communication utilizes the Bluetooth 5.0 protocol and includes an onboard antenna with a reserved SMA antenna interface for connecting an external antenna to enhance signal coverage. Wired communication uses a 10 / 100 / 1000 Mbps adaptive Ethernet port, connecting to an external network via a network cable. External devices include a shooter display terminal and a backend control device. The shooter display terminal can be a wristwatch, tablet, or a display screen mounted on the laser simulator, used to display the current hit score in real time. The backend control device can be a training management server or an instructor terminal, used to record and manage all shooting results. The communication module can automatically select wired or wireless transmission based on the actual deployment environment, or it can use both methods simultaneously.
[0097] A power module is used to supply power to modules integrated on a printed circuit board.
[0098] Specifically, the power module includes a polymer lithium battery, a Type-C charging port, and a charge / discharge management circuit. The polymer lithium battery's capacity is designed based on the overall power consumption of the camera, ensuring a standby time of no less than 10 hours and supporting 4-6 hours of continuous shooting training. The Type-C charging port supports fast charging, fully charging the battery in 2 hours. The charge / discharge management circuit features a soft-start function; users can start the camera by pressing and holding the power button, eliminating the need for a mechanical switch. Furthermore, the charge / discharge management circuit integrates overcharge protection, over-discharge protection, and short-circuit protection. It automatically cuts off the charging / discharging circuit when the battery voltage exceeds 4.2V or falls below 3.0V, effectively extending battery life.
[0099] The AI camera provided in this embodiment highly integrates image acquisition, AI processing, communication, and power functions onto a single printed circuit board. It can independently complete the entire laser target shooting and judgment process without the need for an external computer or image acquisition card. Its small size, light weight, and low power consumption allow for flexible deployment in various indoor and outdoor shooting training grounds, making it highly practical.
[0100] In some technical solutions, auxiliary function modules are also integrated into the printed circuit board; the auxiliary function modules include: an attitude correction module, used to collect the installation attitude data of the camera and correct the installation attitude of the camera according to the installation attitude data; and / or an image calibration module, used to perform lens focal length calibration operation through a resolution test card.
[0101] This technical solution, based on the basic structure of an artificial intelligence camera, further integrates auxiliary function modules on a printed circuit board to improve the camera's environmental adaptability and long-term stability. The auxiliary function modules may include at least one of an attitude correction module and an image calibration module, which are described in detail below.
[0102] The attitude correction module is used to collect the camera's installation attitude data and correct the camera's installation attitude based on the collected attitude data, thereby eliminating the spot positioning deviation caused by camera tilt or twisting. In the actual deployment of laser simulation target shooting systems, cameras are usually installed inside target boxes or on tripods. Due to uneven ground, loose supports, or bumps during transportation, it is difficult to ensure that the camera is perfectly horizontal. If images acquired under tilted conditions are used directly for target judgment, the distance from the center of the spot to the center of the target ring will be distorted by perspective projection, leading to misjudgment of the ring value (for example, a hit of 9 rings may be misjudged as 8 rings).
[0103] The core component of the attitude correction module can be an onboard six-axis inertial measurement unit (IMU), specifically a combination of a microelectromechanical system (MEMS) gyroscope and an accelerometer. This IMU is fixed to a printed circuit board, with its sensitive axis parallel to the optical axis of the image sensor. During camera initialization or each power-on startup, the attitude correction module reads the pitch angle (rotation angle about the horizontal axis), roll angle (rotation angle about the horizontal axis), and yaw angle (rotation angle about the vertical axis) data output by the IMU, with an attitude detection accuracy of no more than 0.5 degrees.
[0104] After acquiring the attitude data, the attitude correction module performs the following correction operations: First, determine whether the angles of each axis exceed the preset correction threshold (for example, correction is initiated when the absolute value of the pitch or roll angle is greater than 1 degree, and correction is initiated when the yaw angle exceeds 2 degrees). If the threshold is not exceeded, the installation attitude is considered to be basically horizontal, no correction is required, and the original image is used directly for subsequent processing to save computing resources; If the threshold is exceeded, a perspective transformation matrix or an affine transformation matrix is calculated based on the angle data. Specifically, for trapezoidal distortion caused by camera tilt, a perspective transformation is used for correction: given the camera's pitch and roll angles, the homography matrix from the original image plane to the horizontal virtual plane can be derived. The attitude correction module applies this matrix to each frame of the target image, reprojecting the image from the tilted viewpoint to the image from the normal viewpoint. For image rotation caused by yaw angle, a rotation transformation (a type of affine transformation) is used for correction: with the image center as the origin, the entire image is rotated by the opposite angle of the yaw angle, restoring the vertical axis of the target ring to the vertical direction.
[0105] In practical implementation, to reduce the computational overhead of each frame, the pose correction module can be calibrated once after the camera is deployed: after the camera is fixed, pose data is read once, a fixed transformation matrix is calculated, and then this matrix is uniformly applied to all subsequent frames. The transformation matrix is only recalculated when the camera moves again or the pose sensor detects a change in pose (e.g., an angle change exceeding 0.5 degrees). This ensures correction accuracy while avoiding the performance degradation caused by performing matrix operations for each frame.
[0106] After attitude correction, the originally tilted target image is corrected to a frontal image, the target ring center remains near the image center, and the pixel distance distribution of each ring radius is more uniform. Subsequent target ring center extraction, spot positioning, and ring value determination are all based on the corrected image, thereby eliminating the systematic error caused by the installation tilt.
[0107] The image calibration module is used to calibrate the lens focal length using a resolution test chart, ensuring that the target image captured by the camera is distortion-free and meets the target judgment requirements in terms of clarity. During long-term use, the lens may experience focus drift due to vibration, temperature changes, or human contact, resulting in blurred images. Simultaneously, the radial and tangential distortion of the lens itself can also affect the accuracy of geometric measurements. The image calibration module provides a convenient on-site calibration method, restoring the camera to its optimal imaging state without requiring it to be sent back to the manufacturer.
[0108] The execution flow of the image calibration module is as follows: First, the user fixes a dedicated resolution test chart (such as an ISO 12233 standard test chart or a checkerboard calibration board) on the target surface, making its plane parallel to the target surface and located in the center of the camera's field of view.
[0109] Next, the user can activate the AI processing module to enter image calibration mode by pressing and holding a physical button on the camera or by sending a specific command through the communication module. In this mode, the camera continuously captures images from the test card.
[0110] Then, the AI processing module analyzes the acquired test card images and calculates the high-frequency components of the images (e.g., extracting edge energy using the Laplacian or Sobel operators). The module drives the voice coil motor or stepper motor inside the lens to gradually move the lens position within a preset focal length range, while simultaneously calculating the image sharpness evaluation value at each position in real time. When the evaluation value reaches its maximum value (i.e., the image is sharpest), the motor stops and that position is recorded as the optimal focal length for the current object distance.
[0111] If the test card is a checkerboard calibration board (a black and white checkerboard array), the artificial intelligence processing module detects the coordinates of all corner points in the image and compares them with the corner coordinates of a theoretically distortion-free checkerboard. It then uses the least squares method to solve for the radial distortion coefficients (k1, k2) and tangential distortion coefficients (p1, p2) of the camera. The obtained distortion parameters are stored in a non-volatile region of memory. In the subsequent normal target identification process, each frame of image first undergoes distortion correction (remapping pixel positions based on the distortion parameters) and then proceeds to grayscale conversion, median filtering, and other processing steps.
[0112] Finally, after calibration, the AI processing module re-acquires the test card image and calculates the sharpness evaluation value and geometric error. If the preset thresholds are met (e.g., edge sharpness improved by more than 30%, and the reprojection error of the checkerboard corner points is less than 0.2 pixels), the calibration is successful; otherwise, the above steps are repeated or the user is prompted to check whether the test card is placed correctly.
[0113] Preferably, the AI camera integrates both a pose correction module and an image calibration module. These two modules can work together; for example, image calibration is performed first to ensure accurate lens focal length and distortion-free images; then pose correction is performed to adjust the camera's mounting posture to be horizontal. The calibration and correction parameters (distortion coefficients, perspective transformation matrix) are stored in memory and automatically loaded and applied to each frame during the normal target identification process. This combined approach minimizes system errors introduced by hardware installation and the optical system, ensuring that the spot positioning accuracy (0.1 pixel) and target identification accuracy (false positive rate less than 0.5%) of this application remain reliably guaranteed even in complex real-world environments.
[0114] In some technical solutions, the printed circuit board also integrates an LED lighting module; the LED lighting module is used to adjust the lighting brightness according to the ambient light intensity.
[0115] The LED lighting module can include multiple LED lights. These LED lights are evenly distributed around the perimeter of a printed circuit board, and their brightness can be automatically adjusted by an artificial intelligence processing module based on the detection results of an ambient light sensor. When the ambient light is low, the module automatically increases the LED brightness to ensure a clear target image; when the ambient light is sufficient, it reduces or turns off the LEDs to save power. This lighting module enables the camera to operate stably in low-light indoor or nighttime training scenarios.
[0116] In some technical solutions, the artificial intelligence processing module also includes an image signal processor, which is used to perform noise reduction processing and white balance adjustment on the target surface image acquired by the image acquisition module.
[0117] The image signal processor is directly connected to the image acquisition module and is used to perform hardware-level noise reduction and white balance adjustment on the target image output by the image acquisition module before the raw image enters the core target discrimination algorithm. Through the preprocessing of the image signal processor, image quality can be improved, providing cleaner and more realistic input data for subsequent software algorithms such as grayscale conversion, median filtering, and background subtraction, thereby further improving the accuracy of spot localization and ring value determination.
[0118] The image signal processor can specifically be an ISP image signal processor. This processor can be directly connected to the CMOS image sensor of the image acquisition module via a MIPI CSI-2 interface. The raw Bayer format image data output by the sensor first enters the ISP pipeline for processing.
[0119] CMOS image sensors generate significant Gaussian noise in low-light environments (such as indoor training environments or at night). Relying solely on software median filtering for noise removal requires a large filtering window (e.g., 5×5 or 7×7), which blurs the edges of the noise spots and increases computation time. This technical solution, however, uses an image signal processor to first perform hardware-level bilateral filtering for noise reduction on the original image. This effectively smooths Gaussian noise while preserving edges, allowing subsequent software median filtering to achieve the desired noise reduction effect using a smaller window (e.g., 3×3). This reduces the processor's computational load and helps maintain a real-time frame rate of over 20 frames per second.
[0120] Thirdly, this application provides a laser target identification system, including: A laser simulation gun (or simply a laser gun) is used to emit near-infrared pulsed laser light in the 825 nanometer band to form a light spot on the surface of a real target; the laser simulation gun is set at a preset distance in front of the target. As in any of the technical solutions in the second aspect, the artificial intelligence camera (which may be simply referred to as the camera); the artificial intelligence camera is located in the direction deviating from the straight line connecting the target surface and the laser simulation gun, and the positional relationship between the two can be found in [reference needed]. Figure 6 ; The shooter's display terminal is used to receive and display the hit ring value sent by the artificial intelligence camera; The back-end main control device is used to receive and manage shooting scores based on the hit ring values sent by the artificial intelligence camera.
[0121] The laser target shooting and judgment system integrates the aforementioned artificial intelligence camera, laser simulation gun, shooter display terminal, and back-end main control equipment, forming a complete laser simulation shooting training solution. The following section provides a detailed description of the system in conjunction with specific deployment scenarios and workflows.
[0122] This system consists of four main parts: a laser simulation gun, an artificial intelligence camera, a shooter display terminal, and a back-end main control device.
[0123] The laser simulator gun emits near-infrared pulsed laser light in the 825nm wavelength band. Its shape and operation mimic a real firearm, integrating a laser emission module, trigger switch, and battery. When the shooter pulls the trigger, the laser emission module instantly emits a near-infrared pulsed laser beam with a wavelength of 825nm, a pulse width in the nanosecond range, and a peak power that meets human eye safety standards. The laser beam travels along the aiming line of the barrel, illuminating the actual target surface and forming a spot invisible to visible light (but detectable by the system's camera). The laser simulator gun is positioned at a preset distance in front of the target; this distance is set according to the shooting training subject, commonly 25 meters, 50 meters, or 100 meters. The laser simulator gun is placed on the firing line 50 meters from the target surface, allowing the shooter to aim and fire from a standing, kneeling, or prone position.
[0124] The AI camera, employing any of the technical solutions described in the second aspect, is used to acquire real-time images of the target surface containing light spots and execute a target identification algorithm to output a hit ring value. The camera is positioned off-center from the straight line connecting the target surface and the laser simulation gun; that is, the camera is not installed directly behind the laser simulation gun or directly in front of the target surface, but rather offset at a certain angle (e.g., an angle of 15° to 30° with the normal direction of the target surface). This off-center deployment avoids the laser simulation gun's body obstructing the camera's line of sight and also prevents the direct impact of muzzle smoke or flame from laser emission on the lens. The camera is typically installed inside the target housing, above or to the side, and fixed using a tripod or dedicated bracket. Its lens is aligned with the center of the target surface to ensure complete acquisition of the entire target area. The camera is powered by a built-in polymer lithium battery, eliminating the need for external power cables and facilitating rapid deployment and relocation on-site.
[0125] The shooter's display terminal receives and displays the hit ring value sent by the AI camera. The shooter's display terminal can take various forms, such as a small OLED display mounted on the laser simulator, a wrist-worn display worn by the shooter, a tablet placed next to the shooting position, or a heads-up display integrated into shooting goggles. The shooter's display terminal wirelessly pairs with the AI camera via Bluetooth. After the shooter completes a shot, the camera calculates the hit ring value within milliseconds and immediately sends it to the display terminal via Bluetooth. The terminal displays the ring value (e.g., "10 rings") and a diagram of the bullet impact point in real time, allowing the shooter to receive immediate feedback and adjust their aim. In addition to sending the hit ring value, the AI camera can also send the coordinates of the spot center to the shooter's display terminal and other external devices for display.
[0126] The main control unit is used to receive and manage shooting scores based on the hit ring values sent by the AI cameras. This main control unit can be a computer or server with dedicated management software installed, deployed at the instructor's workstation or training control center. The device connects to the AI cameras via a wired network (such as Gigabit Ethernet). After each target assessment, the camera simultaneously uploads information such as the hit ring value, spot coordinates, shooting timestamp, and shooter number to the main control unit. The main control unit has the following functions: recording all shooters' past shooting scores, generating training reports and statistical analysis charts; supporting network connectivity for multiple cameras and simultaneous management of multiple target positions; allowing instructors to view the current scores at any target position in real time; and supporting score export, printing, and comparative analysis with historical training data.
[0127] For example, the complete laser target identification process is as follows: Step 1: System Initialization. Before training begins, deploy the laser simulator, AI camera, shooter display terminal, and backend control device. The camera automatically calibrates its horizontal angle through the attitude correction module and completes lens focusing and distortion correction through the image calibration module. The shooter display terminal pairs with the camera via Bluetooth, and the backend control device connects to the camera via Ethernet cable and confirms normal communication. The camera captures and stores a background image without light spots.
[0128] Step 2: Shooter aims and fires. The shooter aims at the target through the sight of the laser simulator and pulls the trigger. The laser simulator fires an 825nm near-infrared pulse laser, creating a momentary spot on the target surface.
[0129] Step 3: Image Acquisition and Target Identification. An AI camera acquires target images containing light spots in real time and executes the laser target identification method described in the first aspect of this application: the image is converted to grayscale, median filtering is applied, background subtraction is performed, light spot region extraction is conducted, subpixel localization is achieved using grayscale weighted centrifugation, and target ring geometric parameters are calculated, ultimately yielding the hit ring value. The entire process is completed within 50 milliseconds.
[0130] Step 4: Result Feedback and Data Management. The camera sends the hit score to the shooter's display terminal via Bluetooth. The terminal immediately displays the score, allowing the shooter to see their shooting result. Simultaneously, the camera uploads the hit score and detailed data to the backend control device via network cable. The backend control device records the result and updates the training statistics. Coaches can view the shooter's training performance in real time through the backend control device.
[0131] The steps in the various embodiments of this application are not necessarily executed sequentially according to the order indicated by the step numbers. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in each embodiment may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least a portion of the sub-steps or stages of other steps.
Claims
1. A laser target identification method, characterized in that, Includes the following steps: Acquire a first target surface image that does not contain a pulsed light spot and a second target surface image that contains a pulsed light spot; The first target image is preprocessed to obtain a background grayscale image; The second target image is preprocessed to obtain a target grayscale image; the preprocessing includes grayscale conversion and median filtering. Based on the diameter of the physical target, the focal length of the camera, and the distance from the camera to the physical target surface, the center coordinates of the target ring and the radii of multiple target rings are extracted from the background grayscale image. The target grayscale image is compared pixel by pixel with the background grayscale image. If the current pixel value is equal, the pixel value at the corresponding position in the result image is set to the first value. If the current pixel value is not equal, the pixel value at the corresponding position in the result image is set to the second value, thus obtaining a binary difference image. The first value and the second value are not equal. Extract the spot region from the binary difference image, and calculate the center coordinates of the spot region based on the gray values of each pixel in the spot region, which are then used as the center coordinates of the spot. The hit ring value is determined based on the center coordinates of the target rings, the radii of each target ring, and the center coordinates of the light spot.
2. The method according to claim 1, characterized in that, The step of extracting the target ring center coordinates and the radii of multiple target rings from the background grayscale image based on the diameter of the physical target, the focal length of the camera, and the distance from the camera to the physical target surface includes: Locate the small white circular area in the center region of the target surface 10 rings in the background grayscale image; Obtain the row and column coordinates of all pixels within the white small circle area, calculate the average value of the row coordinates and the average value of the column coordinates respectively, and use the average value of the row coordinates as the row coordinates of the target ring center and the average value of the column coordinates as the column coordinates of the target ring center. The target image width is calculated based on the diameter of the actual target, the focal length of the camera, and the distance from the camera to the actual target surface. Divide the width of the target image by the total number of target rings to obtain the target ring spacing; The radius of each target ring is determined based on the target ring spacing.
3. The method according to claim 1, characterized in that, The step of calculating the center coordinates of the light spot region based on the grayscale values of each pixel in the light spot region includes: Calculate the product of the column index of each pixel in the light spot area and the gray value of that pixel, sum the products of all pixels, and then divide by the sum of the gray values of all pixels in the light spot area to obtain the center column coordinates of the light spot area. Calculate the product of the row index of each pixel within the spot area and the gray value of that pixel. Sum the products of all pixels and divide by the sum of the gray values of all pixels within the spot area to obtain the center row coordinates of the spot area.
4. The method according to claim 1 or 2, characterized in that, The step of determining the hit ring value based on the target ring center coordinates, the radius of each target ring, and the spot center coordinates includes: Calculate the Euclidean distance from the center of the light spot to the center of the target ring based on the coordinates of the target ring center and the coordinates of the light spot center. The Euclidean distance is compared with the radius of each target ring, and the hit ring value is determined based on the comparison result.
5. The method according to claim 4, characterized in that, The step of comparing the Euclidean distance with the radius of each target ring and determining the hit ring value based on the comparison result includes: If the Euclidean distance is greater than or equal to 0 and less than the target ring spacing, then the hit ring value is determined to be 10 rings; If the Euclidean distance is greater than or equal to the target ring spacing and less than twice the target ring spacing, then the hit ring value is determined to be 9 rings; If the Euclidean distance is greater than or equal to twice the target ring spacing and less than three times the target ring spacing, then the hit ring value is determined to be 8 rings; If the Euclidean distance is greater than or equal to three times the target ring spacing and less than four times the target ring spacing, then the hit ring value is determined to be 7 rings; If the Euclidean distance is greater than or equal to four times the target ring spacing and less than five times the target ring spacing, then the hit ring value is determined to be 6 rings.
6. An artificial intelligence camera, characterized in that, It includes a printed circuit board, an image acquisition module, an artificial intelligence processing module, a communication module, and a power supply module all integrated on the printed circuit board; The image acquisition module is used to acquire target surface images; the image acquisition module includes a visible light CMOS sensor installed at the center of the printed circuit board and an 825 nm narrowband filter installed at the front end of the lens; The artificial intelligence processing module includes a processor and a memory, wherein the memory stores a computer program, and the processor executes the computer program to implement the method as described in any one of claims 1 to 5; The communication module is used to send the hit ring value output by the artificial intelligence processing module to an external device via wired or wireless communication; the external device includes a shooter display terminal and a back-end main control device; The power module is used to supply power to the module integrated on the printed circuit board.
7. The device according to claim 6, characterized in that, The printed circuit board also integrates an auxiliary function module; the auxiliary function module includes: An attitude correction module is used to collect the installation attitude data of the camera and correct the installation attitude of the camera based on the installation attitude data. And / or, The image calibration module is used to perform lens focal length calibration using a resolution test chart.
8. The device according to claim 6, characterized in that, The printed circuit board also integrates an LED lighting module; The LED lighting module is used to adjust the lighting brightness according to the ambient light intensity.
9. The device according to claim 6, characterized in that, The artificial intelligence processing module also includes: An image signal processor is used to perform noise reduction and white balance adjustment on the target image acquired by the image acquisition module.
10. A laser target identification system, characterized in that, include: A laser simulation gun is used to emit near-infrared pulsed laser light in the 825 nanometer band to form a light spot on the surface of a real target; the laser simulation gun is set at a preset distance in front of the target. The artificial intelligence camera as described in any one of claims 6 to 9; the artificial intelligence camera is located in a direction deviating from the straight line connecting the target surface and the laser simulation gun; The shooter display terminal is used to receive and display the hit ring value sent by the artificial intelligence camera; The back-end main control device is used to receive and manage shooting scores based on the hit ring value sent by the artificial intelligence camera.