Urban lighting fault positioning method and device
By analyzing images of the lighting areas of urban lighting equipment, filtering out abnormal pixels and regions, and calculating anomaly evaluation coefficients, the problem of untimely fault location in existing technologies is solved, enabling rapid and accurate fault location and reducing maintenance costs.
Patent Information
- Application Number
- CN202510525790.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-25
- Publication Date
- 2025-11-25
- Estimated Expiration
- 2045-04-25
AI Technical Summary
Existing methods for locating faults in urban energy-saving lighting equipment lack sensitivity to minute anomalies, leading to untimely fault location and impacting traffic and public safety.
By acquiring images of the illuminated area, fault analysis is performed, abnormal pixels and regions are screened, anomaly evaluation coefficients are calculated, abnormal lighting equipment is identified, and its location information is obtained for localization.
It enables rapid and accurate fault location, reduces the consumption of human and material resources, lowers maintenance costs, and improves the efficiency of fault detection and location.
Smart Images

Figure CN120352111B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of urban lighting fault location, and in particular to a method and apparatus for urban lighting fault location. Background Technology
[0002] In today's rapidly urbanizing world, energy-saving lighting equipment is an important part of urban infrastructure. Its stable and reliable operation is of great significance for ensuring traffic safety, enhancing the city's image, and promoting the prosperity of the nighttime economy.
[0003] However, in urban energy-saving lighting systems, the sheer number and wide distribution of energy-saving lighting equipment make timely and accurate fault location a significant challenge for urban lighting management. Traditional methods for locating faults in urban energy-saving lighting equipment have many limitations, relying primarily on manual inspections and simple fault alarm systems, which can only detect faults with relatively obvious anomalies, such as continuous flickering of urban energy-saving lighting equipment. While these faults are conspicuous, they are often the result of the accumulation of minor fault states in the urban energy-saving lighting equipment. In fact, urban energy-saving lighting equipment typically undergoes a series of minor anomalies before malfunctioning. If these minor anomalies can be detected and addressed in a timely manner, preventative maintenance can be carried out before a true fault occurs, avoiding adverse effects on traffic and public safety. However, most current detection schemes lack sensitivity and detection strategies for minor anomalies, leaving street light maintenance and management often in a reactive state.
[0004] Therefore, there is an urgent need for a method and device for locating urban lighting faults to solve the above problems. Summary of the Invention
[0005] The present invention aims to at least partially solve one of the technical problems in the aforementioned technologies. Therefore, a first aspect of the present invention aims to provide a method for locating urban lighting faults, which analyzes faults based on images of the lighting area to visually detect minor anomalies in lighting equipment, enabling preventative maintenance before a fault actually occurs and avoiding adverse effects on traffic and public safety.
[0006] A second objective of the present invention is to provide a fault location device for urban lighting.
[0007] To achieve the above objectives, a first aspect of the present invention provides a method for locating urban lighting faults, comprising:
[0008] Acquire images of the illuminated areas of several lighting devices within the city;
[0009] Fault analysis of several lighting devices is performed based on images of the lighting area to identify abnormal lighting devices;
[0010] Obtain the location information of abnormal lighting equipment;
[0011] The fault location of lighting equipment is completed based on the location information of abnormal lighting equipment.
[0012] Preferably, it also includes: numbering several lighting devices in the urban lighting area and determining the location information of each lighting device.
[0013] Preferably, fault analysis is performed on several lighting devices based on image data of the lighting area to identify abnormal lighting devices, including:
[0014] Choose any lighting device as the target lighting device; obtain a temporal image of the lighting area of the target lighting device;
[0015] The time-domain image is decomposed to obtain an image dataset of the illumination area of the target lighting device;
[0016] Randomly select one illuminated region image from the illuminated region image dataset as the target image;
[0017] The target image is filtered for abnormal pixels to obtain a number of initial abnormal pixels;
[0018] Obtain a reference image of the illumination area of the target lighting device; the pixels in the reference image correspond one-to-one with the pixels in the target image;
[0019] Based on the baseline image, several initial abnormal pixels are filtered to obtain several target abnormal pixels;
[0020] Based on a number of abnormal target pixels, determine a number of abnormal target regions;
[0021] The anomaly evaluation coefficient of the target lighting equipment is determined based on several target anomaly areas;
[0022] Iterate through all lighting equipment and determine the anomaly evaluation coefficient for each piece of lighting equipment;
[0023] The abnormal evaluation coefficient is compared with the preset abnormal evaluation threshold. When the abnormal evaluation coefficient is greater than or equal to the preset abnormal evaluation threshold, the lighting device is identified as an abnormal lighting device.
[0024] Preferably, the target image is screened for abnormal pixels to obtain several initial abnormal pixels, including:
[0025] The target image is processed to obtain a grayscale image;
[0026] Obtain the grayscale value of each pixel in a grayscale image;
[0027] Choose any pixel as the target pixel;
[0028] The first target region is determined with the target pixel as the center and a preset distance as the radius.
[0029] Calculate the average gray value of each pixel in the first target region to obtain the first average gray value;
[0030] Calculate the difference between the gray value of the target pixel and the first gray value mean to obtain the first difference;
[0031] The first difference is compared with a first preset difference threshold. When it is determined that the first difference is greater than or equal to the first preset difference threshold, the target pixel is taken as the initial abnormal pixel.
[0032] Preferably, based on a reference image, several initial anomalous pixels are filtered to obtain several target anomalous pixels, including:
[0033] Calculate the grayscale difference between the initial abnormal pixel and the corresponding pixel in the reference image to obtain the second difference;
[0034] The second difference is compared with the second preset difference threshold. When it is determined that the second difference is greater than or equal to the second preset difference threshold, the initial abnormal pixel is taken as the target abnormal pixel.
[0035] Traverse all initial abnormal pixels to obtain a number of target abnormal pixels.
[0036] Preferably, based on several target anomalous pixels, several target anomalous regions are determined, including:
[0037] Cluster the aforementioned target abnormal pixels to obtain several initial abnormal regions;
[0038] Obtain the minimum bounding rectangle of several initial abnormal regions, and then obtain several minimum bounding rectangles;
[0039] Choose any initial abnormal region as the first region;
[0040] Count the number of pixels in the smallest bounding rectangle corresponding to the first region to obtain the first count;
[0041] The number of abnormal target pixels in the smallest bounding rectangle corresponding to the first region is counted to obtain the second count.
[0042] The third number is obtained by counting the number of pixels outside the smallest bounding rectangle corresponding to the first region.
[0043] The fourth count is obtained by counting the number of abnormal target pixels outside the smallest bounding rectangle corresponding to the first region.
[0044] Calculate the difference between the first quantity and the second quantity to obtain the third difference;
[0045] Calculate the difference between the third and fourth quantities to obtain the fourth difference;
[0046] Calculate the absolute value of the difference between the third and fourth differences, and use it as the anomaly evaluation value for the first region;
[0047] Traverse all initial abnormal regions to obtain the abnormality evaluation value corresponding to each initial abnormal region;
[0048] The abnormal evaluation value is compared with a preset abnormal evaluation threshold. When the abnormal evaluation value is determined to be greater than or equal to the preset abnormal evaluation threshold, the initial abnormal region is taken as the target abnormal region, and several target abnormal regions are obtained.
[0049] Preferably, the anomaly evaluation coefficient of the target lighting equipment is determined based on several target anomaly areas, including:
[0050] Obtain the total number of pixels in several target abnormal regions to get the fifth quantity;
[0051] Obtain the total number of all pixels in the target image to get the sixth quantity;
[0052] The ratio of the fifth quantity to the sixth quantity is used as the anomaly coefficient corresponding to the target image;
[0053] Traverse all images in the illuminated area image dataset, determine the anomaly coefficient corresponding to each illuminated area image, and obtain the anomaly coefficient dataset corresponding to the illuminated area image dataset.
[0054] The mean of the anomaly coefficient dataset is evaluated to determine the anomaly evaluation coefficient of the target lighting equipment.
[0055] Preferably, before performing fault analysis on several lighting devices based on the lighting area image, the method further includes enhancing the lighting area image.
[0056] Preferably, enhancing the image of the illuminated area includes:
[0057] Select any image of the illuminated area;
[0058] Obtain the grayscale value of each pixel in the image of the illuminated area;
[0059] Select any pixel from the grayscale image as the first target pixel;
[0060] The second target region is determined with the target pixel as the center and a preset distance as the radius.
[0061] Select any pixel in the second target region as the second target pixel;
[0062] Calculate the grayscale difference between the second target pixel and other pixels in the second target region to obtain several difference values;
[0063] The summation of several differences and the average value are used as the grayscale evaluation value of the second target pixel.
[0064] Iterate through all pixels in the second target region to obtain the grayscale evaluation value corresponding to each pixel;
[0065] Calculate the absolute value of the difference between the grayscale evaluation values corresponding to any two pixels to obtain several absolute values; sum the several absolute values as the feature value of the first target pixel;
[0066] Iterate through all pixels in the grayscale image to obtain the feature value corresponding to each pixel in the grayscale image;
[0067] Calculate the absolute value of the difference between the feature values corresponding to any two adjacent pixels in a grayscale image to obtain several absolute feature differences;
[0068] The absolute feature difference is compared with a preset absolute feature difference threshold. Two pixels whose absolute feature difference is less than or equal to the preset absolute feature difference threshold are grouped into one category, resulting in a number of pixel classifications.
[0069] Several image regions are determined based on the classification of several pixels;
[0070] Calculate the grayscale enhancement coefficient for each image region;
[0071] The pixels of each image region are enhanced based on the gray-level enhancement coefficient corresponding to each image region, resulting in an enhanced illuminated area image.
[0072] Traverse all the illuminated area images to obtain the enhanced illuminated area images.
[0073] To achieve the above objectives, a second aspect of the present invention provides an urban lighting fault location device, comprising:
[0074] The first acquisition module is used to acquire images of the lighting areas of several lighting devices;
[0075] The analysis module is used to perform fault analysis on several lighting devices based on the lighting area image to identify abnormal lighting devices;
[0076] The second acquisition module is used to acquire the location information of abnormal lighting devices;
[0077] The positioning module is used to locate lighting equipment faults based on the location information of abnormal lighting equipment.
[0078] This invention provides a method and apparatus for locating urban lighting faults. Utilizing image analysis technology, it can simultaneously process images of the lighting areas of several lighting devices. This allows for rapid screening of abnormal lighting equipment from a large pool, significantly reducing fault location time, improving work efficiency, and ensuring faults are detected and located in the shortest possible time, thus reducing the duration of urban lighting faults. Fault analysis based on lighting area images overcomes the limitations of relying solely on electrical parameters for fault diagnosis. It can intuitively detect various micro-anomalies in lighting equipment. By analyzing these image details, it accurately identifies potential micro-anomalies in abnormal lighting equipment, avoiding location deviations caused by the ambiguity of electrical parameter anomalies, and greatly improving the accuracy of fault location. It also reduces the significant manpower and material resources required for manual inspections. Previously, manual inspections required numerous staff and transportation, resulting in high costs. This technical solution automates and intelligently locates faults, reducing reliance on manpower. Maintenance personnel can then target specific fault locations for repairs based on accurate location results, improving the utilization efficiency of maintenance resources and effectively reducing the overall maintenance cost of urban lighting systems.
[0079] Other features and advantages of the invention will be set forth in the following description, and will be apparent in part from the description, or may be learned by practicing the invention. The objects and other advantages of the invention may be realized and obtained by means of the structures particularly pointed out in the written description and the accompanying drawings.
[0080] The technical solution of the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. Attached Figure Description
[0081] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings:
[0082] Figure 1 This is a flowchart of a method for locating urban lighting faults according to an embodiment of the present invention;
[0083] Figure 2 This is a flowchart illustrating the process of obtaining a plurality of target abnormal pixels according to an embodiment of the present invention;
[0084] Figure 3 This is a block diagram of an urban lighting fault location device according to an embodiment of the present invention. Detailed Implementation
[0085] The preferred embodiments of the present invention will be described below with reference to the accompanying drawings. It should be understood that the preferred embodiments described herein are for illustration and explanation only and are not intended to limit the present invention.
[0086] Example 1
[0087] like Figure 1 As shown, the first aspect of the present invention proposes a method for locating urban lighting faults, including steps S1-S4:
[0088] S1: Obtain images of the illuminated areas of several lighting devices within the city;
[0089] S2: Perform fault analysis on several lighting devices based on the lighting area image to identify abnormal lighting devices;
[0090] S3: Obtain the location information of abnormal lighting equipment;
[0091] S4: Locate the fault in the lighting equipment based on the location information of the abnormal lighting equipment.
[0092] In this embodiment, the method for acquiring the illumination area image of the lighting device is as follows: each lighting device is equipped with a monitoring camera to monitor the illumination area of the lighting device and collect the illumination area image of the lighting device.
[0093] The working principle of the above technical solution is as follows: by analyzing the images of the lighting areas of several lighting devices, the micro-anomalies of the lighting devices are identified, the lighting devices with micro-anomalies are marked and identified as abnormal lighting devices, the location information of the abnormal lighting devices is obtained, and the fault location of the lighting devices is completed based on the location information of the abnormal lighting devices.
[0094] The beneficial effects of the above technical solution are as follows: Image analysis technology can simultaneously process images of the lighting areas of several lighting devices; abnormal lighting devices can be quickly screened from a large number of devices in a short time, greatly saving fault location time, improving work efficiency, ensuring that faults can be discovered and located in the shortest possible time, and reducing the duration of urban lighting faults; fault analysis based on lighting area images overcomes the limitations of relying solely on electrical parameters to determine faults. It can intuitively discover various micro-anomalies in lighting devices, and through the analysis of these image details, accurately determine the potential micro-anomalies of abnormal lighting devices, avoiding location deviations caused by the ambiguity of abnormal electrical parameters, and greatly improving the accuracy of fault location; it reduces the large amount of manpower and material resources consumed by manual inspections. Previously, manual inspections required numerous staff and transportation, resulting in high costs. This technical solution automates and intelligently locates faults, reducing reliance on manpower, enabling maintenance personnel to target specific fault locations for repairs based on accurate location results, improving the utilization efficiency of maintenance resources, and effectively reducing the overall maintenance cost of urban lighting systems.
[0095] Example 2
[0096] It also includes: numbering several lighting devices in the urban lighting area and determining the location information of each lighting device.
[0097] In this embodiment, the location information includes, but is not limited to, the latitude and longitude information and geographic location marker information of the lighting device.
[0098] Example 3
[0099] Fault analysis was performed on several lighting devices based on image data of the lighting area to identify abnormal lighting devices, including:
[0100] Choose any lighting device as the target lighting device; obtain a temporal image of the lighting area of the target lighting device;
[0101] The time-domain image is decomposed to obtain an image dataset of the illumination area of the target lighting device;
[0102] Randomly select one illuminated region image from the illuminated region image dataset as the target image;
[0103] The target image is filtered for abnormal pixels to obtain a number of initial abnormal pixels;
[0104] Obtain a reference image of the illumination area of the target lighting device; the pixels in the reference image correspond one-to-one with the pixels in the target image;
[0105] Based on the baseline image, several initial abnormal pixels are filtered to obtain several target abnormal pixels;
[0106] Based on a number of abnormal target pixels, determine a number of abnormal target regions;
[0107] The anomaly evaluation coefficient of the target lighting equipment is determined based on several target anomaly areas;
[0108] Iterate through all lighting equipment and determine the anomaly evaluation coefficient for each piece of lighting equipment;
[0109] The abnormal evaluation coefficient is compared with the preset abnormal evaluation threshold. When the abnormal evaluation coefficient is greater than or equal to the preset abnormal evaluation threshold, the lighting device is identified as an abnormal lighting device.
[0110] The working principle of the above technical solution is as follows: A lighting device is randomly selected as the target lighting device; a temporal image of the lighting area of the target lighting device is acquired; the temporal image is decomposed to obtain a dataset of lighting area images of the target lighting device; one lighting area image from the dataset is randomly selected as the target image; abnormal pixels are filtered in the target image to obtain several initial abnormal pixels; a reference image of the lighting area of the target lighting device is acquired; the pixels in the reference image correspond one-to-one with the pixels in the target image; the initial abnormal pixels are filtered based on the reference image to obtain several target abnormal pixels; several target abnormal regions are determined based on the several target abnormal pixels; an abnormal evaluation coefficient of the target lighting device is determined based on the several target abnormal regions; all lighting devices are traversed to determine the abnormal evaluation coefficient of each lighting device; the abnormal evaluation coefficient is compared with a preset abnormal evaluation threshold, and when the abnormal evaluation coefficient is greater than or equal to the preset abnormal evaluation threshold, the lighting device is determined to be an abnormal lighting device.
[0111] The beneficial effects of the above technical solution are as follows: By using image data and automated processing (such as abnormal pixel screening and target abnormal area identification), the automation level of fault detection is greatly improved, reducing the workload of manual inspection and troubleshooting, and increasing efficiency; by screening target abnormal pixels and abnormal areas, it is possible to accurately identify whether there is a fault in the lighting equipment area. This avoids the inefficiency of blindly searching for faults, enabling maintenance personnel to quickly locate the problem area and reduce maintenance time; by utilizing the time-domain image dataset of the target lighting equipment, the operating status of the lighting equipment changing over time can be captured, thereby better analyzing fault modes. This dynamic analysis allows the system to promptly detect occasional or periodic faults, rather than relying solely on static images, further improving the accuracy of fault diagnosis; by comparing the pixels of the reference image with those of the target image one by one, abnormal pixels can be screened more accurately. This comparison mechanism ensures the accuracy of the system in determining whether the lighting equipment has malfunctioned, avoiding misjudgments caused by environmental factors or other interference factors.
[0112] Example 4
[0113] The target image is filtered for abnormal pixels, resulting in several initial abnormal pixels, including:
[0114] The target image is processed to obtain a grayscale image;
[0115] Obtain the grayscale value of each pixel in a grayscale image;
[0116] Choose any pixel as the target pixel;
[0117] The first target region is determined with the target pixel as the center and a preset distance as the radius.
[0118] Calculate the average gray value of each pixel in the first target region to obtain the first average gray value;
[0119] Calculate the difference between the gray value of the target pixel and the first gray value mean to obtain the first difference;
[0120] The first difference is compared with a first preset difference threshold. When it is determined that the first difference is greater than or equal to the first preset difference threshold, the target pixel is taken as the initial abnormal pixel.
[0121] The working principle of the above technical solution is as follows: perform grayscale processing on the target image to obtain a grayscale image; obtain the grayscale value of each pixel in the grayscale image; arbitrarily select a pixel as the target pixel; determine a first target region with the target pixel as the center and a preset distance as the radius; calculate the grayscale mean of each pixel in the first target region to obtain a first grayscale mean; calculate the difference between the grayscale value of the target pixel and the first grayscale mean to obtain a first difference; compare the first difference with a first preset difference threshold, and when it is determined that the first difference is greater than or equal to the first preset difference threshold, the target pixel is taken as an initial abnormal pixel.
[0122] The beneficial effects of the above technical solution are as follows: By comparing the grayscale average of the target pixel with that of its neighboring pixels, abnormal pixels deviating from the normal grayscale range can be effectively identified. By calculating the difference and comparing it with a preset threshold, it is possible to accurately determine whether the target pixel is abnormal, thereby improving the detection accuracy of abnormal pixels. The calculation of the grayscale average considers the grayscale values of multiple pixels in the neighborhood, thus reducing the potential misjudgment caused by the abnormal value of a single pixel. Even under the interference of environmental changes, the system can still stably detect real abnormal areas, enhancing the robustness of the algorithm. By setting different difference thresholds, the judgment criteria for abnormal pixels can be flexibly adjusted. This makes the method adaptable to the needs of different lighting environments, different devices, or different detection conditions, and has strong adaptability. By defining a preset detection area centered on the target pixel and performing statistical analysis on the grayscale values within that area, this local detection method can quickly and effectively locate abnormal areas in the image, avoiding redundant processing of the entire image and improving detection efficiency.
[0123] Example 5
[0124] like Figure 2 As shown, several initial abnormal pixels are filtered based on a reference image to obtain several target abnormal pixels, including steps S261-S263:
[0125] S261: Calculate the grayscale difference between the initial abnormal pixel and the corresponding pixel in the reference image to obtain the second difference;
[0126] S262: Compare the second difference with the second preset difference threshold, and when it is determined that the second difference is greater than or equal to the second preset difference threshold, take the initial abnormal pixel as the target abnormal pixel;
[0127] S263: Traverse all initial abnormal pixels to obtain several target abnormal pixels.
[0128] The working principle of the above technical solution is as follows: calculate the grayscale difference between the initial abnormal pixel and the corresponding pixel in the reference image to obtain a second difference; compare the second difference with a second preset difference threshold, and when it is determined that the second difference is greater than or equal to the second preset difference threshold, take the initial abnormal pixel as the target abnormal pixel; traverse all the initial abnormal pixels to obtain a number of target abnormal pixels.
[0129] The beneficial effects of the above technical solution are as follows: by calculating the grayscale difference between the initial abnormal pixel and the corresponding pixel in the reference image, and comparing it with a second preset difference threshold, the true abnormal pixel can be identified more accurately. Compared to relying solely on the detection of the initial abnormal pixel, this method reduces false positives and false negatives; the reference image, as a reference image, can effectively reduce errors caused by changes in lighting, noise, or other external factors, thus making the screening of abnormal pixels more reliable. This allows the detection process to operate stably under various environmental conditions; by setting different second preset difference thresholds, the screening criteria for abnormal pixels can be flexibly adjusted to adapt to different scenarios or application requirements.
[0130] Example 6
[0131] Based on several target anomalous pixels, several target anomalous regions are determined, including:
[0132] Cluster the aforementioned target abnormal pixels to obtain several initial abnormal regions;
[0133] Obtain the minimum bounding rectangle of several initial abnormal regions, and then obtain several minimum bounding rectangles;
[0134] Choose any initial abnormal region as the first region;
[0135] Count the number of pixels in the smallest bounding rectangle corresponding to the first region to obtain the first count;
[0136] The number of abnormal target pixels in the smallest bounding rectangle corresponding to the first region is counted to obtain the second count.
[0137] The third number is obtained by counting the number of pixels outside the smallest bounding rectangle corresponding to the first region.
[0138] The fourth count is obtained by counting the number of abnormal target pixels outside the smallest bounding rectangle corresponding to the first region.
[0139] Calculate the difference between the first quantity and the second quantity to obtain the third difference;
[0140] Calculate the difference between the third and fourth quantities to obtain the fourth difference;
[0141] Calculate the absolute value of the difference between the third and fourth differences, and use it as the anomaly evaluation value for the first region;
[0142] Traverse all initial abnormal regions to obtain the abnormality evaluation value corresponding to each initial abnormal region;
[0143] The abnormal evaluation value is compared with a preset abnormal evaluation threshold. When the abnormal evaluation value is determined to be greater than or equal to the preset abnormal evaluation threshold, the initial abnormal region is taken as the target abnormal region, and several target abnormal regions are obtained.
[0144] The working principle of the above technical solution is as follows: cluster several target abnormal pixels to obtain several initial abnormal regions; determine the degree of abnormality of the initial abnormal regions by calculating the abnormality evaluation value of the initial abnormal regions, and take the initial abnormal regions with a high degree of abnormality as target abnormal regions to obtain several target abnormal regions.
[0145] The beneficial effects of the above technical solution are as follows: By clustering the target abnormal pixels and obtaining the minimum bounding rectangle based on the clustering results, scattered abnormal pixels can be effectively summarized into relatively concentrated and clear abnormal regions. This method can more accurately identify abnormal regions, rather than relying solely on a single abnormal pixel, reducing the possibility of false positives and false negatives. By calculating the first, second, third, and fourth quantities and their differences, a detailed anomaly evaluation can be performed on each initial abnormal region. This multi-dimensional analysis not only identifies abnormal regions but also provides a more accurate basis for subsequent anomaly diagnosis and processing. The calculation of the anomaly evaluation value reflects the density and distribution characteristics of abnormal pixels within the region, thereby optimizing the screening process for abnormal regions. By calculating the minimum bounding rectangle, the boundary of the abnormal region can be quickly determined, greatly improving the efficiency of anomaly region localization. In the processing of large-scale image data, this method has high real-time performance and stability, enabling rapid detection and evaluation of abnormal regions. Calculating the minimum bounding rectangle and analyzing the pixels inside and outside the region can effectively eliminate the influence of noise in the image, preventing noise points from being mistakenly identified as abnormal regions. By performing detailed statistics within the minimum bounding rectangle, the interference of external noise on the detection of abnormal regions can be reduced.
[0146] Example 7
[0147] The anomaly evaluation coefficient of the target lighting equipment is determined based on several target anomaly areas, including:
[0148] Obtain the total number of pixels in several target abnormal regions to get the fifth quantity;
[0149] Obtain the total number of all pixels in the target image to get the sixth quantity;
[0150] The ratio of the fifth quantity to the sixth quantity is used as the anomaly coefficient corresponding to the target image;
[0151] Traverse all images in the illuminated area image dataset, determine the anomaly coefficient corresponding to each illuminated area image, and obtain the anomaly coefficient dataset corresponding to the illuminated area image dataset.
[0152] The mean of the anomaly coefficient dataset is evaluated to determine the anomaly evaluation coefficient of the target lighting equipment.
[0153] The working principle of the above technical solution is as follows: obtain the total number of pixels in several target abnormal regions to obtain the fifth quantity; obtain the total number of all pixels in the target image to obtain the sixth quantity; take the ratio of the fifth quantity to the sixth quantity as the abnormal coefficient corresponding to the target image; traverse all images in the lighting area image dataset, determine the abnormal coefficient corresponding to each lighting area image, and obtain the abnormal coefficient dataset corresponding to the lighting area image dataset; perform mean evaluation on the abnormal coefficient dataset to determine the abnormal evaluation coefficient of the target lighting device.
[0154] The beneficial effects of the above technical solution are as follows: by calculating the ratio of pixels in the target abnormal region to the total number of pixels in the entire image, the degree of abnormality can be quantified, thereby more accurately assessing the operating status of lighting equipment. This method can effectively reflect the abnormal performance of lighting equipment in images and provide evaluation results with a quantitative indicator; by traversing all images in the lighting area image dataset and calculating the abnormality coefficient of each image, an abnormality coefficient dataset is finally obtained, which can reflect the overall performance of the equipment under different times and different scenarios. Evaluating the mean of these data helps to assess the stability and health status of the equipment during long-term operation.
[0155] Example 8
[0156] Before performing fault analysis on several lighting devices based on the lighting area image, the process also includes enhancing the lighting area image.
[0157] Example 9
[0158] Enhancement of the illuminated area image includes:
[0159] Select any image of the illuminated area;
[0160] Obtain the grayscale value of each pixel in the image of the illuminated area;
[0161] Select any pixel from the grayscale image as the first target pixel;
[0162] The second target region is determined with the target pixel as the center and a preset distance as the radius.
[0163] Select any pixel in the second target region as the second target pixel;
[0164] Calculate the grayscale difference between the second target pixel and other pixels in the second target region to obtain several difference values;
[0165] The summation of several differences and the average value are used as the grayscale evaluation value of the second target pixel.
[0166] Iterate through all pixels in the second target region to obtain the grayscale evaluation value corresponding to each pixel;
[0167] Calculate the absolute value of the difference between the grayscale evaluation values corresponding to any two pixels to obtain several absolute values; sum the several absolute values as the feature value of the first target pixel;
[0168] Iterate through all pixels in the grayscale image to obtain the feature value corresponding to each pixel in the grayscale image;
[0169] Calculate the absolute value of the difference between the feature values corresponding to any two adjacent pixels in a grayscale image to obtain several absolute feature differences;
[0170] The absolute feature difference is compared with a preset absolute feature difference threshold. Two pixels whose absolute feature difference is less than or equal to the preset absolute feature difference threshold are grouped into one category, resulting in a number of pixel classifications.
[0171] Several image regions are determined based on the classification of several pixels;
[0172] Calculate the grayscale enhancement coefficient for each image region;
[0173] The pixels of each image region are enhanced based on the gray-level enhancement coefficient corresponding to each image region, resulting in an enhanced illuminated area image.
[0174] Traverse all the illuminated area images to obtain the enhanced illuminated area images.
[0175] In this embodiment,
[0176]
[0177] Among them, T i k represents the grayscale enhancement coefficient of the i-th image region. i v represents the average grayscale value of all pixels in the i-th image region; i This represents the average gradient magnitude of all pixels in the i-th image region; This represents the average gray value of pixels in all image regions adjacent to the i-th image region; The gradient magnitude of pixels in all image regions adjacent to the i-th image region is represented by ; Sigmoid represents the normalization function.
[0178] In this embodiment,
[0179]
[0180] Among them, B i,j b represents the enhanced grayscale value of the j-th pixel in the i-th image region; i,j This represents the initial grayscale value of the j-th pixel in the i-th image region; This represents the floor function.
[0181] The working principle of the above technical solution is as follows: classify each pixel in the illumination area image into as many categories as possible. The more categories and the finer the classification, the more accurate the corresponding grayscale enhancement coefficient. Divide the illumination area image into several image regions. Calculate the grayscale enhancement coefficient corresponding to each image region. Enhance the pixels of each image region based on the grayscale enhancement coefficient corresponding to each image region to obtain the enhanced illumination area image.
[0182] The beneficial effects of the above technical solution are as follows: By calculating the grayscale evaluation value of each pixel and classifying pixels according to feature differences, the local contrast of the image can be effectively improved, making image details clearer. This is particularly important for scenarios requiring detailed observation of the working status of lighting equipment or abnormal areas, helping to better identify important information in the image; by calculating the grayscale enhancement coefficient of the image region and performing enhancement processing, the brightness and contrast of the image can be improved, especially in environments with insufficient lighting or complex backgrounds, significantly improving image visibility. This is of great significance for image processing and analysis, especially for the status assessment of lighting areas; this method not only focuses on the grayscale value of individual pixels but also optimizes the overall image effect through the contrast differences of local regions, thereby achieving a balance between local enhancement and global consistency. This can improve the local clarity of the image while avoiding image distortion caused by over-enhancement; by calculating grayscale feature differences and classifying pixels, the image can be accurately divided into regions. Each region is processed according to a specific enhancement coefficient, effectively avoiding the over- or under-enhancement that may result from global enhancement, thus obtaining a more balanced enhancement effect.
[0183] like Figure 3 As shown, a second aspect of the present invention provides a city lighting fault location device, comprising:
[0184] The first acquisition module is used to acquire images of the lighting areas of several lighting devices;
[0185] The analysis module is used to perform fault analysis on several lighting devices based on the lighting area image to identify abnormal lighting devices;
[0186] The second acquisition module is used to acquire the location information of abnormal lighting devices;
[0187] The positioning module is used to locate lighting equipment faults based on the location information of abnormal lighting equipment.
[0188] The working principle of the above technical solution is as follows: by analyzing the images of the lighting areas of several lighting devices, the micro-anomalies of the lighting devices are identified, the lighting devices with micro-anomalies are marked and identified as abnormal lighting devices, the location information of the abnormal lighting devices is obtained, and the fault location of the lighting devices is completed based on the location information of the abnormal lighting devices.
[0189] The beneficial effects of the above technical solution are as follows: Image analysis technology can simultaneously process images of the lighting areas of several lighting devices; abnormal lighting devices can be quickly screened from a large number of devices in a short time, greatly saving fault location time, improving work efficiency, ensuring that faults can be discovered and located in the shortest possible time, and reducing the duration of urban lighting faults; fault analysis based on lighting area images overcomes the limitations of relying solely on electrical parameters to determine faults. It can intuitively discover various micro-anomalies in lighting devices, and through the analysis of these image details, accurately determine the potential micro-anomalies of abnormal lighting devices, avoiding location deviations caused by the ambiguity of abnormal electrical parameters, and greatly improving the accuracy of fault location; it reduces the large amount of manpower and material resources consumed by manual inspections. Previously, manual inspections required numerous staff and transportation, resulting in high costs. This technical solution automates and intelligently locates faults, reducing reliance on manpower, enabling maintenance personnel to target specific fault locations for repairs based on accurate location results, improving the utilization efficiency of maintenance resources, and effectively reducing the overall maintenance cost of urban lighting systems.
[0190] Obviously, those skilled in the art can make various modifications and variations to this invention without departing from its spirit and scope. Therefore, if these modifications and variations fall within the scope of the claims of this invention and their equivalents, this invention also intends to include these modifications and variations.
Claims
1. A method for locating urban lighting faults, characterized in that, include: Acquire images of the illuminated areas of several lighting devices within the city; Fault analysis of several lighting devices is performed based on images of the lighting area to identify abnormal lighting devices; Obtain the location information of abnormal lighting equipment; Fault location of lighting equipment is completed based on the location information of abnormal lighting equipment; Fault analysis was performed on several lighting devices based on images of the lighting area to identify abnormal lighting devices, including: Choose any lighting device as the target lighting device; obtain a temporal image of the lighting area of the target lighting device; The time-domain image is decomposed to obtain an image dataset of the illumination area of the target lighting device; Randomly select one illuminated region image from the illuminated region image dataset as the target image; The target image is filtered for abnormal pixels to obtain a number of initial abnormal pixels; Obtain a reference image of the illumination area of the target lighting device; the pixels in the reference image correspond one-to-one with the pixels in the target image; Based on the baseline image, several initial abnormal pixels are filtered to obtain several target abnormal pixels; Based on a number of abnormal target pixels, determine a number of abnormal target regions; The anomaly evaluation coefficient of the target lighting equipment is determined based on several target anomaly areas; Iterate through all lighting equipment and determine the anomaly evaluation coefficient for each piece of lighting equipment; The abnormal evaluation coefficient is compared with the preset abnormal evaluation threshold. When the abnormal evaluation coefficient is determined to be greater than or equal to the preset abnormal evaluation threshold, the lighting device is determined to be an abnormal lighting device. Based on several target anomalous pixels, several target anomalous regions are determined, including: Cluster the aforementioned target abnormal pixels to obtain several initial abnormal regions; Obtain the minimum bounding rectangle of several initial abnormal regions, and then obtain several minimum bounding rectangles; Choose any initial abnormal region as the first region; Count the number of pixels in the smallest bounding rectangle corresponding to the first region to obtain the first count; The number of abnormal target pixels in the smallest bounding rectangle corresponding to the first region is counted to obtain the second count. The third number is obtained by counting the number of pixels outside the smallest bounding rectangle corresponding to the first region. The fourth count is obtained by counting the number of abnormal target pixels outside the smallest bounding rectangle corresponding to the first region. Calculate the difference between the first quantity and the second quantity to obtain the third difference; Calculate the difference between the third and fourth quantities to obtain the fourth difference; Calculate the absolute value of the difference between the third and fourth differences, and use it as the anomaly evaluation value for the first region; Traverse all initial abnormal regions to obtain the abnormality evaluation value corresponding to each initial abnormal region; The abnormal evaluation value is compared with a preset abnormal evaluation threshold. When the abnormal evaluation value is determined to be greater than or equal to the preset abnormal evaluation threshold, the initial abnormal region is taken as the target abnormal region, and several target abnormal regions are obtained. The anomaly evaluation coefficient of the target lighting equipment is determined based on several target anomaly areas, including: Obtain the total number of pixels in several target abnormal regions to get the fifth quantity; Obtain the total number of all pixels in the target image to get the sixth quantity; The ratio of the fifth quantity to the sixth quantity is used as the anomaly coefficient corresponding to the target image; Traverse all images in the illuminated area image dataset, determine the anomaly coefficient corresponding to each illuminated area image, and obtain the anomaly coefficient dataset corresponding to the illuminated area image dataset. The mean of the anomaly coefficient dataset is evaluated to determine the anomaly evaluation coefficient of the target lighting equipment.
2. The urban lighting fault location method as described in claim 1, characterized in that, Before acquiring the operational data of several lighting devices, the process also includes: numbering several lighting devices in the urban lighting area and determining the location information of each lighting device.
3. The urban lighting fault location method as described in claim 1, characterized in that, The target image is filtered for abnormal pixels, resulting in several initial abnormal pixels, including: The target image is processed to obtain a grayscale image; Obtain the grayscale value of each pixel in a grayscale image; Choose any pixel as the target pixel; The first target region is determined with the target pixel as the center and a preset distance as the radius. Calculate the average gray value of each pixel in the first target region to obtain the first average gray value; Calculate the difference between the gray value of the target pixel and the first gray value mean to obtain the first difference; The first difference is compared with a first preset difference threshold. When it is determined that the first difference is greater than or equal to the first preset difference threshold, the target pixel is taken as the initial abnormal pixel.
4. The urban lighting fault location method as described in claim 3, characterized in that, Based on the baseline image, several initial anomalous pixels are filtered to obtain several target anomalous pixels, including: Calculate the grayscale difference between the initial abnormal pixel and the corresponding pixel in the reference image to obtain the second difference; The second difference is compared with the second preset difference threshold. When it is determined that the second difference is greater than or equal to the second preset difference threshold, the initial abnormal pixel is taken as the target abnormal pixel. Traverse all initial abnormal pixels to obtain a number of target abnormal pixels.
5. The urban lighting fault location method as described in claim 1, characterized in that, Before performing fault analysis on several lighting devices based on the lighting area image, the process also includes enhancing the lighting area image.
6. The urban lighting fault location method as described in claim 5, characterized in that, Enhancement of the illuminated area image includes: Select any image of the illuminated area; Obtain the grayscale value of each pixel in the image of the illuminated area; Select any pixel from the grayscale image as the first target pixel; The second target region is determined with the target pixel as the center and a preset distance as the radius. Select any pixel in the second target region as the second target pixel; Calculate the grayscale difference between the second target pixel and other pixels in the second target region to obtain several difference values; The summation of several differences and the average value are used as the grayscale evaluation value of the second target pixel. Iterate through all pixels in the second target region to obtain the grayscale evaluation value corresponding to each pixel; Calculate the absolute value of the difference between the grayscale evaluation values corresponding to any two pixels to obtain several absolute values; sum the several absolute values as the feature value of the first target pixel. Iterate through all pixels in the grayscale image to obtain the feature value corresponding to each pixel in the grayscale image; Calculate the absolute value of the difference between the feature values corresponding to any two adjacent pixels in a grayscale image to obtain several absolute feature differences; The absolute feature difference is compared with a preset absolute feature difference threshold. Two pixels whose absolute feature difference is less than or equal to the preset absolute feature difference threshold are grouped into one category, resulting in a number of pixel classifications. Several image regions are determined based on a classification of several pixels; Calculate the grayscale enhancement coefficient for each image region; The pixels of each image region are enhanced based on the gray-level enhancement coefficient corresponding to each image region, resulting in an enhanced illuminated area image. Traverse all the illuminated area images to obtain the enhanced illuminated area images.
7. An urban lighting fault location device that applies the urban lighting fault location method as described in any one of claims 1-6, characterized in that, include: The first acquisition module is used to acquire images of the lighting areas of several lighting devices; The analysis module is used to perform fault analysis on several lighting devices based on the lighting area image to identify abnormal lighting devices; The second acquisition module is used to acquire the location information of abnormal lighting devices; The positioning module is used to locate lighting equipment faults based on the location information of abnormal lighting equipment.
Citation Information
Patent Citations
LED traffic light quality patrol inspection method and system based on mobile robot
CN111060286A
Lamp bead plane fault monitoring method and device, computer equipment and storage medium
CN116309470A