Positioning detection method and system for pinhole camera

By integrating laser emission module and multi-spectral camera unit on the mechanical motion platform, combining convolutional neural network model and coordinate calculation module, the pinhole camera detection has been solved in the existing technology with high false alarm rate, difficulty in detecting hidden cameras and detection range. Limited problems achieve efficient and accurate pinhole camera positioning detection.

CN119494877APending Publication Date: 2025-02-21ZHONGSHAN LIGHTWAVE TECH CO LTD
View PDF 0 Cites 4 Cited by

Patent Information

Application Number
CN202411521111.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-29
Publication Date
2025-02-21

AI Technical Summary

Technical Problem

The existing pinhole camera detection methods have problems such as high false alarm rate, difficulty in detecting hidden cameras, and limited detection range in complex scenarios.

Method used

The mechanical motion platform is used to integrate the laser emission module and multi-spectral camera unit, and the feature matrix is ​​generated through inter-frame differential calculation and multi-spectral data fusion, and the high-inverse area feature analysis and pinhole camera classification judgment are carried out by combining the convolutional neural network model, and the coordinates are used. The computing module achieves precise positioning.

Benefits of technology

It effectively reduces environmental noise interference, improves the accuracy and reliability of the detection system, and realizes accurate positioning of pinhole cameras and efficient detection in complex environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119494877A_ABST
    Figure CN119494877A_ABST
Patent Text Reader

Abstract

The invention discloses a pinhole camera positioning detection method and a pinhole camera positioning detection system, and the pinhole camera positioning detection method provided by the invention realizes mobile detection and covers multiple scenes by integrating a laser emission module and a multispectral camera unit on a mechanical motion platform. High-reflection area features are extracted through inter-frame difference calculation, ultraviolet, thermal imaging and near-infrared image data are aligned and fused, a unified feature matrix is generated, and interference of environmental noise is effectively reduced. A convolutional neural network model is utilized to analyze high-reflectivity region features, and a pinhole camera and other reflecting objects are accurately distinguished. And finally, the position of the detection target is normalized into a unified coordinate system through a coordinate calculation module, accurate positioning of the pinhole camera is realized, a detection result is transmitted to a control terminal in real time to trigger an alarm system, and it is ensured that the system can provide efficient and intelligent safety protection in a complex environment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of pinhole camera detection, and in particular, relates to a pinhole camera positioning detection method and system. Background Art

[0002] With the continuous development of information technology, miniature hidden camera equipment such as pinhole cameras are widely used in legal fields such as commercial monitoring and home care due to their small size and high concealment.

[0003] At present, the detection methods of pinhole cameras mainly rely on manual inspections or single-band detection equipment, such as manual detection using laser pointers and infrared cameras. However, these methods face many limitations in complex scenes. On the one hand, highly reflective objects such as glass and metal surfaces will produce strong reflection effects similar to those of pinhole cameras, causing the detection system to generate a large number of false alarms and reducing the accuracy of detection; on the other hand, many hidden cameras are designed to blend into the environment and are difficult to detect in low light or obscured conditions. In addition, traditional fixed detection systems can only cover a limited range and require manual adjustment of the position to scan a large area. This limitation makes it difficult to meet the detection needs in large spaces or complex environments.

[0004] In view of this, the present invention is proposed. Summary of the invention

[0005] The technical problem to be solved by the present invention is to overcome the deficiencies of the prior art and provide a positioning detection method and system for a pinhole camera, which solves the problems raised in the above-mentioned background technology.

[0006] In order to solve the above technical problems, the basic concept of the technical solution adopted by the present invention is:

[0007] A method for positioning a pinhole camera comprises the following steps:

[0008] S1: Set the detection path of the motion platform and install the laser emission module and multi-spectral camera unit on the platform;

[0009] S2: In the target area, the control unit drives the multispectral camera unit to obtain an initial image in a non-illuminated state, then starts the laser emission module for illumination, and simultaneously collects image data in an illuminated state;

[0010] S3: Perform inter-frame difference calculation on image data without illumination and with illumination, extract features of high-reflection areas, and align and fuse multispectral data from ultraviolet, thermal imaging and near-infrared to generate a unified feature matrix;

[0011] S4: Input the fused feature matrix into the convolutional neural network model, analyze the features of each high-reflection area, and classify and determine whether it is a pinhole camera;

[0012] S5: Calculate the spatial coordinates of the suspicious target based on the classification results, normalize the bright spot position at each moment into a unified coordinate system, confirm the existence of the pinhole camera, and transmit the results to the control terminal to trigger the alarm system.

[0013] Optionally, the steps of setting the detection path of the motion platform and installing the laser emission module and the multi-spectral camera unit on the platform are:

[0014] According to the structure of the detection area and the task requirements, first obtain the size, layout and obstacle information of the area, determine the accessible area and detour path; then clarify the location of the key areas of the detection task and mark these areas as detection sites; plan the path of the motion platform on the layout map and define the specific location of each site;

[0015] Input the movement sequence and stay time of the stations into the control system, and set the stay time of the platform at each station according to the task requirements; finally, verify the feasibility of the path through the system simulation function, adjust the path or station sequence, and upload the planned path to the control unit;

[0016] Fix the laser emission module on the bracket of the platform to ensure the stability of the emission head. According to the height of the platform and the range of the detection area, adjust the emission angle of the laser so that it can cover the target area and keep consistent with the viewing angle of the multi-spectral camera unit.

[0017] Optionally, in the target area, the control unit drives the multispectral camera unit to obtain an initial image in a non-illuminated state, then starts the laser emission module for illumination, and synchronously collects image data in an illuminated state in the following steps:

[0018] First, turn off the laser emission module, start the CCD camera, UV camera and thermal imaging module, and sequentially acquire images of each band without lighting according to the set sampling frequency, and record the timestamp of each frame. Then, send out a trigger signal, and the laser emission module will emit laser at the set power and angle, and continuously illuminate the target area to simulate a bright scene.

[0019] Under laser illumination, the control unit drives the CCD camera, UV camera, and thermal imaging module again to acquire images at the same sampling frequency and ensure that the collected multispectral data matches the timestamp;

[0020] All image data in the non-illumination state and the illumination state are stored in the data processing unit frame by frame, ensuring that each set of image data contains complete band information and time tags.

[0021] Optionally, the steps of performing inter-frame difference calculation on the image data without illumination and with illumination, extracting the features of the high-reflection area, and aligning and fusing the multispectral data from ultraviolet, thermal imaging and near-infrared to generate a unified feature matrix are as follows:

[0022] Read the non-illuminated image data collected at the same time point from the data storage unit I dark (x, y) and image data I with lighting status light (x, y), where x and y are pixel positions. Then, for each pair of image data without illumination and with illumination, the formula I is used pixel by pixel. diff (x, y) = I light (x, y)-I dark (x, y) calculates the brightness difference and generates the corresponding frame difference image I diff (x, y) to extract the high reflective area features in the scene. Then, the frame difference image I diff (x, y) is denoised using Gaussian filtering to remove errors caused by light changes and environmental noise. The expression is: G(i, j) is a two-dimensional Gaussian kernel, k is the window size, then, for the UV image I UV (x, y), thermal imaging image I Thermal (x, y) and near infrared image I NIR The (x, y) data are aligned in space and time dimensions, and the data of different bands are normalized to the same pixel coordinate system and time base. Finally, the aligned multispectral data are superimposed pixel by pixel to generate a unified feature matrix, which is expressed as: F(x, y) = [I′ UV (x, y), I′ Thermal (x, y), I′ NIR (x, y)], where I′ UV (x, y), I′ Thermal (x, y), I′ NIR (x, y) are the normalized ultraviolet image, thermal imaging image, and near-infrared image, respectively.

[0023] Optionally, before inputting the fused feature matrix into the convolutional neural network model, a convolutional neural network model needs to be constructed, wherein the steps of constructing the convolutional neural network model are:

[0024] From the multispectral feature matrix F(x, y) = [I′ UV , I′ Thermal , I′ NIR ] to extract 32×32×3 image blocks, where each image block corresponds to the ultraviolet, thermal imaging and near-infrared band data at a time point. All image blocks are organized into tensor format Where n is the number of samples. Next, normalize each pixel value and scale it to the range of [0, 1]. Then set the hierarchy of the convolutional neural network. The first convolution layer uses a convolution kernel size of 3×3, a step size of 1, and a padding method of SAME. The expression of the convolution operation is: Where W1 is the convolution kernel weight, b1 is the bias, (x, y) represents the pixel position, and then the convolution result is passed through the ReLU activation function ReLU(z)=max(0, z). Then, a 2×2 maximum pooling operation is performed on the convolution output with a step size of 2. The maximum value in each 2×2 area is used as the output to reduce the size of the feature map. The expression is Pooll(x, y)=max{Conv1(2x, 2y), Conv1(2x+1, 2y), Conv1(2x, 2y+1), Conv1(2x+1, 2y+1)};

[0025] Then, the convolution operation is continued on the maximum pooling result using a 3×3 convolution kernel, and the ReLU activation function is used again to perform the second maximum pooling on the convolution output to obtain a further compressed feature map. Subsequently, the feature map after the second pooling is flattened into a one-dimensional vector and input into the fully connected layer for calculation. The expression is: h = W3 Flatten (Pool2) + b3, where W3 is the weight of the fully connected layer and Flatten (·) represents the flattening operation; then, the output of the fully connected layer is passed through the Softmax activation function to calculate the probability of each category. Among them, z k is the score for category k. The model outputs the probabilities of the two categories, and then the cross entropy loss is calculated using the training dataset:

[0026] Among them, y i is the true label, To predict the probability, the model parameters are then updated using stochastic gradient descent: Among them, η is the learning rate. Finally, the model performance is evaluated on the validation set to check the classification accuracy;

[0027] Finally, the trained model is deployed to the detection system to analyze the multispectral feature matrix input in real time and output the classification results. When the model determines that it is a pinhole camera, the system will record the location and trigger an alarm.

[0028] Optionally, the steps of inputting the fused feature matrix into a convolutional neural network model, analyzing the features of each high-reflection area, and classifying and determining whether it is a pinhole camera are as follows:

[0029] The data blocks of each high-reflection area are extracted from the fused multispectral feature matrix and adjusted to 32×32×3 image blocks. Then, the 32×32×3 image blocks are input to the convolution layer. The convolution kernel slides gradually on the image to extract local features by superimposing the information of the pixel area. The convolution result is processed by the activation function, retaining positive features and ignoring negative values, extracting the structure and pattern of the image. Subsequently, the convolution feature map enters the pooling layer to reduce the size of the image and extract important features of the local area. Then, the feature map after multiple convolution and pooling operations is flattened into a one-dimensional vector and input into the fully connected layer. The fully connected layer converts these deep features into the input of the classification model. Finally, the flattened feature vector enters the classification layer. The model calculates the probability that each high-reflection area belongs to the "pinhole camera" or "non-pinhole camera" category. The system determines whether the target is a pinhole camera based on the probability result and outputs the classification result to the control system.

[0030] Optionally, the steps of calculating the spatial coordinates of the suspicious target according to the classification results, normalizing the bright spot position at each moment into a unified coordinate system, confirming the existence of the pinhole camera, and transmitting the results to the control terminal to trigger the alarm system are:

[0031] Extract the pixel coordinates (x) of the high-reflection area classified as a pinhole camera from the output of the convolutional neural network. i ,y i ) and its timestamp t i All detected bright spot positions are sorted in chronological order. i ,y i ) is converted to space coordinates (X i , Y i , Z i ), the 3D reconstruction is completed based on the platform position and the internal and external parameter matrix of the camera unit, which is expressed as: Among them, K is the camera internal parameter matrix, Pose t is the platform at time t i After completing the three-dimensional reconstruction of the internal and external parameter matrices, the pose matrix at different time points t i The bright spot position is aligned and normalized, converted to the same time reference and space coordinate system, and the relative displacement ΔX, ΔY, ΔZ of the bright spot is calculated, and the expression is: ΔX = X i+1 -X i , ΔY=Y i+1 -Y i , ΔZ=Z i+1 -Z i,Then, according to the normalized coordinate trajectory, the final position (X, Y, Z) of the bright spot in space is determined, and marked as the position of the pinhole camera, and the ,three-dimensional spatial coordinates are converted into visual marks on the layout diagram. ,Finally, the calculated spatial coordinates and detection time of the pinhole camera are uploaded to the control terminal, and the alarm system is triggered after the detection is confirmed.

[0032] A system for completing a positioning detection method of a pinhole camera, comprising:

[0033] A mechanical motion platform, used to move within the inspection area, carry the inspection equipment and perform path planning;

[0034] A laser emission module, mounted on the motion platform, for emitting near-infrared laser to illuminate the detection area;

[0035] A multispectral camera unit, including a CCD camera, an ultraviolet camera and a thermal imaging module, is used to collect multispectral image data of the target area;

[0036] A control unit, used to drive the motion platform, the multi-spectral camera unit and the laser emission module to work together and complete path planning and data collection;

[0037] Convolutional neural network model module, used to analyze the features of the collected images and classify and determine whether the target is a pinhole camera;

[0038] The data processing and coordinate calculation module is used to perform inter-frame difference calculation on image data without illumination and with illumination, extract the features of high-reflection areas, align and fuse multi-spectral data to generate a feature matrix, and calculate the spatial coordinates of the target;

[0039] The control terminal and the alarm system are used to receive the classification results. When the existence of a pinhole camera is confirmed, the alarm system is triggered and the detection results are recorded.

[0040] After adopting the above technical solution, the present invention has the following beneficial effects compared with the prior art. Of course, any product implementing the present invention does not necessarily need to achieve all the advantages described below at the same time:

[0041] The pinhole camera positioning detection method provided by the present invention realizes mobile detection and covers a variety of scenarios by integrating a laser emission module and a multi-spectral camera unit on a mechanical motion platform. The features of the high-reflection area are extracted through inter-frame difference calculation, and the ultraviolet, thermal imaging and near-infrared image data are aligned and fused to generate a unified feature matrix, which effectively reduces the interference of environmental noise. The convolutional neural network model is used to analyze the features of the high-reflection area to accurately distinguish the pinhole camera from other reflective objects. Finally, through the coordinate calculation module, the position of the detection target is normalized to a unified coordinate system, realizing the precise positioning of the pinhole camera, and the detection results are transmitted to the control terminal in real time to trigger the alarm system, ensuring that the system can provide efficient and intelligent security protection in complex environments.

[0042] The specific implementation modes of the present invention are further described in detail below with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] The drawings described below are only some embodiments. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.

[0044] In the figure:

[0045] Figure 1 The figure is a flow chart of the positioning detection method of a pinhole camera.

[0046] It should be noted that these drawings and textual descriptions are not intended to limit the conceptual scope of the present invention in any way, but are intended to illustrate the concept of the present invention for those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION

[0047] The present invention will now be described in further detail with reference to the accompanying drawings.

[0048] See also Figure 1 As shown, in this embodiment, a method for positioning and detecting a pinhole camera is provided, comprising the following steps:

[0049] S1: Set the detection path of the motion platform and install the laser emission module and multi-spectral camera unit on the platform; through reasonable planning of the detection path of the motion platform and equipment installation, the system can efficiently cover the detection area, avoid missing any corners, and improve the flexibility and adaptability of the detection process.

[0050] S2: In the target area, the control unit drives the multispectral camera unit to obtain the initial image in the non-illuminated state, then starts the laser emission module for illumination, and synchronously collects image data in the illuminated state; image data is collected in the non-illuminated and illuminated states to ensure that the multispectral camera unit can obtain complete optical information, laying the foundation for subsequent accurate detection of high-reflection areas.

[0051] S3: Perform inter-frame difference calculation on the image data in the unilluminated and illuminated states, extract the features of the high-reflection area, and align and fuse the multispectral data from ultraviolet, thermal imaging and near-infrared to generate a unified feature matrix; through inter-frame difference calculation and multispectral data fusion, effectively eliminate the interference of ambient light and noise, ensure that the features of the high-reflection area are clear and accurate, and improve the reliability of the detection system.

[0052] S4: Input the fused feature matrix into the convolutional neural network model, analyze the features of each high-reflective area, and classify and determine whether it is a pinhole camera; the convolutional neural network model accurately distinguishes pinhole cameras from other high-reflective objects through deep feature analysis, reduces the false alarm rate, and ensures the classification performance of the system in complex environments.

[0053] S5: Calculate the spatial coordinates of the suspicious target based on the classification results, normalize the bright spot position at each moment into a unified coordinate system, confirm the existence of the pinhole camera, and transmit the results to the control terminal to trigger the alarm system. By calculating and normalizing the spatial coordinates of the bright spot position, the pinhole camera is accurately positioned, and the detection results can be transmitted to the control terminal in real time to trigger the alarm system, improving the efficiency and intelligence level of overall security protection.

[0054] The pinhole camera positioning detection method provided by the present invention realizes mobile detection and covers a variety of scenarios by integrating a laser emission module and a multi-spectral camera unit on a mechanical motion platform. The features of the high-reflection area are extracted through inter-frame difference calculation, and the ultraviolet, thermal imaging and near-infrared image data are aligned and fused to generate a unified feature matrix, which effectively reduces the interference of environmental noise. The convolutional neural network model is used to analyze the features of the high-reflection area to accurately distinguish the pinhole camera from other reflective objects. Finally, through the coordinate calculation module, the position of the detection target is normalized to a unified coordinate system, realizing the precise positioning of the pinhole camera, and the detection results are transmitted to the control terminal in real time to trigger the alarm system, ensuring that the system can provide efficient and intelligent security protection in complex environments.

[0055] In this embodiment, the steps of setting the detection path of the motion platform and installing the laser emission module and the multi-spectral camera unit on the platform are as follows:

[0056] According to the structure of the detection area and the task requirements, first obtain the size, layout and obstacle information of the area, determine the accessible area and detour path; then clarify the location of the key areas of the detection task and mark these areas as detection sites; plan the path of the motion platform on the layout map and define the specific location of each site;

[0057] Input the movement sequence and stay time of the stations into the control system, and set the stay time of the platform at each station according to the task requirements; finally, verify the feasibility of the path through the system simulation function, adjust the path or station sequence, and upload the planned path to the control unit;

[0058] Fix the laser emission module on the bracket of the platform to ensure the stability of the emission head. According to the height of the platform and the range of the detection area, adjust the emission angle of the laser so that it can cover the target area and be consistent with the viewing angle of the multi-spectral camera unit. By rationally planning the path of the motion platform, accurately installing the laser emission module and the multi-spectral camera unit, and collecting complete multi-spectral image data in both unlit and illuminated states, this embodiment can ensure that the detection system covers all key areas and high-risk locations, and achieve multi-angle acquisition and precise detection. By recording the timestamp of each frame of the image and ensuring data synchronization, the system can capture detailed information of high-reflection areas under different lighting conditions, providing an accurate and comprehensive basis for subsequent data analysis.

[0059] In this embodiment, within the target area, the control unit drives the multispectral camera unit to obtain an initial image in a non-illuminated state, then starts the laser emission module for illumination, and synchronously collects image data in an illuminated state in the following steps:

[0060] First, turn off the laser emission module, start the CCD camera, UV camera and thermal imaging module, and sequentially acquire images of each band without lighting according to the set sampling frequency, and record the timestamp of each frame. Then, send out a trigger signal, and the laser emission module will emit laser at the set power and angle, and continuously illuminate the target area to simulate a bright scene.

[0061] Under laser illumination, the control unit drives the CCD camera, UV camera, and thermal imaging module again to acquire images at the same sampling frequency and ensure that the collected multispectral data matches the timestamp;

[0062] All image data in the non-illumination state and the illumination state are stored in the data processing unit frame by frame, ensuring that each set of image data contains complete band information and time tags.

[0063] In this embodiment, the steps of performing inter-frame difference calculation on image data in the non-illuminated and illuminated states, extracting high-reflection area features, and aligning and fusing multispectral data from ultraviolet, thermal imaging, and near-infrared to generate a unified feature matrix are as follows:

[0064] Read the non-illuminated image data collected at the same time point from the data storage unit I dark (x, y) and image data I with lighting status light (x, y), where x and y are pixel positions. Then, for each pair of image data without illumination and with illumination, the formula I is used pixel by pixel. diff (x, y) = I light (x, y)-I dark (x, y) calculates the brightness difference and generates the corresponding frame difference image I diff (x, y) to extract the high reflective area features in the scene. Then, the frame difference image I diff (x, y) is denoised using Gaussian filtering to remove errors caused by light changes and environmental noise. The expression is: G(i, j) is a two-dimensional Gaussian kernel, k is the window size, then, for the UV image I UV (x, y), thermal imaging image I Thermal (x, y) and near infrared image I NIR The (x, y) data are aligned in space and time dimensions, and the data of different bands are normalized to the same pixel coordinate system and time base. Finally, the aligned multispectral data are superimposed pixel by pixel to generate a unified feature matrix, which is expressed as: F(x, y) = [I′ UV (x, y), I′ Therma1 (x, y), I′ NIR (x, y)], where I′ UV (x, y), I′ Thermal (x, y), I′ NIR (x, y) are the normalized ultraviolet image, thermal imaging image, and near-infrared image, respectively. By reading the image data in the unilluminated and illuminated states at the same time point, the brightness difference is calculated pixel by pixel to generate a frame difference image, accurately extract the features of the high-reflection area, and effectively reduce interference factors. By using Gaussian filtering to denoise the frame difference image, the influence of light changes and environmental noise on the detection results is further eliminated. Subsequently, the ultraviolet, thermal imaging, and near-infrared band data are aligned in spatial and temporal dimensions, and the data of different bands are normalized to the same pixel coordinate system and time reference. Finally, by superimposing the aligned multispectral data by pixel, a unified feature matrix is ​​generated to provide consistent and complete feature data for the subsequent convolutional neural network model analysis, thereby improving the detection accuracy and reliability of the system.

[0065] In this embodiment, before the fused feature matrix is ​​input into the convolutional neural network model, a convolutional neural network model needs to be constructed, wherein the steps of constructing the convolutional neural network model are:

[0066] From the multispectral feature matrix F(x, y) = [I′ UV , I′ Thermal , I′ NIR ] to extract 32×32×3 image blocks, where each image block corresponds to the ultraviolet, thermal imaging and near-infrared band data at a time point. All image blocks are organized into tensor format Where n is the number of samples. Next, normalize each pixel value and scale it to the range of [0, 1]. Then set the hierarchy of the convolutional neural network. The first convolution layer uses a convolution kernel size of 3×3, a step size of 1, and a padding method of SAME. The expression of the convolution operation is: Where W1 is the convolution kernel weight, b1 is the bias, (x, y) represents the pixel position, and then the convolution result is passed through the ReLU activation function ReLU(z)=max(0, z). Then, a 2×2 maximum pooling operation is performed on the convolution output with a step size of 2. The maximum value in each 2×2 area is used as the output to reduce the size of the feature map. The expression is Pooll(x, y)=max{Conv1(2x, 2y), Conv1(2x+1, 2y), Conv1(2x, 2y+1), Conv1(2x+1, 2y+1)};

[0067] Then, the convolution operation is continued on the maximum pooling result using a 3×3 convolution kernel, and the ReLU activation function is used again to perform the second maximum pooling on the convolution output to obtain a further compressed feature map. Subsequently, the feature map after the second pooling is flattened into a one-dimensional vector and input into the fully connected layer for calculation. The expression is: h = W3 Flatten (Pool2) + b3, where W3 is the weight of the fully connected layer and Flatten (·) represents the flattening operation; then, the output of the fully connected layer is passed through the Softmax activation function to calculate the probability of each category. Among them, z k is the score for category k. The model outputs the probabilities of the two categories, and then the cross entropy loss is calculated using the training dataset:

[0068] Among them, y i is the true label, To predict the probability, the model parameters are then updated using stochastic gradient descent: Among them, η is the learning rate. Finally, the model performance is evaluated on the validation set to check the classification accuracy;

[0069] Finally, the trained model is deployed to the detection system to analyze the multispectral feature matrix input in real time and output the classification results. When the model determines that it is a pinhole camera, the system will record the location and trigger an alarm. By extracting image blocks from the multispectral feature matrix, the data is organized into tensor format and normalized to ensure that data from different bands are analyzed at the same scale. The hierarchical structure of the convolutional neural network is set up, and the local features of the image are extracted layer by layer through the convolution layer. The maximum pooling operation is used to reduce the size of the feature map, retain key information, and reduce the amount of calculation. After multiple convolution and pooling operations, the features are flattened into a one-dimensional vector and input into the fully connected layer for deep calculation to ensure that the system can capture the complex features of the high-reflection area. The Softmax layer outputs the category probability to achieve accurate classification of pinhole cameras and non-camera targets. The cross entropy loss and stochastic gradient descent method are used to optimize the model to improve the training effect of the model. The deployed model can be used to analyze the input data in real time. When a pinhole camera is detected, the system will immediately record its location and trigger an alarm to ensure a rapid response and timely protection against privacy threats.

[0070] In this embodiment, the steps of inputting the fused feature matrix into the convolutional neural network model, analyzing the features of each high-reflection area, and classifying and determining whether it is a pinhole camera are as follows:

[0071] The data blocks of each high-reflection area are extracted from the fused multispectral feature matrix and adjusted to 32×32×3 image blocks. Then, the 32×32×3 image blocks are input to the convolution layer. The convolution kernel slides gradually on the image to extract local features by superimposing the information of the pixel area. The convolution result is processed by the activation function, retaining positive features and ignoring negative values, extracting the structure and pattern of the image. Subsequently, the convolution feature map enters the pooling layer to reduce the size of the image and extract important features of the local area. Then, the feature map after multiple convolution and pooling operations is flattened into a one-dimensional vector and input into the fully connected layer. The fully connected layer converts these deep features into the input of the classification model. Finally, the flattened feature vector enters the classification layer. The model calculates the probability that each high-reflection area belongs to the "pinhole camera" or "non-pinhole camera" category. The system determines whether the target is a pinhole camera based on the probability result and outputs the classification result to the control system.

[0072] In this embodiment, the steps of calculating the spatial coordinates of the suspicious target according to the classification results, normalizing the bright spot position at each moment to a unified coordinate system, confirming the existence of the pinhole camera, and transmitting the results to the control terminal to trigger the alarm system are as follows:

[0073] Extract the pixel coordinates (x) of the high-reflection area classified as a pinhole camera from the output of the convolutional neural network. i ,y i ) and its timestamp ti All detected bright spot positions are sorted in chronological order. i ,y i ) is converted to space coordinates (X i , Y i , Z i ), the three-dimensional reconstruction is completed based on the platform position and the internal and external parameter matrix of the camera unit, which is expressed as: Among them, K is the camera internal parameter matrix, Pose t is the platform at time t i After completing the three-dimensional reconstruction of the internal and external parameter matrices, the pose matrix at different time points t i The bright spot position is aligned and normalized, converted to the same time reference and space coordinate system, and the relative displacement ΔX, ΔY, ΔZ of the bright spot is calculated, and the expression is: ΔX = X i+1 -X i , ΔY=Y i+1 -Y i , ΔZ=Z i+1 -Z i Then, according to the normalized coordinate trajectory, the final position (X, Y, Z) of the bright spot in space is determined, and it is marked as the position of the pinhole camera, and the three-dimensional spatial coordinates are converted into visual marks on the layout diagram. Finally, the calculated spatial coordinates and detection time of the pinhole camera are uploaded to the control terminal, and the alarm system is triggered after the detection is confirmed. This embodiment realizes the accurate tracking of the target in the time dimension by extracting the pixel coordinates and timestamps of the high-reflective area classified as the pinhole camera from the output results of the convolutional neural network. The pixel coordinates are converted into spatial coordinates, and three-dimensional reconstruction is performed based on the platform position and the internal and external parameter matrix of the camera unit to ensure that the system can accurately restore the position of the target in the real world. The coordinates of the bright spot positions at different time points are aligned and normalized to ensure the accuracy of the data in the same time reference and coordinate system, and the target position changes are dynamically captured by relative displacement calculation. The system marks the position of the pinhole camera according to the normalized coordinate trajectory and maps it to the layout diagram or map for visualization. Finally, the detection results are uploaded to the control terminal, and the alarm system is triggered after the pinhole camera is confirmed to be found, so as to realize the rapid positioning and timely response to illegal devices and ensure the privacy and security of users.

[0074] A system for completing a positioning detection method of a pinhole camera, comprising:

[0075] A mechanical motion platform, used to move within the inspection area, carry the inspection equipment and perform path planning;

[0076] A laser emission module, mounted on the motion platform, for emitting near-infrared laser to illuminate the detection area;

[0077] A multispectral camera unit, including a CCD camera, an ultraviolet camera and a thermal imaging module, is used to collect multispectral image data of the target area;

[0078] A control unit, used to drive the motion platform, the multi-spectral camera unit and the laser emission module to work together and complete path planning and data collection;

[0079] Convolutional neural network model module, used to analyze the features of the collected images and classify and determine whether the target is a pinhole camera;

[0080] The data processing and coordinate calculation module is used to perform inter-frame difference calculation on image data without illumination and with illumination, extract the features of high-reflection areas, align and fuse multi-spectral data to generate a feature matrix, and calculate the spatial coordinates of the target;

[0081] The control terminal and the alarm system are used to receive the classification results. When the existence of a pinhole camera is confirmed, the alarm system is triggered and the detection results are recorded.

[0082] The present invention is not limited to the above-mentioned embodiments. Anyone should be aware that any structural changes made under the enlightenment of the present invention, and any technical solutions that are the same or similar to the present invention, fall within the protection scope of the present invention. The technology, shape, and structural parts not described in detail in the present invention are all well-known technologies.

Claims

1. A pinhole camera positioning detection method, characterized in that: The following steps are involved: S1: Set the detection path of the motion platform and install the laser emission module and multi-spectral camera unit on the platform; S2: In the target area, the control unit drives the multispectral camera unit to obtain an initial image in a non-illuminated state, then starts the laser emission module for illumination, and simultaneously collects image data in an illuminated state; S3: Perform inter-frame difference calculation on image data without illumination and with illumination, extract features of high-reflection areas, and align and fuse multispectral data from ultraviolet, thermal imaging and near-infrared to generate a unified feature matrix; S4: Input the fused feature matrix into the convolutional neural network model, analyze the features of each high-reflection area, and classify and determine whether it is a pinhole camera; S5: Calculate the spatial coordinates of the suspicious target based on the classification results, normalize the bright spot position at each moment into a unified coordinate system, confirm the existence of the pinhole camera, and transmit the results to the control terminal to trigger the alarm system.

2. The method for positioning a pinhole camera according to claim 1, characterized in that: The steps for setting the detection path of the motion platform and installing the laser emission module and the multi-spectral camera unit on the platform are as follows: According to the structure of the detection area and the task requirements, first obtain the size, layout and obstacle information of the area, determine the accessible area and detour path; then clarify the location of the key areas of the detection task and mark these areas as detection sites; plan the path of the motion platform on the layout map and define the specific location of each site; Input the movement sequence and stay time of the stations into the control system, and set the stay time of the platform at each station according to the task requirements; finally, verify the feasibility of the path through the system simulation function, adjust the path or station sequence, and upload the planned path to the control unit; Fix the laser emission module on the bracket of the platform to ensure the stability of the emission head. According to the height of the platform and the range of the detection area, adjust the emission angle of the laser so that it can cover the target area and be consistent with the viewing angle of the multi-spectral camera unit.

3. The method for positioning a pinhole camera according to claim 1, characterized in that: In the target area, the control unit drives the multispectral camera unit to obtain an initial image in a non-illuminated state, then starts the laser emission module for illumination, and synchronously collects image data in an illuminated state in the following steps: First, turn off the laser emission module, start the CCD camera, UV camera and thermal imaging module, and sequentially acquire images of each band without lighting according to the set sampling frequency, and record the timestamp of each frame. Then, send out a trigger signal, and the laser emission module will emit laser at the set power and angle, and continuously illuminate the target area to simulate a bright scene. Under laser illumination, the control unit drives the CCD camera, UV camera, and thermal imaging module again to acquire images at the same sampling frequency and ensure that the collected multispectral data matches the timestamp; All image data in the non-illumination state and the illumination state are stored in the data processing unit frame by frame, ensuring that each set of image data contains complete band information and time tags.

4. The method for positioning a pinhole camera according to claim 1, characterized in that: The steps of performing inter-frame difference calculation on image data without illumination and with illumination, extracting features of high-reflection areas, and aligning and fusing multispectral data from ultraviolet, thermal imaging, and near-infrared to generate a unified feature matrix are as follows: Read the non-illuminated image data collected at the same time point from the data storage unit I dark (x, y) and image data I with lighting status light (x, y), where x and y are pixel positions. Then, for each pair of image data without illumination and with illumination, the formula I is used pixel by pixel. diff (x, y) = I light (x, y)-I dark (x, y) calculates the brightness difference and generates the corresponding frame difference image I diff (x, y) to extract the high reflective area features in the scene. Then, the frame difference image I diff (x, y) is denoised using Gaussian filtering to remove errors caused by light changes and environmental noise. The expression is: G(i, j) is a two-dimensional Gaussian kernel, k is the window size, then, for the UV image I UV (x, y), thermal imaging image I Thermal (x, y) and near infrared image I NIR The (x, y) data are aligned in space and time dimensions, and the data of different bands are normalized to the same pixel coordinate system and time base. Finally, the aligned multispectral data are superimposed pixel by pixel to generate a unified feature matrix, which is expressed as: F(x, y) = [I′ UV (x, y), I′ Thermal (x, y), I′ NIR (x, y)], where I′ UV (x, y), I′ Thermal (x, y), I′ NIR (x, y) are the normalized ultraviolet image, thermal imaging image, and near-infrared image, respectively.

5. The method for positioning a pinhole camera according to claim 1, characterized in that: Before inputting the fused feature matrix into the convolutional neural network model, it is necessary to build a convolutional neural network model. The steps of building the convolutional neural network model are: From the multispectral feature matrix F(x, y) = [I′ UV , I′ Thermal , I′ NIR ] to extract 32×32×3 image blocks, where each image block corresponds to the ultraviolet, thermal imaging and near-infrared band data at a time point, and all image blocks are organized into tensor format Where n is the number of samples. Next, each pixel value is normalized and scaled to [ 0 , 1 ] range, and then set the hierarchy of the convolutional neural network. The first convolution layer uses a convolution kernel size of 3×3 , the step size is 1, the filling method is SAME, and the expression of the convolution operation is: Where W1 is the convolution kernel weight, b1 is the bias, (x, y) represents the pixel position, and then the convolution result is passed through the ReLU activation function ReLU(z)=max(0, z). Then, a 2×2 maximum pooling operation is performed on the convolution output with a step size of 2. The maximum value in each 2×2 area is used as the output to reduce the size of the feature map. The expression is Pooll(x, y)=max{Conv1(2x, 2y), Conv1(2x+1, 2y), Conv1(2x, 2y+1), Conv1(2x+1, 2y+1)}; Then, the convolution operation is continued on the maximum pooling result using a 3×3 convolution kernel, and the ReLU activation function is used again to perform the second maximum pooling on the convolution output to obtain a further compressed feature map. Subsequently, the feature map after the second pooling is flattened into a one-dimensional vector and input into the fully connected layer for calculation. The expression is: h = W3 Flatten (Pool2) + b3, where W3 is the weight of the fully connected layer and Flatten (·) represents the flattening operation; then, the output of the fully connected layer is passed through the Softmax activation function to calculate the probability of each category. Among them, z k is the score for category k, the model outputs the probabilities of the two categories, and then the cross entropy loss is calculated using the training dataset: Among them, y i is the true label, To predict the probability, the model parameters are then updated using stochastic gradient descent: Among them, η is the learning rate. Finally, the model performance is evaluated on the validation set to check the classification accuracy; Finally, the trained model is deployed into the detection system to analyze the multispectral feature matrix input in real time and output the classification results. When the model determines that it is a pinhole camera, the system will record the location and trigger an alarm.

6. A pinhole camera positioning detection method according to claim 5, characterized in that: The fused feature matrix is ​​input into the convolutional neural network model to analyze the features of each high-reflection area and classify and determine whether it is a pinhole camera. The steps are as follows: The data block of each high-reflection area is extracted from the fused multi-spectral feature matrix and adjusted to a 32×32×3 image block. The 32×32×3 image block is then input into the convolution layer. The convolution kernel slides gradually on the image to extract local features by superimposing the information of the pixel area. The convolution result is processed by the activation function to retain positive features and ignore negative values, and extract the structure and pattern of the image. Subsequently, the convolved feature map enters the pooling layer for processing to reduce the size of the image and extract important features of the local area. Then, the feature map after multiple convolution and pooling operations is flattened into a one-dimensional vector and input into the fully connected layer. The fully connected layer converts these deep features into the input of the classification model. Finally, the flattened feature vector enters the classification layer. The model calculates the probability that each high-reflection area belongs to the "pinhole camera" or "non-pinhole camera" category. The system determines whether the target is a pinhole camera based on the probability result and outputs the classification result to the control system.

7. A pinhole camera positioning detection method according to claim 6, characterized in that: The steps of calculating the spatial coordinates of the suspicious target based on the classification results, normalizing the bright spot position at each moment to a unified coordinate system, confirming the existence of the pinhole camera, and transmitting the results to the control terminal to trigger the alarm system are as follows: Extract the pixel coordinates (x) of the high-reflection area classified as a pinhole camera from the output of the convolutional neural network. i ,y i ) and its timestamp t i , all detected bright spot positions are sorted in chronological order, and each pixel coordinate (x i ,y i ) is converted to space coordinates (X i , Y i , Z i ), the 3D reconstruction is completed based on the platform position and the internal and external parameter matrix of the camera unit, which is expressed as: Among them, K is the camera internal parameter matrix, Pose t is the platform at time t i After completing the three-dimensional reconstruction of the internal and external parameter matrices, the pose matrix at different time points t i The bright spot position is aligned and normalized, converted to the same time reference and space coordinate system, and the relative displacement ΔX, ΔY, ΔZ of the bright spot is calculated, and the expression is: ΔX=X i+1 -X i , ΔY=Y i+1 -Y i , ΔZ=Z i+1 -Z i ,Then, according to the normalized coordinate trajectory, the final position (X, Y, Z) of the bright spot in space is determined, and marked as the position of the pinhole camera, and the ,three-dimensional spatial coordinates are converted into visual marks on the layout diagram. ,Finally, the calculated spatial coordinates and detection time of the pinhole camera are uploaded to the control terminal, and the alarm system is triggered after the detection is confirmed.

8. A system for implementing the positioning detection method of a pinhole camera according to any one of claims 1 to 7, characterized in that: include: A mechanical motion platform, used to move within the inspection area, carry the inspection equipment and perform path planning; A laser emission module, mounted on the motion platform, for emitting near-infrared laser to illuminate the detection area; A multispectral camera unit, including a CCD camera, an ultraviolet camera and a thermal imaging module, is used to collect multispectral image data of the target area; A control unit, used to drive the motion platform, the multi-spectral camera unit and the laser emission module to work together and complete path planning and data collection; Convolutional neural network model module, used to analyze the features of the collected images and classify and determine whether the target is a pinhole camera; The data processing and coordinate calculation module is used to perform inter-frame difference calculation on image data without illumination and with illumination, extract the features of high-reflection areas, align and fuse multi-spectral data to generate a feature matrix, and calculate the spatial coordinates of the target; The control terminal and the alarm system are used to receive the classification results. When the existence of a pinhole camera is confirmed, the alarm system is triggered and the detection results are recorded.

Citation Information

Cited By

  • Subway protection area illegal construction identification and detection method based on image identification

    CN119904754A

  • Hidden camera positioning method and system based on infrared detection equipment and medium

    CN121033173A

  • Hidden camera positioning method and system based on infrared detection device and medium

    CN121033173B

  • Pinhole camera detection method and device, electronic equipment and storage medium

    CN121329882A