A bathroom cabinet intelligent storage management early warning method and system based on the Internet of Things

By optimizing the sensor network topology and constructing multi-hop transmission paths, combined with environmental prediction models, the problems of uneven energy consumption and insufficient early warning in traditional bathroom cabinet sensor networks have been solved, achieving improvements in energy consumption balance, data reliability, and proactive early warning.

CN122372583APending Publication Date: 2026-07-10ZHEJIANG JINDI HLDG GRP CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
ZHEJIANG JINDI HLDG GRP CO LTD
Filing Date
2026-04-17
Publication Date
2026-07-10

AI Technical Summary

Technical Problem

In traditional bathroom cabinet sensor networks, node energy consumption is uneven, with some nodes running out of power quickly. Long-distance node communication consumes a lot of energy and has unstable signal quality. The early warning mechanism lacks the ability to intervene in advance, resulting in insufficient data reliability and network lifespan.

Method used

By dynamically calculating the optimal number of clusters and selecting central nodes, optimizing the sensor network topology based on the remaining power and location of nodes, constructing multi-hop transmission paths, and combining environmental prediction models for early warning, the energy consumption balance and data transmission reliability of the sensor network are improved.

Benefits of technology

It achieves energy balance in the bathroom cabinet sensor network, extends network lifespan, improves data transmission reliability and proactive early warning, avoids premature node failure and excessive communication energy consumption, and provides an early warning mechanism for early intervention.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122372583A_ABST
    Figure CN122372583A_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of locker sensor network, a bathroom cabinet intelligent storage management early warning method and system based on Internet of Things, comprising: selecting a plurality of central sensor nodes from the Internet of Things sensor node set according to the optimal number of clusters, using the plurality of central sensor nodes to distribute nodes to the Internet of Things sensor node set to obtain a plurality of intra-path sensor node sets, constructing a plurality of sensor data transmission paths according to the plurality of intra-path sensor node sets and the plurality of central sensor nodes, transmitting bathroom cabinet data based on the plurality of sensor data transmission paths to obtain bathroom cabinet environment data, using the bathroom cabinet environment data to perform storage early warning to obtain a storage early warning signal. The present application can improve the overall service life and data transmission reliability of the bathroom cabinet sensor network, and improve the initiative of the bathroom cabinet early warning.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of sensor network technology for lockers, and in particular to an intelligent storage management and early warning method and system for bathroom cabinets based on the Internet of Things. Background Technology

[0002] With the rapid development of IoT technology and the in-depth application of smart home scenarios, the refined and intelligent management of storage space environments has become increasingly important. Abnormal changes in parameters such as temperature, humidity, and concentration of harmful gases in such environments may directly lead to mold growth, damage, or safety hazards of stored items. Therefore, achieving real-time and reliable monitoring of such environments and building a forward-looking early warning mechanism based on monitoring data is of key significance for ensuring the safety of items and improving management efficiency.

[0003] Traditional technologies typically involve simply deploying sensor nodes inside bathroom cabinets and having them upload data directly or via a fixed route to the gateway. This approach has several drawbacks: First, uneven node power consumption, with some nodes quickly running out of power due to excessive forwarding tasks, leading to partial network failures. Second, direct communication between long-distance nodes and the gateway is energy-intensive and has unstable signal quality, affecting data reliability. Third, early warning mechanisms are mostly based on current environmental parameter thresholds, which is a reactive approach and cannot provide a window of opportunity for early intervention. Summary of the Invention

[0004] This invention provides an IoT-based intelligent storage management and early warning method for bathroom cabinets, and a computer-readable storage medium. Its main purpose is to improve the overall lifespan and data transmission reliability of the bathroom cabinet sensor network, and enhance the proactiveness of the bathroom cabinet's early warning system.

[0005] To achieve the above objectives, the present invention provides an intelligent storage management and early warning method for bathroom cabinets based on the Internet of Things, comprising: Identify the bathroom cabinet to be warned and identify the set of IoT sensor nodes in the bathroom cabinet to be warned, wherein the set of IoT sensor nodes includes multiple IoT sensor nodes; The optimal number of clusters is set based on the IoT sensor node set. Multiple central sensor nodes are selected from the IoT sensor node set according to the optimal number of clusters. The number of central sensor nodes is the same as the optimal number of clusters. Multiple central sensor nodes are used to allocate IoT sensor node sets, resulting in multiple intra-path sensor node sets. Multiple sensor data transmission paths are constructed based on multiple sets of in-path sensor nodes and multiple central sensor nodes, wherein each sensor data transmission path corresponds one-to-one with a central sensor node. Data is transmitted to the bathroom cabinet via multiple sensor data transmission paths to obtain bathroom cabinet environmental data. By utilizing environmental data from the bathroom cabinet, storage warnings are generated, and a smart storage management warning system for the bathroom cabinet based on the Internet of Things is completed.

[0006] Optionally, setting the optimal cluster size based on the IoT sensor node set includes: The sensor transmission distance set is obtained by measuring the sensor transmission distance between each IoT sensor node in the IoT sensor node set and the pre-built data gateway. The average transmission distance is obtained by averaging the set of sensor transmission distances. Count the total number of nodes in the IoT sensor node set; Obtain the bathroom cabinet material of the bathroom cabinet to be warned, and set the signal shielding adjustment coefficient based on the bathroom cabinet material; The optimal number of clusters is calculated based on the average transmission distance, the total number of nodes, and the signal shielding adjustment coefficient. The optimal number of clusters is expressed as: in, Indicates the optimal number of clusters. This represents the signal shielding adjustment coefficient. This indicates the total number of nodes. This indicates the total area of ​​the bathroom vanity unit requiring a warning. This indicates the average transmission distance.

[0007] Optionally, the step of selecting multiple central sensor nodes from the IoT sensor node set based on the optimal clustering number includes: Extract IoT sensor nodes sequentially from the IoT sensor node set, and obtain the current node power and maximum node power of the extracted IoT sensor nodes; Calculate the current power percentage based on the current node's power level and the maximum node's power level; Summarize the current battery percentages to obtain the current battery percentage set; Multiple central sensor nodes are determined in the IoT sensor node set based on the optimal number of clusters and the current power ratio set, wherein the number of central sensor nodes is the same as the optimal number of clusters.

[0008] Optionally, the method of allocating IoT sensor node sets using multiple central sensor nodes to obtain multiple intra-path sensor node sets includes: Perform the following operation on each of the multiple central sensor nodes: Obtain the location of the central sensor node and the location of the data gateway; The transmission distance of the central node is determined based on the location of the central node and the location of the gateway. Determine the central power ratio of the central sensor node, and divide the management weight according to the central power ratio and the central node transmission distance to obtain the node management weight; The number of nodes under management is calculated based on node management weights; Based on the number of nodes managed, the in-path nodes are identified in the IoT sensor node set to obtain the in-path sensor node set, which includes multiple in-path sensor nodes. By summing up the set of in-path sensor nodes corresponding to each central sensor node, multiple in-path sensor node sets are obtained.

[0009] Optionally, the step of constructing multiple sensor data transmission paths based on multiple intra-path sensor node sets and multiple central sensor nodes includes: The sensor nodes to be transmitted are extracted sequentially from multiple central sensor nodes, and the transmission distance is obtained based on the sensor nodes to be transmitted and the data gateway. If the transmission distance is less than the preset transmission distance threshold, a node transmission path is constructed based on the sensor node to be transmitted and the data gateway. If the transmission distance is not less than the transmission distance threshold, then the relay sensor node of the sensor node to be transmitted is determined based on multiple central sensor nodes and multiple sets of intra-path sensor nodes. Construct a multi-hop transmission path based on the sensor node to be transmitted, the relay sensor node, and the data gateway; The node transmission path or multi-hop transmission path is denoted as the sensor data transmission path; By summing up the sensor data transmission paths corresponding to each sensor node to be transmitted, multiple sensor data transmission paths are obtained.

[0010] Optionally, determining the relay sensor node for the sensor node to be transmitted based on multiple central sensor nodes and multiple sets of intra-path sensor nodes includes: Based on the sensor node to be transmitted, multiple candidate sensor nodes are extracted from multiple central sensor nodes; For each of the multiple candidate sensor nodes, perform the following operation: Determine the candidate relay transmission distance between the candidate sensor and the sensor node to be transmitted; Obtain the candidate node power ratio of the candidate sensor nodes, and determine the load sensor node set of the candidate sensor nodes from multiple in-path sensor node sets; Count the number of load nodes in the load sensor node set; The relay priority is calculated based on the candidate relay transmission distance, the candidate node power ratio, and the number of load nodes. The relay priority corresponding to each candidate sensor is summarized to obtain multiple relay priorities; Relay sensor nodes are determined based on multiple relay priorities.

[0011] Optionally, the step of extracting multiple candidate sensor nodes from multiple central sensor nodes based on the sensor node to be transmitted includes: The sensor nodes to be transmitted are removed from multiple central sensor nodes to obtain multiple sensor nodes with different names; Extract the heteronymous sensor nodes sequentially from multiple heteronymous sensor nodes, and obtain the heteronymous transmission distance between the extracted heteronymous sensor nodes and the data gateway; If the transmission distance of the different name is less than the transmission distance, then the different name sensor node is recorded as a candidate sensor node; By summing up the candidate sensor nodes, multiple candidate sensor nodes are obtained.

[0012] Optionally, the step of constructing a multi-hop transmission path based on the sensor node to be transmitted, the relay sensor node, and the data gateway includes: Obtain the subsequent sensor nodes of the relay sensor node; Determine whether the subsequent sensor node is a data gateway; If the subsequent sensor node is not a data gateway, then the subsequent sensor node is used as a relay sensor node, and the step of obtaining the subsequent sensor node of the relay sensor node is returned until the subsequent sensor node is a data gateway. If the subsequent sensor node is a data gateway, then the subsequent sensor nodes are aggregated to obtain multiple subsequent sensor nodes; A multi-hop transmission path is constructed based on the sensor node to be transmitted, the relay sensor node, multiple subsequent sensor nodes, and the data gateway.

[0013] Optionally, the step of using bathroom cabinet environmental data to generate a storage warning signal includes: Construct a bathroom cabinet environment prediction model and storage environment parameter range; The bathroom cabinet environmental data is input into the bathroom cabinet environmental prediction model to obtain the bathroom cabinet predicted environmental parameter sequence, which includes multiple bathroom cabinet predicted environmental parameters. Predicted environmental parameters for bathroom cabinets are extracted from the sequence of predicted environmental parameters for bathroom cabinets. Based on the range of storage environment parameters, the predicted environmental parameters for bathroom cabinets are used to make early warning judgments and obtain early warning indicators, where the early warning indicator is either an early warning or a non-early warning. The warning signs are aggregated to obtain a warning sign set, and a storage warning signal is generated based on the warning sign set.

[0014] To achieve the above objectives, the present invention also provides an IoT-based intelligent storage management and early warning system for bathroom cabinets, comprising: The IoT node confirmation module is used to identify the bathroom cabinet to be warned and to identify the set of IoT sensor nodes in the bathroom cabinet to be warned, wherein the set of IoT sensor nodes includes multiple IoT sensor nodes. The cluster number calculation module is used to set the optimal cluster number based on the IoT sensor node set, and select multiple central sensor nodes from the IoT sensor node set according to the optimal cluster number, wherein the number of central sensor nodes is the same as the optimal cluster number. The central node allocation module is used to allocate IoT sensor node sets using multiple central sensor nodes to obtain multiple in-path sensor node sets. Based on the multiple in-path sensor node sets and multiple central sensor nodes, multiple sensor data transmission paths are constructed, wherein each sensor data transmission path corresponds one-to-one with a central sensor node. The warning signal generation module is used to transmit data to the bathroom cabinet based on multiple sensor data transmission paths, obtain bathroom cabinet environmental data, and use the bathroom cabinet environmental data to generate storage warning signals.

[0015] To address the above problems, the present invention also provides an electronic device, the electronic device comprising: Memory, storing at least one instruction; The processor executes the instructions stored in the memory to implement the above-described IoT-based smart storage management and early warning method for bathroom cabinets.

[0016] To address the aforementioned issues, the present invention also provides a computer-readable storage medium storing at least one instruction, which is executed by a processor in an electronic device to implement the aforementioned IoT-based smart storage management and early warning method for bathroom cabinets.

[0017] To address the problems described in the background, this invention first dynamically calculates the optimal number of clusters by combining the number of nodes, distribution area, average transmission distance, and a signal shielding adjustment coefficient reflecting the signal attenuation characteristics of the cabinet material. Then, it selects a central node based on the remaining power of each node. Compared to existing clustering methods that often rely on experience or simply node density, this step optimizes the sensor network topology from the source to achieve energy balance and extended network lifespan. Next, multiple central sensor nodes are used to allocate IoT sensor node sets, resulting in multiple intra-path sensor node sets. Compared to the common allocation based on proximity, this step considers the remaining power of the central node and its distance to the data gateway to calculate the node management weight, thereby determining its management burden. This allows central nodes with more power and better locations to assume more management responsibilities, achieving… Dynamic load balancing based on node status prevents some central nodes from failing too quickly due to excessive workload. Furthermore, addressing the issue of high energy consumption or unstable signals in direct communication due to distance from the gateway in existing technologies, this invention intelligently determines whether to use direct transmission or multi-hop transmission requiring relay by setting a distance threshold. When selecting nodes requiring relay, it comprehensively evaluates the remaining power, load, and distance from the source node of candidate nodes, thereby constructing a more energy-efficient and reliable data forwarding path. This reduces transmission energy consumption at long-distance nodes and improves data transmission success rate. Finally, unlike traditional methods that only provide immediate alarms based on current environmental parameter thresholds, this step constructs a predictive model to predict environmental parameters for a future period and compares them with safe ranges, enabling managers to intervene in potential risks in advance, improving the initiative and preventative nature of storage environment management. Therefore, this invention can improve the overall lifespan and data transmission reliability of bathroom cabinet sensor networks, enhancing the initiative of bathroom cabinet early warning systems. Attached Figure Description

[0018] Figure 1 A flowchart illustrating an IoT-based intelligent storage management and early warning method for bathroom cabinets, provided in an embodiment of the present invention. Figure 2 A functional block diagram of an IoT-based smart storage management and early warning system for bathroom cabinets provided in an embodiment of the present invention; Figure 3 This is a schematic diagram of the structure of an electronic device that implements the IoT-based smart storage management and early warning method for bathroom cabinets, according to an embodiment of the present invention.

[0019] Explanation of reference numerals in the attached figures: 10. Electronic device; 11. Processor; 12. Memory; 13. Bus.

[0020] The realization of the objective, functional features and advantages of the present invention will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation

[0021] It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.

[0022] This application provides an IoT-based intelligent storage management and early warning method for bathroom cabinets. The executing entity of this IoT-based intelligent storage management and early warning method includes, but is not limited to, at least one of the following electronic devices that can be configured to execute the method provided in this application: a server, a terminal, etc. In other words, the IoT-based intelligent storage management and early warning method for bathroom cabinets can be executed by software or hardware installed on a terminal device or a server device, and the software can be a blockchain platform. The server includes, but is not limited to, a single server, a server cluster, a cloud server, or a cloud server cluster.

[0023] Reference Figure 1 The diagram shown is a flowchart illustrating an IoT-based intelligent storage management and early warning method for bathroom cabinets according to an embodiment of the present invention. In this embodiment, the IoT-based intelligent storage management and early warning method for bathroom cabinets includes: S1. Determine the bathroom cabinet to be warned and identify the set of IoT sensor nodes in the bathroom cabinet to be warned, wherein the set of IoT sensor nodes includes multiple IoT sensor nodes.

[0024] It is clear that the bathroom cabinet to be warned refers to a bathroom cabinet that requires storage management, such as a public bathroom cabinet in a shopping mall or hotel. The IoT sensor node set refers to a collection of multiple IoT sensor nodes, wherein the IoT sensor nodes refer to sensor nodes distributed in the bathroom cabinet to be warned, used to monitor environmental parameters such as temperature, humidity, and concentration of harmful gases, such as temperature and humidity sensors and VOC gas sensors.

[0025] S2. Based on the IoT sensor node set, set the optimal number of clusters, and select multiple central sensor nodes from the IoT sensor node set according to the optimal number of clusters. The number of central sensor nodes is the same as the optimal number of clusters.

[0026] Understandably, the optimal cluster size refers to the number of central sensor nodes subsequently selected. Since the number of IoT sensor nodes in the bathroom cabinet to be monitored is large and widely distributed, and their energy consumption is uneven when directly transmitting data with the data gateway, it is necessary to set this optimal cluster size to guide the IoT sensor node set in constructing a cluster structure with relatively balanced energy consumption and extended overall lifespan. This cluster structure is the subsequent multiple intra-path sensor node sets. The central sensor node refers to the IoT sensor node selected from the IoT sensor node set with a relatively high current remaining power ratio. This central sensor node is used to manage and coordinate a portion of the IoT sensor nodes (i.e., the corresponding intra-path sensor node set). Management and coordination refer to the responsibilities undertaken by the central sensor node for data collection, processing, and forwarding within its corresponding intra-path sensor node set. For example, the central sensor node receives the collected data from the IoT sensor nodes it manages and coordinates.

[0027] Specifically, the setting of the optimal cluster size based on the IoT sensor node set includes: The sensor transmission distance set is obtained by measuring the sensor transmission distance between each IoT sensor node in the IoT sensor node set and the pre-built data gateway. The average transmission distance is obtained by averaging the set of sensor transmission distances. Count the total number of nodes in the IoT sensor node set; Obtain the bathroom cabinet material of the bathroom cabinet to be warned, and set the signal shielding adjustment coefficient based on the bathroom cabinet material; The optimal number of clusters is calculated based on the average transmission distance, the total number of nodes, and the signal shielding adjustment coefficient. The optimal number of clusters is expressed as: in, Indicates the optimal number of clusters. This represents the signal shielding adjustment coefficient. This indicates the total number of nodes. This indicates the total area of ​​the bathroom vanity unit requiring a warning. This indicates the average transmission distance.

[0028] It should be explained that the data gateway refers to the central communication device responsible for aggregating and forwarding data collected by IoT sensor nodes, such as a Wi-Fi / Bluetooth gateway module installed on the top or side of a bathroom cabinet awaiting early warning. The sensor transmission distance set refers to the collection of transmission distances from multiple sensors, where the sensor transmission distance refers to the shortest distance between the IoT sensor node and the data gateway. The average transmission distance refers to the average of the transmission distances of all sensors in the sensor transmission distance set. The total number of nodes refers to the total number of IoT sensor nodes in the IoT sensor node set. The bathroom cabinet material refers to the material used in the manufacture of the bathroom cabinet to be monitored. Since different bathroom cabinet materials will cause varying degrees of attenuation and shielding of wireless signals, a signal shielding adjustment coefficient needs to be set according to the different bathroom cabinet materials. This signal shielding adjustment coefficient quantifies the degree of shielding of wireless signals by the bathroom cabinet material. The larger the signal shielding adjustment coefficient, the stronger the shielding effect of the bathroom cabinet material on the signal. In this case, a larger optimal cluster number needs to be set. The value range of the signal shielding adjustment coefficient is 0 to 1, and the setting basis is based on the attenuation characteristics of the bathroom cabinet material on electromagnetic waves, using an empirical setting. For example, when the bathroom cabinet material is metal, its conductivity is good and its signal shielding is strong, so the signal shielding adjustment coefficient should be set to a larger value, such as 0.8 to 1.0. When the bathroom cabinet material is wood or plastic, its signal shielding is weak, so the signal shielding adjustment coefficient can be set to a smaller value, such as 0.1 to 0.3.

[0029] Furthermore, a larger total number of nodes indicates a larger IoT sensor node set, requiring more nodes for cluster management. This necessitates more central sensor nodes to manage and coordinate these IoT sensor nodes, thus leading to a higher optimal cluster number. Similarly, a larger total area of ​​the bathroom cabinet requiring early warning indicates a wider spatial distribution of the IoT sensor node set, also requiring more central sensor nodes for management and coordination, again resulting in a higher optimal cluster number. However, too many central sensor nodes lead to more relay transmission (data transmission between two central sensor nodes), reducing data transmission efficiency. Therefore, the formula for calculating the optimal cluster number introduces a... This term is used to suppress the large number of optimal clusters caused by the large size of IoT sensor node sets and the large space, so that the number of central sensor nodes can achieve a balance between transmission energy consumption and transmission efficiency.

[0030] Specifically, the step of selecting multiple central sensor nodes from the IoT sensor node set based on the optimal clustering number includes: Extract IoT sensor nodes sequentially from the IoT sensor node set, and obtain the current node power and maximum node power of the extracted IoT sensor nodes; Calculate the current power percentage based on the current node's power level and the maximum node's power level; Summarize the current battery percentages to obtain the current battery percentage set; Multiple central sensor nodes are determined in the IoT sensor node set based on the optimal number of clusters and the current power ratio set, wherein the number of central sensor nodes is the same as the optimal number of clusters.

[0031] It is clear that the current node power refers to the remaining power of the IoT sensor node. The maximum node power refers to the nominal total capacity of the IoT sensor node's battery. The current power ratio refers to the ratio of the current node power to the maximum node power. The larger the current power ratio, the more sufficient the remaining energy of the IoT sensor node, that is, the greater the probability that the IoT sensor node can become a central sensor node. The above-mentioned determination of multiple central sensor nodes in the IoT sensor node set based on the optimal cluster number and the current power ratio set means: determining multiple current power ratios ranked in the top m positions of the current power ratio set, where m represents the optimal cluster number, and recording the multiple IoT sensor nodes corresponding to these multiple current power ratios as multiple central sensor nodes.

[0032] S3. Utilize multiple central sensor nodes to allocate nodes to the IoT sensor node set, thereby obtaining multiple intra-path sensor node sets.

[0033] Understandably, the in-path sensor node set refers to a collection of multiple in-path sensor nodes, wherein an in-path sensor node refers to an Internet of Things sensor node that is coordinated and managed by a central sensor node.

[0034] In detail, the method of allocating IoT sensor node sets using multiple central sensor nodes to obtain multiple intra-path sensor node sets includes: Perform the following operation on each of the multiple central sensor nodes: Obtain the location of the central sensor node and the location of the data gateway; The transmission distance of the central node is determined based on the location of the central node and the location of the gateway. Determine the central power ratio of the central sensor node, and divide the management weight according to the central power ratio and the central node transmission distance to obtain the node management weight; The number of nodes under management is calculated based on node management weights; Based on the number of nodes managed, the in-path nodes are identified in the IoT sensor node set to obtain the in-path sensor node set, which includes multiple in-path sensor nodes. By summing up the set of in-path sensor nodes corresponding to each central sensor node, multiple in-path sensor node sets are obtained.

[0035] It should be explained that the gateway location refers to the actual location of the data gateway. The central node transmission distance refers to the shortest distance between the central node location and the gateway location. The central power ratio refers to the current power ratio of the central sensor node. The node management weight refers to a numerical value that quantifies the comprehensive management capability of the central sensor node. The larger the node management weight, the greater the potential for coordinated management of the central sensor node, that is, the more IoT sensor nodes the corresponding central sensor node can manage. The formula for calculating the node management weight is: ,in, Indicates the node management weight. Indicates the proportion of the central power. The central node's transmission distance is indicated by the proportion of central power. The larger the proportion of central power, the more sufficient the remaining power of the central sensor node, which means the greater the node's management weight. The larger the central node's transmission distance, the higher the energy consumption required for the central sensor node to transmit data back to the data gateway, which means the smaller the node's management weight.

[0036] Furthermore, the node management quantity refers to the number of IoT sensor nodes that the central sensor node needs to manage. The calculation of this node management quantity is as follows: First, the node management weights corresponding to all central sensor nodes are aggregated to obtain a node management weight set. Then, each node management weight in the node management weight set is normalized to obtain a normalized management weight set. The normalization method is as follows: each node management weight is divided by the sum of all node management weights to obtain the remaining number of all sensor nodes in the IoT sensor node set excluding the multiple central sensor nodes. The remaining number of nodes is then multiplied sequentially by each normalized management weight in the normalized management weight set. The resulting calculated values ​​are the node management quantity corresponding to each central sensor node. The above-mentioned identification of in-path nodes in the IoT sensor node set based on the number of nodes managed refers to: sequentially extracting IoT sensor nodes from the IoT sensor node set, calculating the distance between the IoT sensor node and each central sensor node, and designating the IoT sensor node as the in-path sensor node of the central sensor node with the smallest distance. If the in-path sensor node set of the central sensor node with the smallest distance is full (i.e., the number has reached the number of nodes managed), then designating the IoT sensor node as the in-path sensor node of the central sensor node with the second smallest distance, and so on, so that all IoT sensor nodes are allocated, thereby obtaining the in-path sensor node set.

[0037] S4. Construct multiple sensor data transmission paths based on multiple sets of in-path sensor nodes and multiple central sensor nodes, wherein each sensor data transmission path corresponds one-to-one with a central sensor node.

[0038] It is clear that the sensor data transmission path refers to the path through which a central sensor node transmits data to the data gateway.

[0039] In detail, the construction of multiple sensor data transmission paths based on multiple intra-path sensor node sets and multiple central sensor nodes includes: The sensor nodes to be transmitted are extracted sequentially from multiple central sensor nodes, and the transmission distance is obtained based on the sensor nodes to be transmitted and the data gateway. If the transmission distance is less than the preset transmission distance threshold, a node transmission path is constructed based on the sensor node to be transmitted and the data gateway. If the transmission distance is not less than the transmission distance threshold, then the relay sensor node of the sensor node to be transmitted is determined based on multiple central sensor nodes and multiple sets of intra-path sensor nodes. Construct a multi-hop transmission path based on the sensor node to be transmitted, the relay sensor node, and the data gateway; The node transmission path or multi-hop transmission path is denoted as the sensor data transmission path; By summing up the sensor data transmission paths corresponding to each sensor node to be transmitted, multiple sensor data transmission paths are obtained.

[0040] It should be explained that the "sensor node to be transmitted" refers to a central sensor node extracted from multiple central sensor nodes, and the "transmission distance" refers to the shortest distance between the sensor node to be transmitted and the data gateway. The "transmission distance threshold" is a manually set distance threshold used to determine whether relay forwarding is necessary. When the transmission distance is less than this threshold, it indicates that the distance between the sensor node to be transmitted and the data gateway is sufficiently short, and the energy consumption of direct single-hop transmission by the sensor node is within an acceptable range, resulting in high efficiency. The transmission distance threshold is set by conducting sensor data transmission experiments in the environment of the bathroom to be monitored, thereby obtaining the energy consumption of sensor data transmission at different transmission distances. Relevant engineers then select a maximum acceptable transmission distance based on the different energy consumption levels. The "node transmission path" refers to the path taken when the sensor node to be transmitted directly transmits data to the data gateway.

[0041] Furthermore, when the transmission distance is not less than the transmission distance threshold, it indicates that the distance between the sensor node to be transmitted and the data gateway is relatively far. Direct single-hop transmission would consume too much energy or have unstable data quality. In this case, it is necessary to find one or more relay nodes (such as relay sensor nodes) for the node to forward the sensor data to the data gateway through a multi-hop method, thereby reducing the huge energy consumption caused by a single long-distance transmission and improving the data quality of the sensor data. The relay sensor node refers to another central sensor node used to receive and forward the data of the sensor node to be transmitted. The multi-hop transmission path refers to the complete communication path of the sensor data starting from the sensor node to be transmitted, passing through one or more relay sensor nodes for hop-by-hop forwarding, and finally reaching the data gateway. The specific construction method of this multi-hop transmission path will be given in subsequent embodiments.

[0042] Specifically, determining the relay sensor node of the sensor node to be transmitted based on multiple central sensor nodes and multiple intra-path sensor node sets includes: Based on the sensor node to be transmitted, multiple candidate sensor nodes are extracted from multiple central sensor nodes; For each of the multiple candidate sensor nodes, perform the following operation: Determine the candidate relay transmission distance between the candidate sensor and the sensor node to be transmitted; Obtain the candidate node power ratio of the candidate sensor nodes, and determine the load sensor node set of the candidate sensor nodes from multiple in-path sensor node sets; Count the number of load nodes in the load sensor node set; Relay priority is calculated based on candidate relay transmission distance, candidate node power ratio, and number of load nodes. The relay priority corresponding to each candidate sensor is summarized to obtain multiple relay priorities; Relay sensor nodes are determined based on multiple relay priorities.

[0043] It should be explained that the candidate sensor node refers to the central sensor node that, after preliminary selection, is geographically suitable to serve as a relay sensor node. The candidate relay transmission distance refers to the shortest communication distance between the candidate sensor and the sensor node to be transmitted. The candidate node power ratio refers to the current power ratio of the candidate sensor node. The load sensor node set refers to the set of sensor nodes within the radius corresponding to the candidate sensor node. The number of load nodes refers to the number of IoT sensor nodes in the load sensor node set. The relay priority is a numerical value quantifying the overall suitability of a candidate sensor node as a relay sensor node for the sensor node to be transmitted. The higher the relay priority, the more suitable the candidate sensor node is to be selected as a relay sensor node. The formula for calculating the relay priority is: ,in, Indicates relay priority. Indicates the percentage of candidate node power. Indicates the transmission distance of the candidate relay. This indicates the number of load nodes.

[0044] Furthermore, the greater the transmission distance of the candidate relay, the higher the energy consumption of a single transmission from the sensor node to the candidate sensor node. In this case, the lower the relay priority and the higher the proportion of the candidate node's power, the more energy the candidate sensor node has remaining and the more capable it is of handling additional relay forwarding tasks. Conversely, the higher the relay priority and the greater the number of load nodes, the heavier the amount of data the candidate sensor node currently needs to manage and forward. Taking on additional relay tasks may cause the candidate sensor node's energy to be depleted too quickly or create a transmission bottleneck. Therefore, the lower the relay priority, the better. Determining the relay sensor node based on multiple relay priorities means: designating the candidate sensor node corresponding to the relay priority with the highest value among multiple relay priorities as the relay sensor node.

[0045] Specifically, the extraction of multiple candidate sensor nodes from multiple central sensor nodes based on the sensor node to be transmitted includes: The sensor nodes to be transmitted are removed from multiple central sensor nodes to obtain multiple sensor nodes with different names; Extract the heteronymous sensor nodes sequentially from multiple heteronymous sensor nodes, and obtain the heteronymous transmission distance between the extracted heteronymous sensor nodes and the data gateway; If the transmission distance of the different name is less than the transmission distance, then the different name sensor node is recorded as a candidate sensor node; By summing up the candidate sensor nodes, multiple candidate sensor nodes are obtained.

[0046] It is clear that the heteronymous sensor node refers to one of the remaining central sensor nodes after removing the sensor node to be transmitted from the multiple central sensor nodes. The heteronymous transmission distance refers to the shortest communication distance between the heteronymous sensor node and the data gateway.

[0047] Specifically, the construction of a multi-hop transmission path based on the sensor node to be transmitted, the relay sensor node, and the data gateway includes: Obtain the subsequent sensor nodes of the relay sensor node; Determine whether the subsequent sensor node is a data gateway; If the subsequent sensor node is not a data gateway, then the subsequent sensor node is used as a relay sensor node, and the step of obtaining the subsequent sensor node of the relay sensor node is returned until the subsequent sensor node is a data gateway. If the subsequent sensor node is a data gateway, then the subsequent sensor nodes are aggregated to obtain multiple subsequent sensor nodes; A multi-hop transmission path is constructed based on the sensor node to be transmitted, the relay sensor node, multiple subsequent sensor nodes, and the data gateway.

[0048] It is clear that the subsequent sensor node refers to the next node chosen by the relay sensor node on the path to the data gateway for data forwarding; that is, the subsequent sensor node can be considered as a relay sensor node within itself. If the subsequent sensor node is not the data gateway, it means that the relay sensor node cannot directly transmit data to the data gateway and still needs to continue forwarding towards the data gateway. In this case, this subsequent sensor node needs to be considered a new relay sensor node, and the process recursively searches for its own subsequent sensor node until a relay sensor node that can directly reach the data gateway is found. When the subsequent sensor node is the data gateway, it means that the relay sensor node can directly transmit data to the data gateway; that is, the entire multi-hop path is constructed with this relay sensor node as the last hop, and the recursive process terminates at this point. The above-mentioned construction of a multi-hop transmission path based on the sensor node to be transmitted, relay sensor node, multiple subsequent sensor nodes and data gateway refers to arranging these sensor nodes to be transmitted, relay sensor node and multiple subsequent sensor nodes in the order of data forwarding to form a complete and ordered node sequence from the sensor node to be transmitted to the data gateway. For example, if the sensor node to be transmitted is G1, its first-hop relay sensor node is G2, the subsequent sensor node of G2 is G3, and the subsequent sensor node of G3 is the data gateway GP, then the constructed multi-hop transmission path is G1, G2, G3, GP.

[0049] S5. Data transmission to the bathroom cabinet is performed based on multiple sensor data transmission paths to obtain bathroom cabinet environmental data.

[0050] Understandably, the bathroom cabinet environmental data refers to a set of parameters collected by the IoT sensor node set that represent the environmental state inside the bathroom cabinet to be warned. This bathroom cabinet environmental data includes environmental parameters collected by each IoT sensor node in the IoT sensor node set, such as temperature, humidity, and volatile organic compound concentration.

[0051] S6. Utilize bathroom cabinet environmental data to generate storage warnings, obtain storage warning signals, and complete the smart storage management and warning system for bathroom cabinets based on the Internet of Things.

[0052] It is clear that the aforementioned storage warning signal includes a set of warning indicators. This storage warning signal can indicate whether the predicted state of the internal environmental parameters of the bathroom cabinet under warning is safe within a certain period of time. Therefore, this storage warning signal can remind relevant managers to promptly carry out ventilation, cleaning, dehumidification, and temperature adjustment for the bathroom cabinet under warning.

[0053] Specifically, the method of using bathroom cabinet environmental data to generate storage warning signals includes: Construct a bathroom cabinet environment prediction model and storage environment parameter range; The bathroom cabinet environmental data is input into the bathroom cabinet environmental prediction model to obtain the bathroom cabinet predicted environmental parameter sequence, which includes multiple bathroom cabinet predicted environmental parameters. Predicted environmental parameters for bathroom cabinets are extracted from the sequence of predicted environmental parameters for bathroom cabinets. Based on the range of storage environment parameters, the predicted environmental parameters for bathroom cabinets are used to make early warning judgments and obtain early warning indicators, where the early warning indicator is either an early warning or a non-early warning. The warning signs are aggregated to obtain a warning sign set, and a storage warning signal is generated based on the warning sign set.

[0054] It should be explained that the bathroom cabinet environmental prediction model refers to a model used to predict the environmental parameters of the bathroom cabinet to be warned. The bathroom cabinet environmental prediction model is constructed as follows: historical environmental data of the bathroom cabinet to be warned is collected. The data composition of the historical environmental data is the same as that of the bathroom cabinet environmental data, both including environmental parameters such as temperature, humidity or concentration of specific gases (such as VOCs). Then, the neural network is trained with a large amount of historical environmental data, so that the neural network learns the rules and patterns of the changes of historical environmental parameters over time. The training here is carried out in a supervised learning manner. The neural network can adopt a long short-term memory network, so that the neural network can predict the environmental parameter values ​​at multiple future time points based on historical environmental data over a period of time, thereby obtaining the bathroom cabinet environmental prediction model.

[0055] Furthermore, the aforementioned bathroom cabinet predicted environmental parameter sequence refers to a time series of multiple bathroom cabinet predicted environmental parameters. These parameters are environmental parameters predicted by the bathroom cabinet environmental prediction model for a future point in time, such as temperature and humidity in the next 20 or 40 minutes. The storage environment parameter range refers to a range of values ​​for a specific environmental parameter that the bathroom cabinet to be warned of is in a safe and suitable storage state, set manually. This range can be set based on actual needs through experience or experimentation. For example, to ensure the clothes inside the bathroom cabinet are dry, the temperature or humidity range that maintains the dryness of various types of clothing can be obtained experimentally. For instance, a storage environment parameter range might be: humidity less than 60%RH. The warning indicator refers to an indicator generated after a warning judgment. A warning indicates that the bathroom cabinet predicted environmental parameter is outside the storage environment parameter range, while a non-warning indicates that the bathroom cabinet predicted environmental parameter is within the storage environment parameter range. The warning judgment based on the storage environment parameter range means: if the storage environment parameter range is within the bathroom cabinet predicted environmental parameter range, a warning is used as the warning indicator; otherwise, a non-warning is used as the warning indicator.

[0056] To address the problems described in the background, this invention first dynamically calculates the optimal number of clusters by combining the number of nodes, distribution area, average transmission distance, and a signal shielding adjustment coefficient reflecting the signal attenuation characteristics of the cabinet material. Then, it selects a central node based on the remaining power of each node. Compared to existing clustering methods that often rely on experience or simply node density, this step optimizes the sensor network topology from the source to achieve energy balance and extended network lifespan. Next, multiple central sensor nodes are used to allocate IoT sensor node sets, resulting in multiple intra-path sensor node sets. Compared to the common allocation based on proximity, this step considers the remaining power of the central node and its distance to the data gateway to calculate the node management weight, thereby determining its management burden. This allows central nodes with more power and better locations to assume more management responsibilities, achieving… Dynamic load balancing based on node status prevents some central nodes from failing too quickly due to excessive workload. Furthermore, addressing the issue of high energy consumption or unstable signals in direct communication due to distance from the gateway in existing technologies, this invention intelligently determines whether to use direct transmission or multi-hop transmission requiring relay by setting a distance threshold. When selecting nodes requiring relay, it comprehensively evaluates the remaining power, load, and distance from the source node of candidate nodes, thereby constructing a more energy-efficient and reliable data forwarding path. This reduces transmission energy consumption at long-distance nodes and improves data transmission success rate. Finally, unlike traditional methods that only provide immediate alarms based on current environmental parameter thresholds, this step constructs a predictive model to predict environmental parameters for a future period and compares them with safe ranges, enabling managers to intervene in potential risks in advance, improving the initiative and preventative nature of storage environment management. Therefore, this invention can improve the overall lifespan and data transmission reliability of bathroom cabinet sensor networks, enhancing the initiative of bathroom cabinet early warning systems.

[0057] like Figure 2 The diagram shown is a functional block diagram of an IoT-based smart storage management and early warning system for bathroom cabinets provided in an embodiment of the present invention.

[0058] The IoT-based smart storage management and early warning system 100 for bathroom cabinets described in this invention can be installed in an electronic device. Depending on the functions implemented, the IoT-based smart storage management and early warning system 100 may include an IoT node confirmation module 101, a cluster quantity calculation module 102, a central node allocation module 103, and an early warning signal generation module 104. The module described in this invention can also be called a unit, which refers to a series of computer program segments that can be executed by the processor of an electronic device and can perform a fixed function, and which are stored in the memory of the electronic device. The IoT node confirmation module 101 is used to determine the bathroom cabinet to be warned and identify the IoT sensor node set in the bathroom cabinet to be warned, wherein the IoT sensor node set includes multiple IoT sensor nodes. The cluster number calculation module 102 is used to set an optimal cluster number based on the IoT sensor node set, and select multiple central sensor nodes in the IoT sensor node set according to the optimal cluster number, wherein the number of central sensor nodes is the same as the optimal cluster number. The central node allocation module 103 is used to allocate IoT sensor node sets using multiple central sensor nodes to obtain multiple in-path sensor node sets, and to construct multiple sensor data transmission paths based on the multiple in-path sensor node sets and multiple central sensor nodes, wherein the sensor data transmission paths correspond one-to-one with the central sensor nodes. The warning signal generation module 104 is used to transmit bathroom cabinet data based on multiple sensor data transmission paths to obtain bathroom cabinet environmental data, and use the bathroom cabinet environmental data to conduct storage warnings to obtain storage warning signals.

[0059] In detail, the modules in the IoT-based smart storage management and early warning system 100 for bathroom cabinets described in this embodiment of the invention employ the same methods as described above during use. Figure 1 The method used here is the same as the IoT-based smart storage management and early warning method for bathroom cabinets, and it can produce the same technical effect, so it will not be elaborated here.

[0060] like Figure 3 The diagram shown is a structural schematic of an electronic device for implementing an IoT-based smart storage management and early warning method for bathroom cabinets, according to an embodiment of the present invention.

[0061] The electronic device 1 may include a processor 10, a memory 11 and a bus 12, and may also include a computer program stored in the memory 11 and capable of running on the processor 10, such as an Internet of Things-based smart storage management and early warning method program for bathroom cabinets.

[0062] The memory 11 includes at least one type of readable storage medium, such as flash memory, portable hard drive, multimedia card, card-type memory (e.g., SD or DX memory), magnetic memory, magnetic disk, optical disk, etc. In some embodiments, the memory 11 can be an internal storage unit of the electronic device 1, such as the portable hard drive of the electronic device 1. In other embodiments, the memory 11 can be an external storage device of the electronic device 1, such as a plug-in portable hard drive, smart media card (SMC), secure digital card (SD), flash card, etc., equipped on the electronic device 1. Furthermore, the memory 11 includes both internal storage units and external storage devices of the electronic device 1. The memory 11 can be used not only to store application software and various types of data installed on the electronic device 1, such as the code of an IoT-based smart storage management and early warning method program for bathroom cabinets, but also to temporarily store data that has been output or will be output.

[0063] In some embodiments, the processor 10 may be composed of integrated circuits, such as a single packaged integrated circuit or multiple integrated circuits with the same or different functions, including combinations of one or more central processing units (CPUs), microprocessors, digital processing chips, graphics processors, and various control chips. The processor 10 is the control unit of the electronic device, connecting various components of the entire electronic device through various interfaces and lines. It executes programs or modules stored in the memory 11 (e.g., an IoT-based smart storage management and early warning method program for bathroom cabinets) and calls data stored in the memory 11 to perform various functions of the electronic device 1 and process data.

[0064] The bus 12 can be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus, etc. The bus 12 can be divided into an address bus, a data bus, a control bus, etc. The bus 12 is configured to realize the connection and communication between the memory 11 and at least one processor 10, etc.

[0065] Figure 3 Only electronic devices with components are shown; it will be understood by those skilled in the art that... Figure 3The structure shown does not constitute a limitation on the electronic device 1, and may include fewer or more components than shown, or combine certain components, or have different component arrangements.

[0066] For example, although not shown, the electronic device 1 may also include a power supply (such as a battery) to power the various components. Preferably, the power supply can be logically connected to the at least one processor 10 through a power management device, thereby enabling functions such as charging management, discharging management, and power consumption management. The power supply may also include one or more DC or AC power supplies, recharging devices, power fault detection circuits, power converters or inverters, power status indicators, and other arbitrary components. The electronic device 1 may also include various sensors, Bluetooth modules, Wi-Fi modules, etc., which will not be described in detail here.

[0067] Furthermore, the electronic device 1 may also include a network interface. Optionally, the network interface may include a wired interface and / or a wireless interface (such as a Wi-Fi interface, a Bluetooth interface, etc.), which is typically used to establish communication connections between the electronic device 1 and other electronic devices.

[0068] Optionally, the electronic device 1 may further include a user interface, which may be a display, an input unit (such as a keyboard), and optionally, a standard wired interface or a wireless interface. Optionally, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, or an OLED (Organic Light-Emitting Diode) touchscreen, etc. The display may also be appropriately referred to as a screen or display unit, used to display information processed in the electronic device 1 and to display a visual user interface.

[0069] The IoT-based smart storage management and early warning method program for bathroom cabinets stored in the memory 11 of the electronic device 1 is a combination of multiple instructions. When run in the processor 10, it can achieve the following: Identify the bathroom cabinet to be warned and identify the set of IoT sensor nodes in the bathroom cabinet to be warned, wherein the set of IoT sensor nodes includes multiple IoT sensor nodes; The optimal number of clusters is set based on the IoT sensor node set. Multiple central sensor nodes are selected from the IoT sensor node set according to the optimal number of clusters, wherein the number of central sensor nodes is the same as the optimal number of clusters. Multiple central sensor nodes are used to allocate IoT sensor node sets, resulting in multiple intra-path sensor node sets. Multiple sensor data transmission paths are constructed based on multiple sets of in-path sensor nodes and multiple central sensor nodes, wherein each sensor data transmission path corresponds one-to-one with a central sensor node. Data is transmitted to the bathroom cabinet via multiple sensor data transmission paths to obtain bathroom cabinet environmental data. By utilizing environmental data from the bathroom cabinet, storage warnings are generated, and a smart storage management warning system for the bathroom cabinet based on the Internet of Things is completed.

[0070] Specifically, the processor 10's implementation method for the above instructions can be found in [reference needed]. Figures 1 to 3 The descriptions of the relevant steps in the corresponding embodiments are not repeated here.

[0071] Furthermore, if the modules / units integrated in the electronic device 1 are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. The computer-readable storage medium can be volatile or non-volatile. For example, the computer-readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a USB flash drive, a portable hard drive, a magnetic disk, an optical disk, a computer memory, or a read-only memory (ROM).

[0072] The present invention also provides a computer-readable storage medium storing a computer program, which, when executed by a processor of an electronic device, can perform the following: Identify the bathroom cabinet to be warned and identify the set of IoT sensor nodes in the bathroom cabinet to be warned, wherein the set of IoT sensor nodes includes multiple IoT sensor nodes; The optimal number of clusters is set based on the IoT sensor node set. Multiple central sensor nodes are selected from the IoT sensor node set according to the optimal number of clusters, wherein the number of central sensor nodes is the same as the optimal number of clusters. Multiple central sensor nodes are used to allocate IoT sensor node sets, resulting in multiple intra-path sensor node sets. Multiple sensor data transmission paths are constructed based on multiple sets of in-path sensor nodes and multiple central sensor nodes, wherein each sensor data transmission path corresponds one-to-one with a central sensor node. Data is transmitted to the bathroom cabinet via multiple sensor data transmission paths to obtain bathroom cabinet environmental data. By utilizing environmental data from the bathroom cabinet, storage warnings are generated, and a smart storage management warning system for the bathroom cabinet based on the Internet of Things is completed.

[0073] In the embodiments provided by this invention, it should be understood that the disclosed devices, systems, and methods can be implemented in other ways. For example, the system embodiments described above are merely illustrative, and actual implementations may have other classification methods.

[0074] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.

[0075] Furthermore, the functional modules in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or in the form of hardware plus software functional modules.

[0076] It will be apparent to those skilled in the art that the present invention is not limited to the details of the exemplary embodiments described above, and that the present invention can be implemented in other specific forms without departing from the spirit or essential characteristics of the present invention.

[0077] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention.

Claims

1. A smart storage management and early warning method for bathroom cabinets based on the Internet of Things, characterized in that, The method includes: Identify the bathroom cabinet to be warned and identify the set of IoT sensor nodes in the bathroom cabinet to be warned, wherein the set of IoT sensor nodes includes multiple IoT sensor nodes; The optimal number of clusters is set based on the IoT sensor node set. Multiple central sensor nodes are selected from the IoT sensor node set according to the optimal number of clusters. The number of central sensor nodes is the same as the optimal number of clusters. Multiple central sensor nodes are used to allocate IoT sensor node sets, resulting in multiple intra-path sensor node sets. Multiple sensor data transmission paths are constructed based on multiple sets of in-path sensor nodes and multiple central sensor nodes, wherein each sensor data transmission path corresponds one-to-one with a central sensor node. Data is transmitted to the bathroom cabinet via multiple sensor data transmission paths to obtain bathroom cabinet environmental data. By utilizing environmental data from the bathroom cabinet, storage warnings are generated, and a smart storage management warning system for the bathroom cabinet based on the Internet of Things is completed.

2. The IoT-based intelligent storage management and early warning method for bathroom cabinets as described in claim 1, characterized in that, The setting of the optimal cluster size based on the IoT sensor node set includes: The sensor transmission distance set is obtained by measuring the sensor transmission distance between each IoT sensor node in the IoT sensor node set and the pre-built data gateway. The average transmission distance is obtained by averaging the set of sensor transmission distances. Count the total number of nodes in the IoT sensor node set; Obtain the bathroom cabinet material of the bathroom cabinet to be warned, and set the signal shielding adjustment coefficient based on the bathroom cabinet material; The optimal number of clusters is calculated based on the average transmission distance, the total number of nodes, and the signal shielding adjustment coefficient. The optimal number of clusters is expressed as: in, Indicates the optimal number of clusters. This represents the signal shielding adjustment coefficient. This indicates the total number of nodes. This indicates the total area of ​​the bathroom vanity unit requiring a warning. This indicates the average transmission distance.

3. The IoT-based intelligent storage management and early warning method for bathroom cabinets as described in claim 2, characterized in that, The step of selecting multiple central sensor nodes from the IoT sensor node set based on the optimal clustering number includes: Extract IoT sensor nodes sequentially from the IoT sensor node set, and obtain the current node power and maximum node power of the extracted IoT sensor nodes; Calculate the current power percentage based on the current node's power level and the maximum node's power level; Summarize the current battery percentages to obtain the current battery percentage set; Multiple central sensor nodes are determined in the IoT sensor node set based on the optimal number of clusters and the current power ratio set, wherein the number of central sensor nodes is the same as the optimal number of clusters.

4. The IoT-based intelligent storage management and early warning method for bathroom cabinets as described in claim 3, characterized in that, The method of allocating IoT sensor node sets using multiple central sensor nodes results in multiple intra-path sensor node sets, including: Perform the following operation on each of the multiple central sensor nodes: Obtain the location of the central sensor node and the location of the data gateway; The transmission distance of the central node is determined based on the location of the central node and the location of the gateway. Determine the central power ratio of the central sensor node, and divide the management weight according to the central power ratio and the central node transmission distance to obtain the node management weight; The number of nodes under management is calculated based on node management weights; Based on the number of nodes managed, the in-path nodes are identified in the IoT sensor node set to obtain the in-path sensor node set, which includes multiple in-path sensor nodes. By summing up the set of in-path sensor nodes corresponding to each central sensor node, multiple in-path sensor node sets are obtained.

5. The IoT-based intelligent storage management and early warning method for bathroom cabinets as described in claim 4, characterized in that, The construction of multiple sensor data transmission paths based on multiple intra-path sensor node sets and multiple central sensor nodes includes: The sensor nodes to be transmitted are extracted sequentially from multiple central sensor nodes, and the transmission distance is obtained based on the sensor nodes to be transmitted and the data gateway. If the transmission distance is less than the preset transmission distance threshold, a node transmission path is constructed based on the sensor node to be transmitted and the data gateway. If the transmission distance is not less than the transmission distance threshold, then the relay sensor node of the sensor node to be transmitted is determined based on multiple central sensor nodes and multiple sets of intra-path sensor nodes. Construct a multi-hop transmission path based on the sensor node to be transmitted, the relay sensor node, and the data gateway; The node transmission path or multi-hop transmission path is denoted as the sensor data transmission path; By summing up the sensor data transmission paths corresponding to each sensor node to be transmitted, multiple sensor data transmission paths are obtained.

6. The IoT-based intelligent storage management and early warning method for bathroom cabinets as described in claim 5, characterized in that, The step of determining the relay sensor node for the sensor node to be transmitted based on multiple central sensor nodes and multiple sets of intra-path sensor nodes includes: Based on the sensor node to be transmitted, multiple candidate sensor nodes are extracted from multiple central sensor nodes; For each of the multiple candidate sensor nodes, perform the following operation: Determine the candidate relay transmission distance between the candidate sensor and the sensor node to be transmitted; Obtain the candidate node power ratio of the candidate sensor nodes, and determine the load sensor node set of the candidate sensor nodes from multiple in-path sensor node sets; Count the number of load nodes in the load sensor node set; The relay priority is calculated based on the candidate relay transmission distance, the candidate node power ratio, and the number of load nodes. The relay priority corresponding to each candidate sensor is summarized to obtain multiple relay priorities; Relay sensor nodes are determined based on multiple relay priorities.

7. The IoT-based intelligent storage management and early warning method for bathroom cabinets as described in claim 6, characterized in that, The extraction of multiple candidate sensor nodes from multiple central sensor nodes based on the sensor node to be transmitted includes: The sensor nodes to be transmitted are removed from multiple central sensor nodes to obtain multiple sensor nodes with different names; Extract the heteronymous sensor nodes sequentially from multiple heteronymous sensor nodes, and obtain the heteronymous transmission distance between the extracted heteronymous sensor nodes and the data gateway; If the transmission distance of the different name is less than the transmission distance, then the different name sensor node is recorded as a candidate sensor node; By summing up the candidate sensor nodes, multiple candidate sensor nodes are obtained.

8. The IoT-based intelligent storage management and early warning method for bathroom cabinets as described in claim 7, characterized in that, The construction of a multi-hop transmission path based on the sensor node to be transmitted, the relay sensor node, and the data gateway includes: Obtain the subsequent sensor nodes of the relay sensor node; Determine whether the subsequent sensor node is a data gateway; If the subsequent sensor node is not a data gateway, then the subsequent sensor node is used as a relay sensor node, and the step of obtaining the subsequent sensor node of the relay sensor node is returned until the subsequent sensor node is a data gateway. If the subsequent sensor node is a data gateway, then the subsequent sensor nodes are aggregated to obtain multiple subsequent sensor nodes; A multi-hop transmission path is constructed based on the sensor node to be transmitted, the relay sensor node, multiple subsequent sensor nodes, and the data gateway.

9. The IoT-based intelligent storage management and early warning method for bathroom cabinets as described in claim 8, characterized in that, The method of using bathroom cabinet environmental data to generate storage warning signals includes: Construct a bathroom cabinet environment prediction model and storage environment parameter range; The bathroom cabinet environmental data is input into the bathroom cabinet environmental prediction model to obtain the bathroom cabinet predicted environmental parameter sequence, which includes multiple bathroom cabinet predicted environmental parameters. Predicted environmental parameters for bathroom cabinets are extracted from the sequence of predicted environmental parameters for bathroom cabinets. Based on the range of storage environment parameters, the predicted environmental parameters for bathroom cabinets are used to make early warning judgments and obtain early warning indicators, where the early warning indicator is either an early warning or a non-early warning. The warning signs are aggregated to obtain a warning sign set, and a storage warning signal is generated based on the warning sign set.

10. A smart storage management and early warning system for bathroom cabinets based on the Internet of Things, characterized in that, The system includes: The IoT node confirmation module is used to identify the bathroom cabinet to be warned and to identify the set of IoT sensor nodes in the bathroom cabinet to be warned, wherein the set of IoT sensor nodes includes multiple IoT sensor nodes. The cluster number calculation module is used to set the optimal cluster number based on the IoT sensor node set, and select multiple central sensor nodes from the IoT sensor node set according to the optimal cluster number, wherein the number of central sensor nodes is the same as the optimal cluster number. The central node allocation module is used to allocate IoT sensor node sets using multiple central sensor nodes to obtain multiple in-path sensor node sets. Based on the multiple in-path sensor node sets and multiple central sensor nodes, multiple sensor data transmission paths are constructed, wherein each sensor data transmission path corresponds one-to-one with a central sensor node. The warning signal generation module is used to transmit data to the bathroom cabinet based on multiple sensor data transmission paths, obtain bathroom cabinet environmental data, and use the bathroom cabinet environmental data to generate storage warning signals.