DistSense: Distributed System for Activity Recognition in Smart Environments

Introduction

In the present day, as Portugal and the world face demographic challenges and an increasingly aging population, the field of Ambient Assisted Living (AAL) emerges as a crucial response to enhance the quality of life and promote user autonomy. The growing use of audiovisual sensors in smart homes for functions such as security, automation, and health monitoring makes data protection an urgent concern. Users demand assurances that sensitive information captured in their residences will not be compromised, accessed by unauthorized third parties, or used improperly. This need for security places substantial pressure on audiovisual capture systems, requiring approaches that ensure user privacy and data safeguarding. Additionally, it is essential that these systems are designed with user acceptance in mind, offering transparency, control, and, at the same time, an appropriate degree of accuracy in household activity detection. In this context, the DistSense system emerges as an innovative response to these challenges. The adoption of a distributed Peer-to-Peer (P2P) network of intelligent household sensors, in conjunction with the use of a variety of technologies to prioritize user data security, ensures efficient and collaborative processing of audiovisual information. This approach enables a significant reduction in false positives in the detection and recognition of domestic activities, especially in situations involving angle occlusion, variations in lighting, and acoustic noise. To validate the effectiveness of DistSense, functional tests were conducted for each implemented module, and two use cases were investigated, one in a real environment and another in a simulated environment. The trained audio and video models demonstrated accuracy rates of 88% and 80%, respectively. The results obtained during the implementation of the use cases were positive, highlighting the system’s ability to effectively meet user needs in terms of security and acceptance, as well as reducing uncertainties in the detection of household activities in the presence of audiovisual noise variations

High Level Design

Advancements in the field of monitoring have brought about significant improvements in the collection and analysis of user activity data. Monitoring systems adopting a centralized architecture may exhibit certain drawbacks, such as lack of privacy, data security, and fault tolerance.

Figure 1: Generic Architecture

In this context, a distributed approach is proposed to provide a secure and reliable system for communication and monitoring of sensitive user data. Figure above illustrates an overview of the architecture proposed in this research, wherein the system comprises independent nodes, referred to as peers, establishing connections with each other to form a Peer-to-Peer (P2P) network. Our system consists of four main modules, each playing a distinct role that contributes to the overall achievement of the objective. These modules include the discovery and initialization module, network communication module, machine learning module, and, finally, knowledge processing and representation for the user. This distributed architecture enables decentralized interaction among devices reducing false positive, promoting greater resilience and scalability in managing sensitive data while enhancing security and trust in the handling of this information

Hardware Design

In terms of hardware, the system requires the use of integrated video cameras and microphones in a microcomputer such as Jetson Nano or Raspberry Pi, the latter being a Single Board Computer (SBC) that provides a compact, cost-effective, and energy-efficient solution. The processing capability and connectivity features of these devices make them suitable for monitoring applications. The incorporation of integrated microphones and video cameras in each intelligent device allows for the direct capture of images and audio. Subsequently, local processing of the captured information is performed, simplifying implementation and enhancing system efficiency.


Evaluation and Results

In this context, the system evaluation unfolds in three distinct phases, aiming to ensure its capability to address challenges in both a controlled environment and the complexities of the real world. The first testing phase focuses on the individual assessment of each security system module. The goal is to ensure that each implemented module functions harmoniously together, guaranteeing scalability and overall system efficiency in accordance with research specifications.

Task DescriptionValidation
Verify whether each device is capable of identifying new devices entering the local network and responding efficiently to changes in the networkYes
Verify if each device can successfully add a new device to the network by updating its list of known peersYes
Verify if the devices can establish connections and communicate with each otherYes
Verify if one of the nodes is elected as the coordinator correctlyYes
Verify if only the coordinator node can communicate with the Home AssistantYes
Verify if the device consults the blockchain in case it does not reach a certain threshold in activity detectionYes

In the second phase, the system undergoes tests simulating a specific use case: the detection of household risks. This use case involves risk situations, such as water leaks, for instance, or other common threats in a domestic environment. Simulated tests are conducted in controlled environments where risks are staged using videos, and the system’s response is evaluated. It is crucial to verify if the system correctly identifies the simulated risks and acts in accordance with established safety guidelines. This phase allows for the assessment of algorithms and decision logic implementation to ensure accurate detection and effective system response. It was concluded that through collaboration, it was possible to reduce false positives in risk detection, thereby minimizing early alerts for the use

In the third and final phase, the system undergoes real-world evaluation using two Jetson Nano devices. Various types of common noise and interferences in a home environment are introduced, including background noise, lighting variations, pet movements, and other real-world conditions. The goal is to evaluate system performance under more challenging conditions that may impact its ability to detect risks and act appropriately. In this use case, the identification of users daily activities emerged as a critical facet to provide personalized and efficient experiences in smart home environments. However, it is imperative to acknowledge the environmental complexity inherent in domestic settings. These spaces prove to be highly dynamic, where multiple factors, such as occlusion of sight angles, substantially influence the interpretation of user actions. Additionally, environmental variables, including changes in lighting, background noise, and the presence of various objects, contribute to the complexity of the context. Furthermore, the variety of activities performed within a residence and the individual preferences of users further increase the heterogeneity of the task at hand. In this scenario, the adaptability of the system is of paramount importance. These challenges were overcome through collaboration among the system nodes, aiming to mitigate these aspects and enhance accuracy in the detection of domestic activities

Task DescriptionNo collaborationWith Collaboration
Reading a book24%82%
Washing dishes78%N/A

In the first scenario (reading a book), one of the peers responsible for detecting the activity failed to achieve a minimum level of reliability in identifying that specific audiovisual activity, obtaining approximately 24% accuracy. In this context, the node sought collaboration with another node that also observed the same scene but from a different perspective, achieving an accuracy of approximately 82%. In this regard, since “NODE-1” did not reach the minimum threshold of certainty in detecting the activity, it resorted to the blockchain for additional information. On the other hand in the second scenario, the system demonstrated effectiveness in detecting the user’s “Wash/Clean Dishes” activity, achieving an accuracy of approximately 78%. Due to the successful detection of the activity above the established precision threshold, the responsible node proceeded to record this event in the blockchain. Subsequently, these data were distributed to the node’s peers so that the event inserted into the blockchain could be validated by all nodes in the network. Following this validation, information about the detected event was sent to the Home Assistant (HA) by the coordinator node, with the purpose of informing and storing this data. This storage will later allow for a more detailed analysis of the user’s activities throughout the day. These additional pieces of information, obtained through blockchain querying, allow the node to identify the ongoing activity with greater precision, even if it is not completely visible or clear to a single node. This ability to cooperate and consult external sources to enhance the decision-making process in a smart home context is particularly valuable where the environment is constantly changing.

Conclusion

Although the system validation was successfully achieved through functional testing and the implementation of use cases, as technology continues to advance and cyber threats become more sophisticated, the distributed approach adopted in the DistSense system may serve as an interesting study for future projects in the field of monitoring smart home environments, where the landscape is continually evolving. However, it is crucial to recognize that security and collaboration among devices are ongoing efforts, requiring the system to be consistently evaluated and updated to remain resilient against evolving threats and ensure the continuous security of user data.