The modern world has witnessed increased incidences of handgun violence; therefore, systems with automatic gun detection have become very important for detecting crime. The presented tool, YOLO10, proposes two new image sharpening methods that use a thresholding operation based on an activation function; this is a new technique for selecting the threshold value for image enhancement as a pre-processing step before training the YOLOv10 model to detect guns.