# Heart DT: Monitoring and Preventing Cardiac Pathologies Using AI and IoT Sensors
## 1 Introduction  
Modern healthcare faces several challenges due to the increasing demand for healthcare services. This demand is driven by the growing volume of patient data, the continuously evolving technological capabilities, and the need for rapid and efficient healthcare processes and systems. According to a 2019 study [1], over the last decade, the healthcare information technology market has significantly expanded along with the focus on remote health-monitoring techniques adopting wearable devices, usually defined as IoT health sensors, connected to the internet. This growth trend is further highlighted by the recent health crisis caused by COVID-19. In fact, further studies [2] predict that the wearable medical devices market will be worth USD 50 billion by 2026. Smart healthcare is the term that identifies the set of modern technologies and approaches used to address healthcare challenges. Platforms that allow for the collection of medical data are considered to be essential components of smart healthcare, and they are used to develop end-user solutions, such as web or mobile applications. The main implementation aspects that the new intelligent health services platforms must guarantee are:  
* Data acquisition: the way in which medical data is acquired from various IoT sensors;
* Data storage: innovative methodologies for long-term storage of all medical data from various patients which allows for immediate and resilient access to the information;
* Data processing: algorithms that allow for validation and real-time data prediction through the use of machine learning techniques;* Data sharing and visualization: creation of dynamic dashboards that optimize the use of previously processed information and allow sharing the information with other systems. The currently available tools are effective for processing data, but lack homogeneous infrastructural organization, which may provide a centralized solution to the encountered issues. An efficient system may reduce costs and improve services by minimizing errors [3]. In this paper, we propose the use of digital twins (DTs) to solve various problems; in particular, we use DT technology in the classification of cardiac pathologies through the ECG signals. The main objectives, which also represent the novelty of this paper compared to the state of the art described in Section 2, are as follows:
* The implementation of a case study including a proof-of-concept of a heart DT based on microservices architecture characterized by an artificial intelligence component (studied and presented in [4; 5]) is provided;
* The proposed heart DT architecture collects several input signals, such as ECG signal, blood pressure, pulse, and blood oxygen saturation. In particular, real-time ECG data recorded by a smartwatch is analyzed and validated through an inference process on a pre-trained model;
* An extension of this study, a higher-level platform for disease management and monitoring is presented, in particular we focused on a specific cardiac pathology, i.e., ACS. The rest of the paper is structured as follows: Section 2 provides an overview of the state of the art regarding DT-based systems applied to healthcare, with particular attention to cardiovascular diseases analyzed through ECG signals. The architecture and implementation of the heart DT is described in Section 3. The setup description of the heart DT is conducted in Section 4. This section outlines the structure of an ECG signal, the pre-trained network model with a dataset containing normal ECG signals and those affected by cardiac pathologies, the real-time ECG signal acquisition system, and the obtained results. In Section 5, a higher-level platform is contextualized, which allows for the integration of different DTs, each for a specific organ, defined as Organ DT, to classify a specific pathology. Section 6 provides an example on how the platform can be utilized to address a particular cardiac pathology.