Method for detecting indicator light of computer device and electronic device

CN122695185BActive Publication Date: 2026-10-23INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202611161575.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-07-31
Publication Date
2026-10-23
Estimated Expiration
2046-07-31

AI Technical Summary

Technical Problem

[0003]本申请提供了一种计算机设备的指示灯的检测方法及电子设备,以至少解决相关技术中指示灯检测准确性较低的问题

Benefits of technology

[0008]本申请还提供了一种计算机程序产品,包括计算机程序,计算机程序被处理器执行时实现上述任一种计算机设备的指示灯的检测方法的步骤。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122695185B_ABST
    Figure CN122695185B_ABST
Patent Text Reader

Abstract

The application discloses a detection method of an indicator light of a computer device and an electronic device, and relates to the technical field of computers. The method comprises the following steps: receiving a detection request; in response to the detection request, acquiring first target information and second target information, and first reference information and second reference information; predicting third target information according to the first target information, the first reference information and the second reference information, wherein the second target information can indicate image features of a target region in a second environment state and when a to-be-detected indicator light is in a working state, and the third target information can indicate image features of the target region in the second environment state and when the to-be-detected indicator light is in a non-working state; and determining a target light-emitting state of the to-be-detected indicator light according to the second target information and the third target information. Therefore, the application solves the problem of low detection accuracy of an indicator light in the prior art, and thus achieves the technical effect of improving the detection accuracy of an indicator light.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a method for detecting indicator lights in a computer device and an electronic device. Background Technology

[0002] To display the operating status of computer equipment, various indicator lights are typically installed, such as power indicators, health status indicators, and location indicators. Related technologies usually detect the illumination status of these indicator lights through manual observation or image recognition. However, due to factors such as changes in ambient light and image acquisition parameters, the observed illumination of the indicator lights or the illumination presented in the image may deviate from the actual illumination, resulting in low accuracy in indicator light detection. Summary of the Invention

[0003] This application provides a method and electronic device for detecting indicator lights in computer equipment, so as to at least solve the problem of low accuracy of indicator light detection in related technologies.

[0004] This application provides a method for detecting an indicator light on a computer device, comprising: receiving a detection request, wherein the detection request is used to request detection of the illumination state of an indicator light under test on the computer device; responding to the detection request, acquiring first target information and second target information, as well as first reference information and second reference information, wherein the first target information is used to indicate the image features of a target area in a first environmental state and the indicator light under test is in a non-working state, the second target information is used to indicate the image features of the target area in a second environmental state and the indicator light under test is in a working state, the first reference information is used to indicate the image features of a reference area in the first environmental state, the second reference information is used to indicate the image features of a reference area in the second environmental state, the target area is the area corresponding to the indicator light under test, and the reference area is the area affected by the same environmental state as the target area; predicting third target information based on the first target information, the first reference information, and the second reference information, wherein the third target information is used to indicate the image features of the target area in the second environmental state and the indicator light under test is in a non-working state; and determining the target illumination state of the indicator light under test based on the second target information and the third target information, wherein the target illumination state is used to indicate the actual illumination state of the indicator light under test in a working state.

[0005] This application also provides a detection device for an indicator light on a computer device, comprising: a receiving module for receiving a detection request, wherein the detection request is for requesting detection of the illumination state of an indicator light under test on a computer device; a response module for responding to the detection request and acquiring first target information and second target information, as well as first reference information and second reference information, wherein the first target information is used to indicate the image features of a target area in a first environmental state and the indicator light under test is in a non-working state, the second target information is used to indicate the image features of the target area in a second environmental state and the indicator light under test is in a working state, the first reference information is used to indicate the image features of a reference area in the first environmental state, the second reference information is used to indicate the image features of a reference area in the second environmental state, the target area is the area corresponding to the indicator light under test, and the reference area is the area affected by the same environmental state as the target area; a prediction module for predicting third target information based on the first target information, the first reference information, and the second reference information, wherein the third target information is used to indicate the image features of the target area in the second environmental state and the indicator light under test is in a non-working state; and a determination module for determining the target illumination state of the indicator light under test based on the second target information and the third target information, wherein the target illumination state is used to indicate the actual illumination state of the indicator light under test in a working state.

[0006] This application also provides an electronic device, including: a memory for storing a computer program; and a processor for executing the computer program to implement the steps of the indicator light detection method of any of the above-described computer devices.

[0007] This application also provides a computer-readable storage medium storing a computer program, wherein when the computer program is executed by a processor, it implements the steps of the method for detecting the indicator light of any of the above-described computer devices.

[0008] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the method for detecting the indicator light of any of the above-described computer devices.

[0009] This application, upon receiving a detection request, first responds to the request by acquiring first target information of the target area in a first environmental state and when the indicator light under test is in a non-working state, second target information of the target area in a second environmental state and when the indicator light under test is in a working state, first reference information of the reference area in the first environmental state, and second reference information of the reference area in the second environmental state. Then, based on the first target information, the first reference information, and the second reference information, it predicts third target information of the target area in the second environmental state and when the indicator light under test is in a non-working state. Finally, based on the second and third target information, it determines the actual illumination of the indicator light under test in the working state. Since the reference area and the target area are affected by the same environmental state, the image feature changes of the reference area under different environmental states can be used to predict the image feature changes of the target area from the first environmental state to the second environmental state, and the influence caused by the environmental state change can be eliminated from the second target information. This reduces the interference of factors such as changes in ambient light and image acquisition parameters on the detection results, improving the accuracy of the indicator light illumination detection. Therefore, this application solves the problem of low indicator light detection accuracy in related technologies, thereby achieving the technical effect of improving the accuracy of indicator light detection. Attached Figure Description

[0010] To more clearly illustrate the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0011] Figure 1 This is a hardware structure block diagram of a detection device according to an embodiment of this application;

[0012] Figure 2 This is a flowchart of a method for detecting an indicator light of a computer device according to an embodiment of this application;

[0013] Figure 3 This is a schematic diagram of the target area and reference area according to an embodiment of this application;

[0014] Figure 4 This is a flowchart illustrating the process of determining the illumination state of an indicator light under test based on environmental parameters according to an embodiment of this application.

[0015] Figure 5 This is a schematic diagram of a scenario for detecting an execution indicator light according to an embodiment of this application;

[0016] Figure 6 This is a schematic diagram of a reference area filtering scenario according to an embodiment of this application;

[0017] Figure 7 This is a schematic diagram of the adjustable support structure of an image acquisition device according to an embodiment of this application;

[0018] Figure 8 This is a schematic diagram of the target acquisition pose determination process according to an embodiment of this application;

[0019] Figure 9 This is a schematic diagram of the interface of the test system according to an embodiment of this application;

[0020] Figure 10 This is a schematic diagram of a scenario for executing a test task according to an embodiment of this application;

[0021] Figure 11 This is a schematic diagram of the server loop startup test process according to an embodiment of this application;

[0022] Figure 12 This is a structural block diagram of an indicator light detection device for a computer device according to an embodiment of this application. Detailed Implementation

[0023] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the protection scope of this application.

[0024] It should be noted that, in the description of this application, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. The terms "first," "second," etc., in this application are used to distinguish similar objects and are not used to describe a specific order or sequence.

[0025] To enable those skilled in the art to better understand the present application, the present application will be further described in detail below with reference to the accompanying drawings and specific embodiments.

[0026] The methods and embodiments provided in this application can be executed in a detection device or a similar computing device. Taking running on a detection device as an example, Figure 1 This is a hardware structure block diagram of a detection device according to an embodiment of this application. Figure 1 As shown, the testing equipment may include one or more ( Figure 1(Only one is shown in the image) Processor 102 and memory 104. Processor 102 is connected to memory 104, which stores computer programs, such as application software programs and modules, like the computer program corresponding to the indicator light detection method of the computer device in this embodiment. Processor 102 executes various functional applications and data processing by running the computer program stored in memory 104, thereby realizing the indicator light detection method of the computer device in this embodiment. The detection device may include, but is not limited to, servers, industrial computers, personal computers, controllers, testing equipment, or other devices with data processing capabilities. Processor 102 may include, but is not limited to, central processing units (CPUs), microcontroller units (MCUs), field programmable gate arrays (FPGAs), or other processing devices capable of performing data processing operations. Memory 104 may include high-speed random access memory and non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, memory 104 may also include a memory remotely located relative to processor 102, which can be connected to the detection device via a network. Examples of the aforementioned networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.

[0027] The testing equipment may also include a transmission device 106 and an input / output device 108. The transmission device 106 can be used for data transmission between the testing equipment and other devices. The input / output device 108 can be used to receive testing requests, input testing parameters, or output the testing results of the indicator light under test. For example, the input / output device 108 may include, but is not limited to, a display, keyboard, mouse, touch screen, communication interface, or other devices capable of inputting or outputting information.

[0028] The processor 102, memory 104, transmission device 106, and input / output device 108 can be connected via a bus or other connection method. Those skilled in the art will understand that... Figure 1 The structure shown is for illustrative purposes only and does not limit the structure of the testing equipment. For example, the testing equipment may also include components that are more... Figure 1 Showing more or fewer components, or having with Figure 1 The different configurations shown.

[0029] This embodiment provides a method for detecting indicator lights in a computer device. Figure 2 This is a flowchart of a method for detecting an indicator light of a computer device according to an embodiment of this application, such as... Figure 2As shown, the process includes the following steps:

[0030] Step S202: Receive a detection request, wherein the detection request is used to request the detection of the illumination status of the indicator light under test on the computer device;

[0031] Step S204: Respond to the detection request, obtain first target information and second target information, as well as first reference information and second reference information. The first target information is used to indicate the image features of the target area in the first environmental state and when the indicator light under test is in a non-working state. The second target information is used to indicate the image features of the target area in the second environmental state and when the indicator light under test is in a working state. The first reference information is used to indicate the image features of the reference area in the first environmental state. The second reference information is used to indicate the image features of the reference area in the second environmental state. The target area is the area corresponding to the indicator light under test, and the reference area is the area affected by the same environmental state as the target area.

[0032] Step S206: Predict third target information based on first target information, first reference information and second reference information, wherein the third target information is used to indicate the image features of the target area in the second environmental state and when the indicator light under test is not in working state.

[0033] Step S208: Determine the target illumination state of the indicator light under test based on the second target information and the third target information, wherein the target illumination state is used to indicate the actual illumination state of the indicator light under test in the working state.

[0034] For ease of explanation, the first target information will be referred to as the baseline target information, the first reference information as the baseline reference information, the second target information as the measured target information, the second reference information as the measured reference information, and the third target information as the compensation target information. However, the above designations do not constitute a limitation on the first target information, the first reference information, the second target information, the second reference information, and the third target information.

[0035] Through the above steps, upon receiving a detection request, the system first responds to the request by acquiring the baseline target information, measured target information, baseline reference information, and measured reference information of the reference area. Then, based on the baseline target information, baseline reference information, and measured reference information, it predicts the compensation target information for the target area under a second environmental state when the indicator light under test is in a non-working state. Finally, based on the measured target information and the compensation target information, it determines the actual illumination of the indicator light under test in a working state. Since the reference area and the target area are affected by the same environmental state, the image feature changes of the reference area under different environmental states can be used to predict the image feature changes of the target area from the first environmental state to the second environmental state. Based on this, the influence of environmental state changes can be eliminated from the measured target information, thereby reducing the interference of factors such as changes in ambient light and image acquisition parameters on the detection results and improving the accuracy of indicator light illumination detection. Therefore, this application solves the problem of low indicator light detection accuracy in related technologies, thus achieving the technical effect of improving indicator light detection accuracy.

[0036] Optionally, in this embodiment, the computer device may be, but is not limited to, a server, storage device, network device, industrial computer, personal computer, or other device equipped with indicator lights. The indicator lights may be, but are not limited to, power indicator lights, health status indicator lights, positioning indicator lights, network status indicator lights, or component operation status indicator lights. The indicator lights may be monochrome indicator lights or multi-color indicator lights capable of displaying multiple colors. It is understood that when both the testing device and the computer device are servers, the computer device is the server under test, and the testing device is a test server set up separately from the server under test.

[0037] Optionally, in this embodiment, the computer device may be equipped with one or more indicator lights, and the indicator light to be tested is the indicator light whose illumination state needs to be detected. When it is necessary to detect the illumination state of multiple indicator lights, each indicator light can be identified as the indicator light to be tested, and the method provided in this embodiment can be executed for each indicator light to be tested.

[0038] In the embodiment provided in step S202 above, the detection request can be a request generated in response to a preset detection trigger operation. The detection request may, but is not limited to, carrying detection information such as the device identifier of the computer device, the indicator light identifier of the indicator light under test, or the detection frequency. The detection frequency can indicate how frequently the illumination state of the indicator light under test is detected. For example, after receiving a detection request, the detection device can determine the computer device D1 to be tested based on the device identifier "D1". If the computer device D1 is equipped with indicator lights A, B, and C, and the indicator light identifier carried in the detection request is "C", then the indicator light C identified by the indicator light identifier "C" can be determined as the indicator light under test.

[0039] In one alternative implementation, the test request can be triggered by an operator through the input / output devices of the testing equipment. For example, the operator can select the computer device "D1" to be tested and the indicator light "C" on the interface provided by the testing equipment, and trigger the testing equipment to receive the test request by clicking the test button, entering a test command, or performing other test triggering operations. In another alternative implementation, the test request can be sent to the testing equipment by an automated testing system, a production testing platform, or other control equipment. In yet another alternative implementation, the test request can be automatically generated by a testing program running in the testing equipment. For example, the testing program can generate a test request when a preset test time arrives or preset test conditions are met.

[0040] In the embodiment provided in step S204 above, the detection device can respond to a detection request and acquire benchmark target information, benchmark reference information, measured target information, and measured reference information. In an optional embodiment, the detection device can acquire a benchmark image and a measured image, and extract benchmark target information and benchmark reference information from the benchmark image, and extract measured target information and measured reference information from the measured image.

[0041] Optionally, the reference image can be an image acquired when the indicator light under test is in a non-operating state, and the measured image can be an image acquired when the indicator light under test is in an operating state. In this embodiment, the indicator light under test being in an operating state means that the indicator light under test has entered a state where it should perform the light-emitting indication function, and does not necessarily mean that the indicator light under test has emitted light normally. For example, if the computer device has already output a light-emitting drive signal to the indicator light under test, it can be determined that the indicator light under test is in an operating state. Even if the indicator light under test does not actually emit light due to damage to the light-emitting component, abnormal connection, or abnormal drive circuit, it can still be considered that the indicator light under test is in an operating state. The indicator light under test being in a non-operating state may mean that the indicator light under test has not received a light-emitting drive signal, or that the light-emitting indication function of the indicator light under test is in a turned-off state.

[0042] Optionally, the environmental state is used to characterize the imaging conditions that can affect the imaging results during image acquisition. The imaging conditions for acquiring a reference image can be represented by a first environmental state, and the imaging conditions for acquiring a measured image can be represented by a second environmental state. The first environmental state and the second environmental state can be the same or different. The imaging conditions can include external environmental conditions and / or image acquisition conditions. External environmental conditions can include, but are not limited to, at least one of ambient light intensity, ambient light color temperature, the reflection state of the computer equipment surface, and ambient light occlusion. Image acquisition conditions can include, but are not limited to, at least one of the acquisition pose of the image acquisition device and acquisition parameters, which can include exposure time, image gain, and white balance parameters, etc.

[0043] Optionally, the testing equipment may acquire reference images and / or measured images through an integrated image acquisition device, or it may control a separately configured image acquisition device to acquire reference images and / or measured images and receive images returned by the image acquisition device. The image acquisition device may include, but is not limited to, industrial cameras, network cameras, digital cameras, image acquisition devices in mobile terminals, or other devices with image acquisition capabilities. The image acquisition device can be connected to the testing equipment via wired or wireless communication.

[0044] In one alternative implementation, the detection device can determine the target region and the reference region from the reference image, and extract reference target information from the target region of the reference image and reference reference information from the reference region of the reference image; the detection device can also determine the target region and the reference region from the measured image, and extract measured target information from the target region of the measured image and measured reference information from the reference region of the measured image.

[0045] Optionally, the target area may include the area corresponding to the light-emitting component of the indicator light under test in the image, or may further include an image area within a preset range around the light-emitting component. The shape of the target area can be determined according to the shape of the indicator light under test, its installation location, or image processing needs; for example, it can be a circle, ellipse, rectangle, polygon, or irregular area.

[0046] Optionally, the reference region can be determined based on the correlation between its image features and the image features of the target region when affected by environmental conditions. In this embodiment, the reference region and the target region being affected by the same environmental condition means that during image acquisition, the reference region and the target region are jointly affected by the same or related imaging conditions characterized by that environmental condition. When the imaging conditions change, the change in image features of the reference region can be used to characterize or predict the change in image features of the target region caused by the change in imaging conditions. It should be noted that this embodiment does not require that the changes in image features caused by the change in imaging conditions to the target region and the reference region be completely consistent.

[0047] Optionally, the reference area can consist of a continuous image region or include multiple mutually separate image sub-regions. The shape, number, and location of the reference area can be determined based on the panel structure of the computer equipment, the installation location of the indicator light under test, and the degree of correlation between different areas affected by environmental conditions.

[0048] Figure 3 This is a schematic diagram of the target area and reference area according to an embodiment of this application. Figure 3 As shown, when indicator C is the indicator light to be tested, the detection device can determine the image area corresponding to indicator C as the target area in the acquired image, and determine the image area outside the target area whose image features can reflect the influence of the environmental state on the target area as the reference area. Figure 3 The shape, number, and location of the target and reference areas shown are for illustrative purposes only and do not constitute a limitation.

[0049] Optionally, the target region in the reference image and the target region in the measured image can correspond to the same physical region on the computer device, and the reference region in the reference image and the reference region in the measured image can also correspond to the same physical region on the computer device. In the case of a positional offset between the reference image and the measured image, the detection device can perform image registration on the reference image and the measured image based on panel edges, interfaces, screws, text markings, or other relatively fixed structures on the computer device, and determine the target region and reference region corresponding to the same physical location in the two types of images based on the registration result.

[0050] Optionally, before extracting image features from the target or reference region, the detection device may perform color space conversion, denoising, and / or distortion correction on the corresponding image to reduce the impact of the image acquisition process on the feature extraction results. For a circular target or reference region, the detection device may extract pixel features at the center of the circle, or it may extract statistical features of multiple pixels within a preset sub-region centered on the center of the circle to reduce the impact of image noise or bad pixels on the detection results.

[0051] In one optional embodiment, the detection device can determine the color features, brightness features, pixel distribution features, or a feature vector composed of at least one of the above features of pixels within the target area as reference target information or measured target information; and can determine the color features, brightness features, pixel distribution features, or a feature vector composed of at least one of the above features of pixels within the reference area as reference reference information or measured reference information. The color features can adopt the RGB (Red, Green, Blue) color space or LAB (Low-light, Green, Blue) color space. a b L (Lightness) refers to brightness; a (Green–Red Axis) represents the green-red gradation axis; b The (Blue-Yellow Axis) represents the feature values ​​in a color space or other color space. Brightness features can include the average brightness, median brightness, maximum brightness, brightness distribution, or brightness histogram of multiple pixels within the corresponding region.

[0052] In one optional implementation, the detection device can continuously acquire multiple frames of images while the indicator light under test is in the same state, and extract image features from corresponding regions in the multiple frames of images respectively. For example, the detection device can perform averaging, median processing, weighted processing, or other fusion processing on the image features of corresponding regions in multiple reference images or multiple measured images, and determine the processing results as the corresponding target information or reference information, so as to reduce the impact of instantaneous illumination changes, image noise, or image acquisition device jitter on the information acquisition results.

[0053] In one optional implementation, at least some of the information from the benchmark target information, benchmark reference information, measured target information, and measured reference information can be acquired in real time during the current detection process, or they can be acquired and stored in advance. For example, the detection device can acquire a benchmark image in advance when the indicator light under test is in a non-working state, and store the benchmark target information and benchmark reference information extracted from the benchmark image. After receiving a detection request, the detection device can read the pre-stored benchmark target information and benchmark reference information, and acquire the measured target information and measured reference information in real time.

[0054] In the embodiment provided in step S206 above, the detection device can determine the image feature changes generated when the reference area changes from a first environmental state to a second environmental state based on the benchmark reference information and the measured reference information, and predict the image feature changes generated when the target area changes from the first environmental state to the second environmental state based on the image feature changes. The detection device can apply the predicted image feature changes to the benchmark target information to obtain compensated target information.

[0055] For example, the first environmental state corresponds to a standard white light environment, and the second environmental state corresponds to a warm light environment with a yellowish tint. The reference information extracted by the detection equipment (such as the LAB features of a certain reference area on the chassis under standard white light) is (60, 0, 0), and the measured reference information (such as the LAB features of the same reference area under warm light) is (65, 5, 10). Based on the difference between the measured reference information and the reference reference information, the detection equipment can determine the feature offset of the reference area when it changes from a standard white light environment to a warm light environment as (5, 5, 10).

[0056] Considering that the surface of the light-emitting component of the indicator light under test is usually covered with a transparent cover made of plastic or glass, ambient light may be reflected or refracted when it acts on the target area, causing a difference in the response degree of the target area and the reference area to the same environmental changes. Therefore, the detection device can convert the feature offset of the reference area according to predetermined correction parameters to obtain the effective feature offset of the target area. For example, the correction parameters may include a correction coefficient of 0.8 for the brightness component, a correction coefficient of 0.8 for the red-green component, and a correction coefficient of 0.9 for the yellow-blue component. The detection device can use the above correction coefficients to correct the feature offset of the reference area (5, 5, 10) to obtain the effective feature offset of the target area (4, 4, 9).

[0057] If the baseline target information (such as the LAB features of the target area when the indicator light under test is not lit under standard white light) is (38, -2, 3), then the detection device can apply the effective feature offset to the baseline target information and predict the compensation target information (such as the LAB features that the target area should present when the indicator light under test is not lit under warm light) as (42, 2, 12).

[0058] The values ​​above are for illustrative purposes only and do not constitute a limitation. In practical applications, the correction parameters can be determined through calibration, fitting, or model training, based on factors such as the material of the chassis, the material, color, and light transmittance of the light-transmitting cover.

[0059] In the embodiment provided in step S208 above, the measured target information may include both the influence of the second environmental state on the target area and the image features generated by the self-illumination of the indicator light under test. Therefore, the detection device can compare the measured target information and the compensated target information to determine the image features used to characterize the influence of the self-illumination of the indicator light under test, and determine the target illumination state of the indicator light under test based on the image features.

[0060] Optionally, the detection device can calculate the feature difference between the measured target information and the compensated target information, and determine the color, brightness, and / or pixel distribution changes caused by the self-illumination of the indicator light under test based on the calculated feature difference. The detection device can match the color, brightness, and / or pixel distribution changes caused by the self-illumination of the indicator light under test with the color, brightness, and / or pixel distribution changes corresponding to different illumination states, and determine the target illumination state of the indicator light under test based on the matching result.

[0061] For example, if the measured target information is a LAB feature vector of (70, 10, 65) and the compensated target information is a LAB feature vector of (42, 2, 12), then the feature difference between the two is (28, 8, 53). This feature difference indicates that both the luminance component and the yellow-blue component of the target area have changed significantly. The detection device can match this feature difference with the color range, luminance range, and / or pixel distribution changes corresponding to pre-set green, yellow, red, or other luminance states. If the feature difference falls within the feature range corresponding to the yellow luminance state, it can be determined that the indicator light under test actually emits yellow light.

[0062] Optionally, the target illumination state may include whether the indicator light under test is emitting light, the color of the light emitted, the brightness of the light emitted, the flashing frequency, the flashing period, or a combination of the above illumination conditions. For example, the target illumination state may be no light emitted, continuous red light emitted, continuous green light emitted, flashing yellow light emitted, or the light emitted color switching in a preset order. When the target illumination state includes flashing frequency, flashing period, or the order of light emitted color switching, the detection device can determine the color, brightness, and / or pixel distribution changes corresponding to each frame of the continuously acquired images, and determine the corresponding target illumination state based on the changes in multiple colors, brightness, and / or pixel distribution changes over time.

[0063] Optionally, after determining the target luminous state of the indicator light under test based on the second and third target information, the target luminous state can be further verified based on the pre-established calibration relationship between environmental parameters and color compensation parameters. The detection device can obtain the measured color of the indicator light under test in the second environmental state from the second target information, and detect the color difference value between the measured color and the possible luminous colors of multiple indicator lights under test based on the color compensation parameters corresponding to the second environmental state. The color difference value is compared with the difference threshold. If there is a color difference value less than or equal to the difference threshold, the possible luminous color corresponding to the smallest color difference value is determined as the verification color of the indicator light under test. If the verification color matches the target color included in the target luminous state, the luminous color indicated by the target luminous state is determined to be accurate.

[0064] Optionally, the color compensation parameters corresponding to the second environmental state can be obtained by detecting the color chart using a colorimeter and an image acquisition device under various calibration environmental states. The color chart may include multiple standard color regions corresponding to the possible emission colors of the indicator light under test. For each calibration environmental state, the corresponding ambient light intensity, ambient light color temperature, LAB characteristics of each standard color region acquired by the image acquisition device, and LAB characteristics of each standard color region measured by the colorimeter can be recorded. The detection device can use the LAB characteristics measured by the colorimeter as the standard color characteristics of the corresponding standard color region, and determine the color compensation parameters corresponding to the calibration environmental state based on the deviation between the LAB characteristics acquired by the image acquisition device and the standard color characteristics. The color compensation parameters may include the comparison weights corresponding to the red and green components. Comparison weights corresponding to the yellow and blue components It can also include the color difference threshold used for luminescence determination. The detection equipment can establish a calibration relationship between ambient light intensity, ambient light color temperature, and color compensation parameters based on environmental parameters and color compensation parameters corresponding to various calibration environmental conditions.

[0065] Optionally, the calibration relationships can be stored in a calibration table, as shown in Table 1.

[0066]

[0067] Table 1 Calibration Table

[0068] In a warm light environment with a color temperature of 2700 K (Kelvin) and an illuminance of 200 lux, and In an environment with a color temperature of 4000 K and an illuminance of 500 lux, and In an environment with a color temperature of 6500 K and an illuminance of 800 lux, and 1.

[0069] Figure 4 This is a schematic flowchart illustrating the process of determining the illumination state of an indicator light under test based on environmental parameters, according to an embodiment of this application. Figure 4 As shown, after acquiring the measured image, the detection device can obtain the color temperature and illuminance (equivalent to ambient light intensity) corresponding to the second environmental state through a color temperature sensor, illuminance sensor, or other environmental detection devices, and obtain the corresponding values ​​from the calibration relationship. and When the current environmental parameter corresponding to the second environmental state falls between multiple calibrated environmental parameters, the detection device can determine the corresponding environmental parameter through interpolation. and For example, if the color temperature of the second environmental state is 3350 K and the illuminance is 350 lux, the detection equipment can interpolate according to the calibration table to obtain the value corresponding to the second environmental state. , .

[0070] The detection equipment can obtain the measured color of the indicator light under test from the second target information, and based on... and Calculate the color difference between the measured color and the possible emitted color. The color difference can be calculated using the following formula:

[0071] ;

[0072] in, , and These represent the differences in lightness component, red-green component, and yellow-blue component between the measured color and the standard color in the LAB color space, respectively. The detection equipment compares the calculated color difference value with a color difference threshold. If a color difference value is less than or equal to the threshold, the possible luminous color corresponding to the smallest color difference value is determined as the calibration color of the indicator light under test. If the calibration color matches the target color included in the target luminous state, the luminous color indicated by the target luminous state is confirmed to be accurate. If the calibration color does not match the target color, the luminous color indicated by the target luminous state is confirmed to be deviated, and the calibration color is used as the final determined luminous color of the indicator light under test. If no color difference value is less than or equal to the threshold, it is determined that no possible luminous color matching the measured color has been identified, and the target luminous state has failed the auxiliary calibration.

[0073] For example, the measured color of the indicator light under test obtained from the second target information corresponds to the LAB feature vector (54, -32, 40). Assuming the possible emission colors of the indicator light under test include green and yellow, the standard color feature corresponding to the green emission state, obtained beforehand by a colorimeter, is the LAB feature vector (52, -35, 38), and the standard color feature corresponding to the yellow emission state is the LAB feature vector (78, -5, 75). Substituting... and The color difference between the measured color and the standard color corresponding to the green emission state is 4.26, and the color difference between the measured color and the standard color corresponding to the yellow emission state is 49.50. With a difference threshold of 10, the color difference value of 4.26 corresponding to the green emission state is less than the threshold, while the color difference value of 49.50 corresponding to the yellow emission state is greater than the threshold. Therefore, the green light corresponding to the minimum color difference value can be determined as the calibration color of the indicator light under test. If the target color included in the target emission state is green, the emission color indicated by the target emission state can be determined to be accurate because the calibration color matches the target color. If the target color included in the target emission state is not green, it can be determined that the emission color indicated by the target emission state has a deviation, and green light can be determined as the emission color of the indicator light under test obtained through calibration.

[0074] Optionally, the color difference threshold can be an adaptive color difference threshold dynamically determined based on the current image acquisition environment. The adaptive color difference threshold can be based on the base color difference threshold. Environmental compensation amount corresponding to the current image acquisition environment state Determined. For example, adaptive color difference threshold. It can be determined in the following ways:

[0075] ;

[0076] in, This is used to represent the dynamic adjustment coefficient corresponding to the environmental compensation amount. Environmental compensation amount The environmental compensation amount can be determined based on at least one of the following: the deviation of the current ambient light intensity from the calibrated ambient light intensity, the deviation of the current ambient light color temperature from the calibrated ambient light color temperature, and the degree of image feature fluctuation in the reference area. The greater the deviation of the current image acquisition environment from the calibrated environment, the greater the environmental compensation amount. The larger the threshold, the larger the adaptive color difference threshold can be.

[0077] Optionally, the dynamic adjustment coefficient can be predetermined based on multiple sets of calibration samples. For example, sample images of the indicator light under test in its standard operating and non-operating states can be collected under various ambient light intensities and color temperatures. By statistically analyzing the fluctuations in sample color difference values ​​under different environmental compensation levels and using a linear regression algorithm to fit the data, the proportional relationship between the environmental compensation level and the color difference fluctuation can be determined, and the proportionality constant corresponding to this relationship can be determined as the dynamic adjustment coefficient. For example, the dynamic adjustment coefficient can be a value in the range of 0.5 to 1.5.

[0078] Optionally, the detection device can perform the above verification on multiple consecutively acquired images. If the color difference value corresponding to a preset number of consecutive images is greater than the corresponding adaptive color difference threshold, it can be determined that the emission color indicated by the target emission state has failed the verification, and it can be determined that the indicator light under test has an abnormal color state.

[0079] In one exemplary embodiment, the first target information and the second target information, as well as the first reference information and the second reference information, may be obtained in the following manner, but not limited to: detecting the power supply status of the computer device; when the computer device is detected to be in a power-off state, obtaining the first target information and the first reference information; detecting first change information; when the first change information is detected to indicate that the power supply status of the computer device is switched from a power-off state to a power-on state, obtaining the second target information and the second reference information; when the computer device is detected to be in a power-on state, obtaining the second target information and the second reference information; detecting second change information; when the second change information is detected to indicate that the power supply status of the computer device is switched from a power-on state to a power-off state, obtaining the first target information and the first reference information.

[0080] Optionally, the power-on state can be a power supply state in which the computer equipment is connected to the power supply and the indicator light under test is ready to enter the working state; the power-off state can be a power supply state in which the computer equipment is disconnected from the power supply, or the power supply circuit where the indicator light under test is located stops supplying power, so that the indicator light under test is in a non-working state.

[0081] Figure 5 This is a schematic diagram of a scenario for detecting the execution indicator light according to an embodiment of this application, such as... Figure 5 As shown, the indicator light detection system may include a detection device 502, an image acquisition device 504, and a power supply device 506. The power supply device 506 is connected to the computer device under test and is used to turn the power supply of the computer device on or off; the image acquisition device 504 is positioned facing the computer device and is used to acquire reference images and measured images; the detection device 502 is connected to both the power supply device 506 and the image acquisition device 504 and is used to detect and / or control the power supply status of the computer device and control the image acquisition device 504 to acquire images.

[0082] For example, the testing equipment can be a test computer, the power supply equipment can be a Power Distribution Unit (PDU), the image acquisition equipment can be a camera, and the computer equipment can be the server under test. The testing equipment can query the on / off status of the power supply port connected to the server under test in the PDU to determine whether the server under test is powered on or off; it can also send power-on or power-off commands to the PDU and determine whether the power supply status of the server under test has changed based on the execution result returned by the PDU or the status change of the power supply port.

[0083] Optionally, the first change information and the second change information may be the instruction execution result returned by the power supply equipment, or information generated by the detection equipment based on the on / off status of the power supply port, the power supply status information returned by the computer equipment, or changes in the power supply voltage and current.

[0084] For example, when the server under test is initially powered off, the testing device can control the camera to acquire a reference image and obtain reference target information and reference information from the reference image; then, when it detects that the power supply port has changed from a disconnected state to a connected state, it determines that the first change information has been detected, and controls the camera to acquire the measured image and obtain the measured target information and the measured reference information.

[0085] Accordingly, when the server under test is initially powered on, the testing device can first obtain the actual target information and the actual reference information; then, when it detects that the power supply port has changed from the on state to the off state, it determines that the second change information has been detected, and obtains the benchmark target information and the benchmark reference information.

[0086] Optionally, after the computer device switches from a power-off state to a power-on state or vice versa, the detection device can acquire target information and reference information after a preset time period to avoid acquiring images before the power supply state has been switched or the status of the indicator light under test has stabilized.

[0087] This embodiment allows for the determination of the acquisition order of two sets of information based on the initial power supply status of the computer equipment, and the determination of the acquisition timing of the corresponding information based on changes in the power supply status. This improves the accuracy of the correspondence between the benchmark target information and benchmark reference information and the non-working state of the indicator light under test, as well as between the measured target information and measured reference information and the working state of the indicator light under test.

[0088] In one exemplary embodiment, the first target information and the first reference information may be obtained in the following manner, but not limited to: acquiring a first image including the indicator light under test; identifying the area where the indicator light under test is located in the first image to obtain a target area; filtering out a reference area from the areas in the first image other than the target area; extracting the first target information from the target area and extracting the first reference information from the reference area.

[0089] Optionally, the first image can be the aforementioned reference image. The detection device can identify the indicator light under test in the reference image based on its deployment position on the computer device. For example, the detection device can determine the corresponding area in the reference image based on the pre-recorded relative position of the indicator light under test on the computer device panel; alternatively, it can use contour detection, target recognition, or other image recognition methods to find an image area that matches the indicator light under test.

[0090] Optionally, after identifying the indicator light to be tested, the detection device can determine the area corresponding to the light-emitting component of the indicator light in the image or the image area within a preset range around the light-emitting component as the target area.

[0091] Optionally, the detection device can divide the area in the reference image other than the target area into at least one candidate area, and select a reference area from the candidate areas based on the image content, location, or imaging characteristics of the candidate areas. For example, the detection device can first exclude candidate areas containing other light-emitting components or interfaces, and then select from the remaining candidate areas a candidate area whose image feature changes are related to the image feature changes of the target area caused by the influence of environmental conditions as a reference area.

[0092] This embodiment enables the determination of target and reference regions from the same reference image, ensuring that the reference target information and reference reference information correspond to the same environmental conditions. This reduces potential time and environmental differences that may arise from separately acquiring the target and reference regions, thereby improving the reliability of the reference target information and reference reference information.

[0093] It is understandable that the extraction methods for measured target information and measured reference information are similar to those for benchmark target information and benchmark reference information. The difference is that the images used to extract benchmark target information and benchmark reference information are benchmark images, while the images used to extract measured target information and measured reference information are measured images.

[0094] It should be noted that, when acquiring the baseline target information and baseline reference information first, and then acquiring the measured target information and measured reference information, the detection equipment can first determine the target region and reference region in the baseline image, and then extract the measured target information and measured reference information from the target region and reference region in the measured image, respectively. Alternatively, when acquiring the measured target information and measured reference information first, and then acquiring the baseline target information and baseline reference information, the detection equipment can first save the measured image. After acquiring the baseline image and determining the target region and reference region from the baseline image, the measured target information and measured reference information can then be extracted from the saved measured image, respectively, from the target region and reference region.

[0095] In one exemplary embodiment, a reference region may be selected from the region other than the target region in a first image by, but not limited to, the following methods: acquiring a plurality of second images including a test indicator light, wherein the plurality of second images are acquired under different environmental conditions and the test indicator light is in a non-operating state, and the same object on the computer device is located in the same image region in the first image and the plurality of second images; acquiring target change information and at least one candidate change information, wherein the target change information is used to indicate the changes in image features of the target region with environmental conditions in the plurality of second images, and at least one candidate change information corresponds one-to-one with at least one candidate region, the candidate change information being used to indicate the changes in image features of the corresponding candidate region in the plurality of second images with environmental conditions, and the region in the first image other than the target region includes at least one candidate region; detecting the association state of at least one candidate region based on the target change information and at least one candidate change information, wherein the association state is used to indicate whether the synchronization degree between the image features of the candidate region and the image features of the target region with environmental conditions has reached a synchronization condition; and selecting a reference region from the at least one candidate region whose synchronization degree indicated by the association state has reached the synchronization condition.

[0096] Optionally, the multiple second images can be images acquired from the indicator light under test in a non-operating state under different ambient light intensities, ambient light color temperatures, and / or image acquisition parameters. When acquiring multiple second images, the acquisition pose of the image acquisition device can be fixed so that the same object on the computer device is located in the same image area.

[0097] Optionally, the detection device can divide the area in the reference image other than the target area into multiple candidate areas. The candidate areas can be divided according to preset size and preset shape, or according to the edges, material, or structure of the computer device surface.

[0098] Optionally, the detection device can select the environmental state corresponding to one of the multiple second images as the baseline environmental state, calculate the feature offset of the target region and each candidate region relative to the baseline environmental state under other environmental states, and form target change information and candidate change information corresponding to each candidate region based on the multiple feature offsets. The detection device can compare the target change information with each candidate change information, and determine whether the synchronization degree corresponding to the candidate region meets the synchronization condition based on whether the image feature change direction of the target region and the candidate region is consistent and whether the change trend is similar.

[0099] It should be noted that, since the target area may be covered by a light-transmitting cover made of plastic or glass, the response amplitude of the target area and the candidate area to the same environmental state change may differ. As long as the direction and / or trend of the image feature changes of the two meet the synchronization condition, it can be considered that the image feature changes of the candidate area affected by the environmental state are related to the image feature changes of the target area affected by the environmental state.

[0100] Figure 6 This is a schematic diagram illustrating a reference area filtering scenario according to an embodiment of this application. For example... Figure 6 As shown, the computer device's panel can be equipped with indicator lights A, B, and a test indicator light C. The area corresponding to test indicator light C in the image can be used as the target area. The detection device can divide the area in the image other than the target area into multiple candidate areas, such as candidate area 1 and candidate area 2, and select a reference area from the multiple candidate areas based on the changes in image features of each candidate area and the target area under different environmental conditions.

[0101] For example, images of the indicator light C under test in a non-working state were acquired under environmental conditions with color temperatures of 2700 K, 4000 K, and 6500 K, with a color temperature of 2700 K as the baseline environmental condition. The LAB feature offsets of the target region relative to the baseline environmental condition were (0, 0, 0), (4, 3, 7), and (8, 5, 12), respectively, while the LAB feature offsets of candidate region 1 relative to the baseline environmental condition were (0, 0, 0), (5, 3, 8), and (9, 6, 13), respectively. It can be seen that the feature components of candidate region 1 and the target region generally have the same direction of change and similar trends. Therefore, it can be determined that the synchronization degree corresponding to candidate region 1 meets the synchronization condition, and candidate region 1 is determined as the reference region.

[0102] The LAB feature offsets of candidate region 2 relative to the baseline environment state are (0, 0, 0), (-2, 8, 1), and (3, -5, 4), respectively. Since the feature components of candidate region 2 and the target region differ significantly in their direction and trend of change, it can be determined that the synchronization level of candidate region 2 has not met the synchronization conditions, and therefore candidate region 2 is not designated as the reference region.

[0103] Optionally, when there are multiple candidate regions that meet the synchronization conditions, the candidate region with the highest degree of synchronization can be determined as the reference region, or multiple candidate regions can be jointly determined as the reference region.

[0104] Through this embodiment, reference areas can be selected based on the synchronous changes of candidate areas and target areas under different environmental conditions. This allows the selected reference areas to more accurately reflect the impact of environmental changes on the target area, thereby improving the reliability of subsequent predictions of the environmental impact on the target area.

[0105] In one exemplary embodiment, target change information and at least one candidate change information may be obtained, but not limited to, by means of: extracting pixel features of multiple test regions in multiple second images, wherein the pixel features are used to indicate the pixel information of the corresponding test region in the corresponding second image, the multiple test regions include a target region and at least one candidate region; constructing information curves for each test region based on the pixel features of the multiple test regions and the environmental states corresponding to the multiple second images, wherein the information curves are used to indicate the changing trend of the pixel information of the corresponding test region with the environmental state, the target change information includes the information curve of the target region, and the at least one candidate change information includes the information curve of at least one candidate region.

[0106] Optionally, the detection device can extract pixel features of each test region from multiple second images. Pixel features may include color features, brightness features, pixel distribution features, or combinations of the above features of pixels within the test region. For example, the detection device can calculate the average, median, or weighted average of the LAB features of multiple pixels within the test region as the pixel features of that test region in the corresponding second image.

[0107] Optionally, the detection device can sort multiple environmental states based on at least one of the environmental parameters, including ambient light intensity, ambient light color temperature, and image acquisition parameters, and construct information curves for pixel information as a function of the corresponding environmental parameter. Here, the environmental parameter corresponding to the environmental state can be used as the independent variable, and the pixel information of the area to be measured can be used as the dependent variable. The information curve can be composed of multiple discrete feature points, or it can be obtained by fitting multiple discrete feature points.

[0108] When a pixel feature includes multiple feature components, the information curve of the region to be measured can include multiple feature curves corresponding to the multiple feature components. For example, when the pixel feature is an LAB feature vector, the information curve can include the curve of the brightness component L changing with the environmental state, the curve of the red-green component a changing with the environmental state, and the curve of the yellow-blue component b changing with the environmental state.

[0109] For example, under environmental conditions with color temperatures of 2700 K, 4000 K, and 6500 K, the LAB feature vectors extracted by the detection device from the target regions of the three second images are (42, 3, 12), (46, 4, 19), and (50, 8, 24), respectively. The detection device can construct the L-component curve, a-component curve, and b-component curve of the target region based on the color temperature and corresponding LAB feature vectors for the three environmental conditions, and use these curves as the information curves of the target region. Correspondingly, the detection device can construct the information curves of each candidate region in the same way.

[0110] Optionally, when the environmental conditions include multiple environmental parameters, the detection device can construct information curves for pixel information as a function of each environmental parameter.

[0111] In one exemplary embodiment, the association state of at least one candidate region can be detected based on target change information and at least one candidate change information in the following manner: detecting the similarity between target change information and candidate change information; comparing the similarity with a similarity threshold; if the similarity is greater than or equal to the similarity threshold, determining the association state of the candidate region associated with the candidate change information as a first association state, wherein the first association state is used to indicate that the synchronization degree has reached the synchronization condition; if the similarity is less than the similarity threshold, determining the association state of the candidate region associated with the candidate change information as a second association state, wherein the second association state is used to indicate that the synchronization degree has not reached the synchronization condition.

[0112] Optionally, similarity is used to represent the degree to which the pixel information of the candidate region and the pixel information of the target region change in the direction and trend of environmental state changes. The higher the similarity, the higher the degree of synchronization between the candidate region and the target region when affected by environmental state.

[0113] Optionally, when the pixel feature includes multiple feature components, the detection device can calculate the component similarity between the information curves corresponding to each feature component separately, and determine the comprehensive similarity based on the multiple component similarities. For example, when the pixel feature is an LAB feature vector, the similarity between the L component curve, the a component curve, and the b component curve can be calculated separately, and then the three component similarities can be averaged or weighted to obtain the similarity between the target change information and the candidate change information.

[0114] Optionally, before calculating similarity, the detection device can normalize the target change information and candidate change information to reduce the difference in the magnitude of change between the target region and the candidate region due to differences in material or color. Similarity can be calculated using correlation coefficient, cosine similarity, curve shape similarity, or other parameters that can represent the degree of similarity in change trends.

[0115] For example, the similarity between the information curves of the target region and candidate region 1 is 0.93, and the similarity between the information curves of the target region and candidate region 2 is 0.42, with a similarity threshold of 0.8. Since the similarity corresponding to candidate region 1 is greater than the similarity threshold, the association state of candidate region 1 can be determined as the first association state; since the similarity corresponding to candidate region 2 is less than the similarity threshold, the association state of candidate region 2 can be determined as the second association state. The similarity threshold can be calibrated based on pre-collected sample images.

[0116] This embodiment can quantify the degree of synchronous change between candidate regions and target regions under different environmental conditions, and filter reference regions based on the quantification results, thereby improving the accuracy of reference region filtering.

[0117] In an exemplary embodiment, before acquiring a first image including the indicator light under test, the following steps may be performed, but are not limited to: finding a target acquisition pose corresponding to the indicator light under test from a correspondence between indicator lights and acquisition poses, wherein the target acquisition pose is an acquisition pose that allows the acquisition of an image including the indicator light under test; controlling the image acquisition device to be positioned at the target acquisition pose, wherein the image acquisition device is used to acquire the first image.

[0118] Optionally, the acquisition pose may include the acquisition position and direction of the image acquisition device relative to the computer device, and may include, but is not limited to, at least one of horizontal position, vertical position, horizontal angle, pitch angle, or acquisition distance. The target acquisition pose may be an acquisition pose that places the indicator light under test within the acquisition range of the image acquisition device and ensures that the indicator light under test meets preset position, size, or acquisition angle requirements in the image.

[0119] Optionally, the correspondence between indicator lights and acquisition poses can be stored in the form of a mapping table or a configuration file. For example, the acquisition positions and directions corresponding to indicator lights A, B, and C on the computer device can be recorded separately. The detection device can find the target acquisition pose from the above correspondence based on the indicator light identifier carried in the detection request.

[0120] Optionally, the detection device can control the image acquisition device to move and / or rotate according to the target acquisition pose, and after the image acquisition device reaches the target acquisition pose, control the image acquisition device to acquire an image from the computer device to obtain a first image, i.e., a reference image. The image acquisition device can be mounted on a robotic arm, a moving platform, a slide rail, or a pan-tilt unit to adjust its acquisition position and / or acquisition direction. Even when the image acquisition device is already in the target acquisition pose, the detection device can also directly control the image acquisition device to acquire the first image.

[0121] Through this embodiment, the acquisition pose of the image acquisition device can be adjusted according to the position of the indicator light under test on the computer device, so that the first acquired image completely includes the indicator light under test, and the influence of differences in acquisition position and acquisition direction on the image features of the target area can be reduced.

[0122] In an exemplary embodiment, before searching for the target acquisition pose corresponding to the indicator light under test from the corresponding indicator lights and acquisition poses, the following steps may be performed, but are not limited to: controlling the image acquisition device to acquire an image of the computer device in at least one acquisition pose to obtain at least one device image; identifying the indicator light under test from the at least one device image; and, if a target device image including the indicator light under test is identified, determining the acquisition pose used when acquiring the target device image as the target acquisition pose, and establishing a correspondence between the indicator light under test and the target acquisition pose, wherein at least one acquisition pose includes the target acquisition pose.

[0123] Figure 7 This is a schematic diagram of an adjustable support structure for an image acquisition device according to an embodiment of this application. Figure 7 As shown, the adjustable bracket may include a fixing part 702, a rotating part 704, a telescopic part 706, and a mounting part 708. The fixing part 702 is used to fix the adjustable bracket to the inspection station; the rotating part 704 is used to adjust the acquisition direction of the image acquisition device relative to the computer device; the telescopic part 706 is used to adjust the acquisition distance between the image acquisition device and the computer device; and the mounting part 708 is used to mount the image acquisition device. The acquisition posture can be represented by parameters such as the rotation angle of the rotating part 704, the telescopic length of the telescopic part 706, and the acquisition direction of the image acquisition device.

[0124] In one optional embodiment, the adjustable bracket can be a three-axis gimbal, with a horizontal angle adjustment range of 360° and a pitch angle adjustment range of ±30°. The image acquisition device can also support electric focus adjustment to adjust the image size and clarity of the indicator light under test in the device image. When establishing the correspondence between the indicator light under test and the target acquisition pose, the detection device can control the rotating part 704 and / or the telescopic part 706 to move sequentially to at least one preset position, so that the image acquisition device can acquire images of the computer device in at least one acquisition pose to obtain at least one device image. The at least one acquisition pose can be determined sequentially according to a preset pose sequence, or it can be determined by adjusting the rotation angle and telescopic length within the preset pose range.

[0125] The detection equipment can identify whether each device image includes a test indicator light. For example, the detection equipment can identify each device image based on the deployment position or contour features of the test indicator light on the computer device. When a target device image including the test indicator light is identified, the detection equipment can acquire the rotation angle of the rotating part 704, the extension length of the telescopic part 706, and / or the acquisition direction of the image acquisition device when acquiring the target device image, determine the acquisition pose represented by the above parameters as the target acquisition pose, and establish a correspondence between the test indicator light and the target acquisition pose.

[0126] Optionally, when multiple device images include the indicator light under test, the testing device can filter the target device image from the multiple device images based on the completeness of the indicator light under test in the device images, image size, and clarity. For example, a device image in which the indicator light under test is fully displayed, the image size reaches a preset size, and the clarity is higher than a clarity threshold can be identified as the target device image.

[0127] Through this embodiment, by adjusting the acquisition direction and acquisition distance of the image acquisition device, the target acquisition pose that can be acquired by the indicator light under test can be automatically determined, and the correspondence between the indicator light under test and the target acquisition pose can be saved, reducing the time required to repeatedly search for the indicator light under test in the subsequent detection process.

[0128] In one exemplary embodiment, the indicator light under test can be identified from at least one device image by, but is not limited to, detecting the matching degree between each device image in the at least one device image and a standard device image, wherein the standard device image is an image of a computer device that includes the indicator light under test and is collected in advance; and determining candidate device images in the at least one device image whose matching degree with the standard device image is greater than or equal to a matching degree threshold as target device images.

[0129] Optionally, the standard device image can be an image of the computer device that includes the indicator light under test, which has been pre-captured. The testing device can calculate the matching degree between each device image and the standard device image. The matching degree is used to represent the degree of matching between the device image and the standard device image in terms of computer device outline, panel structure, interface position, etc. The higher the matching degree, the closer the computer device area presented by the corresponding device image is to the standard device image, and the higher the probability that the indicator light under test is located in that device image.

[0130] Optionally, the detection device can calculate the matching degree between the device image and the standard device image using image similarity. If there are differences in image size or shooting angle between the device image and the standard device image, the device image can be scaled, rotated, perspective-transformed, or registered before calculating the matching degree.

[0131] Optionally, the detection device can compare the matching degree between each device image and the standard device image with a matching degree threshold, and determine the candidate device image with a matching degree greater than or equal to the matching degree threshold as the target device image. If the matching degree of multiple candidate device images is greater than or equal to the matching degree threshold, the detection device can determine the candidate device image with the highest matching degree as the target device image.

[0132] Through this embodiment, it is possible to use pre-acquired standard device images to determine whether the device images obtained under each acquisition pose include the indicator light to be tested, thereby determining the target device image that can acquire the indicator light to be tested and its corresponding target acquisition pose.

[0133] In one exemplary embodiment, the matching degree between each device image in at least one device image and a standard device image can be detected by, but is not limited to, the following: searching for candidate display areas including at least one indicator light in each device image; extracting reference deployment features from the candidate display areas, wherein the reference deployment features are used to characterize the deployment position of at least one indicator light in the candidate display areas on a computer device; and matching the reference deployment features with target deployment features to obtain a matching degree, wherein the target deployment features are deployment features extracted from the standard device image to characterize the deployment position of the indicator light under test on the computer device.

[0134] Optionally, at least one indicator light can be identified from the device image based on its outline, size, or structure, and the image area where the at least one indicator light is located can be determined as a candidate display area.

[0135] Optionally, the reference deployment features may include the position of the indicator lights in the candidate display area relative to the panel, interface, characters, edge, or other fixed structure of the computer device, as well as the relative positions, arrangement orientation, and / or spacing between multiple indicator lights. Correspondingly, the target deployment features may include the position of the indicator light under test relative to the aforementioned fixed structure, as well as the relative positions, arrangement orientation, and / or spacing between the indicator light under test and other indicator lights.

[0136] Optionally, when the candidate display area includes multiple indicator lights, the detection device can identify each indicator light as a candidate indicator light, extract the reference deployment features corresponding to each candidate indicator light, and match each reference deployment feature with the target deployment features of the indicator light under test to obtain the candidate matching degree for each candidate indicator light. The detection device can determine the maximum value among multiple candidate matching degrees as the matching degree between the device image and the standard device image. The smaller the positional deviation, arrangement direction deviation, and / or spacing deviation between the reference deployment features and the target deployment features, the greater the matching degree obtained.

[0137] For example, in a standard device image, three indicator lights are arranged vertically in sequence, and the indicator light to be tested is the third indicator light from the bottom. If a candidate display area of ​​a device image also includes three indicator lights arranged vertically, and the position of the bottom indicator light relative to the panel edge and adjacent indicator lights is similar to the target deployment features, then the candidate matching degree corresponding to this candidate indicator light is relatively high, thus indicating a high matching degree between this device image and the standard device image. If the number, arrangement direction, or relative position of the indicator lights in the candidate display area differs significantly from the target deployment features, then the matching degree between the device image and the standard device image is relatively low.

[0138] Figure 8 This is a schematic diagram of the target acquisition pose determination process according to an embodiment of this application. Figure 8 As shown, the detection device can obtain the initial acquisition pose of the image acquisition device, determine the initial acquisition pose as the current acquisition pose, and control the image acquisition device to acquire the device image of the computer device under the current acquisition pose.

[0139] The detection device can identify candidate display areas that include at least one indicator light from a device image. Once a candidate display area is found, the detection device can extract reference deployment features corresponding to each candidate indicator light within the candidate display area, match each reference deployment feature with the target deployment features of the indicator light under test, and determine the maximum value among multiple candidate matching degrees as the matching degree between the current device image and the standard device image.

[0140] If the matching degree is greater than or equal to the matching degree threshold, candidate indicator lights in the current device image can be identified whose deployment positions match those of the indicator light under test. The detection device can then determine the current device image as the target device image, the current acquisition pose as the target acquisition pose, and establish a correspondence between the indicator light under test and the target acquisition pose.

[0141] If no candidate display area is found, or the matching degree is less than the matching degree threshold, the detection device can update the current acquisition pose and control the image acquisition device to re-acquire the device image in the updated current acquisition pose until a target device image with a matching degree greater than or equal to the matching degree threshold is obtained with respect to the standard device image.

[0142] The initial acquisition pose can be the acquisition pose when the image acquisition device begins to recognize the indicator light under test, or it can be a pre-set acquisition pose. The current acquisition pose can be updated by adjusting the acquisition position, acquisition direction, and / or acquisition distance of the image acquisition device.

[0143] This embodiment can identify the device image including the indicator light under test based on the deployment location of the indicator light under test on the computer device, reduce misidentification caused by multiple indicator lights having similar appearances, and determine the target acquisition pose that can be acquired from the indicator light under test.

[0144] In one exemplary embodiment, the third target information can be predicted based on the first target information, the first reference information, and the second reference information in the following manner: determining a target mapping parameter based on the first target information and the first reference information, wherein the target mapping parameter is used to indicate the mapping relationship between the image features of the reference area and the image features of the target area when the indicator light under test is in a non-working state; and mapping the second reference information using the target mapping parameter to obtain the third target information.

[0145] For example, if the baseline reference information is (60, 0, 0), the baseline target information is (38, -2, 3), and the measured reference information is (65, 5, 10), then the feature offset of the reference area when it changes from the first environmental state to the second environmental state is (5, 5, 10). The detection device can convert this feature offset into the effective feature offset (4, 4, 9) corresponding to the target area according to the target mapping parameters, and combine it with the baseline target information to obtain the compensated target information (42, 2, 12).

[0146] Optionally, the detection device can also perform validity checks on the compensation target information, for example, checking whether each feature component in the compensation target information falls within the corresponding preset value range. If the compensation target information fails the validity check, the compensation target information can be re-predicted after changing the reference area.

[0147] Optionally, the target mapping parameters may include correction coefficients corresponding to each image feature component, such as correction coefficients corresponding to the brightness component, the red-green component, and the yellow-blue component.

[0148] This embodiment can convert the environmental state influence reflected by the measured reference information into the image features that the target area is expected to present under the same environmental conditions.

[0149] In one exemplary embodiment, the target illumination state of the indicator light under test can be determined based on the second target information and the third target information in the following manner: determining target difference information based on the second target information and the third target information, wherein the target difference information is used to indicate the difference between the image features indicated by the second target information and the image features indicated by the third target information; and determining the target illumination state based on the target difference information.

[0150] Optionally, the detection device can compare the differences between the measured target information and the compensated target information in terms of color, brightness, and / or pixel distribution to obtain target difference information. Target difference information may include the differences between various image feature components, used to characterize the impact of the indicator light's own emission on the image features of the target area.

[0151] Optionally, the detection device can compare the overall difference between the luminance component and / or multiple color components in the target difference information with preset luminance detection conditions. If neither the luminance component difference nor the overall difference between multiple color components meets the luminance detection conditions, it can be determined that the indicator light under test is not emitting light; if either the luminance component difference or the overall difference between multiple color components meets the luminance detection conditions, it can be determined that the indicator light under test is emitting light. The overall difference between multiple color components can be determined based on the red-green component difference and the yellow-blue component difference.

[0152] Optionally, after determining that the indicator light under test has illuminated, the detection device can compare the red-green component difference and the yellow-blue component difference in the target difference information with the color component range corresponding to different luminous colors, and determine the luminous color of the indicator light under test based on the comparison results.

[0153] For example, if the measured target information is a LAB feature vector (70, 10, 65) and the compensated target information is a LAB feature vector (42, 2, 12), the detection device can determine the target difference information between the two as (28, 8, 53). If the preset luminance detection conditions include a luminance component difference greater than 10, or a combined difference of multiple color components greater than a preset threshold, then since the luminance component difference in this target difference information is 28, which is greater than 10, it can be determined that the target difference information meets the luminance detection conditions, and thus it can be determined that the indicator light under test has emitted light.

[0154] Furthermore, the detection equipment can match the target difference information with the standard difference features corresponding to different emission colors. For example, the standard difference features corresponding to the yellow emission state may include: the luminance component difference is between 20 and 35, the red-green component difference is between 0 and 15, and the yellow-blue component difference is between 40 and 60. Since the target difference information (28, 8, 53) falls within the above feature range corresponding to the yellow emission state, the emission color of the indicator light under test can be determined to be yellow.

[0155] For example, if the target difference information between the measured target information and the compensated target information is (3, 1, 2), and the difference in the brightness component and the overall difference in multiple color components in this target difference information do not meet the luminous emission detection conditions, then it can be determined that the indicator light under test is not emitting light.

[0156] Optionally, when detecting whether the indicator light under test is flashing, the detection device can continuously acquire multiple frames of images at a acquisition cycle of once every 0.5 seconds, and determine the target difference information corresponding to each acquisition moment. If the target difference information corresponding to multiple acquisition moments alternately meets and does not meet the light emission detection condition, for example, the target difference information corresponding to the 1st, 3rd, and 5th acquisition moments meets the light emission detection condition, while the target difference information corresponding to the 2nd, 4th, and 6th acquisition moments does not meet the light emission detection condition, then it can be determined that the indicator light under test is in a flashing state, and the corresponding flashing period and flashing frequency are determined according to the time interval between two adjacent entry into the light emission state. If the target difference information corresponding to multiple consecutive acquisition moments meets the light emission detection condition, and the corresponding light emission color remains unchanged, then it can be determined that the indicator light under test is in a continuous light emission state of the corresponding color.

[0157] Optionally, the detection equipment can determine the comparison weights and / or luminescence detection conditions corresponding to different color components based on the environmental parameters or measured reference information corresponding to the second environmental state, and process the target difference information using the determined comparison weights. For example, in a warm light environment with a yellowish tint, the influence of the yellow and blue components on the luminescence state judgment result can be reduced, or the difference threshold corresponding to the yellow and blue components can be increased accordingly to reduce the misjudgment of the luminescence state caused by the residual influence of the warm light environment.

[0158] Through this embodiment, the difference between the measured target information and the compensated target information can be used to represent the changes in image features caused by the illumination of the indicator light under test, and based on this, it can be determined whether the indicator light under test is emitting light and the corresponding emitting color and timing state.

[0159] In one exemplary embodiment, a test request may be received, but is not limited to, by: detecting a received test task for a computer device; and determining that a test request has been received if the test task is detected to be for testing a target function of the computer device, wherein the target function is a device function of the computer device that allows the indicator light under test to indicate the function status.

[0160] Optionally, test tasks can be triggered by personnel or sent by automated testing systems, production testing platforms, or other control equipment. For example, personnel can select the computer equipment to be tested and the target function to be tested in the interface provided by the testing system, and generate a test task by clicking a button, triggering a command, or performing other triggering operations. The target function may include functions such as computer equipment startup, component self-test, fault detection, data reading and writing, network communication, or equipment positioning.

[0161] Optionally, the testing equipment can parse the device identifier, function identifier, test items, and / or test procedures carried in the test task to determine the computer device to be tested and its target function. Based on a pre-established correspondence between device functions and indicator lights, it can locate the indicator light under test used to indicate the functional status of the target function. If the indicator light under test corresponding to the target function is found, it can be determined that the test task includes a testing requirement to detect the illumination status of that indicator light, thus confirming that a testing request has been received.

[0162] In one alternative implementation, when the test task is used to test the startup function of the server, and the startup function allows the indicator light C to indicate the function status, the startup function can be identified as the target function, the indicator light C can be identified as the indicator light to be tested, and a detection request for detecting the illumination status of the indicator light C can be received.

[0163] Figure 9 This is a schematic diagram of the interface of a test system according to an embodiment of this application. For example... Figure 9 As shown, the interface of the testing system may include an image display area, a test parameter configuration area, a communication parameter configuration area, a function operation area, and a test status display area. It is understandable that... Figure 9 The interface layout shown is only an example. The test system can add or remove input boxes, configuration items, operation buttons, and status display content according to actual test needs.

[0164] The image display area can be used to display images of the server under test captured by the camera in real time. For example, the image display area can be implemented using a custom image display control (CustomGraphicsView) or a graphics view control (QGraphicsView), and can display the indicator light under test, the target area, and the reference area. The test system can also save the images captured by the camera and the recorded videos.

[0165] The test parameter configuration area can be used to configure the serial number of the whole machine, the number of AC power cycles (equivalent to the preset number of startups), the power-off duration, the power-on duration, the power supply port and the image acquisition cycle. It can also be used to set whether to record video automatically during the test, as well as the saving format and location of images, videos, logs and test reports.

[0166] The communication parameter configuration area can be used to configure PDU communication parameters, IPMI (Intelligent Platform Management Interface) communication parameters, and BMC (Baseboard Management Controller) access parameters. PDU communication parameters can include the PDU's network address, communication port, login information, power supply port for connection to the server under test, and the communication protocol used. IPMI communication parameters can include the management network address, login information, and command parameters for obtaining system event logs. BMC access parameters can include the BMC's management address, login information, and the hardware status information or log type to be obtained. These communication parameters can be entered and modified through the configuration dialog box (ConfigDialog) or the corresponding menu configuration items.

[0167] The function operation area can be equipped with buttons for turning on the camera, turning off the camera, taking a photo test, recording a video test, clearing the area, starting the test, and stopping the test. Staff can also use these buttons to draw or clear target and reference areas in the image display area.

[0168] The test status display area can include a progress bar, status labels, and a log output area. The progress bar can display the completion percentage of the current test task, or the relationship between the current number of starts and the preset number of starts. Status labels can display the current test status of the server under test, such as power-down, power-on, startup, image acquisition, log acquisition, anomaly analysis, or report generation. The log output area can display PDU control results, camera control results, IPMI or BMC access results, image detection results, and anomaly information during the test in real time.

[0169] Figure 10This is a schematic diagram illustrating a scenario of performing a test task according to an embodiment of this application. For example... Figure 10 As shown, the test computer 1001, power supply 1002, camera 1003, and server under test 1004 can be communicatively connected to the network switch 1005 via network cable 1007. The power supply 1002 is connected to the server under test 1004 via power cord 1006. The camera 1003 is positioned facing the server under test 1004, which can be placed in a rack 1008. In an optional embodiment, the test computer 1001 can be a testing device and run a test system; the power supply 1002 can be a PDU. The test computer 1001 can control the power supply status of the server under test 1004 via the power supply 1002 and control the camera 1003 to acquire images including the indicator light under test. The camera 1003 can be mounted on an adjustable bracket to adjust its acquisition position.

[0170] Optionally, during the test, the image display area can continuously display images captured by the camera, the test status display area can synchronously update the test progress, current test status and test logs, and the test system can synchronously save images, videos and test logs.

[0171] In one exemplary embodiment, after determining the target illumination state of the indicator light under test based on the second target information and the third target information, the following steps may be performed, but are not limited to: acquiring the target execution progress, wherein the target execution progress is the execution progress of the target function by the computer device when acquiring the image used to extract the second target information; determining a reference illumination state of the indicator light under test based on the target execution progress, wherein the reference illumination state is used to indicate the expected illumination state of the indicator light under test when the target function is executed to the target execution progress; detecting an abnormal illumination state of the indicator light under test based on the target illumination state and the reference illumination state; if an abnormal illumination state is detected to indicate that the indicator light under test has an abnormal illumination state, acquiring a test log, wherein the test log is used to indicate the execution status of the target function by the computer device; and detecting the cause of the abnormal illumination state based on the test log.

[0172] Optionally, when the target function is the startup function, the target execution progress can be used to indicate whether the server is in an execution phase such as power-on initialization, hardware self-test, operating system loading, or startup completion. The testing device can determine the execution phase the server is in at the image acquisition time based on the image acquisition time corresponding to the second target information, as well as the start and end times of each execution phase recorded by the test system, and define this execution phase as the target execution progress.

[0173] Optionally, the testing equipment can pre-establish a correspondence between different execution progresses of the target function and the reference illumination state of the indicator light under test. The reference illumination state can include whether it is emitting light, the color of the light, the brightness of the light, whether it is flashing, the flashing period, or the color switching sequence. For example, when the server is in the power-on initialization phase, the reference illumination state of the indicator light under test C can be flashing yellow; when the server is in the hardware self-test phase, the reference illumination state of the indicator light under test C can be continuously emitting yellow; when the server has successfully started up, the reference illumination state of the indicator light under test C can be continuously emitting green.

[0174] Optionally, the detection device can compare the target illumination state with the reference illumination state to see if they are consistent in terms of whether or not the light is emitted, the color of the light emitted, and / or the timing of the light emitted. If they are consistent, it can be determined that the indicator light under test does not have an illumination abnormality; if they are inconsistent, it can be determined that the target illumination state does not match the reference illumination state. For example, if the reference illumination state is a continuous green light, while the target illumination state is not emitting light, emitting red light, or flashing yellow light, it can be determined that the target illumination state does not match the reference illumination state.

[0175] Since the discrepancy between the target's emission state and the reference emission state could be caused by an abnormality in the indicator light itself or by an abnormality in the computer equipment during the execution phase corresponding to the target's execution progress, the testing equipment can acquire test logs generated around the image acquisition time and further investigate the cause of the abnormality based on the test logs. The test logs may include at least one of the following: test system logs, basic input / output system logs, baseboard management controller logs, system event logs, operating system logs, or functional test logs corresponding to the target function.

[0176] In one exemplary embodiment, the cause of the abnormal illumination may be detected based on the test log in the following manner, but is not limited to: detecting whether the target function has been executed normally to the target execution progress based on the test log and target log information, wherein the target log information is used to indicate the log information expected to be recorded during the process of the computer device normally executing the target function to the target execution progress; if the target function is detected to have been executed normally to the target execution progress, the cause of the abnormality is determined to be an abnormal indicator light under test; if the target function is detected to have not been executed normally to the target execution progress, the cause of the abnormality is determined to include a computer device abnormality.

[0177] Optionally, the target log information may include at least one of the following: log identifier, log content, log type, or log generation order that should be generated when the computer device normally executes the target function to the target execution progress. The detection device can detect whether the test log includes the log indicated by the target log information, and whether the content, generation time, and / or generation order of the corresponding log meet preset conditions, and determine whether the computer device has normally executed the target function to the target execution progress based on the detection results.

[0178] If the test log matches the target log information, indicating that the computer device has successfully executed the target function to the target execution progress, but the target illumination state is inconsistent with the reference illumination state, the cause of the anomaly can be determined to be a faulty indicator light under test. Faulty indicator lights under test can include faulty light-emitting components, connection faults, driver faults, or control faults.

[0179] If the test log lacks the logs indicated by the target log information, the generation order of the corresponding logs does not meet the preset conditions, or the test log includes logs indicating that the target function failed to execute, it can be determined that the computer equipment did not execute the target function normally to the target execution progress, and the cause of the anomaly can be identified as a computer equipment malfunction. In this case, the discrepancy between the target illumination state and the reference illumination state may be due to the computer equipment not executing to the expected progress, rather than necessarily a malfunction in the indicator light under test itself.

[0180] For example, if the target function is the startup function, the target execution progress is used to indicate that the server has reached the hardware self-test completion stage, and the target log information includes hardware self-test success logs, then if the test log includes hardware self-test success logs but the target illumination state is inconsistent with the reference illumination state, it can be determined that the server has completed the hardware self-test normally, and the cause of the anomaly is determined to be an abnormal indicator light under test; if the test log does not include hardware self-test success logs, or the test log includes hardware self-test failure logs, it can be determined that the server has not normally reached the hardware self-test completion stage, and the cause of the anomaly is determined to be at least a server malfunction.

[0181] This embodiment can be used to verify whether the computer device has successfully executed the target function to the target execution progress using test logs, and can distinguish between abnormal indicator lights under test and abnormal execution of the target function by the computer device based on the verification results, thereby improving the accuracy of abnormality detection.

[0182] Optionally, in this embodiment, in order to better understand the indicator light detection process of the above-mentioned computer device, the following uses the server loop startup test as an example to describe the indicator light detection process of the above-mentioned computer device, but it is not intended to limit the technical solution of the embodiment of this application. Figure 11 This is a schematic diagram of the server loop startup test process according to an embodiment of this application. Figure 11 As shown, the process may include the following steps:

[0183] Step S1101: Initialize test parameters.

[0184] The test system reads the serial number of the server under test, D1, as "D1-001", with a preset startup count of 10, a power-on duration of 180 seconds, a power-off duration of 30 seconds, and an image acquisition cycle of 1 second. It also confirms that server D1 is connected to the 6th power supply port of the intelligent power supply PDU. Based on the serial number "D1-001" and the identifier "C" of the indicator light under test, the test system can locate the pre-saved target acquisition pose, target area, and reference area. For example, the target area could be the circular region of interest located on the front panel of server D1 where indicator light C is located, and the reference area could be the chassis area to the left of indicator light C. The test system can initialize the current startup count to 0 and execute step S1102.

[0185] Optionally, the camera can be warmed up for 5 minutes before starting image acquisition to reduce the impact of unstable imaging state during the initial startup of the camera.

[0186] Step S1102: Control the server under test to start.

[0187] Before the control server D1 is started, server D1 is powered off, and the indicator light C under test is in a non-working state. The test system controls the camera to acquire 30 reference images at 1-second intervals. The LAB color features of pixels in the target area of ​​the 30 reference images are extracted and the average value is calculated to obtain the reference target information. At the same time, the LAB color features of pixels in the reference area of ​​the 30 reference images are extracted and the average value is calculated to obtain the reference reference information.

[0188] Subsequently, the test system updates the current startup count from 0 to 1 and sends a command to the intelligent power supply PDU to enable the 6th power supply port, causing server D1 to switch from the power-off state to the power-on state and begin startup. The test system reads the port status returned by the intelligent power supply PDU, and after confirming that the 6th power supply port has been connected, it begins to record the power-on duration of this startup test and executes step S1103.

[0189] Step S1103: Detect the illumination status of the indicator light under test.

[0190] While server D1 is powered on, the test system continuously acquires test images of the indicator light C under test at a 1-second image acquisition cycle, and records the acquisition time of each test image. The test system uses each acquired test image as the current test image and repeats the following steps until an abnormal luminescence is detected in indicator light C under test, or the power-on duration reaches a preset 180 seconds:

[0191] (1) Extract the LAB color features of pixels from the target area of ​​the current measured image and calculate the average value to obtain the measured target information; extract the LAB color features of pixels from the reference area of ​​the current measured image and calculate the average value to obtain the measured reference information.

[0192] (2) Based on the benchmark target information, benchmark reference information and measured reference information, the compensation target information is predicted;

[0193] (3) Compare the measured target information with the compensated target information to determine the target illumination state of the indicator light C to be tested;

[0194] (4) Based on the acquisition time of the current measured image and the test execution progress, determine the target execution progress of the server D1 for the start function, and determine the reference luminous state corresponding to the target execution progress;

[0195] (5) Compare the target light emission state with the reference light emission state to determine whether the indicator light C under test has any light emission abnormality.

[0196] If the target luminous state does not match the reference luminous state, it is determined that the indicator light C under test has an luminous abnormality. The acquisition time of the current measured image is recorded as the time of the abnormality occurrence. The target luminous state and the reference luminous state are also recorded. Processing of subsequent measured images is stopped, and step S1104 is executed.

[0197] If the target illumination state matches the reference illumination state, it is determined that the indicator light C under test is illuminating normally at the current acquisition time, and it is determined whether the power-on duration of server D1 has reached the preset 180 seconds. If the power-on duration has not reached 180 seconds, the next measured image is acquired and processed as the current measured image; if the power-on duration reaches 180 seconds, and no abnormal illumination of indicator light C under test is detected during the power-on process, the indicator light detection during the power-on process ends, and step S1106 is executed.

[0198] Step S1104: Obtain test logs.

[0199] If an abnormality is detected in the indicator light C under test, the testing system can retrieve test logs generated within a preset time range before and after the time of the abnormality. For example, if the testing system detects an abnormality in indicator light C 95 seconds after server D1 is powered on, the testing system can call the corresponding log retrieval interface to obtain test logs generated between 85 and 105 seconds after server D1 is powered on. After obtaining the test logs, step S1105 is executed.

[0200] Step S1105: Determine the cause of the abnormality.

[0201] The testing system can determine the target log information that should be recorded when server D1 normally executes the startup function to the target execution progress when the exception occurs, based on the target execution progress of the startup function when the exception occurs, and match the test log with the target log information.

[0202] For example, at the time of the anomaly, server D1 should have already reached the hardware self-test completion stage in the target execution progress indicator for the startup function, and the target log information should include a successful hardware self-test log. If the test log does not include a successful hardware self-test log, but includes error logs such as "DIMM training failed," indicating that the Dual In-line Memory Module (DIMM) training has failed, it can be determined that server D1 did not normally reach the hardware self-test completion stage, and the cause of the anomaly can be identified as a memory anomaly of server D1. After determining the cause of the anomaly, step S1106 is executed.

[0203] If the test log includes a hardware self-test success log, and the content, generation time, and generation order of the corresponding log meet the preset conditions, it indicates that server D1 has successfully completed the hardware self-test. Therefore, the cause of the anomaly can be determined as an error in the indicator light C under test. After determining the cause of the anomaly, proceed to step S1106.

[0204] Step S1106: Record the test report.

[0205] The testing system can record the number of times the test was started, the time of the anomaly, the target emission state, the reference emission state, the cause of the anomaly, and the corresponding image detection results. The image detection results can include a baseline image, a measured image, an image marked with the target region and / or reference region, anomaly regions with detected color differences, and the degree of color difference corresponding to each anomaly region.

[0206] For example, if the testing system detects an abnormal emission 95 seconds after the server D1's first startup, it can record: "An abnormal emission occurred 95 seconds after the server's first startup. The target emission state is yellow, the reference emission state is continuous green, and the cause of the abnormality is DIMM training failure." Simultaneously, the testing system can save the baseline image used for this detection and the measured image acquired at the 95th second. It can mark the abnormal regions with detected color differences in the measured images and record the degree of color difference corresponding to each abnormal region. For example, it can record: "The color difference degree of the target region is 73.7%."

[0207] If no abnormal light emission is detected in server D1 during this power-on process, the test system can record "Server starts normally for the first time" and save the image acquisition time, target light emission status, reference image and measured image corresponding to this startup test.

[0208] After recording the results of this startup test, proceed to step S1107.

[0209] Step S1107: Determine whether to end the loop start test.

[0210] The testing system can determine whether to terminate the loop startup test of server D1 based on the current number of startups, the preset number of startups, and the preset exception handling method.

[0211] For example, if the current startup count is 1, the preset startup count is 10, and the test system adopts the processing method of stopping the test after completing all preset startup counts, then after the power-on time of server D1 reaches 180 seconds, the test system can send a power supply port 6 shutdown command to the intelligent power supply PDU, causing server D1 to switch from the power-on state to the power-off state. After server D1 remains in the power-off state for 30 seconds, if the current startup count has not yet reached 10, the test system can return to step S1102, update the current startup count from 1 to 2, and execute the second startup test; if the current startup count has reached 10, then step S1108 is executed.

[0212] If the testing system adopts the method of stopping the test immediately after detecting an anomaly, then after detecting the abnormal light emission and determining the cause of the anomaly, the server D1 is powered down and step S1108 is executed.

[0213] Step S1108: Generate a test report.

[0214] The testing system can generate a cyclic startup test report for server D1 based on the test results of each startup test. The test report can summarize and record the server D1's serial number "D1-001", the planned number of startups (10), the actual number of startups completed, the power-on and power-off times for each startup, the target illumination status detected in each anomaly detection, and the corresponding anomaly diagnosis results. For example, for an anomaly detected in the first startup test, the test report can include the original image acquired 95 seconds after server D1 powers on, images marked with the target and reference areas, detection result images of areas marked with color differences, the degree of color difference corresponding to each anomaly area, the target illumination status, the reference illumination status, the cause of the anomaly, and key log segments automatically associated with the anomaly.

[0215] After generating the test report, the test system ends the current cycle startup test of server D1.

[0216] Optionally, the testing system can also perform parallel cyclic startup tests on servers D1 and D2 simultaneously. For example, server D1 is connected to the 6th power supply port of the intelligent power supply PDU, and server D2 is connected to the 7th power supply port. The testing system can independently record the current startup count, power supply status, image acquisition time, target emission status, emission anomaly status, and test logs for servers D1 and D2 respectively. When server D1 meets the stop test conditions, the testing system can terminate the cyclic startup test of server D1 independently without affecting server D2's continued execution of its remaining cyclic startup test process.

[0217] Through this embodiment, the testing system can automatically complete server power-on / off control, indicator light status detection, abnormal light detection, test log acquisition, abnormal cause judgment, and test report generation. By matching abnormal images with test logs for the corresponding time period, it can distinguish between computer equipment abnormalities and abnormal indicator lights under test, thereby improving testing efficiency and accuracy.

[0218] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods according to the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method.

[0219] Based on this understanding, the technical solution of this application, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods of the various embodiments of this application.

[0220] This embodiment also provides a detection device for indicator lights of a computer device. This device is used to implement the above embodiments and preferred embodiments, and will not be repeated as already described. As used below, the term "module" can be a combination of software and / or hardware that implements a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.

[0221] Figure 12 This is a structural block diagram of a detection device for an indicator light of a computer device according to an embodiment of this application, such as... Figure 12 As shown, it includes:

[0222] The receiving module 1202 is used to receive a detection request, wherein the detection request is used to request the detection of the illumination status of the indicator light under test on the computer device;

[0223] The response module 1204 is used to respond to a detection request, acquire first target information and second target information, as well as first reference information and second reference information. The first target information is used to indicate the image features of the target area in the first environmental state and when the indicator light under test is in a non-working state. The second target information is used to indicate the image features of the target area in the second environmental state and when the indicator light under test is in a working state. The first reference information is used to indicate the image features of the reference area in the first environmental state. The second reference information is used to indicate the image features of the reference area in the second environmental state. The target area is the area corresponding to the indicator light under test, and the reference area is the area affected by the same environmental state as the target area.

[0224] The prediction module 1206 is used to predict third target information based on first target information, first reference information and second reference information, wherein the third target information is used to indicate the image features of the target area in the second environmental state and when the indicator light under test is in a non-working state.

[0225] The determination module 1208 is used to determine the target illumination state of the indicator light under test based on the second target information and the third target information, wherein the target illumination state is used to indicate the actual illumination state of the indicator light under test in the working state.

[0226] The detection device provided in this application embodiment is also used to perform the steps in the above-described computer device indicator light detection method embodiment. For the description of the features of the detection device corresponding to the embodiment, please refer to the relevant description of the computer device indicator light detection method embodiment, which will not be repeated here.

[0227] It should be noted that the above modules can be implemented by software or hardware. For the latter, they can be implemented in the following ways, but are not limited to: all the above modules are located in the same processor; or, the above modules are located in different processors in any combination.

[0228] Embodiments of this application also provide an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to perform the steps in the embodiment of the indicator light detection method for any of the computer devices described above.

[0229] In one exemplary embodiment, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor and the input / output device is connected to the processor.

[0230] Specific examples in this embodiment can be found in the examples described in the above embodiments and exemplary implementations, and will not be repeated here.

[0231] Embodiments of this application also provide a computer-readable storage medium storing a computer program, wherein the computer program is configured to execute the steps in the embodiments of the indicator light detection method for any of the above-described computer devices when it is run.

[0232] In one exemplary embodiment, the aforementioned computer-readable storage medium may include, but is not limited to, various media capable of storing computer programs, such as a USB flash drive, read-only memory (ROM), random access memory (RAM), portable hard disk, magnetic disk, or optical disk.

[0233] The embodiments of this application also provide a computer program product, which includes a computer program that, when executed by a processor, implements the steps in the embodiments of the indicator light detection method for any of the above-described computer devices.

[0234] Embodiments of this application also provide another computer program product, including a non-volatile computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps in the embodiments of the indicator light detection method for any of the above-described computer devices.

[0235] Any of the components, modules, units, parts, methods, and operations described herein can be implemented using software, firmware, hardware (e.g., fixed logic circuitry), manual processing, or any combination thereof. Alternatively or additionally, any functionality described herein can be performed at least in part by one or more hardware logic components, such as, but not limited to, CPUs, FPGAs, Application-Specific Integrated Circuits (ASICs), Application-Specific Standard Products (ASSPs), Systems on Chips (SoCs), Complex Programmable Logic Devices (CPLDs), Microcontroller Units (MCUs), etc. The terms "system," "computing device," or "apparatus" used herein encompass various means, devices, and machines for processing data, including, for example, one or more programmable processors, computers, SoCs, or combinations thereof. The apparatus may also include code that creates an execution environment for the computer program in question, such as code constituting processor firmware, protocol stacks, database management systems, operating systems, cross-platform runtime environments, virtual machines, or combinations thereof. The aforementioned computer program (also known as a program, software, software application, application (APP), script, or code) can be written in any form of programming language, including compiled or interpreted languages, declarative or procedural languages, and can be deployed in any form, including as a standalone program or as a module, component, subroutine, object, or other unit suitable for a computing environment.

[0236] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0237] The foregoing has provided a detailed description of a method for detecting an indicator light on a computer device and an electronic device provided in this application. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the embodiments above are merely for the purpose of helping to understand the method and its core ideas. It should be noted that those skilled in the art can make various improvements and modifications to this application without departing from its principles, and these improvements and modifications also fall within the protection scope of the claims of this application.

Claims

1. A method for detecting indicator lights in a computer device, characterized in that, include: Receive a detection request, wherein the detection request is used to request the detection of the illumination status of the indicator light under test on the computer device; In response to the detection request, first target information and second target information, as well as first reference information and second reference information are obtained. The first target information indicates the image features of the target area under a first environmental state and when the indicator light under test is in a non-working state. The second target information indicates the image features of the target area under a second environmental state and when the indicator light under test is in a working state. The first reference information indicates the image features of a reference area under the first environmental state. The second reference information indicates the image features of the reference area under the second environmental state. The target area is the area corresponding to the indicator light under test, and the reference area is the area affected by the same environmental state as the target area. A third target information is predicted based on the first target information, the first reference information, and the second reference information, wherein the third target information is used to indicate the image features of the target area in the second environmental state and the indicator light under test is in the non-working state; The target illumination state of the indicator light under test is determined based on the second target information and the third target information, wherein the target illumination state is used to indicate the actual illumination state of the indicator light under test in the working state; The reference area is determined by the following method: acquiring a first image including the indicator light under test; identifying the area where the indicator light under test is located in the first image to obtain the target area; and filtering out the reference area from the areas in the first image other than the target area. The step of selecting the reference region from the regions in the first image other than the target region includes: Acquire multiple second images including the indicator light under test, wherein the multiple second images are acquired under different environmental conditions and the indicator light under test is in the non-working state, and the same object on the computer device is located in the same image area in the first image and the multiple second images; Acquire target change information and at least one candidate change information, wherein the target change information is used to indicate the changes in image features of the target region in the plurality of second images as environmental conditions change, the at least one candidate change information corresponds one-to-one with at least one candidate region, the candidate change information is used to indicate the changes in image features of the corresponding candidate region in the plurality of second images as environmental conditions change, and the region in the first image other than the target region includes the at least one candidate region; The association status of at least one candidate region is detected based on the target change information and the at least one candidate change information, wherein the association status is used to indicate whether the synchronization degree between the image features of the candidate region and the image features of the target region as the environmental state changes has reached the synchronization condition; From the at least one candidate region, the reference region whose synchronization degree indicated by the association state reaches the synchronization condition is selected; The step of detecting the association status of the at least one candidate region based on the target change information and the at least one candidate change information includes: Detect the similarity between the target change information and the candidate change information; Compare the stated similarity with the similarity threshold; If the similarity is greater than or equal to the similarity threshold, the association state of the candidate region associated with the candidate change information is determined as the first association state, wherein the first association state is used to indicate that the synchronization degree has reached the synchronization condition; The step of predicting the third target information based on the first target information, the first reference information, and the second reference information includes: Target mapping parameters are determined based on the first target information and the first reference information, wherein the target mapping parameters are used to indicate the mapping relationship between the image features of the reference area and the image features of the target area when the indicator light under test is in the non-working state; The second reference information is mapped using the target mapping parameters to obtain the third target information.

2. The method according to claim 1, characterized in that, The acquisition of the first target information and the second target information, as well as the first reference information and the second reference information, includes: Detect the power supply status of the computer device; When the computer device is detected to be in a power-off state, the first target information and the first reference information are acquired; first change information is detected; when the first change information is detected to indicate that the power supply state of the computer device is switched from the power-off state to the power-on state, the second target information and the second reference information are acquired. When the computer device is detected to be in a powered-on state, the second target information and the second reference information are acquired; second change information is detected; when the second change information is detected to indicate that the power supply state of the computer device is switched from the powered-on state to the powered-off state, the first target information and the first reference information are acquired.

3. The method according to claim 2, characterized in that, The step of obtaining the first target information and the first reference information includes: The first target information is extracted from the target region, and the first reference information is extracted from the reference region.

4. The method according to claim 1, characterized in that, The acquisition of target change information and at least one candidate change information includes: Pixel features of multiple test regions in multiple second images are extracted, wherein the pixel features are used to indicate the pixel information of the corresponding test region in the corresponding second image, and the multiple test regions include the target region and the at least one candidate region; Based on the pixel features of the plurality of test regions and the environmental states corresponding to the plurality of second images, information curves are constructed for each of the test regions. The information curves are used to indicate the changing trend of the pixel information of the corresponding test region with the environmental state. The target change information includes the information curve of the target region, and the at least one candidate change information includes the information curve of the at least one candidate region.

5. The method according to claim 3, characterized in that, Before acquiring the first image including the indicator light under test, the method further includes: Find the target acquisition pose corresponding to the indicator light under test from the corresponding indicator lights and acquisition poses, wherein the target acquisition pose is an acquisition pose that allows the acquisition of an image including the indicator light under test; The image acquisition device is positioned at the target acquisition pose, wherein the image acquisition device is used to acquire the first image.

6. The method according to claim 5, characterized in that, Before searching for the target acquisition pose corresponding to the indicator light to be tested from the corresponding indicator lights and acquisition poses, the method further includes: The image acquisition device is controlled to acquire images of the computer device in at least one acquisition pose, thereby obtaining at least one device image; Identify the indicator light under test from the image of at least one device; When a target device image including the indicator light under test is identified, the acquisition pose used when acquiring the target device image is determined as the target acquisition pose, and a correspondence between the indicator light under test and the target acquisition pose is established, wherein the at least one acquisition pose includes the target acquisition pose.

7. The method according to claim 6, characterized in that, The step of identifying the indicator light under test from the at least one device image includes: The matching degree between each device image in the at least one device image and a standard device image is detected, wherein the standard device image is an image of the computer device that includes the indicator light to be tested, which was collected in advance; Candidate device images whose matching degree with the standard device image is greater than or equal to the matching degree threshold among the at least one device images are determined as the target device images.

8. The method according to claim 7, characterized in that, The detection of the matching degree between each device image in the at least one device image and the standard device image includes: From the images of each device, identify candidate display areas that include at least one indicator light; Extract reference deployment features from the candidate display area, wherein the reference deployment features are used to characterize the deployment position of the at least one indicator light in the candidate display area on the computer device; The reference deployment features are matched with the target deployment features to obtain the matching degree, wherein the target deployment features are deployment features extracted from the standard device image to characterize the deployment position of the indicator light under test on the computer device.

9. The method according to claim 1, characterized in that, Determining the target illumination state of the indicator light under test based on the second target information and the third target information includes: Target difference information is determined based on the second target information and the third target information, wherein the target difference information is used to indicate the difference between the image features indicated by the second target information and the image features indicated by the third target information; The target luminescence state is determined based on the target difference information.

10. The method according to claim 1, characterized in that, The receiving of the detection request includes: Detect the received test tasks for the computer device; If the test task is detected to be for testing a target function of the computer device, it is determined that the test request has been received, wherein the target function is a function of the computer device that allows the indicator light under test to indicate the function status.

11. The method according to claim 10, characterized in that, After determining the target illumination state of the indicator light under test based on the second target information and the third target information, the method further includes: The target execution progress is obtained, wherein the target execution progress is the execution progress of the target function by the computer device when the image for extracting the second target information is acquired; The reference illumination state of the indicator light under test is determined based on the target execution progress, wherein the reference illumination state is used to indicate the expected illumination state of the indicator light under test when the target function is executed to the target execution progress; The abnormal light emission state of the indicator light under test is detected based on the target light emission state and the reference light emission state; When the abnormal light emission state is detected as indicating that the indicator light under test has an abnormal light emission state, a test log is obtained, wherein the test log is used to indicate the execution status of the target function by the computer device; The cause of the abnormal luminescence was determined based on the test log.

12. The method according to claim 11, characterized in that, The step of detecting the cause of the abnormal luminescence based on the test log includes: The test log and target log information are used to detect whether the target function has been executed normally to the target execution progress. The target log information is used to indicate the log information that the computer device is expected to record during the process of executing the target function normally to the target execution progress. If the target function is detected to be executing normally to the target execution progress, the cause of the anomaly is determined to be an anomaly of the indicator light under test; If it is detected that the target function has not been executed normally to the target execution progress, the cause of the abnormality is determined to include the computer equipment malfunction.

13. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor, configured to perform the steps of the method for detecting an indicator light of the computer device as claimed in any one of claims 1 to 12 when executing the computer program.

Citation Information

Patent Citations

  • Color recognition method and device and electronic equipment

    CN121213885A

  • Indicator lamp state identification method and device, electronic equipment and storage medium

    CN122391767A