The present disclosure relates to the automatic scoring of targets in a shooting range, for example, and, more particularly, automatic scoring of targets in a shooting range and the like by a portable target practice evaluation unit that identifies targets in a firing lane, determines a type of target, identifies hits of the target, and scores the hits, without user intervention.
Firearm proficiency is a critical skill for the military, law enforcement, and people who endeavor to hunt for their livelihood or sustenance, for example. It is also a sport. Ample practice is required to achieve a high degree of competency. Because of the destructive and dangerous nature of firearms, as well as the potential for hearing loss, practice with live ammo on typical indoor rifle ranges is performed in compartmentalized lanes, generally alone, and always with sound-deadening hearing protection. As a result, firearm practice has become more solitary and less engaging. The opportunities to improve proficiency are also less frequent.
Known target evaluation systems rely on additional equipment in contact with the firearm, special targets with sensors, and markings, for example. US Patent Application No. 2020/0398168 requires the use of external cameras and target hits are determined by a server.
A portable, self-contained target evaluation unit would facilitate the target evaluation process. In one embodiment of the invention, a portable target evaluation unit is disclosed that analyzes images of a target taken by a camera in the portable unit to: 1) determine the paper target type, 2) determine the distance or depth to the target, 3) identify hits on the target and their location, and 4) score the session. In one embodiment, machine learning is used to analyze the target to make at least some of the determinations and identifications. In one example, no modifications to the firearm, the target, or the facility are required. Conventional, off-the-shelf paper targets may be used. Scoring may be performed in real time or near real time. In one example, scoring may be performed in less than one (1) second.
In one example of an embodiment of the invention, camera images of a target are analyzed to determine a type of the target. Target types include a bullseye target; a silhouette target including one or more dangerous characters, such as one or more criminals; and/or a hostage target including at least one real or imagined dangerous character, such as a criminal, terrorist, or a zombie, for example, and a hostage. A distance to the target is also determined. The optimal point of impact and the actual point of impact are determined. An accuracy score is determined based on the actual points of impact versus the optimal point of impact. These determinations may be performed by a single, portable device that includes the camera and one or more processing devices, for example. The portable device may be owned or rented by the user, for example. In this example, no specialized equipment need be installed by the gun range and direct contact with the firearm is not required. In another example, a shooting range may be configured to perform the determinations for respective users.
In one embodiment of the invention, the target practice evaluation unit 12 may be configured to identify a type of target and score hits on the target based on the identified target type.
In accordance with an embodiment of the invention, a method for evaluating hits on a target is disclosed, comprising capturing frames of the target by a camera; detecting a target in a captured frame, by a processing device; classifying the target in the captured frame as a target type, by a processing device; determining a depth of the target from a user; identifying a hit on the target, by a processing device; and scoring the hit, by a processing device. Detecting the target, classifying the target, and/or identifying a hit on the target may be performed by a respective machine learning model.
In accordance with another embodiment of the invention, a system for evaluating bullet hits on a target is disclosed, comprising a camera to capture frames of a target; at least one processing device; and storage; wherein the at least one processing device configured to: detect a target in a captured frame; classify the target in the captured frame as a target type; determine a depth of the target from a user; identify a hit on the target, by running a machine learning model; and score the hit. The system may further comprise a casing having an opening, wherein the camera has a lens proximate the opening to capture frames down range of the casing, and the camera, the at least one processing device, and the storage are contained within a portable casing. The system may be portable and self-contained. The system of claim 16, wherein the casing has a second opening different from the first opening and contains a second camera different from the first camera, the second opening and the second camera being configured to image at least a user's shooting hand during use.
In accordance with another embodiment of the invention, a method for evaluating bullet hits on a target comprises classifying the target in a captured frame by running a first machine learning model and identifying a hit on the target by running a second machine learning model different from the first machine learning model; and scoring the hit.
Embodiments of the invention are also applicable to other types of target practice, such as archery, darts, paintball, airsoft, and virtual reality games, for example.
In accordance with one embodiment of the invention, a target practice evaluation unit for use in a shooting range is portable and includes a case that contains a camera for imaging targets. The target practice evaluation unit may be placed by a user on a table or shelf in a firing lane and positioned so that the camera faces down the firing lane, where a target is or will be located, to image the target. In one example, a processing device in the target practice evaluation unit analyzes the images to identify a target, classifies the type of target, determines a distance to the target, detects hits on the target, and scores the hits. Target identification, target classification, distance to the target, and/or hit detection may be performed by the processing device using artificial intelligence, such as machine learning. Target identification, target classification, and/or hit detection may be performed by machine learning, for example. A second camera may be provided in the case of the target practice evaluation unit to image the shooter's shooting hand or upper body including the hands while shooting. The images of the shooter's hand may be analyzed by machine learning or by an expert to identify problems in form that the shooter can correct. A report may be provided to the user including the user's score and evaluation of form, for example.
The gun range 10 in this example includes a plurality of firing lanes 14a, 14b, 14c . . . , three of which are shown at least in part. The firing lane 14b, which is best shown in
Other components of a shooting range that are known in the art are not shown in
The casing of the target practice evaluation unit 206 may be plastic, such as an injected molded plastic, for example. The plastic may be acrylonitrile butadiene styrene (“ABS”), for example. It is noted that the target evaluation unit 206 may have other shapes and the components of the target evaluation unit 12 may be in different locations.
The processing device 302 provides input to a display 308 via another processing device, here the video controller 310. It is noted that the video controller may also execute machine learning models, or a co-processor (not shown) may be provided to execute machine learning models. As discussed above, the display 308 may be a touch screen. When the display 308 is a touchscreen display, the display may provide input from the touchscreen to the processing device 302 via an input/output (“I/O”) controller 410, for example. The display may be a 480×800 pixel, touchscreen display measuring 3½ inches×6 inches or about 7 inches on the diagonal in portrait mode, for example. The video controller 310 may be an ARM MALI graphics processing unit, available from Arm, Ltd. San Jose, CA, for example. The I/O controller 310 may be an embedded general purpose I/O or subordinate 32 bit processor, such as an ESP 32, available from Espressif Systems, Shanghai, China, for example.
In one example, the video controller 310 may also perform the machine learning functions, on its own or in conjunction with the processing device 302, to detect a target, classify a target, determine a depth of a target, identify hits on the target, score hits, and/or analyze a user's movement while shooting, as is described in more detail below.
If the display 308 is not a touchscreen, then a keyboard may be provided (not shown). The keyboard, if provided, may also provide input to the processing device 302 via the I/O controller 310.
A camera 314 also provides input to the processing device 312 via the I/O controller 310. A second, optional camera 316 also provides input to the processing device 312 via the I/O controller 310. The camera may be a complementary metal oxide semiconductor (“CMOS”) camera, for example. As is known in the art, a CMOS camera is mounted on a printed circuit board along with a processing device, lens, and power supply, such as a battery, for example. The battery may be one or more commercially available lithium polymer (“LiPo”) batteries, such as LiPo 18650 battery cells, for example. Alternatively, or in addition, power may be provided to the system board by an external power supply, camera-via a USB port (not shown) through the casing, such as through a rear wall of the casing, for example.
The camera 314, which acquires images of the target 22 in
The camera 316, if provided to image of a user's hand(s), may have a wide angle, such as a focal-length of 24 mm, for example, at a distance of from about 1 foot to about 3 feet from the user's hands while shooting, for example.
The camera 316 may also be a B0371 camera available from ArduCAM Technology Company, Ltd., Kowloon, Hong Kong, for example, which has a 16 megapixel autofocus.
The target evaluation unit 300 may also include a fan (not shown), if needed, based on the processing device 602.
The portable target evaluation unit of
Other types of targets may also be used in embodiments of the invention.
Frames continue to be captured, in Step 510. When a target is classified, in Step 508, the depth or distance from the target evaluation unit to the target is then determined, in Step 512. The depth (z) may be determined by the processing device 302 and/or the video controller 310 based on the field of view of the camera 314, the known dimensions of the target (x,y), and the detected dimensions (x, y) of the target in pixels. The depth corresponding to the detected number of pixels may be stored in a table, for example. The table may be stored in the non-volatile memory 304 or in another memory or storage device, for example. Alternatively, the depth can be calculated based on the perceived size of a known target, based on the focal length of the camera, and the camera resolution, as is known in the art.
It is then determined whether the depth (z) of the target 12 is zero (0), in Step 514. This may be determined by the processing device 402 and/or the video controller 410 based on whether the detected number of pixels is the same as the actual dimensions of the target in pixels. If the depth (z) is zero (0) (Yes in Step 514), then the target has either been returned to the firing line or has not been advanced to a location downstream of the firing line. In either case, the session is then stopped in Step 516.
If it is determined that the depth is not zero (0) (No in Step 516), then the target is downstream of the firing line and can be shot at by a user. Hit detection is then performed by the processing device or the video controller 410, in Step 518. Hit detection may be performed by comparing a captured frame to a prior captured frame and determining whether there is a change in the two frames indicative of a hit on the target. Hit detection may be performed by the processing device 402 or the video controller 410 by a machine learning algorithm, for example, as discussed further below. If a hit has been detected in Step 520, the hit is scored, in Step 522. The hit may be scored by the processing device 302 and/or the video controller 310 based on the depth of the target 22 and the proximity of the hit to a center of the target or center of mass of the target, for example, as discussed further below. After scoring the hit, the position of the user 20 may be analyzed using frames captured by the second camera 316, if provided, in Step 524. Step 524 is shown in dashed lines because Step 524 is optional. Position analysis is also discussed in more detail, below. After scoring a hit in Step 522 or analyzing the position of the user in Step 524, if performed, the process returns to Step 512 to continue to capture frames and repeat Steps 512 through 522.
If a hit is not detected (No in Step 522), then the process returns to Step 512 to continue to capture frames and repeat Steps 512 through 522.
A session starts in Step 608. A session is a self-contained period of time or activities related to the shooting of a respective target 22. The target evaluation unit 12 is positioned on the shelf or table 28 in the firing lane by the user, in Step 610, for example, as discussed above. The target evaluation unit 12 could also be placed on the floor, if the user 602 is shooting in a prone position. A target is selected and set up by clipping it to the carrier 24 in
In one example, the display 308 of the target evaluation unit 300 may display a select mode option during the start-up procedure, in Step 616, for selection by the user. Step 616 is shown in dashed lines because it is an optional Step. Available modes may include a standard target practice mode, a government bureau agent qualification or certification mode, and/or a game mode, for example, as discussed herein. A game mode may enable one user or multiple users to play tic-tac-toe, for example, on targets shaped like a tic-tac-toe board, for example. The target 22 and/or scoring in Step 522 of
After a session is created, in Step 618 of
Object detection to identify a target in the firing lane 14b may be performed machine learning model.
Returning to
The flowchart 600 then proceeds to perform target classification to determine the type of target 22 detected in the frame, in Step 630. In this example, target classification is performed by machine learning by the machine learning manager 606. If there is only one (1) target in the frames (No in Step 624), the process proceeds directly from Step 624 to target classification, in Step 630.
The frame is sent to a first machine learning model (“ML 1”), in Step 815. The ML 1 predicts whether the target identified in the frame matches a known target and the confidence of the prediction, in Step 820. The predicted matching target may be identified by a target ID. The ML 1 may have the form of the machine learning model 700 of
The output layer 706 in this example may include a softmax function to classify the target 22 as a specifically identified, known target referenced by a unique ID and confidence score. This unique ID will be used to retrieve additional details such as whether it is a bullseye type, silhouette type, or hostage type with a determined confidence score, for example.
The classification and confidence score are output by the output layer 706 and the confidence score is evaluated in Step 825. The classification and confidence score may be evaluated by the processing device 302, the video controller 310, or a co-processor (not shown), for example. If it is determined that the confidence score associated with the predicted target is greater than a predetermined confidence score for an acceptable target inference, such as 0.8, for example, in Step 825, then target area data is retrieved for the predicted target type, in Step 830. Target area data for known targets may be stored in a database or table in the non-volatile storage 604 or in other storage, for example. The threshold may be set when the system is programmed. The threshold may be a value in the range of from 0.7 to 0.8, for example. Higher or lower thresholds may be used. The target area data is added to the session and stored in RAM 306 in
Target area data may comprise the x, y coordinates of each point in an array of points defining valid target areas and invalid target areas. For example, in the bullseye target 400a of
In a known silhouette target 400b of
A user will receive positive scores for hits in the areas covered by the valid masks 924, 926 and no score or a penalty score for hits in the area covered by the invalid mask. A penalty score would reduce the total score in a session. A miss of all masks results in a no score. In certain modes, such as a professional certification for the law enforcement, for example, a hit in an invalid area, such as a hostage, results in a failure of the test, ending the session.
Returning to Step 830 of
Returning to Step 825 of
The presence of one or more circles in the target is inferred, in Step 878. In this example, the presence of circles is inferred by the ML Model for Object Circle detection 850. The hidden layers 704 (
The presence of one or more faces in the target is inferred, in Step 882. In this example, the presence of faces is inferred by the ML Model for Object FACE Object detection 855, in Step 1082. The hidden layers 704 in the ML model for Object FACE may be a CNN, for example, trained to infer the presence of one or more faces based on face-like shapes, such as an eye, a nose, a mouth, in spatial ratios consistent with human faces. The presence of one or more faces may be used to infer that the target is a silhouette type target or a hostage type target, for example. The training set for the ML Model for Object FACE Object detection 855 may include images of faces of different types and sizes. The size of the training set may be several thousand images, for example. Some of the images in the training set may be synthetically generated. An output of the ML Model 855 may be provided in the form of a count for each identified face, in Step 884.
The sentiment of one or more faces in the target is inferred, in Step 884. Sentiment is used in the hostage type target to differentiate between the hostage and the hostage takers. For example, in the hostage type target 400c of
In this example, the sentiment of faces is inferred by the ML Model for SENTIMENT detection 860, in Step 886. The hidden layers 704 in the ML model for Object Sentiment may be a neural network, such as a multi-class neural network, for example, for example, trained to infer the sentiment expressed by the identified faces. The training set for the ML Model for SENTIMENT detection 860 may be a labelled set of one or several thousand images of faces expressing different sentiments, including synthetically generated images for example. An output of the ML Model for SENTIMENT detection 860 may be provided in the form of a count for different classes of sentiment, such as a count for the inference of anger or disgust, for example, and a count for fear, sadness, and surprise, for example, in Step 888. The ML Model for SENTIMENT detection 860 need not be executed if no faces are inferred, as indicated by the arrow 885.
The outputs of Steps 876, 880, 884, 888 are resolved based on the received counts, in Step 890, for example. Resolution of the counts is performed by the Final Target Classification Determination algorithm 865 in
Table I resolves the SEGMENT_COUNT, CIRCLE_COUNT, FACE_COUNT, and FACE SENTIMENT to reach a Final Target Classification Determination in the final column. A SEGMENT_COUNT of 1 and a CIRCLE_COUNT of 1 is resolved to a Bullseye Target, in Row 1. A SEGMENT_COUNT of 1+(indicating more than one (1) segment) and a CIRCLE_COUNT of 1+(indicating more than 1 circle) is resolved to a Multiple Bullseye Target (where more than one bullseye target is provided on the same target. A SEGMENT_COUNT of 0−1, a CIRCLE_COUNT of zero (0) and a FACE_COUNT of 1, and any SENTIMENT COUNT is resolved to a Silhouette Target. A SEGMENT_COUNT of 1+, a CIRCLE_COUNT of 0, a FACE_COUNT of 1+, and a FACE SENTIMENT of 2+ Angry and/or Disgust and Fear, Sadness, or Surprise, for example, resolves to a Hostage Target. In the case of the Hostage Target, Valid areas correspond to faces showing Angry or Disgust sentiments and Invalid areas correspond to faces fear, sadness, or surprise, for example.
The Final Target Classification Determination Algorithm 865 may apply weightings to the outputs of the machine learning models 845-860, based on experimentation.
The resolved target classification is output in Step 892. The target area data is added to the session and stored in RAM 306 in
Returning to
After the depth is inferred, it is determined whether the depth is zero (0), in Step 514. If the depth is zero (0) (Yes in Step 514), it indicates that the user has retrieved the target and the session is ended, in Step 516. If the depth is not zero (0) (No in Step 514), then the process 500 continues to determine whether a hit is detected in the target, in Step 518.
Hit detection in Step 518 will now be described.
A current frame is received and converted to grayscale, in Step 1105. A blur is then applied to the current grayscale frame, in Step 1110. The current blurred frame is compared to a prior blurred frame, in Step 1115. The result of the compared frames is referred to as a CleanFrame.
The CleanFrame is provided to a machine learning model that is trained to detect bullet hits.
The hidden activation layers 1 . . . N (1135 . . . 1140) are the first and last layers of a multiple layer neural network. The hidden activation layers 1 . . . N (1135 . . . 1140) in this example are each rectified linear unit (“ReLU”) layers. The neural network may be a convolutional neural network or another type of deep learning neural network, for example. The neural network may include eight (8) layers, for example. Each layer may have 10 activations, for example.
The hidden activation ReLU layers of the neural network progressively analyze the change between the current frame and the prior frame that are indicated in the CleanFrame, to determine whether any difference between the frames is indicative of a possible bullet hit in terms of size and shape, for example. The activation layers also determine a confidence score of the determination that there is a bullet hit. Possible hits are identified as 3×3, or 5×5 pixel squares referred to as kernels.
The neural network 1135-1140 is trained by a training set including from about 50,000 to about 100,000 training images of different types of targets with labelled bullet hits and of different calibers, and clean, white paper with bullet hits with different calibers, for example. The training set may be based on about 10,000 different images of examples of bullet hits on targets, from which the remaining images in the training set may be generated synthetically, as is known in the art. In accordance with an embodiment of the invention, some of the synthetically generated images may have a modified texture to simulate real world defects in a potential actual target, such as being crumbled, worn, dog-eared, etc. The training set may also include labelled images of muzzle flash to train the machine learning model not to identify a muzzle flash for a bullet hit. The training set would include clean targets.
In addition, the output layer 1045 learns where to define a threshold between a hit or not based on the training set. The threshold identifies how much change from one change to the next indicates a bullet hit. The output layer 1045 provides a binary decision of Yes or No of whether a frame indicates the presence of a bullet hit based on the learned threshold and a confidence score. If Yes, the output layer 1145 identifies the x, y coordinate(s) of the pixel(s) where the hit is identified.
Other machine learning techniques could be used instead of deep learning, such as statistical techniques.
When a hit in a CleanFrame is output by the output layer 1145, the x, y coordinates of the hit are recorded I Step 1150 and provided to Step 522 of
Scoring of hits is explained with respect to
It is then determined whether the distance D is greater than R, in Step 1220. If the distance D is greater than R (Yes in Step 1220), then the hit is outside of the bullseye and no score is granted, in Step 1225. If the distance D is not greater than R (No in Step 1220), then the hit is within the bullseye. The distance D is rounded down to the nearest whole number, in Step 1230. The score is then determined to be 10−D (rounded down), in Step 1235.
The coordinates (x, y) of the hit and the target area data are retrieved from the RAM 306 by the processing device 302, for example, in Step 1260. The center of mass of the target hit area is determined and a distance D from the hit to the center of mass (cx, cy) is calculated, in Step 1265. It is then determined whether the distance D is less than the bullseye target radius R, in Step 1270.
If the distance D is not less than the the bullseye target radius (No in Step 1270), then the bullseye has been missed and no score is assigned to the hit, in Step 1275. If the distance D is less than the bullseye radius (Yes in Step 1270), then the hit is within the area of the bullseye. To score the hit based on how close the hit is to the center of mass of the bullseye in this example, a minute of angle (“MOA”) is calculated based on the distance D. The MOA may be calculated by dividing the distance D (in inches) between the hit and the center by 100, for example.
The hit is then scored by calculating the square of the depth and subtracting the MOA ((depth)2−MOA)). The score is returned for storage in the RAM 306 in association with the session, for example. Other scoring methodologies may also be used.
The coordinates (x, y) of the hit are compared to a valid hit area of the target, in Step 1315. If the target is a known target, the valid hit area is defined by the mask of the target. If the target is an unknown target, the valid hit area may be defined by a machine learning model in the manner described above.
It is determined whether the coordinates of the hit are within the valid hit area, in Step 1320. If the the coordinates of the hit are not within the valid hit area (No in Step 1320), the hit receives no score, in Step 1325.
If the coordinates of the hit are within the valid hit area (Yes in Step 1320), then the hit is scored by calculating the MOA, in Step 1330, as discussed above with respect to Step 1280 of
The coordinates of the hit are retrieved, in Step 1405, as discussed above. In this case, where there are multiple valid hit areas, the distance D from the hit to a center of mass (cx, cy) of the closest valid area is calculated, in Step 1410. As discussed above with respect to
The coordinates of the hit (x, y) are compared to the coordinates of the valid hit areas of the target, in Step 1415. The coordinates of the hit (x, y) are compared to the coordinates of the invalid hit areas of the target, in Step 1420.
The process proceeds to Step 1425, in
If the hit is not within an invalid hit area (No in Step 1430), then a no score is returned, in Step 1435. If the hit is within an invalid hit area (Yes in Step 1430), then a penalty score is returned, in Step 1440.
If the coordinates of the hit are within the valid hit area (Yes in Step 1425), then the hit is scored by calculating the MOA, in Step 1330, as discussed above with respect to Step 1280 of
If the coordinates of the hit are within the valid hit area (Yes in Step 1425), then the hit is scored by calculating the MOA, in Step 1445, as discussed above. The hit is then scored by calculating the square of the depth and subtracting the MOA ((depth)2−MOA)), as in Step 1450 of
Returning to
It is noted that a user may inform the system of a hit that was not counted as a hit, via the display, to improve the CNN. In one example, a user interface may be displayed on the display 208 showing hits on the target. The user interface may include an option to indicate a hit on the target that has not been counted, via the touchscreen 208 or other user input device, for example. Feedback may also be provided if, for example, a user always attends a respective shooting range so that lighting and shadowing unique to the respective shooting range, for example. In this case, a user would be provided with an option on the display to further train the CNN with the frames of the targets that the user has shot.
In addition, new targets may be entered into the system so that they become a known target. This may be done by updating a training set or by sending the new target to a centralized system, which can update the target evaluation device.
A data structure representative of the range session may be generated and available for the user's review and/or for submission to a combination of automated and/or expert review for evaluation, suggested training, and classification of whether a user would qualify for specific government, military or specialist certification based on performance, for example.
While embodiments of the invention have been described including a portable target evaluation unit that performs the analysis of targets to identify bullet hits and perform scoring, some or all of the determinations and inferences performed by the portable target evaluation device may be performed by a server at the location of the firing range or in the cloud, for example.
Examples of implementations of embodiments of the invention are described above. Modifications may be made to those examples without departing from the scope of the invention, which is defined by the claims below.
The present application claims the benefit of U.S. Provisional Patent Application No. 63/335,145, which was filed on Apr. 26, 2022, and is incorporated by reference herein.
Number | Date | Country | |
---|---|---|---|
63335145 | Apr 2022 | US |