Method, system, apparatus, device, and storage medium for preventing electric shock
By using image recognition technology to identify objects that are susceptible to electric shock and controlling the power-on control device to cut off the power, the problem of insufficient physical protection measures in the existing technology is solved, effective protection is achieved for objects that are susceptible to electric shock, and the risk of electric shock is reduced.
Patent Information
- Application Number
- CN202210363423.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-04-07
- Publication Date
- 2025-10-14
- Estimated Expiration
- 2042-04-07
AI Technical Summary
In the prior art, power control devices that rely on physical protection measures cannot effectively prevent electric shock accidents to special groups of people, such as children, the elderly, and pets, who are susceptible to electric shock.
The image of the monitored area is acquired through image recognition technology, and objects susceptible to electric shock are identified and the power-on control device is controlled to be powered off when the conditions for susceptible to electric shock are met, including setting prohibited areas and image matching technology, and adopting an immediate power-off or delayed power-off mode.
It effectively reduces the probability of electric shock accidents for objects that are susceptible to electric shock, improves the safety of electricity use, and especially protects special groups of people and pets.
Smart Images

Figure CN114758295B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of smart home, and in particular to an anti-electric shock method, system, device, equipment and storage medium. Background Art
[0002] In recent years, more and more electrical appliances have entered every household. With the increase in the number of electrical appliances, many families have increased the number of power control devices such as sockets and switches in their homes. When using electrical appliances, electrical safety is a very important issue.
[0003] In the prior art, most power-on control devices are equipped with physical protection measures, such as socket protection doors, to reduce the risk of electric shock.
[0004] However, some special groups, such as children with limited safety awareness, may treat sockets as toys; older people may misuse them; and pets may become interested in and touch sockets. These situations can bypass physical protective measures and cause electric shock accidents. Relying solely on physical protective measures to prevent electric shock accidents is not completely reliable. Special groups still face the risk of electric shock even with the protection of existing technologies. Summary of the Invention
[0005] This application provides an electric shock prevention method, system, device, equipment, and storage medium to address the problem that electric shock prevention measures in related technologies still have risks when using only physical protection methods, and effectively reduce the probability of electric shock accidents involving susceptible objects. The specific technical solutions are as follows:
[0006] In a first aspect, a method for preventing electric shock is provided, comprising:
[0007] Acquiring an image of a monitored area, wherein the monitored area is equipped with a power control device;
[0008] When it is determined that there is an object susceptible to electric shock in the image and the object susceptible to electric shock meets the electric shock condition, the power control device is controlled to cut off the power; wherein the electric shock condition indicates that the object susceptible to electric shock has the risk of electric shock by touching the power control device.
[0009] Optionally, determining that the object susceptible to electric shock meets the electric shock condition includes:
[0010] Acquire N prohibited areas in the image of the monitored area, each of the N prohibited areas containing a power-on control device, and each prohibited area having an area smaller than the area indicated by the image of the monitored area, where N is a positive integer;
[0011] If a target prohibited area exists among the N prohibited areas, determining that the object susceptible to electric shock meets the condition susceptible to electric shock;
[0012] The target prohibited area is a prohibited area among the N prohibited areas, the distance between which and the object susceptible to electric shock is less than a distance threshold.
[0013] Optionally, obtaining N prohibited areas in the image of the monitored area includes:
[0014] Identifying M powered control devices present in the image of the monitored area, where M is a positive integer;
[0015] Obtaining a position of each of the M power-on control devices;
[0016] Based on the position of each energized control device, the N prohibited areas are delineated.
[0017] Optionally, determining that an object susceptible to electric shock exists in the image includes:
[0018] intercepting, from the image of the monitored area, an image of an object belonging to the same category as the object susceptible to electric shock;
[0019] Matching the image of the category object with the image of a preset object susceptible to electric shock to obtain an image matching degree;
[0020] If the image matching degree of the category object is greater than a preset threshold, it is determined that the object susceptible to electric shock exists in the image of the category object.
[0021] Optionally, controlling the power-on control device to be powered off includes:
[0022] Obtaining a power-off control mode; the power-off control mode includes a first mode or a second mode; the first mode is a mode for controlling the power-on control device to immediately power off; the second mode is a mode for controlling the power-on control device to delay powering off for a preset time;
[0023] Based on the power-off control mode, the power-on control device is controlled to be powered off.
[0024] Optionally, the power-off control mode is the second mode;
[0025] The controlling the power-on control device to be powered off based on the power-off control mode includes:
[0026] Obtaining the acquisition time of the image of the monitored area;
[0027] The timing is started from the acquisition moment, and when the timing duration is not less than the preset duration indicated by the second mode, the power-on control device is controlled to be powered off.
[0028] Optionally, after the timing starts from the acquisition moment and before the timing duration is no less than the preset duration indicated by the second mode, the method further includes:
[0029] Determine that within the timing period, the object susceptible to electric shock always meets the condition susceptible to electric shock.
[0030] Optionally, before controlling the power-on control device to be powered off, the method further includes:
[0031] Outputting a prompt message to the user, wherein the prompt message is used to prompt the power control device to be powered off after the preset time period;
[0032] Receive indication information fed back by the user, wherein the indication information indicates confirmation to control the power-on control device to be powered off after the preset time period.
[0033] Optionally, after controlling the power-on control device to be powered off, the method further includes:
[0034] When it is determined that the object susceptible to electric shock changes from meeting the condition susceptible to electric shock to not meeting the condition susceptible to electric shock, the power-on control device is controlled to be powered on.
[0035] In a second aspect, an electric shock protection system is provided, comprising:
[0036] Image acquisition device, server and power control device;
[0037] The server is used to obtain an image of the monitored area through the image acquisition device; based on the image, when it is determined that there is an object that is susceptible to electric shock in the image, and when the object is susceptible to electric shock meets a condition for susceptible electric shock, the server controls the power-on control device to cut off the power; wherein the condition for susceptible electric shock indicates that the object that is susceptible to electric shock has a risk of electric shock by touching the power-on control device.
[0038] In a third aspect, an anti-electric shock device is provided, comprising:
[0039] an acquisition unit, configured to acquire an image of a monitored area, wherein the monitored area is provided with a power-on control device;
[0040] A control unit is used to control the power-on control device to cut off the power when it is determined that there is an object that is susceptible to electric shock in the image and the object meets a condition that it is susceptible to electric shock; wherein the condition that it is susceptible to electric shock indicates that the object that is susceptible to electric shock has a risk of electric shock by touching the power-on control device.
[0041] In a fourth aspect, an electronic device is provided, comprising: a processor, a memory, and a communication bus, wherein the processor and the memory communicate with each other via the communication bus;
[0042] The memory is used to store computer programs;
[0043] The processor is configured to execute the program stored in the memory to implement the electric shock prevention method described in the first aspect.
[0044] In a fifth aspect, a computer-readable storage medium is provided, on which a computer program is stored. When the program is executed by a processor, the method for preventing electric shock described in the first aspect is implemented.
[0045] The above-mentioned technical solution provided by the embodiment of the present application has the following advantages compared with the existing technology: it uses image recognition to determine whether people who are prone to electric shock meet the conditions for being prone to electric shock. Meeting the conditions for being prone to electric shock means that the object has the risk of electric shock, and accordingly, power-off measures are taken for the power-on control device. This protection method can effectively reduce the probability of electric shock accidents occurring to objects that are prone to electric shock. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.
[0047] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0048] Figure 1 A schematic diagram of a flow chart of a method for preventing electric shock in an embodiment of the present application;
[0049] Figure 2 This is a schematic structural diagram of an electric shock protection system according to an embodiment of the present application;
[0050] Figure 3 This is another flow chart of a method for preventing electric shock in an embodiment of the present application;
[0051] Figure 4 This is a schematic structural diagram of an electric shock protection device according to an embodiment of the present application;
[0052] Figure 5 This is a schematic diagram of the structure of an electronic device shown in an embodiment of the present application. DETAILED DESCRIPTION
[0053] To make the purpose, technical solutions, and advantages of the embodiments of this application more clear, the technical solutions in the embodiments of this application will be clearly and completely described below in conjunction with the drawings in the embodiments of this application. Obviously, the described embodiments are part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0054] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequential order. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in a sequence other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0055] The present application provides an electric shock prevention method applicable to electronic devices, which may include modules capable of implementing communication functions or terminal devices including such modules. The terminal devices may be fixed terminals, mobile terminals, or smart terminals. The fixed terminals may include at least one of servers and base stations, and the mobile terminals may include at least one of mobile phones, tablet computers, and laptop computers.
[0056] like Figure 1 As shown, the method may include the following steps:
[0057] Step 101: Acquire an image of a monitored area, where a power control device is installed.
[0058] It should be understood that the image of the monitored area includes all energized control devices that need to be monitored. In applications, the monitored area may be a collection of multiple areas that are not directly connected in space. To improve efficiency and obtain a more comprehensive image, it is possible to continuously acquire multiple images of the monitored area in a short period of time and synthesize these images into a single image, which is then used as the monitored area image.
[0059] Step 102: When it is determined that there is an object susceptible to electric shock in the image and the object susceptible to electric shock meets the electric shock condition, the power control device is controlled to be powered off; wherein the electric shock condition indicates that the object susceptible to electric shock has the risk of electric shock by touching the power control device.
[0060] It should be understood that objects susceptible to electric shock may be children, the elderly, pets, and other objects with characteristics such as weak judgment or weak behavioral abilities.
[0061] In the application, objects that are prone to electric shock can be directly determined through image matching. Of course, in order to improve processing efficiency, images that belong to the same category as the objects that are prone to electric shock can be captured first, and then the objects that are prone to electric shock can be determined based on the captured images.
[0062] When identifying vulnerable objects through direct image matching, to determine whether an object exists within an image of the monitored area, a pre-trained neural network can be used to identify the image of the monitored area, and the presence of the object can be determined based on the matching results. Alternatively, the user can pre-set an image of the vulnerable object, and the acquired image of the monitored area can be matched against the pre-set image of the vulnerable object, with the presence of the object determined based on the matching results.
[0063] When an object susceptible to electric shock is determined by matching captured images, in an optional embodiment, an image of a category object belonging to the same category as the object susceptible to electric shock is captured from an image of the monitored area; the image of the category object is matched with a preset image of the object susceptible to electric shock to obtain an image matching degree; if the image matching degree of the image of the category object belonging to the same category as the object susceptible to electric shock is greater than a preset threshold, it is determined that an object susceptible to electric shock exists in the image of the category image.
[0064] It should be understood that the preset threshold value can be set artificially based on experience or according to actual needs, and this embodiment does not specifically limit this.
[0065] It should be understood that when the image matching degree of the image of the category object belonging to the same category as the object susceptible to electric shock is not greater than the preset threshold, it is confirmed that there is no object susceptible to electric shock in the image of the monitored area, and the process ends.
[0066] For example, if the subject susceptible to electric shock is a child, then the category of the subject susceptible to electric shock is also a child. Therefore, if the image of the subject susceptible to electric shock, which is in the same category as the subject susceptible to electric shock, is an image of an adult, the degree of image matching obtained is no greater than a preset threshold.
[0067] In this embodiment, various methods are available for obtaining the degree of image matching. In applications, a pre-trained neural network can be used to obtain the degree of image matching. When using this method, images of pre-set objects susceptible to electric shock serve as a pre-set training dataset, and the degree of image matching obtained is the matching result output by the neural network. Alternatively, matching can be performed based on user-preset images of objects susceptible to electric shock. When using this method, the specific matching method can be customized, and the degree of image matching obtained is the image matching degree output after matching according to the customized matching method.
[0068] In one example, the user may set a specific matching method by matching the image to be matched pixel by pixel, and outputting the percentage of pixel matching as the image matching degree.
[0069] To improve the accuracy of image matching, when using a pre-trained neural network to obtain image matching, the accuracy can be improved by increasing the amount of training data. When using user-preset images of susceptible electric shock objects to obtain image matching, the accuracy can be improved by inputting images of the susceptible electric shock object from various angles.
[0070] In one example, a user can enter four types of images, namely, facial image, front image, side image and back image of a subject susceptible to electric shock. When the degree of matching between an image of a category object belonging to the same category as the subject susceptible to electric shock and an image of any of these four categories is greater than a threshold, it is determined that a subject susceptible to electric shock exists in the category image.
[0071] In this embodiment, the user-entered vulnerable objects can also be automatically updated. Specifically, when an image of an object belonging to the same category as the vulnerable object is identified, and the image of the object is not a pre-entered image of a family member, the user will be prompted to identify the image of the new category object. The user can receive this prompt through the user terminal and instruct it to store the image of the new category object and set it as the image of the vulnerable object. This method can solve the problem of having visitors at home but not having recorded the visitor's image, while there are still vulnerable objects that need to be protected.
[0072] It should be noted that in actual situations, multiple categories of objects may enter the monitored area at the same time, so multiple image matching degrees will be obtained. As long as one of the image matching degrees is higher than the threshold, it is determined that there is an object that is prone to electric shock in the image of the monitored area.
[0073] In this embodiment, whether the object susceptible to electric shock meets the condition susceptible to electric shock is determined based on the prohibited area.
[0074] In an optional embodiment, N prohibited areas are obtained in the image of the monitored area, each of the N prohibited areas contains a power-on control device, the area range of each prohibited area is smaller than the area range indicated by the image of the monitored area, and N is a positive integer; if there is a target prohibited area among the N prohibited areas, it is determined that the object that is prone to electric shock meets the condition of being prone to electric shock; the target prohibited area is a prohibited area among the N prohibited areas whose distance to the object that is prone to electric shock is less than a distance threshold.
[0075] In this embodiment, the preset distance threshold may be set artificially based on experience or according to actual needs, and this embodiment does not specifically limit this.
[0076] It should be understood that according to the spatial position of the image of the object susceptible to electric shock in the image of the monitored area, the distance between the image and N prohibited areas is calculated respectively, and N distances are obtained and matched with the distance threshold. When the distance is less than or equal to the threshold in the matching result, it is considered that the object susceptible to electric shock meets the condition of being susceptible to electric shock.
[0077] In one example, a child is susceptible to electric shock and enters a monitored area. The monitored area includes prohibited areas A, B, and C. The distance threshold is set to 1m. When the child is calculated to be 1.5m away from prohibited area A, 0.8m away from prohibited area B, and 1.1m away from prohibited area C, the matching result shows that the child's distance from prohibited area B is less than the distance threshold. Prohibited area B is the target prohibited area in this example, and the child is considered to meet the condition of being susceptible to electric shock.
[0078] It should be understood that the prohibited area is an area containing powered control devices, and the division of the prohibited area is performed based on the spatial position of the powered control devices in the image of the monitored area.
[0079] In an optional embodiment, M power-on control devices present in the image of the monitored area are identified, where M is a positive integer; the position of each of the M power-on control devices is obtained; and N prohibited areas are delineated based on the position of each power-on control device.
[0080] When demarcating prohibited areas, the spatial location of a single power-on control device is generally determined, with that location as the center, and a portion of the area surrounding the center is demarcated as the prohibited area. The shape of the portion of the area surrounding the center can be circular, rectangular, or irregular, and the area of the portion of the area surrounding the center can also be specifically set according to actual circumstances. This embodiment does not specifically limit the shape and area of the portion of the area surrounding the center. However, when there are multiple power-on control devices in similar spatial locations, the prohibited areas defined by these power-on control devices can be merged to form a prohibited area shared by these power-on control devices. Therefore, the number of prohibited areas does not correspond one-to-one to the number of power-on control devices, and the division needs to be adapted to the actual situation based on the spatial relationship between the power-on control devices.
[0081] In applications, the prohibited area can be delineated automatically by a trained neural network, or manually by a user based on an acquired image of the monitored area.
[0082] In this embodiment, the power-on control device is controlled to be powered off.
[0083] In an optional embodiment, a power-off control mode is obtained; the power-off control mode includes a first mode or a second mode; the first mode is a mode in which the power-on control device is controlled to be powered off immediately; the second mode is a mode in which the power-on control device is controlled to be powered off after a preset delay;
[0084] When the power-off control mode is in the first mode, if the image of the monitored area determines that an object susceptible to electric shock exists and meets the conditions for such an object to be susceptible to electric shock, the power-on control device is immediately powered off. This mode can be used when the user is not at home, such as on weekdays. In such cases, the immediate power-off method used in the first mode can more effectively protect the object susceptible to electric shock.
[0085] In one example, the power-off control mode is the first mode, which automatically tests the communication delay in 5G or WIFI mode and selects the mode with the lowest delay. The power-on control device is a smart socket. When it is determined that there is an object susceptible to electric shock in the image and the object susceptible to electric shock meets the conditions for being susceptible to electric shock, the smart socket is immediately controlled to cut off the power through the communication mode with the lowest communication delay. The process of uploading-judging-returning information can be achieved in milliseconds, effectively protecting the object susceptible to electric shock.
[0086] When the power-off control mode is the second mode, it is determined that the live-wire-touching object exists in the image of the monitored area, and the live-wire-touching object meets the live-wire-touching condition, and then, the timing is started at the time when the image of the monitored area is acquired, and the power-off control device is controlled to be powered off when the timing duration is not greater than the preset duration. The mode can be used in the case that the user is at home, and when the user and the live-wire-touching object are in the home at the same time, the mode can reduce the power-off frequency and reduce the influence of the anti-live-wire-touching method on the user's home life.
[0087] In one example, the power-off control mode is the second mode, the power-on control device is a smart socket, and the preset duration is 15 seconds. When it is determined that the live-wire-touching object exists in the image and the live-wire-touching object meets the live-wire-touching condition, the timing is started, and the smart socket is controlled to be powered off when the timing is greater than or equal to 15 seconds.
[0088] It should be understood that when the live-wire-touching object changes from meeting the live-wire-touching condition to not meeting the live-wire-touching condition within the preset duration, the current process is terminated, that is, only when it is determined that the live-wire-touching object is always in the monitored area within the preset duration, the power-off control device is powered off when the timing duration is not less than the preset duration.
[0089] In one example, based on the above description of the live-wire-touching condition and the live-wire-touching object, the preset duration is set to 15 seconds, the live-wire-touching object is a child, and the monitored area has a prohibited area A, a prohibited area B, and a prohibited area C. When it is calculated that the distance between the child and the prohibited area A is 1.5 m, the distance between the child and the prohibited area B is 0.8 m, and the distance between the child and the prohibited area C is 1.1 m, it is considered that the child meets the live-wire-touching condition, and the timing is started. When the timing duration is 5 seconds, it is calculated that the distance between the child and the prohibited area A is 1.4 m, the distance between the child and the prohibited area B is 1.1 m, and the distance between the child and the prohibited area C is 1.1 m, it is considered that the child does not meet the live-wire-touching condition, and the current process is terminated.
[0090] It should be understood that the case of not meeting the live-wire-touching condition not only includes the case that the distance from the prohibited area is greater than the threshold, but also includes the case that the live-wire-touching object leaves the monitored area, and the distance between the live-wire-touching object and the prohibited area cannot be acquired. In this case, it is also considered that the live-wire-touching object does not meet the live-wire-touching condition. The embodiment does not specifically limit the case of not meeting the live-wire-touching condition.
[0091] In application, the switching between the first mode and the second mode can be manually switched by the user or automatically switched. The embodiment does not specifically limit the switching mode and the duration of using the first or second mode.
[0092] In one example, the user sets the first mode to be executed at 7:30-18:30 on weekdays, and switches to the second mode at other times.
[0093] In this embodiment, when the power-off control mode is the second mode, before the power-on control device is powered off, a prompt message can be sent to the user to remind the user that the power-on control device will be powered off after a preset time period. When an instruction message based on the prompt message is received from the user, the current processing flow is confirmed in conjunction with the instruction message.
[0094] In one example, when the user confirms that the power-on control device is powered off after a preset period of time based on the indication information fed back by the prompt information, the process of controlling the power-on control device to power off is continued; when the user refuses to control the power-on control device to power off after a preset period of time based on the indication information fed back by the prompt information, the process is terminated.
[0095] In the application, the power-off prompt information output to the user may include information such as time, location, power-off control device number, and objects susceptible to electric shock, etc. This embodiment does not impose any specific limitation on this.
[0096] In one example, after determining that there is an object susceptible to electric shock in the image of the monitored area and that the object meets the conditions for being susceptible to electric shock, a power-off prompt message is sent to the user. The user receives the message using a mobile phone, and the power-off message may be (14:00, bedroom, smart socket 1, Zhang San)-power-off.
[0097] In the application, prompt information can be output to the user via a WIFI TV, mobile phone and / or smart watch. When the user is not at home, the prompt information can be received using the mobile phone. When the user is at home and watching TV attentively, the prompt information received through the WIFI TV can still have the effect of reminding the user that there is an object at home that is susceptible to electric shock and meets the conditions for electric shock. When the user is not convenient to use the mobile phone, such as when running outside, the prompt information received through the smart watch can still have the effect of reminding the user that there is an object at home that is susceptible to electric shock and meets the conditions for electric shock.
[0098] It should be understood that when the power-off control mode is the first mode, according to the needs of the user, it is still possible to set the prompt message to be sent to the user. In this case, the prompt message sent can only be viewed by the user.
[0099] In this embodiment, after the power-on control device is powered off, and the object susceptible to electric shock changes from meeting the susceptible electric shock condition to not meeting the susceptible electric shock condition, the power-on control device may be controlled to be powered on.
[0100] In the application, after the power-on control device is powered on, a power-on prompt message can be sent to the user. The power-on prompt message may include information such as time, place, power-on control device number, and the object that is susceptible to electric shock that caused the power-on control device to be powered off last time. This embodiment does not specifically limit the content of the power-on prompt message.
[0101] For example, the power-on prompt information may be (14:00, bedroom, smart socket 1, Zhang San)-power-on.
[0102] Based on the same inventive concept, the embodiment of the present application provides an anti-electric shock system, such as Figure 2 As shown, the system may include:
[0103] Image acquisition device 201, server 202 and power control device 203;
[0104] The server 202 is used to obtain an image of the monitored area through the image acquisition device 201; based on the image of the monitored area, when it is determined that there is an object that is susceptible to electric shock in the image of the monitored area, and when the object that is susceptible to electric shock meets the condition of susceptible electric shock, the power control device 203 is controlled to cut off the power; wherein the condition of susceptible electric shock indicates that the object that is susceptible to electric shock has the risk of electric shock by touching the power control device.
[0105] In the application, the image acquisition device 201 can be a camera with a tracking function. When the area of the monitored area is relatively large, resulting in the camera being unable to capture a complete image of the monitored area at one time, accurate monitoring of objects susceptible to electric shock can be achieved through the tracking function of the camera. For example, the area currently captured by the camera is sub-area A of the monitored area, and the object susceptible to electric shock is also located in sub-area A. When the object susceptible to electric shock moves to sub-area B of the monitored area, the tracking function can be used to track the movement of the object susceptible to electric shock. The camera moves and changes the shooting area to sub-area B of the monitored area.
[0106] It should be understood that the power-on control device 203 can be any power-on control device commonly used in daily life. For example, the power-on control device is a socket, a switch, etc. It should be particularly noted that the power-on control device that can be applied to the present anti-electric shock method should be able to control its execution of power-off and power-on operations through a certain communication method. For example, a smart socket that can be applied to the present anti-electric shock method, in addition to the functional module of the socket itself, also has a WIFI communication module and a control module inside the smart socket. The WIFI communication module is used to receive a power-off instruction or a power-on instruction. When the WIFI communication module receives a power-off instruction, the control module controls the smart socket to power off and stop its power supply function. When the WIFI communication module receives a power-on instruction, the control module controls the smart socket to power on and restore its power supply function.
[0107] The following is an example of a scenario to prevent children from touching the smart socket. Figure 3 As shown, the solution of this application is introduced.
[0108] Users use photos taken with a camera to manually divide the area around the smart socket where children are not allowed to enter into restricted zones A and B. They then use their mobile phone to record front, side, and back images of the child and their family. Based on these images, the child is identified as a person requiring protection. The user-defined restricted zones, along with the images of the people and the protected individuals, are then uploaded to the server.
[0109] Every time the camera captures a new image of a person, the mobile phone will prompt the user whether to enter the new image into the family list or visitor list, and then prompt the user whether the member corresponding to the image needs protection.
[0110] When the camera starts working, after recognizing the movement of a person, it uploads the captured image of the person to the server through photo capture. The server then compares and matches the uploaded image information of the person, giving priority to facial image matching. If the face cannot be recognized, it uses front, side, and back images for identification. If the server determines that the photographed person is a child who has been registered and needs protection, the camera will send a tracking command to the camera, and the camera will begin tracking the child in real time. After receiving the tracking command, the camera will prioritize switching to the fastest network environment, and will prioritize the communication method with the lowest communication delay between 5G or WiFi to ensure low latency in data upload, so that the entire process of upload-judgment-information return and push is achieved at the millisecond level.
[0111] The child's trajectory is uploaded in real time and compared with all pre-stored prohibited areas. When the user is at home, power-off plan 1 is implemented: When a child enters a prohibited area, such as prohibited area A, the server simultaneously pushes a notification to the user's smartwatch, mobile phone, and Wi-Fi TV. The prompt message when the child enters prohibited area A can be "Because a child has entered prohibited area A, smart sockets 1 and 2 will be powered off in 15 seconds. Do you want to cancel?" If the user does not take action, the server will send a power-off command to the smart sockets in the corresponding area after 15 seconds. After the smart sockets in the corresponding area are powered off, the power-off record will be uploaded for the user to view.
[0112] When the user is not at home, for safety reasons, a power-off plan 2 can be added: the power-off time mentioned above can be changed from a 15s delay to an immediate power-off, and the power-off plan 2 can be executed from 8:00 to 19:00 on statutory working days, and the power-off plan 1 can be executed at other times.
[0113] The camera continues tracking the child. When the child leaves the restricted area, the server sends a power-on command to the smart socket. After powering on, the server pushes a notification to the user's smartwatch, mobile phone, and Wi-Fi TV. The message indicating that the child has left restricted area A may be "Child has left restricted area A. Smart sockets 1 and 2 have been powered on again." After the smart sockets in the corresponding area power on, the power-on record is uploaded for the user to view.
[0114] Based on the same concept, an anti-electric shock device is provided in the embodiment of the present application. The specific implementation of the device can be found in the description of the method embodiment part, and the repeated parts will not be repeated. Figure 4 As shown, the device mainly includes:
[0115] An acquisition unit 401 is used to acquire an image of a monitored area, where a power control device is installed;
[0116] The control unit 402 is used to control the power-on control device to cut off the power when it is determined that there is an object that is susceptible to electric shock in the image and the object meets the electric shock condition; wherein the electric shock condition indicates that the object that is susceptible to electric shock has the risk of electric shock by touching the power-on control device.
[0117] The control unit 402 is used to:
[0118] Acquire N prohibited areas in the image of the monitored area, each of the N prohibited areas containing an energized control device, and an area range of each prohibited area being smaller than an area range indicated by the image of the monitored area, where N is a positive integer;
[0119] If the target prohibited area exists among the N prohibited areas, it is determined that the object susceptible to electric shock meets the condition of susceptible to electric shock;
[0120] The target prohibited area is a prohibited area among the N prohibited areas, the distance between which and the object susceptible to electric shock is less than a distance threshold.
[0121] The control unit 402 is used to:
[0122] Identify M powered control devices present in the image of the monitored area, where M is a positive integer;
[0123] Obtaining a position of each of the M powered control devices;
[0124] Based on the position of each energized control device, N prohibited areas are delineated.
[0125] The control unit 402 is used to:
[0126] Extracting images of objects belonging to the same category as the electric shock-prone object from the images of the monitored area;
[0127] Matching the image of the category object with the image of the preset object susceptible to electric shock to obtain the image matching degree;
[0128] If the image matching degree of the category object is greater than a preset threshold, it is determined that an object susceptible to electric shock exists in the image of the category object.
[0129] The control unit 402 is used to:
[0130] Obtaining a power-off control mode; the power-off control mode includes a first mode or a second mode; the first mode is a mode in which the power-on control device is immediately powered off; the second mode is a mode in which the power-on control device is delayed for a preset time to power off;
[0131] Based on the power-off control mode, the energized control device is controlled to be powered off.
[0132] The control unit 402 is used to:
[0133] Acquiring the image acquisition time of the monitored area;
[0134] Timing starts from the collection moment, and when the timing duration is not less than the preset duration indicated by the second mode, the power-on control device is controlled to be powered off.
[0135] The device is also used to:
[0136] After starting to time the acquisition moment, and before the timed duration is no less than the preset duration indicated by the second mode, it is determined that the object susceptible to electric shock always meets the condition susceptible to electric shock during the timed duration.
[0137] The device is also used to:
[0138] Before the power-on control device is powered off, a prompt message is output to the user, where the prompt message is used to prompt the power-on control device to be powered off after a preset time period;
[0139] Receive indication information fed back by the user, wherein the indication information indicates confirmation to control the power-on control device to be powered off after the preset time period.
[0140] The device is also used to:
[0141] After the power-on control device is powered off, when it is determined that the object susceptible to electric shock changes from meeting the condition susceptible to electric shock to not meeting the condition susceptible to electric shock, the power-on control device is powered on.
[0142] Based on the same concept, an electronic device is also provided in the embodiment of the present application, such as Figure 5As shown, the electronic device mainly includes: a processor 501, a memory 502 and a communication bus 503, wherein the processor 501 and the memory 502 communicate with each other via the communication bus 503. The memory 502 stores a program that can be executed by the processor 501, and the processor 501 executes the program stored in the memory 502 to implement the following steps:
[0143] Acquiring an image of a monitored area, wherein a power-on control device is installed in the monitored area;
[0144] When it is determined that there is an object susceptible to electric shock in the image and the object susceptible to electric shock meets the electric shock condition, the power control device is controlled to cut off the power; wherein the electric shock condition indicates that the object susceptible to electric shock has the risk of electric shock by touching the power control device.
[0145] The communication bus 503 mentioned in the above electronic device can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. The communication bus 503 can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 5 Only one thick line is used in the diagram, but this does not mean that there is only one bus or one type of bus.
[0146] The memory 502 may include a random access memory (RAM) or a non-volatile memory, such as at least one disk storage. Alternatively, the memory may be at least one storage device located away from the processor 501.
[0147] The above-mentioned processor 501 can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc., and can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, and discrete hardware components.
[0148] In another embodiment of the present application, a computer-readable storage medium is provided, in which a computer program is stored. When the computer program is run on a computer, the computer executes the electric shock prevention method described in the above embodiment.
[0149] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When software is used for implementation, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions are transmitted from a website, computer, server or data center to another website, computer, server or data center via a wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, microwave, etc.) method. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrations. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a magnetic tape, etc.), an optical medium (e.g., a DVD) or a semiconductor medium (e.g., a solid-state hard disk), etc.
[0150] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article, or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or device. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of other identical elements in the process, method, article, or device comprising the element.
[0151] The foregoing description is intended only to provide specific embodiments of the present invention, which will enable those skilled in the art to understand and implement the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention is not intended to be limited to the embodiments shown herein, but is intended to be accorded the widest scope consistent with the principles and novel features claimed herein.
Claims
1. A method for preventing electric shock, characterized in that: include: Acquiring an image of a monitored area, wherein the monitored area is equipped with a power control device; When it is determined that an object susceptible to electric shock exists in the image and the object susceptible to electric shock meets an electric shock condition, the power-on control device is controlled to be powered off; wherein the electric shock condition indicates that the object susceptible to electric shock has a risk of electric shock when touching the power-on control device; Wherein, determining the presence of an object susceptible to electric shock in the image includes: intercepting an image of a category object belonging to the same category as the object susceptible to electric shock from the image of the monitored area; matching the image of the category object with a preset image of the object susceptible to electric shock to obtain an image matching degree; if the image matching degree of the category object is greater than a preset threshold, determining that the object susceptible to electric shock exists in the image of the category object; When an image of a category object belonging to the same category as the object susceptible to electric shock is identified, and the image of the category object is not a pre-recorded image of a family member, a prompt message is sent to the user terminal, and when an instruction to save the image of the category object is received, the image of the category object is set as the image of the object susceptible to electric shock.
2. The method according to claim 1, characterized in that Determine whether the object susceptible to electric shock meets the conditions for being susceptible to electric shock, including: Acquire N prohibited areas in the image of the monitored area, each of the N prohibited areas containing the power-on control device, and each prohibited area having an area smaller than the area indicated by the image of the monitored area, where N is a positive integer; If a target prohibited area exists among the N prohibited areas, determining that the object susceptible to electric shock meets the condition susceptible to electric shock; The target prohibited area is a prohibited area among the N prohibited areas, the distance between which and the object susceptible to electric shock is less than a distance threshold.
3. The method according to claim 2, characterized in that The obtaining of N prohibited areas in the image of the monitored area includes: Identifying M powered control devices present in the image of the monitored area, where M is a positive integer; Obtaining a position of each of the M power-on control devices; Based on the position of each energized control device, the N prohibited areas are delineated.
4. The method according to claim 1, wherein The controlling the power-on control device to be powered off includes: Obtaining a power-off control mode; the power-off control mode includes a first mode or a second mode; the first mode is a mode for controlling the power-on control device to immediately power off; the second mode is a mode for controlling the power-on control device to delay powering off for a preset time; Based on the power-off control mode, the power-on control device is controlled to be powered off.
5. The method according to claim 4, characterized in that The power-off control mode is the second mode; The controlling the power-on control device to be powered off based on the power-off control mode includes: Obtaining the acquisition time of the image of the monitored area; The timing is started from the acquisition moment, and when the timing duration is not less than the preset duration indicated by the second mode, the power-on control device is controlled to be powered off.
6. The method according to claim 5, characterized in that After the timing starts from the acquisition moment and before the timing duration is no less than the preset duration indicated by the second mode, the method further includes: Determine that within the timing period, the object susceptible to electric shock always meets the condition susceptible to electric shock.
7. The method according to claim 5, characterized in that Before controlling the power-on control device to be powered off, the method further includes: Outputting a prompt message to the user, wherein the prompt message is used to prompt the power control device to be powered off after the preset time period; Receive indication information fed back by the user, wherein the indication information indicates confirmation to control the power-on control device to be powered off after the preset time period.
8. The method according to claim 1, characterized in that After the power-on control device is controlled to be powered off, the method further comprises: When it is determined that the object susceptible to electric shock changes from meeting the condition susceptible to electric shock to not meeting the condition susceptible to electric shock, the power-on control device is controlled to be powered on.
9. An anti-electric shock system, characterized in that: include: Image acquisition device, server and power control device; The server is used to obtain images of the monitored area through the image acquisition device; Based on the image, when it is determined that an object susceptible to electric shock exists in the image and the object susceptible to electric shock meets an electric shock condition, controlling the power-on control device to be powered off; wherein the electric shock condition indicates that the object susceptible to electric shock has a risk of electric shock by touching the power-on control device; Wherein, determining the presence of an object susceptible to electric shock in the image includes: intercepting an image of a category object belonging to the same category as the object susceptible to electric shock from the image of the monitored area; matching the image of the category object with a preset image of the object susceptible to electric shock to obtain an image matching degree; if the image matching degree of the category object is greater than a preset threshold, determining that the object susceptible to electric shock exists in the image of the category object; When an image of a category object belonging to the same category as the object susceptible to electric shock is identified, and the image of the category object is not a pre-recorded image of a family member, a prompt message is sent to the user terminal, and when an instruction to save the image of the category object is received, the image of the category object is set as the image of the object susceptible to electric shock.
10. An anti-electric shock device, characterized in that: include: an acquisition unit, configured to acquire an image of a monitored area, wherein the monitored area is provided with a power-on control device; a control unit, configured to control the power-on control device to be powered off when it is determined that an object susceptible to electric shock exists in the image and the object susceptible to electric shock meets an electric shock condition; wherein the electric shock condition indicates that the object susceptible to electric shock has a risk of electric shock by touching the power-on control device; Wherein, determining the presence of an object susceptible to electric shock in the image includes: intercepting an image of a category object belonging to the same category as the object susceptible to electric shock from the image of the monitored area; matching the image of the category object with a preset image of the object susceptible to electric shock to obtain an image matching degree; if the image matching degree of the category object is greater than a preset threshold, determining that the object susceptible to electric shock exists in the image of the category object; When an image of a category object belonging to the same category as the object susceptible to electric shock is identified, and the image of the category object is not a pre-recorded image of a family member, a prompt message is sent to the user terminal, and when an instruction to save the image of the category object is received, the image of the category object is set as the image of the object susceptible to electric shock.
11. An electronic device, characterized in that: include: A processor, a memory, and a communication bus, wherein the processor and the memory communicate with each other via the communication bus; The memory is used to store computer programs; The processor is configured to execute the program stored in the memory to implement the electric shock prevention method according to any one of claims 1 to 8.
12. A computer-readable storage medium, characterized in that A computer program is stored thereon, and when the program is executed by a processor, the method for preventing electric shock according to any one of claims 1 to 8 is implemented.
Citation Information
Patent Citations
Method and apparatus for disconnecting power source
CN105094009A
Method and device for controlling socket, socket and readable storage medium
CN107976953A
Power supply control method of socket and Internet of things operating system
CN110673500A
Outage control device and method and air conditioner
CN111780339A