Computer image recognition method
By combining deep learning algorithms, image preprocessing technology and feature extraction technology, the computer image recognition method is solved, and the existing technology has limited recognition effect and high computational complexity in complex scenarios is achieved, efficient and accurate identification and alarm functions of target objects in monitoring scenarios are achieved, and monitoring efficiency and accuracy are improved.
Patent Information
- Application Number
- CN202510247847.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-04
- Publication Date
- 2025-03-28
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing image recognition methods have limited recognition effects in complex scenarios, high computational complexity, high hardware resources requirements, and are difficult to meet the growing security monitoring and other application needs.
A computer image recognition method is proposed, combining deep learning algorithms, image preprocessing technology and feature extraction technology, images are collected through multi-spectral cameras, image normalization and data enhancement, and feature information such as color, texture, shape, etc. are extracted, and image classification and recognition are used for deep convolutional neural networks, and alarms are triggered when dangerous targets or abnormal behaviors are identified.
It realizes efficient and accurate identification of target objects in the monitoring scenario, improves monitoring efficiency and accuracy, reduces the requirements for hardware resources, and enhances the generalization ability and robustness of the model.
Smart Images

Figure CN119723646A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of image recognition, and in particular to a computer image recognition method. Background Art
[0002] With the rapid development of computer vision technology, image recognition has been widely used in various fields, such as autonomous driving, medical image analysis, security monitoring, etc. From intelligent monitoring to intrusion detection, to behavior analysis, image recognition technology has become a core component of modern security systems. However, although the existing technology has made significant progress, it still faces many challenges in practical applications.
[0003] Traditional image recognition methods mainly rely on manually designed feature extractors, such as SIFT, HOG, etc. These methods have limited recognition effects in complex scenes. In recent years, image recognition methods based on deep learning have been proposed, such as the publication number "CN118038056A", which discloses a method, device, equipment and readable storage medium for crack segmentation of tunnel crack images, including: obtaining a tunnel crack image; using a trained tunnel crack image crack segmentation model to perform crack segmentation on the tunnel crack image; wherein the tunnel crack image crack segmentation model is obtained by training an improved U2Net neural network with a training data set consisting of annotated pixel-level tunnel crack images, and the improved U2Net neural network includes a feature extraction module, a feature fusion module and a dual attention module, and the feature extraction module is composed of a horizontal dynamic serpentine convolution layer, a vertical dynamic serpentine convolution layer and a residual U-shaped structure block in parallel. By improving the structure of the convolutional neural network (CNN) and introducing an attention mechanism, the long-standing problem of high-precision and complete segmentation of tunnel cracks that is difficult to achieve is solved. However, the above scheme has high computational complexity and high requirements on hardware resources, and cannot meet people's needs for image processing.
[0004] Therefore, a computer image recognition method is needed to meet the growing needs of security monitoring and other applications. Summary of the invention
[0005] In view of this, in order to solve the problems existing in the technical background, the present invention proposes a computer image recognition method, and the specific technical scheme is as follows: a computer image recognition method, characterized in that it includes image acquisition, image preprocessing, feature extraction, image classification and recognition, and alarm and linkage control modules; The image acquisition uses a multi-spectral camera to collect monitored images; The image preprocessing module preprocesses the input image, including image normalization and data enhancement operations, eliminates irrelevant information in the image, restores useful real information, simplifies data, and improves the reliability of feature extraction, wherein the irrelevant information includes noise information and background information in the image, and the useful information includes the target object in the image; The feature extraction extracts useful feature information from the preprocessed image, and the feature information includes color, texture, shape, and size, which are used for subsequent image classification and recognition; The image classification and recognition module uses a deep convolutional neural network (CNN) as a classifier to classify and recognize images based on the extracted feature information to improve recognition accuracy and robustness; When the alarm and linkage control module identifies a preset dangerous target or abnormal behavior, it can automatically trigger an alarm and link the alarm to respond.
[0006] As an improvement, the feature extraction specific operation is as follows: ;in, It is The convolution kernels are located at The output at is the weight of the convolution kernel, is the pixel value of the image obtained after normalization operation, is the bias term; the feature is optimized using the gradient descent method: in, are model parameters, is the loss function, and the update formula of the gradient descent method is: ;in, is the learning rate, The loss function is The gradient at .
[0007] As an improvement, in the image classification and recognition module, after feature extraction, the feature map is flattened into a one-dimensional vector and input into the fully connected layer. The fully connected layer performs linear transformation and nonlinear activation on the feature vector, and finally outputs the score of each category. After classification and recognition operations, it is judged whether it exceeds the preset dangerous target or abnormal behavior. When performing classification and recognition operations, a data category set is included, including a face data set, a vehicle data set, and an abnormal behavior data set. The face data set collects face key point detection and face feature extraction, the vehicle data set collects vehicle color, model, and license plate, and the abnormal behavior data set collects human posture estimation and action recognition. The calculation formula of the image classification and recognition module is as follows: ;in, It is a sample Belongs to category The probability of It is The scores of the categories, is the total number of categories, when When it is greater than 0.9, an alarm is triggered.
[0008] As an improvement, the alarm modes include sound alarm, light alarm and text message alarm. The sound alarm emits an alarm sound to remind security personnel, the light alarm is a flashing warning light, and the text message alarm sends the alarm information to a designated mobile phone or email address.
[0009] As an improvement, in the image preprocessing, the original pixels of the image are obtained , the minimum pixel of the image and the maximum pixel size of the image , and then perform image normalization and data enhancement operations. The formula for image normalization is as follows: ;in, is the original pixel value, and are the minimum and maximum pixel values in the image, respectively.
[0010] An electronic device comprises a memory and a processor, wherein the memory stores a computer program, and the processor is used to run the computer program in the memory to execute the steps in the above-mentioned image recognition method.
[0011] A computer program product includes a computer program or instructions, which implement the steps in the above-mentioned image recognition method when executed by a processor.
[0012] The above technical solution has the following beneficial effects: The present invention combines deep learning algorithms, image preprocessing technology and feature extraction technology to digitally identify images, and realize automatic recognition and classification of target objects in monitoring scenes, such as face recognition, vehicle recognition, abnormal behavior detection, etc. It can realize efficient and accurate recognition of targets in monitoring images, and automatically identify targets in monitoring videos through image recognition technology, and track, classify and alarm, thereby greatly improving monitoring efficiency and accuracy.
[0013] The image data preprocessing in the present invention includes image normalization and data enhancement, which can effectively improve the generalization ability and robustness of the model, reduce the requirements for hardware resources, and reduce feature redundancy and improve the discriminative ability of features, thereby improving the accuracy of image recognition.
[0014] The present invention dynamically monitors the monitoring area through the camera, and realizes alarm of the occurring situation by extracting, classifying and identifying the image features, and reminds the relevant management personnel, so as to avoid more serious incidents. While improving the video monitoring effect, it also greatly reduces the workload of the monitoring management personnel; it can realize efficient and accurate identification of the targets in the monitoring video, and provides strong support for the intelligence and automation of the security monitoring system. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] Figure 1 The figure is a flow chart of a computer image recognition method of the present invention.
[0016] The accompanying drawings are used to provide further understanding of the present invention and constitute a part of the specification. They are used to explain the present invention together with the embodiments of the present invention and do not constitute a limitation of the present invention. DETAILED DESCRIPTION
[0017] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0018] Example 1, see Figure 1 A computer image recognition method shown in the figure includes a complete process from image acquisition to alarm and linkage control. In the image acquisition stage, the method uses a high-precision, multi-spectral camera to capture more delicate and comprehensive image information in the monitoring area, and an image preprocessing module, which performs a series of operations on the input image to optimize the image quality. Image normalization ensures the consistency of images from different sources in terms of brightness, contrast, etc.; data enhancement operations increase the diversity of image samples through rotation, scaling, flipping, etc., which helps to improve the generalization ability of the model. This series of preprocessing steps effectively eliminates noise and redundant information in the image, restores the real details of the image, enhances the detectability of key information, and provides a more reliable data basis for subsequent feature extraction and image recognition.
[0019] In the feature extraction stage, this method accurately captures various feature information such as color, texture, shape, size, etc. from the preprocessed image. This information constitutes the unique "fingerprint" of the image.
[0020] The image classification and recognition module intelligently analyzes and classifies the extracted feature information based on the powerful capabilities of deep convolutional neural networks (CNNs). With its hierarchical structure, CNN can automatically learn deep features in images and achieve high-precision image classification and recognition. This step not only improves the accuracy of recognition, but also enhances the robustness of the system, enabling it to cope with various complex scenes and lighting conditions.
[0021] The alarm and linkage control module monitors and responds quickly in real time. Once a preset dangerous target or abnormal behavior is identified, the module can immediately trigger an alarm signal and link alarms, surveillance cameras and other equipment to quickly activate the emergency response mechanism to ensure timely discovery and handling of security incidents.
[0022] By performing the above operations, the image is digitally recognized by combining deep learning algorithms, image preprocessing technology and feature extraction technology, realizing automatic recognition and classification of target objects in the monitoring scene, such as face recognition, vehicle recognition, abnormal behavior detection, etc. The cost of obtaining image samples is low, the calculation is simple, the hardware requirements are not high, and a large amount of data does not need to be labeled during the processing process.
[0023] Example 2: See Figure 1 , This embodiment presets dangerous targets and abnormal behaviors: a group of dangerous targets and abnormal behaviors are preset as alarm conditions according to actual needs. For example, the preset dangerous targets may include people breaking in, vehicles illegally parked, etc.; the preset abnormal behaviors may include running, fighting, etc., and the recognition results will be judged: the output results of the image classification and recognition module are compared with the preset alarm conditions. If the recognition result meets the alarm condition, the alarm is triggered. Trigger alarm and linkage control: When the alarm is triggered, the system can automatically send out an alarm signal and link other security equipment to respond. For example, the camera can be linked to track and shoot, the alarm can be linked to sound an alarm, and the access control system can be linked to close the exit.
[0024] The specific implementation is as follows: The front-end data sample acquisition obtains real-time video stream image data from the surveillance camera. The module needs to support multiple video input formats and have video stream preprocessing functions such as denoising, resolution adjustment, and frame rate control. In order to ensure the real-time and integrity of the data, the module also needs to have efficient data compression and transmission capabilities.
[0025] The specific operation of feature extraction is as follows: ;in, It is The convolution kernels are located at The output at is the weight of the convolution kernel, is the pixel value of the image obtained after normalization operation, is the bias term; the feature is optimized using the gradient descent method: in, are model parameters, is the loss function, and the update formula of the gradient descent method is: ;in, is the learning rate, The loss function is The gradient at .
[0026] Feature extraction processes and analyzes the preprocessed image data. This module first extracts frames from the video stream and decomposes the video into continuous image frames. Then, a convolutional neural network (CNN) is used to extract features from each frame to capture key information in the image. In order to further improve the accuracy of feature extraction, this module can also introduce an attention mechanism to enable the model to focus on important areas in the image.
[0027] In the image classification and recognition module, after feature extraction, the feature map is flattened into a one-dimensional vector and input into the fully connected layer. The fully connected layer performs linear transformation and nonlinear activation on the feature vector, and finally outputs the score of each category. After classification and recognition operations, it is judged whether it exceeds the preset dangerous target or abnormal behavior. The image classification and recognition includes a data category set, including an abnormal behavior data set. The face data set collects face key point detection and face feature extraction. The abnormal behavior data set collects human posture estimation and action recognition. The calculation formula of the image classification and recognition module is as follows: ;in, It is a sample Belongs to category The probability of It is The scores of the categories, is the total number of categories, when When it is greater than 0.9, an alarm is triggered.
[0028] The behavior recognition and anomaly detection module is responsible for time series analysis and behavior classification of the extracted features. This module uses a recurrent neural network (RNN) to model continuous image frames and capture the dynamic characteristics of the behavior. Through training, the model can identify normal and abnormal behaviors and determine whether to trigger an alarm based on the preset threshold.
[0029] The alarm and linkage control module includes a user interface, which provides users with an intuitive operation interface and real-time alarm information. Users can view real-time monitoring images, query historical records and set system parameters through the interface. When the system detects abnormal behavior, the module will immediately trigger an alarm and notify relevant personnel through various means (such as sound, light, SMS, etc.).
[0030] The feature extraction and selection in this embodiment are key steps in the abnormal behavior security image recognition system, which directly affects the recognition performance and generalization ability of the model. This solution uses convolutional neural network (CNN) for image feature extraction, and combines attention mechanism and self-supervised learning technology to improve the accuracy and robustness of feature extraction.
[0031] Example 3, see Figure 1 As shown, the image recognition method of the present invention is applied in the security monitoring system of a shopping mall. The specific steps are as follows: A computer image recognition method includes image acquisition, image preprocessing, feature extraction, image classification and recognition, and alarm and linkage control modules; the surveillance images in the shopping mall are cropped, grayed, binarized and denoised, and the deep convolutional neural network is used to extract features from the preprocessed surveillance video frames, and the extracted feature vectors are input into a trained classifier for classification and recognition. The recognition results include categories such as personnel, vehicles, and objects. The image acquisition uses a multispectral camera to collect the monitored images; the image preprocessing module: preprocesses the input images, including image normalization and data enhancement operations, eliminates irrelevant information in the image, restores useful real information, enhances the detectability of relevant information, simplifies data, and improves the reliability of feature extraction, image segmentation, matching and recognition.
[0032] The image in this embodiment is cropped according to the size and position of the monitoring area to remove irrelevant background information. The color image is converted into a grayscale image to reduce the amount of calculation and increase the processing speed, and the grayscale image is converted into a binary image to further simplify the image information.
[0033] The feature extraction extracts useful feature information from the preprocessed image, which may include color, texture, shape, size, etc., for subsequent image classification and recognition. The image classification and recognition module uses a deep convolutional neural network (CNN) as a classifier to classify and recognize images based on the extracted feature information to improve recognition accuracy and robustness. When the alarm and linkage control module recognizes a preset dangerous target or abnormal behavior, it can automatically trigger an alarm and link an alarm to respond.
[0034] In this embodiment, the feature extraction operation is as follows: ;in, It is The convolution kernels are located at The output at is the weight of the convolution kernel, is the pixel value of the input image, is the bias term; the feature is optimized using the gradient descent method: ;in, are model parameters, is the loss function. The update formula of the gradient descent method is: ;in, is the learning rate, The loss function is The gradient at In this embodiment, in the image preprocessing, the original pixels of the image are obtained. , the minimum pixel of the image and the maximum pixel size of the image , and then perform image normalization and data enhancement operations. The formula for image normalization is as follows: ;in, is the original pixel value, and are the minimum and maximum pixel values in the image, respectively.
[0035] The data enhancement increases the diversity of the data by adjusting the image's attributes such as brightness, contrast, and saturation. The specific method is as follows: ;in, is the original image, is the brightness adjustment; contrast adjustment is achieved through linear transformation: in, is the contrast factor.
[0036] By applying the image recognition method of the present invention, the security monitoring system of the shopping mall can realize efficient and accurate recognition of targets in the monitoring video, greatly improving the monitoring efficiency and accuracy. At the same time, through the automatic recognition and alarm functions, timely response and processing of dangerous targets and abnormal behaviors are realized.
[0037] For example, taking flame recognition as an example, a multispectral camera is used to collect images of the monitored area to ensure clear image quality and to capture the detailed features of the flame.
[0038] The collected images are normalized to eliminate the differences in the images caused by factors such as lighting and camera parameters.
[0039] In the image preprocessing, the original pixels of the image are obtained , the minimum pixel of the image and the maximum pixel size of the image , and then perform image normalization and data enhancement operations. The formula for image normalization is as follows: ;in, is the original pixel value, and are the minimum and maximum pixel values in the image, respectively; Feature extraction, flames usually have the characteristics of high brightness, high saturation and low blue channel value in color space. Therefore, this embodiment sets a color threshold to preliminarily screen out areas that may be flames. In the RGB color space, the following relationship can be used to extract suspected flame areas: ;in, It is The convolution kernels are located at The output at is the weight of the convolution kernel, is the pixel value of the input image, is the bias term; Image classification and recognition, this embodiment uses a deep convolutional neural network (CNN) as a classifier to classify and recognize the extracted features. The deep convolutional neural network has powerful feature extraction and classification capabilities and can adapt to flame detection under different environments and lighting conditions. The details are as follows: ;in, It is a sample Belongs to category The probability of It is The scores of the categories, is the total number of categories, when When it is greater than 0.9, an alarm is triggered.
[0040] In practical applications, the preprocessed image needs to be input into the trained CNN model, and the model will output a probability value, indicating the possibility that the image contains flames. When the probability value exceeds the set threshold, it can be considered that the image contains flames.
[0041] When the CNN model recognizes a flame, an alarm mechanism is triggered. The alarm methods can include sound alarm, light alarm, and SMS alarm, etc. The specific method is set according to actual needs.
[0042] At the same time, other equipment can be linked to respond, such as starting the fire protection system, notifying relevant personnel, etc., to minimize the losses caused by the fire.
[0043] The basic principles and main features of the present invention are described above. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The above embodiments and descriptions are only for illustrating the principles of the present invention. Without departing from the spirit and scope of the present invention, the present invention may have various changes and improvements, which shall fall within the scope of the present invention to be protected. The scope of protection of the invention shall be defined by the attached claims and their equivalents.
Claims
1. A computer image recognition method, characterized in that: Including image acquisition, image preprocessing, feature extraction, image classification and recognition, as well as alarm and linkage control modules; The image acquisition uses a multi-spectral camera to collect monitored images; The image preprocessing module preprocesses the input image, including image normalization and data enhancement operations, eliminates irrelevant information in the image, restores useful real information, simplifies data, and improves the reliability of feature extraction, wherein the irrelevant information includes noise information and background information in the image, and the useful information includes the target object in the image; The feature extraction extracts useful feature information from the preprocessed image, and the feature information includes color, texture, shape, and size, which are used for subsequent image classification and recognition; The image classification and recognition module uses a deep convolutional neural network as a classifier to classify and recognize images based on the extracted feature information to improve recognition accuracy and robustness; When the alarm and linkage control module identifies a preset dangerous target or abnormal behavior, it can automatically trigger an alarm and link the alarm to respond.
2. A computer image recognition method according to claim 1, characterized in that: The specific operation of feature extraction is as follows: ;in, It is The convolution kernels are located at The output at is the weight of the convolution kernel, is the pixel value of the image obtained after normalization operation, is the bias term; the feature is optimized using the gradient descent method: in, are model parameters, is the loss function, and the update formula of the gradient descent method is: ;in, is the learning rate, The loss function is The gradient at .
3. A computer image recognition method according to claim 1, characterized in that: In the image classification and recognition module, after feature extraction, the feature map is flattened into a one-dimensional vector and input into the fully connected layer. The fully connected layer performs linear transformation and nonlinear activation on the feature vector, and finally outputs the score of each category. After classification and recognition operations, it is judged whether it exceeds the preset dangerous target or abnormal behavior. When performing classification and recognition operations, a data category set is included, including a face data set, a vehicle data set, and an abnormal behavior data set. The face data set collects face key point detection and face feature extraction, the vehicle data set collects vehicle color, model, and license plate, and the abnormal behavior data set collects human posture estimation and action recognition. The calculation formula of the image classification and recognition module is as follows: ;in, It is a sample Belongs to category The probability of It is The scores of the categories, is the total number of categories, when When it is greater than 0.9, an alarm is triggered.
4. A computer image recognition method according to claim 3, characterized in that: The alarm modes include sound alarm, light alarm and text message alarm. The sound alarm emits an alarm sound to remind security personnel, the light alarm is a flashing warning light, and the text message alarm sends the alarm information to a designated mobile phone or mailbox.
5. A computer image recognition method according to claim 1, characterized in that: In the image preprocessing, the original pixels of the image are obtained , the minimum pixel of the image and the maximum pixel size of the image , and then perform image normalization and data enhancement operations. The formula for image normalization is as follows: ;in, is the original pixel value, and are the minimum and maximum pixel values in the image, respectively.
6. An electronic device, characterized in that: The method comprises a memory and a processor, wherein the memory stores a computer program, and the processor is used to run the computer program in the memory to execute the steps in the image recognition method according to any one of claims 1 to 5.
7. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a plurality of instructions, and the instructions are suitable for being loaded by a processor to execute the steps in the image recognition method according to any one of claims 1 to 5.
8. A computer program product comprising a computer program or instructions, characterized in that When the computer program or instruction is executed by a processor, the steps of the image recognition method according to any one of claims 1 to 5 are implemented.
Citation Information
Patent Citations
Tunnel crack image crack segmentation method, device and equipment and readable storage medium
CN118038056A
Stranded wire contact pin broken wire detection device and method
CN118777304A
Security and protection monitoring comprehensive early warning analysis system
CN118823987A
Nursing home intelligent behavior recognition and anomaly detection method based on deep learning
CN119007278A
Pollen monitoring method and device based on convolutional neural network, and convolutional neural network
CN119418194A