Network camera detection method, device, apparatus and computer readable storage medium
By constructing a detection task sequence based on runtime state dependencies, the problems of redundancy and resource waste in network camera anomaly detection are solved, and rapid and accurate anomaly cause localization is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- SHENZHEN WHALE VISION TECH CO LTD
- Filing Date
- 2026-05-07
- Publication Date
- 2026-06-02
AI Technical Summary
When existing network cameras malfunction, the detection process suffers from redundant detection steps, increased invalid communication, and high resource consumption, making it difficult to quickly pinpoint the cause of the malfunction.
Based on the operational status dependencies of network cameras, a detection task sequence is constructed and the detection tasks are executed sequentially to determine the detection strategy, obtain detection results and status identifiers, and determine the cause of the anomaly through the detection results and status identifiers.
It improves the efficiency of locating the cause of network camera anomalies, avoids redundant detection steps, invalid communication and resource consumption, and achieves fast and accurate anomaly location.
Smart Images

Figure CN122137950A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of network camera technology, and in particular to a network camera detection method, apparatus, device, and computer-readable storage medium. Background Technology
[0002] With the development of IoT technology, IoT cameras (network cameras), as important IoT terminal devices, are widely used in scenarios such as remote monitoring and security protection. Existing network cameras typically communicate with cloud servers via mobile terminals, allowing users to manage and view the devices on their mobile devices.
[0003] The operational status of a network camera involves multiple dimensions, and these dimensions are interdependent. However, in existing technologies, when a network camera malfunctions, maintenance personnel typically check one dimension of its operational status based on the abnormal phenomena and their experience. This approach suffers from redundant testing steps, increased invalid communication, and significant resource consumption, making it difficult to quickly pinpoint the cause of the network camera malfunction. Summary of the Invention
[0004] In view of this, the purpose of this application is to overcome the shortcomings of the prior art and provide a network camera detection method, the method comprising: In response to a detection command for a network camera, a detection task sequence is constructed based on the operational state dependencies of the network camera, and each detection task in the detection task sequence is executed sequentially. During the detection process, a detection strategy is determined, and based on the detection task sequence and the detection strategy, the detection results of the detection tasks and the status identifier of the network camera's operating status are obtained. Based on the detection results and the status indicator, the cause of the network camera's abnormality is determined.
[0005] In one embodiment, the step of determining the detection strategy during the detection process includes: During the detection process, if the detection result of the current detection task does not meet the preset conditions, then the subsequent detection task of the current detection task in the detection task sequence is determined. Based on the dependency relationship between each subsequent detection task and the current detection task, determine the valid and invalid detection tasks among the subsequent detection tasks; A detection strategy is determined based on the effective and invalid detection tasks, and the effective detection tasks are processed based on the detection strategy.
[0006] In one embodiment, the step of constructing a detection task sequence based on the operational state dependencies of the network camera includes: Based on the operational status dependencies of the network cameras, a set of strong dependency detection tasks and a set of weak dependency detection tasks are determined. Based on the target execution order, a detection task sequence is constructed by combining the set of strong dependency detection tasks and the set of weak dependency detection tasks.
[0007] In one embodiment, the method further includes: Obtain the set of device capability metadata of the network camera, and determine the set of operating states of the network camera based on the set of device capability metadata. The device capability metadata is data that characterizes the functions of the network camera. Based on the set of operating states and the preset operating state dependency rules, the operating state dependency relationship of the network camera is determined.
[0008] In one embodiment, the step of obtaining the detection result of the detection task and the status identifier of the network camera's operating status includes: For each of the aforementioned detection tasks, the detection result of the completed current detection task is obtained, and the corresponding target running state is determined based on the current detection task. The status identifier of the target's operating state is determined based on the detection results.
[0009] In one embodiment, the step of determining the cause of the network camera's anomaly based on the detection result and the status identifier includes: Summarize the detection results of each detection task and the status indicators of each running state, and filter out abnormal detection results from the detection results of each detection task and abnormal status indicators from the status indicators of each running state. Based on the anomaly detection results, the anomaly status identifier, and the causal relationship between each detection task in the detection task sequence, the cause of the anomaly of the network camera is determined.
[0010] In one embodiment, after determining the cause of the network camera's anomaly, the method further includes: Based on the cause of the anomaly, corresponding repair suggestions are generated and displayed.
[0011] This application also provides a network camera detection device, the network camera detection device comprising: The construction module is used to respond to the detection command of the network camera, construct a detection task sequence based on the operating state dependency of the network camera, and execute each detection task in the detection task sequence in sequence. The detection module is used to determine the detection strategy during the detection process, and based on the detection task sequence and the detection strategy, obtain the detection result of the detection task and the status identifier of the network camera's operating status. The determination module is used to determine the cause of the network camera's abnormality based on the detection results and the status identifier.
[0012] This application also provides a computer device, which includes a processor and a memory, the memory storing a computer program, and the processor executing the computer program to implement the network camera detection method described above.
[0013] This application also provides a computer-readable storage medium storing a computer program that, when run on a processor, executes the above-described network camera detection method.
[0014] The embodiments of this application have the following beneficial effects: In response to a detection command from a network camera, this embodiment constructs a detection task sequence based on the network camera's operational state dependencies and executes each detection task in the sequence sequentially. During the detection process, a detection strategy is determined, and based on the detection task sequence and the strategy, the detection results and the network camera's operational state status identifier are obtained. Based on the detection results and status identifier, the cause of the network camera's anomaly is determined. By constructing a detection task sequence based on the network camera's operational state dependencies and then performing detection based on this sequence to determine the cause of the network camera's anomaly, the problems of redundant detection steps, increased invalid communication, and high resource consumption during the detection process can be avoided, thus improving the efficiency of locating the cause of network camera anomalies. Attached Figure Description
[0015] To more clearly illustrate the technical solutions of this application, the accompanying drawings used in the embodiments will be briefly described below. It should be understood that the following drawings only show some embodiments of this application and therefore should not be considered as a limitation on the scope of protection of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0016] Figure 1 A flowchart illustrating the first embodiment of the network camera detection method provided in this application; Figure 2 A flowchart illustrating a second embodiment of the network camera detection method provided in this application; Figure 3 A flowchart illustrating the third embodiment of the network camera detection method provided in this application; Figure 4 A flowchart illustrating the fourth embodiment of the network camera detection method provided in this application; Figure 5 A flowchart illustrating the fifth embodiment of the network camera detection method provided in this application; Figure 6 A flowchart illustrating the sixth embodiment of the network camera detection method provided in this application; Figure 7 This is a schematic diagram of the testing process provided in this application; Figure 8 This is a schematic diagram of the network camera detection device provided in this application. Detailed Implementation
[0017] The technical solutions in 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.
[0018] The components of the embodiments of this application described and illustrated in the accompanying drawings can be arranged and designed in a variety of different configurations. Therefore, the following detailed description of the embodiments of this application provided in the drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0019] In the following, the terms “comprising,” “having,” and their cognates, which may be used in various embodiments of this application, are intended only to indicate a particular feature, number, step, operation, element, component, or combination thereof, and should not be construed as excluding, firstly, the presence of one or more other features, numbers, steps, operations, elements, components, or combinations thereof, or adding the possibility of one or more features, numbers, steps, operations, elements, components, or combinations thereof.
[0020] Furthermore, the terms "first," "second," and "third" are used only to distinguish descriptions and should not be interpreted as indicating or implying relative importance.
[0021] Unless otherwise specified, all terms used herein (including technical and scientific terms) shall have the same meaning as commonly understood by one of ordinary skill in the art to which the various embodiments of this application pertain. Terms (such as those defined in commonly used dictionaries) shall be interpreted as having the same meaning as in their contextual meaning in the relevant technical field and shall not be construed as having an idealized or overly formal meaning, unless clearly defined in the various embodiments of this application.
[0022] It is understood that the method of this application is applied to a testing device, which can be electrically or communicatively connected to the network camera to test the network camera. The testing device can be a smart terminal, PC terminal, mobile terminal, etc., and is not limited thereto.
[0023] The following detailed description of some embodiments of this application is provided in conjunction with the accompanying drawings. Unless otherwise specified, the following embodiments and features can be combined with each other.
[0024] Please refer to Figure 1 , Figure 1 This is a flowchart illustrating a first embodiment of the network camera detection method provided in this application. The method includes: Step S101: In response to the detection command for the network camera, a detection task sequence is constructed based on the operating state dependency of the network camera, and each detection task in the detection task sequence is executed sequentially.
[0025] In this embodiment, after the detection device establishes an electrical or communication connection with the network camera, it responds to a detection command to the network camera, obtains the network camera's operational state dependencies, and then constructs a detection task sequence based on these dependencies, executing each detection task in the sequence sequentially. It is understood that by responding to a detection command to the network camera and constructing a detection task sequence through a unified triggering mechanism, the detection device can avoid manual intervention in constructing the detection task sequence, thereby improving the efficiency of the sequence construction.
[0026] It should be noted that the operational status of a network camera involves multiple dimensions, including device connection status, network communication status, video data transmission status, event detection function status, storage media status, and device firmware version status. Some operational statuses are interdependent; for example, network communication status depends on device online status, video data acquisition status depends on network communication status, and event detection function status depends on video data acquisition capabilities.
[0027] It should be noted that different operating states correspond to different detection tasks. After determining the dependencies between operating states, the detection device can construct a sequence of detection tasks. For example, the detection task sequence is: 1. Device online status detection, 2. Device network communication status detection, 3. Video data acquisition status detection, 4. Event detection function status detection, 5. Memory card status detection, 6. Device firmware version status detection.
[0028] Step S102: During the detection process, a detection strategy is determined, and based on the detection task sequence and the detection strategy, the detection results of the detection tasks and the status identifier of the network camera's operating status are obtained.
[0029] In this embodiment, after obtaining the detection task sequence, the detection device executes each detection task in the detection task sequence in sequence according to the order of the detection task sequence. During the detection process, a detection strategy is determined, and based on the detection task sequence and the detection strategy, the detection results of the detection tasks and the status identifier of the network camera's operating status are obtained.
[0030] Understandably, the detection strategy is determined based on the dependencies between detection tasks in the detection task sequence and the detection result of the currently executing detection task. If the detection result of the currently executing detection task does not meet the preset conditions, detection tasks that have no dependency relationship with the currently executing detection task will continue to execute, while detection tasks that have a dependency relationship with the currently executing detection task will stop executing.
[0031] Understandably, the detection results are correlated with status identifiers, which indicate the corresponding operating status, such as poor network signal, abnormal video data acquisition, or normal memory card status. Furthermore, executing each detection task sequentially within the detection task sequence avoids the problems of redundant detection steps, increased invalid communication, and excessive resource consumption that can occur when maintenance personnel rely on experience for each test, thus improving the detection efficiency of network cameras.
[0032] Step S103: Based on the detection results and the status identifier, determine the cause of the network camera's abnormality.
[0033] In this embodiment, after obtaining the detection results of each detection task in the detection task sequence and the status identifier of each operating state of the network camera, the detection device performs correlation analysis based on all the detection results and status identifiers to determine the cause of the network camera's anomaly. It should be noted that because the dependencies of the network camera's operating states are determined, the correlation analysis based on all the detection results and status identifiers can accurately pinpoint the most fundamental cause of the anomaly, rather than merely locating superficial causes, thus improving the accuracy of anomaly cause determination.
[0034] For example, if a network camera malfunctions by failing to detect events, and since the event detection function of a network camera depends on its video data acquisition capability, the solution in this application detects both an abnormal event detection function and an abnormal video data acquisition capability. In this case, the detection device can pinpoint the root cause of the abnormality as the abnormal video data acquisition capability leading to the abnormal event detection function, thus accurately locating the most fundamental cause of the abnormality. In contrast, with traditional detection solutions, when an abnormal event detection function is detected, the possible causes might be attributed to a damaged event detection module or event detection not being enabled. However, without corresponding video data acquisition detection results, the root cause cannot be located, resulting in low accuracy in determining the cause of the abnormality.
[0035] In one embodiment, after determining the cause of the network camera's anomaly, the method further includes: Step S104: Based on the cause of the anomaly, generate corresponding maintenance suggestions and display the maintenance suggestions.
[0036] In this embodiment, after determining the cause of the anomaly, the detection device determines the corresponding maintenance suggestion based on the cause of the anomaly and a preset association table of anomaly causes and maintenance suggestions, and then displays the maintenance suggestion.
[0037] For example, the repair suggestions corresponding to the causes of the anomalies include the following: Abnormal device online status: It is recommended to check the power connection or whether the router network is normal; Weak network communication signal: It is recommended to move the device closer to the router or restart the router; Video cannot output images: It is recommended to restart the device or check for camera obstruction; Detection alarm not enabled: It is recommended to enable motion detection or sound detection to avoid missing important events; Memory card malfunction: It is recommended to reinsert or format the memory card; Firmware version too low: It is recommended to upgrade to the latest version to improve system stability. Through the above mechanism, the causes of network camera anomalies can be quickly located and assisted in handling, improving the efficiency of anomaly troubleshooting and reducing network communication overhead and system resource consumption.
[0038] The detection device in this embodiment, in response to a detection command for a network camera, constructs a detection task sequence based on the operational state dependencies of the network camera; it sequentially executes each detection task in the detection task sequence, obtaining the detection result of each detection task and the status identifier of each operational state of the network camera; based on the detection results and the status identifier, it determines the cause of the network camera's anomaly. By constructing a detection task sequence based on the operational state dependencies of the network camera, and then performing detection based on the detection task sequence to determine the cause of the network camera's anomaly, the problems of redundant detection steps, increased invalid communication, and high resource consumption during the detection process can be avoided, thus improving the efficiency of locating the cause of network camera anomalies.
[0039] Please refer to Figure 2 , Figure 2 This is a flowchart illustrating a second embodiment of the network camera detection method provided in this application. The difference between the second embodiment and the first embodiment is that the step of constructing a detection task sequence based on the operational state dependency of the network camera includes: Step S201: Based on the operational status dependencies of the network cameras, determine the set of strong dependency detection tasks and the set of weak dependency detection tasks.
[0040] Step S202: Based on the target execution order, and combining the set of strong dependency detection tasks and the set of weak dependency detection tasks, construct a detection task sequence.
[0041] In this embodiment, the detection device determines a set of strongly dependent detection tasks and a set of weakly dependent detection tasks based on the operational status dependencies of the network cameras. Based on the target execution order, it combines the sets of strongly dependent detection tasks and the sets of weakly dependent detection tasks to construct a detection task sequence.
[0042] It should be noted that a strongly dependent detection task refers to a detection task whose results directly affect whether subsequent detection tasks have effective detection conditions, while a weakly dependent detection task refers to a detection task that is not a prerequisite for other detection tasks and can still be executed independently even if the prerequisite detection is abnormal.
[0043] Understandably, for a set of strong dependency detection tasks, the execution sequence of strong dependency detection tasks must be constructed according to the influence relationship between them. For a set of weak dependency detection tasks, weak dependency detection tasks can be added before and after the execution sequence of strong dependency detection tasks to construct a detection task sequence.
[0044] In one embodiment, the operating status of the network camera includes: device online status, device network communication status, video data acquisition status, event detection function status, memory card status, and device firmware version status; the corresponding detection tasks include: device online status detection, device network communication status detection, video data acquisition status detection, event detection function status detection, memory card status detection, and device firmware version status detection; wherein, there are the following dependencies between the detection tasks: network communication status detection depends on device online status detection, video data acquisition status detection depends on network communication status detection, event detection function status detection depends on video data acquisition capability detection, and memory card status detection depends on memory card status detection. Card status detection and network communication status detection have no direct dependency, and firmware version status detection does not depend on video or storage functions. Correspondingly, strong dependency detection tasks include device online status detection, network communication status detection, and video data acquisition status detection, while weak dependency detection tasks include event detection function status detection, memory card status detection, and firmware version status detection. Weak dependency detection tasks are added after the execution sequence of strong dependency detection tasks, and the constructed detection task sequence is as follows: 1. Device online status detection, 2. Device network communication status detection, 3. Video data acquisition status detection, 4. Event detection function status detection, 5. Memory card status detection, 6. Device firmware version status detection.
[0045] The detection device in this embodiment determines a set of strongly dependent detection tasks and a set of weakly dependent detection tasks based on the operational state dependencies of the network cameras. Based on the target execution order, it constructs a detection task sequence by combining these sets. This ensures that the strongly dependent detection tasks are arranged sequentially according to their influence relationships, improving the rationality of the constructed detection task sequence. This avoids problems such as redundant detection steps, increased invalid communication, and excessive resource consumption during the detection process, thereby improving the efficiency of locating the causes of network camera anomalies.
[0046] Please refer to Figure 3 , Figure 3 This is a flowchart illustrating a third embodiment of the network camera detection method provided in this application. The difference between the third embodiment and the first to second embodiments is that the method further includes: Step S301: Obtain the device capability metadata set of the network camera, and determine the operating status set of the network camera based on the device capability metadata set. The device capability metadata is data that characterizes the functions of the network camera.
[0047] Step S302: Based on the set of operating states and the preset operating state dependency rules, determine the operating state dependency relationship of the network camera.
[0048] In this embodiment, after the detection device establishes an electrical or communication connection with the network camera, it first sends a lightweight capability probe to the network camera to obtain the functional modules it actually supports, and then obtains the network camera's device capability metadata set. The device capability metadata is data that characterizes the functions of the network camera. Based on the device capability metadata set, the network camera's operating state set is determined. Based on the operating state set and preset operating state dependency rules, the network camera's operating state dependency relationship is determined.
[0049] It should be noted that different models of network cameras actually support different functional modules. As a result, the corresponding device capability metadata will also differ. The detection device actively obtains the device capability metadata set of the connected network camera. Based on the device capability metadata set, it can determine which operating states the network camera may have, and thus determine the set of operating states.
[0050] In one embodiment, the network camera actually supports functional modules including a network communication module, a memory card module, and device firmware, but does not support a video data acquisition module or an event detection module. In this case, the detection device can determine that the network camera has a set of operating states, including online status, network communication status, memory card status, and firmware version status. The constructed detection task sequence is: 1. Device online status detection, 2. Device network communication status detection, 3. Memory card status detection, 4. Device firmware version status detection. This avoids including detection processes for operating states that the network camera does not actually support in the constructed detection task sequence, further avoiding redundant detection steps.
[0051] In this embodiment, after establishing an electrical or communication connection with the network camera, the detection device first sends a lightweight capability probe to the network camera to obtain its actual supported functional modules. Then, it obtains the network camera's device capability metadata set and determines the network camera's operating state set based on this metadata set. Based on the operating state set and preset operating state dependency rules, it determines the network camera's operating state dependencies. This further avoids redundant detection steps, helps improve the accuracy of constructing the detection task sequence, and increases the efficiency of locating the causes of network camera anomalies.
[0052] Please refer to Figure 4 , Figure 4 This is a flowchart illustrating a fourth embodiment of the network camera detection method provided in this application. The difference between the fourth embodiment and the first to third embodiments is that the step of sequentially executing each detection task in the detection task sequence to obtain the detection results of each detection task and the status identifier of each operating state of the network camera includes: Step S401: For each detection task, obtain the detection result of the completed current detection task, and determine the corresponding target running state based on the current detection task.
[0053] Step S402: Determine the status identifier of the target operating state based on the detection result.
[0054] In this embodiment, the detection device executes each detection task in the detection task sequence in sequence. For each detection task, it calls the corresponding detection program to detect the network camera, determines the detection result of the current detection task, determines the corresponding target running state based on the current detection task, and determines the status identifier of the target running state based on the detection result.
[0055] For example, when performing device network communication status detection, the corresponding target operating status is device network communication status. If the detection result of device network communication status detection is normal, the status identifier of device network communication status is determined to be normal signal. If the detection result of device network communication status detection is abnormal, the status identifier of device network communication status is determined to be abnormal signal.
[0056] The detection device in this embodiment executes each detection task in the detection task sequence in sequence, records the detection results and status indicators, which helps to locate the cause of network camera anomalies based on the detection results of all detection tasks and all status indicators, and helps to improve the efficiency of network camera anomaly location.
[0057] Please refer to Figure 5 , Figure 5 This is a flowchart illustrating the fifth embodiment of the network camera detection method provided in this application. The difference between the fifth embodiment and the first to fourth embodiments is that the step of determining the detection strategy during the detection process includes: Step S501: During the detection process, if the detection result of the current detection task does not meet the preset conditions, then the subsequent detection task corresponding to the current detection task in the detection task sequence is determined.
[0058] Step S502: Based on the dependency relationship between each subsequent detection task and the current detection task, determine the valid and invalid detection tasks among the subsequent detection tasks.
[0059] Step S503: Generate a detection strategy based on the effective detection tasks and invalid detection tasks, and process the effective detection tasks based on the detection strategy.
[0060] In this embodiment, during the detection process, after each detection task is completed, the detection device analyzes whether the detection result of the current task meets preset conditions. It should be noted that an abnormal detection result indicates that the preset conditions are not met, while a normal result indicates that the preset conditions are met. If the detection device determines that the detection result of the current task does not meet the preset conditions, it determines the subsequent detection tasks corresponding to the current task in the detection task sequence. Based on the dependency relationship between each subsequent detection task and the current detection task, it determines the valid and invalid detection tasks in the subsequent detection tasks. A detection strategy is generated based on the valid and invalid detection tasks. The detection strategy involves executing only the valid detection tasks and ignoring the invalid detection tasks during subsequent detections. The valid detection tasks are then processed based on the detection strategy.
[0061] It should be noted that a valid detection task is a detection task that has no dependency relationship with the detection task whose detection result does not meet the preset conditions, while an invalid detection task is a detection task that has a dependency relationship with the target detection task whose detection result does not meet the preset conditions.
[0062] For example, when the device online status detection result is offline, the detection result does not meet the preset conditions. Since device network communication status detection, video data acquisition status detection, and event detection function status detection all require the device online status detection result to be online, these three detection tasks are invalid. However, memory card status detection and device firmware version status detection are not dependent on the device online status and are therefore valid detection tasks. When the device online status detection result is offline, the detection strategy for the detection device is: do not execute device network communication status detection, video data acquisition status detection, and event detection function status detection; only execute memory card status detection and device firmware version status detection.
[0063] For example, when the detection result of the device network communication status detection is a weak signal, the detection result of the device network communication status detection does not meet the preset conditions. Since the video data acquisition status detection, event detection function status detection, memory card status detection, and device firmware version status detection are not dependent on the device network communication status, they are all valid detection tasks. The detection strategy of the detection device is to perform video data acquisition status detection, event detection function status detection, memory card status detection, and device firmware version status detection.
[0064] For example, when the video data acquisition status detection result is "acquisition failed," the result does not meet the preset conditions. Since the event detection function status detection requires the video data acquisition status detection result to be "acquisition successful," it is an invalid detection task. However, the memory card status detection and device firmware version status detection are independent of the video data acquisition status detection result and are therefore valid detection tasks. When the video data acquisition status detection result is "acquisition failed," the detection strategy of the detection device is: not to perform the event detection function status detection, but only to perform the memory card status detection and device firmware version status detection.
[0065] In this embodiment, if the detection result of a certain target detection task does not meet preset conditions, the detection device determines subsequent detection tasks corresponding to the target detection task in the detection task sequence. Based on the dependency relationship between each subsequent detection task and the target detection task, valid and invalid detection tasks are determined among the subsequent detection tasks. A detection strategy is generated based on the valid and invalid detection tasks, and the valid detection tasks are processed based on the detection strategy. The detection strategy can be adjusted in real time according to the specific detection results during the detection process, avoiding invalid detection operations without interrupting the overall detection flow, improving the accuracy of the detection logic, and increasing detection efficiency.
[0066] Please refer to Figure 6 , Figure 6 This is a flowchart illustrating the sixth embodiment of the network camera detection method provided in this application. The difference between the sixth embodiment and the first to fifth embodiments is that the step of determining the cause of the network camera's abnormality based on the detection result and the status identifier includes: Step S601: Summarize the detection results of each detection task and the status identifiers of each running state, and filter out abnormal detection results from the detection results of each detection task and abnormal status identifiers from the status identifiers of each running state.
[0067] Step S602: Based on the anomaly detection results, the anomaly status identifier, and the causal relationship between each detection task in the detection task sequence, determine the cause of the anomaly of the network camera.
[0068] In this embodiment, after completing the detection task sequence, the detection device summarizes the detection results of each detection task and the status identifier of each operating state, and filters out abnormal detection results from the detection results of each detection task and abnormal status identifiers from the status identifiers of each operating state. Based on the abnormal detection results, abnormal status identifiers, and the causal relationship between each detection task in the detection task sequence, the cause of the network camera's abnormality is determined.
[0069] For example, when video data acquisition is abnormal and the network communication status is weak, the video abnormality can be attributed to a network problem; when the network communication status is normal but video data acquisition is abnormal, it can be inferred that the camera module or video encoding module is abnormal; when the video data is normal but the memory card status is abnormal, it can be determined that the recording function is abnormal but the real-time preview function is normal; when the device's online status is abnormal, it can be determined that the subsequent function test results are due to insufficient preconditions.
[0070] The detection device in this embodiment summarizes the detection results of each detection task and the status identifiers of each operating state. It then filters out abnormal detection results from the detection results of each task and abnormal status identifiers from the status identifiers of each operating state. Based on the abnormal detection results, abnormal status identifiers, and the causal relationships between the detection tasks in the sequence, it determines the cause of the network camera's anomaly. By analyzing the logical correlation between the detection results and status identifiers of multiple detection tasks, the accuracy of determining the cause of network camera anomalies can be improved.
[0071] Please refer to the following for specific implementation: Figure 7 , Figure 7 This is a schematic diagram of the testing process provided in this application. The testing task sequence is as follows: 1. Device online status detection, 2. Device network communication status detection, 3. Video data acquisition status detection, 4. Event detection function status detection, 5. Memory card status detection, 6. Device firmware version status detection. The testing device executes the testing tasks sequentially based on the testing task sequence.
[0072] When the device online status detection result is offline, the device online status detection result does not meet the preset conditions, the device online status status is marked as offline, and the detection device does not perform subsequent device network communication status detection, video data acquisition status detection and event detection function status detection, only memory card status detection and device firmware version status detection.
[0073] When the device network communication status detection result is weak, the detection result does not meet the preset conditions, and the device network communication status is marked as weak network signal. The detection device continues to perform video data acquisition status detection, event detection function status detection, memory card status detection, and device firmware version status detection.
[0074] When the video data acquisition status detection result is acquisition failure, the video data acquisition status detection result does not meet the preset conditions. The status identifier of the video data acquisition status is that the video cannot be output. The detection device does not perform event detection function status detection, but only performs memory card status detection and device firmware version status detection.
[0075] refer to Figure 8 , Figure 8 This is a schematic diagram of the network camera detection device provided in this application. The network camera detection device includes: The construction module 10 is used to construct a detection task sequence based on the operating state dependency relationship of the network camera in response to the detection command of the network camera.
[0076] The detection module 20 is used to detect each operating state of the network camera sequentially based on the detection task sequence, and obtain the detection results of each detection task.
[0077] The determination module 30 is used to determine the cause of the network camera's abnormality based on the detection results and the operational status dependency relationship.
[0078] It is understood that the network camera detection device in this embodiment corresponds to the network camera detection method in the above embodiment, and the options in the above embodiment are also applicable to this embodiment, so they will not be described again here.
[0079] This application also provides a computer device, which can be a detection device. The detection device can be electrically or communicatively connected to a network camera to detect the network camera. Exemplarily, the computer device includes a processor and a memory, wherein the memory stores a computer program, and the processor executes the computer program to enable the computer device to perform the network camera detection method described above.
[0080] The processor can be an integrated circuit chip with signal processing capabilities. The processor can be a general-purpose processor, including at least one of a Central Processing Unit (CPU), Graphics Processing Unit (GPU), Network Processor (NP), Digital Signal Processor (DSP), Application-Specific Integrated Circuit (ASIC), Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. The general-purpose processor can be a microprocessor or any conventional processor, capable of implementing or executing the methods, steps, and logic block diagrams disclosed in the embodiments of this application.
[0081] The memory can be, but is not limited to, Random Access Memory (RAM), Read Only Memory (ROM), Programmable Read-Only Memory (PROM), Erasable Programmable Read-Only Memory (EPROM), Electrically Erasable Programmable Read-Only Memory (EEPROM), etc. The memory is used to store computer programs, and the processor can execute the computer programs accordingly after receiving execution instructions.
[0082] This application also provides a computer storage medium for storing the computer program used in the aforementioned computer device. The computer storage medium can be a readable storage medium, a non-volatile storage medium, or a volatile storage medium. For example, the computer storage medium may include, but is not limited to, various media capable of storing program code, such as a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0083] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can also be implemented in other ways. The apparatus embodiments described above are merely illustrative. For example, the flowcharts and block diagrams in the accompanying drawings show the architecture, functionality, and operation of possible implementations of apparatus, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that, in alternative implementations, the functions marked in the blocks may occur in a different order than those marked in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagram and / or flowchart, and combinations of blocks in the block diagram and / or flowchart, can be implemented using a dedicated hardware-based system that performs the specified function or action, or using a combination of dedicated hardware and computer instructions.
[0084] In addition, the functional modules or units in the various embodiments of this application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.
[0085] If the aforementioned functions are implemented as software functional modules and sold or used as independent products, they can be stored in a readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a smartphone, personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application.
[0086] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application.
Claims
1. A method for detecting network cameras, characterized in that, The method includes: In response to a detection command for a network camera, a detection task sequence is constructed based on the operational state dependencies of the network camera, and each detection task in the detection task sequence is executed sequentially. During the detection process, a detection strategy is determined, and based on the detection task sequence and the detection strategy, the detection results of the detection tasks and the status identifier of the network camera's operating status are obtained. Based on the detection results and the status indicator, the cause of the network camera's abnormality is determined; The step of constructing the detection task sequence based on the operational state dependency of the network camera includes: Based on the operational status dependencies of the network cameras, a set of strong dependency detection tasks and a set of weak dependency detection tasks are determined. Based on the target execution order, a detection task sequence is constructed by combining the set of strong dependency detection tasks and the set of weak dependency detection tasks.
2. The network camera detection method according to claim 1, characterized in that, The step of determining the detection strategy during the detection process includes: During the detection process, if the detection result of the current detection task does not meet the preset conditions, then the subsequent detection task of the current detection task in the detection task sequence is determined. Based on the dependency relationship between each subsequent detection task and the current detection task, determine the valid and invalid detection tasks among the subsequent detection tasks; A detection strategy is determined based on the effective and invalid detection tasks, and the effective detection tasks are processed based on the detection strategy.
3. The network camera detection method according to claim 1, characterized in that, The method further includes: Obtain the set of device capability metadata of the network camera, and determine the set of operating states of the network camera based on the set of device capability metadata. The device capability metadata is data that characterizes the functions of the network camera. Based on the set of operating states and the preset operating state dependency rules, the operating state dependency relationship of the network camera is determined.
4. The network camera detection method according to claim 1, characterized in that, The step of obtaining the detection result of the detection task and the status identifier of the network camera's operating status includes: For each of the aforementioned detection tasks, the detection result of the completed current detection task is obtained, and the corresponding target running state is determined based on the current detection task. The status identifier of the target's operating state is determined based on the detection results.
5. The network camera detection method according to claim 1, characterized in that, The step of determining the cause of the network camera's anomaly based on the detection results and the status identifier includes: Summarize the detection results of each detection task and the status indicators of each running state, and filter out abnormal detection results from the detection results of each detection task and abnormal status indicators from the status indicators of each running state. Based on the anomaly detection results, the anomaly status identifier, and the causal relationship between each detection task in the detection task sequence, the cause of the anomaly of the network camera is determined.
6. The network camera detection method according to any one of claims 1-5, characterized in that, After determining the cause of the network camera's malfunction, the method further includes: Based on the cause of the anomaly, corresponding repair suggestions are generated and displayed.
7. A network camera detection device, characterized in that, The network camera detection device includes: The construction module is used to respond to the detection command of the network camera, construct a detection task sequence based on the operating state dependency of the network camera, and execute each detection task in the detection task sequence in sequence. The detection module is used to determine the detection strategy during the detection process, and based on the detection task sequence and the detection strategy, obtain the detection result of the detection task and the status identifier of the network camera's operating status. The determination module is used to determine the cause of the abnormality of the network camera based on the detection results and the status identifier; The step of constructing the detection task sequence based on the operational state dependency of the network camera includes: Based on the operational status dependencies of the network cameras, a set of strong dependency detection tasks and a set of weak dependency detection tasks are determined. Based on the target execution order, a detection task sequence is constructed by combining the set of strong dependency detection tasks and the set of weak dependency detection tasks.
8. A computer device, characterized in that, The computer device includes a processor and a memory, the memory storing a computer program, and the processor executing the computer program to implement the network camera detection method according to any one of claims 1-6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when run on a processor, executes the network camera detection method according to any one of claims 1-6.