-
Enhanced uncertainty quantification variational autoencoders for the solution of Bayesian inverse problems
Authors:
Andrea Tonini,
Luca Dede'
Abstract:
Among other uses, neural networks are a powerful tool for solving deterministic and Bayesian inverse problems in real-time. In the Bayesian framework, variational autoencoders, a specialized type of neural network, enable the estimation of model parameters and their distribution based on observational data allowing to perform real-time inverse uncertainty quantification. In this work, we build upo…
▽ More
Among other uses, neural networks are a powerful tool for solving deterministic and Bayesian inverse problems in real-time. In the Bayesian framework, variational autoencoders, a specialized type of neural network, enable the estimation of model parameters and their distribution based on observational data allowing to perform real-time inverse uncertainty quantification. In this work, we build upon existing research [Goh, H. et al., Proceedings of Machine Learning Research, 2022] by proposing a novel loss function to train variational autoencoders for Bayesian inverse problems. When the forward map is affine, we provide a theoretical proof of the convergence of the latent states of variational autoencoders to the posterior distribution of the model parameters. We validate this theoretical result through numerical tests and we compare the proposed variational autoencoder with the existing one in the literature. Finally, we test the proposed variational autoencoder on the Laplace equation.
△ Less
Submitted 18 February, 2025;
originally announced February 2025.
-
Discovering Artificial Viscosity Models for Discontinuous Galerkin Approximation of Conservation Laws using Physics-Informed Machine Learning
Authors:
Matteo Caldana,
Paola F. Antonietti,
Luca Dede'
Abstract:
Finite element-based high-order solvers of conservation laws offer large accuracy but face challenges near discontinuities due to the Gibbs phenomenon. Artificial viscosity is a popular and effective solution to this problem based on physical insight. In this work, we present a physics-informed machine learning algorithm to automate the discovery of artificial viscosity models in a non-supervised…
▽ More
Finite element-based high-order solvers of conservation laws offer large accuracy but face challenges near discontinuities due to the Gibbs phenomenon. Artificial viscosity is a popular and effective solution to this problem based on physical insight. In this work, we present a physics-informed machine learning algorithm to automate the discovery of artificial viscosity models in a non-supervised paradigm. The algorithm is inspired by reinforcement learning and trains a neural network acting cell-by-cell (the viscosity model) by minimizing a loss defined as the difference with respect to a reference solution thanks to automatic differentiation. This enables a dataset-free training procedure. We prove that the algorithm is effective by integrating it into a state-of-the-art Runge-Kutta discontinuous Galerkin solver. We showcase several numerical tests on scalar and vectorial problems, such as Burgers' and Euler's equations in one and two dimensions. Results demonstrate that the proposed approach trains a model that is able to outperform classical viscosity models. Moreover, we show that the learnt artificial viscosity model is able to generalize across different problems and parameters.
△ Less
Submitted 5 August, 2024; v1 submitted 26 February, 2024;
originally announced February 2024.
-
Real-time whole-heart electromechanical simulations using Latent Neural Ordinary Differential Equations
Authors:
Matteo Salvador,
Marina Strocchi,
Francesco Regazzoni,
Luca Dede',
Steven Niederer,
Alfio Quarteroni
Abstract:
Cardiac digital twins provide a physics and physiology informed framework to deliver predictive and personalized medicine. However, high-fidelity multi-scale cardiac models remain a barrier to adoption due to their extensive computational costs and the high number of model evaluations needed for patient-specific personalization. Artificial Intelligence-based methods can make the creation of fast a…
▽ More
Cardiac digital twins provide a physics and physiology informed framework to deliver predictive and personalized medicine. However, high-fidelity multi-scale cardiac models remain a barrier to adoption due to their extensive computational costs and the high number of model evaluations needed for patient-specific personalization. Artificial Intelligence-based methods can make the creation of fast and accurate whole-heart digital twins feasible. In this work, we use Latent Neural Ordinary Differential Equations (LNODEs) to learn the temporal pressure-volume dynamics of a heart failure patient. Our surrogate model based on LNODEs is trained from 400 3D-0D whole-heart closed-loop electromechanical simulations while accounting for 43 model parameters, describing single cell through to whole organ and cardiovascular hemodynamics. The trained LNODEs provides a compact and efficient representation of the 3D-0D model in a latent space by means of a feedforward fully-connected Artificial Neural Network that retains 3 hidden layers with 13 neurons per layer and allows for 300x real-time numerical simulations of the cardiac function on a single processor of a standard laptop. This surrogate model is employed to perform global sensitivity analysis and robust parameter estimation with uncertainty quantification in 3 hours of computations, still on a single processor. We match pressure and volume time traces unseen by the LNODEs during the training phase and we calibrate 4 to 11 model parameters while also providing their posterior distribution. This paper introduces the most advanced surrogate model of cardiac function available in the literature and opens new important venues for parameter calibration in cardiac digital twins.
△ Less
Submitted 8 June, 2023;
originally announced June 2023.
-
Latent Dynamics Networks (LDNets): learning the intrinsic dynamics of spatio-temporal processes
Authors:
Francesco Regazzoni,
Stefano Pagani,
Matteo Salvador,
Luca Dede',
Alfio Quarteroni
Abstract:
Predicting the evolution of systems that exhibit spatio-temporal dynamics in response to external stimuli is a key enabling technology fostering scientific innovation. Traditional equations-based approaches leverage first principles to yield predictions through the numerical approximation of high-dimensional systems of differential equations, thus calling for large-scale parallel computing platfor…
▽ More
Predicting the evolution of systems that exhibit spatio-temporal dynamics in response to external stimuli is a key enabling technology fostering scientific innovation. Traditional equations-based approaches leverage first principles to yield predictions through the numerical approximation of high-dimensional systems of differential equations, thus calling for large-scale parallel computing platforms and requiring large computational costs. Data-driven approaches, instead, enable the description of systems evolution in low-dimensional latent spaces, by leveraging dimensionality reduction and deep learning algorithms. We propose a novel architecture, named Latent Dynamics Network (LDNet), which is able to discover low-dimensional intrinsic dynamics of possibly non-Markovian dynamical systems, thus predicting the time evolution of space-dependent fields in response to external inputs. Unlike popular approaches, in which the latent representation of the solution manifold is learned by means of auto-encoders that map a high-dimensional discretization of the system state into itself, LDNets automatically discover a low-dimensional manifold while learning the latent dynamics, without ever operating in the high-dimensional space. Furthermore, LDNets are meshless algorithms that do not reconstruct the output on a predetermined grid of points, but rather at any point of the domain, thus enabling weight-sharing across query-points. These features make LDNets lightweight and easy-to-train, with excellent accuracy and generalization properties, even in time-extrapolation regimes. We validate our method on several test cases and we show that, for a challenging highly-nonlinear problem, LDNets outperform state-of-the-art methods in terms of accuracy (normalized error 5 times smaller), by employing a dramatically smaller number of trainable parameters (more than 10 times fewer).
△ Less
Submitted 28 April, 2023;
originally announced May 2023.
-
lifex-cfd: an open-source computational fluid dynamics solver for cardiovascular applications
Authors:
Pasquale Claudio Africa,
Ivan Fumagalli,
Michele Bucelli,
Alberto Zingaro,
Marco Fedele,
Luca Dede',
Alfio Quarteroni
Abstract:
Computational fluid dynamics (CFD) is an important tool for the simulation of the cardiovascular function and dysfunction. Due to the complexity of the anatomy, the transitional regime of blood flow in the heart, and the strong mutual influence between the flow and the physical processes involved in the heart function, the development of accurate and efficient CFD solvers for cardiovascular flows…
▽ More
Computational fluid dynamics (CFD) is an important tool for the simulation of the cardiovascular function and dysfunction. Due to the complexity of the anatomy, the transitional regime of blood flow in the heart, and the strong mutual influence between the flow and the physical processes involved in the heart function, the development of accurate and efficient CFD solvers for cardiovascular flows is still a challenging task. In this paper we present lifex-cfd, an open-source CFD solver for cardiovascular simulations based on the lifex finite element library, written in modern C++ and exploiting distributed memory parallelism. We model blood flow in both physiological and pathological conditions via the incompressible Navier-Stokes equations, accounting for moving cardiac valves, moving domains, and transition-to-turbulence regimes. In this paper, we provide an overview of the underlying mathematical formulation, numerical discretization, implementation details and examples on how to use lifex-cfd. We verify the code through rigorous convergence analyses, and we show its almost ideal parallel speedup. We demonstrate the accuracy and reliability of the numerical methods implemented through a series of idealized and patient-specific vascular and cardiac simulations, in different physiological flow regimes. The lifex-cfd source code is available under the LGPLv3 license, to ensure its accessibility and transparency to the scientific community, and to facilitate collaboration and further developments.
△ Less
Submitted 20 November, 2023; v1 submitted 24 April, 2023;
originally announced April 2023.
-
A Deep Learning algorithm to accelerate Algebraic Multigrid methods in Finite Element solvers of 3D elliptic PDEs
Authors:
Matteo Caldana,
Paola F. Antonietti,
Luca Dede'
Abstract:
Algebraic multigrid (AMG) methods are among the most efficient solvers for linear systems of equations and they are widely used for the solution of problems stemming from the discretization of Partial Differential Equations (PDEs). The most severe limitation of AMG methods is the dependence on parameters that require to be fine-tuned. In particular, the strong threshold parameter is the most relev…
▽ More
Algebraic multigrid (AMG) methods are among the most efficient solvers for linear systems of equations and they are widely used for the solution of problems stemming from the discretization of Partial Differential Equations (PDEs). The most severe limitation of AMG methods is the dependence on parameters that require to be fine-tuned. In particular, the strong threshold parameter is the most relevant since it stands at the basis of the construction of successively coarser grids needed by the AMG methods. We introduce a novel Deep Learning algorithm that minimizes the computational cost of the AMG method when used as a finite element solver. We show that our algorithm requires minimal changes to any existing code. The proposed Artificial Neural Network (ANN) tunes the value of the strong threshold parameter by interpreting the sparse matrix of the linear system as a black-and-white image and exploiting a pooling operator to transform it into a small multi-channel image. We experimentally prove that the pooling successfully reduces the computational cost of processing a large sparse matrix and preserves the features needed for the regression task at hand. We train the proposed algorithm on a large dataset containing problems with a highly heterogeneous diffusion coefficient defined in different three-dimensional geometries and discretized with unstructured grids and linear elasticity problems with a highly heterogeneous Young's modulus. When tested on problems with coefficients or geometries not present in the training dataset, our approach reduces the computational time by up to 30%.
△ Less
Submitted 2 November, 2023; v1 submitted 21 April, 2023;
originally announced April 2023.
-
A comprehensive mathematical model for cardiac perfusion
Authors:
Alberto Zingaro,
Christian Vergara,
Luca Dede',
Francesco Regazzoni,
Alfio Quarteroni
Abstract:
We present a novel mathematical model that simulates myocardial blood perfusion by embedding multiscale and multiphysics features. Our model incorporates cardiac electrophysiology, active and passive mechanics, hemodynamics, reduced valve modeling, and a multicompartment Darcy model of perfusion. We consider a fully coupled electromechanical model of the left heart that provides input for a fully…
▽ More
We present a novel mathematical model that simulates myocardial blood perfusion by embedding multiscale and multiphysics features. Our model incorporates cardiac electrophysiology, active and passive mechanics, hemodynamics, reduced valve modeling, and a multicompartment Darcy model of perfusion. We consider a fully coupled electromechanical model of the left heart that provides input for a fully coupled Navier-Stokes - Darcy Model for myocardial perfusion. The fluid dynamics problem is modeled in a left heart geometry that includes large epicardial coronaries, while the multicompartment Darcy model is set in a biventricular domain. Using a realistic and detailed cardiac geometry, our simulations demonstrate the accuracy of our model in describing cardiac perfusion, including myocardial blood flow maps. Additionally, we investigate the impact of a regurgitant aortic valve on myocardial perfusion, and our results indicate a reduction in myocardial perfusion due to blood flow taken away by the left ventricle during diastole. To the best of our knowledge, our work represents the first instance where electromechanics, hemodynamics, and perfusion are integrated into a single computational framework.
△ Less
Submitted 24 March, 2023;
originally announced March 2023.
-
An electromechanics-driven fluid dynamics model for the simulation of the whole human heart
Authors:
Alberto Zingaro,
Michele Bucelli,
Roberto Piersanti,
Francesco Regazzoni,
Luca Dede',
Alfio Quarteroni
Abstract:
We introduce a multiphysics and geometric multiscale computational model, suitable to describe the hemodynamics of the whole human heart, driven by a four-chamber electromechanical model. We first present a study on the calibration of the biophysically detailed RDQ20 activation model (Regazzoni et al., 2020) that is able to reproduce the physiological range of hemodynamic biomarkers. Then, we demo…
▽ More
We introduce a multiphysics and geometric multiscale computational model, suitable to describe the hemodynamics of the whole human heart, driven by a four-chamber electromechanical model. We first present a study on the calibration of the biophysically detailed RDQ20 activation model (Regazzoni et al., 2020) that is able to reproduce the physiological range of hemodynamic biomarkers. Then, we demonstrate that the ability of the force generation model to reproduce certain microscale mechanisms, such as the dependence of force on fiber shortening velocity, is crucial to capture the overall physiological mechanical and fluid dynamics macroscale behavior. This motivates the need for using multiscale models with high biophysical fidelity, even when the outputs of interest are relative to the macroscale. We show that the use of a high-fidelity electromechanical model, combined with a detailed calibration process, allows us to achieve remarkable biophysical fidelity in terms of both mechanical and hemodynamic quantities. Indeed, our electromechanical-driven CFD simulations - carried out on an anatomically accurate geometry of the whole heart - provide results that match the cardiac physiology both qualitatively (in terms of flow patterns) and quantitatively (when comparing in silico results with biomarkers acquired in vivo). We consider the pathological case of left bundle branch block, and we investigate the consequences that an electrical abnormality has on cardiac hemodynamics thanks to our multiphysics integrated model. The computational model that we propose can faithfully predict a delay and an increasing wall shear stress in the left ventricle in the pathological condition. The interaction of different physical processes in an integrated framework allows us to faithfully describe and model this pathology, by capturing and reproducing the intrinsic multiphysics nature of the human heart.
△ Less
Submitted 5 March, 2024; v1 submitted 5 January, 2023;
originally announced January 2023.
-
A comprehensive and biophysically detailed computational model of the whole human heart electromechanics
Authors:
Marco Fedele,
Roberto Piersanti,
Francesco Regazzoni,
Matteo Salvador,
Pasquale Claudio Africa,
Michele Bucelli,
Alberto Zingaro,
Luca Dede',
Alfio Quarteroni
Abstract:
While ventricular electromechanics is extensively studied, four-chamber heart models have only been addressed recently; most of these works however neglect atrial contraction. Indeed, as atria are characterized by a complex physiology influenced by the ventricular function, developing computational models able to capture the physiological atrial function and atrioventricular interaction is very ch…
▽ More
While ventricular electromechanics is extensively studied, four-chamber heart models have only been addressed recently; most of these works however neglect atrial contraction. Indeed, as atria are characterized by a complex physiology influenced by the ventricular function, developing computational models able to capture the physiological atrial function and atrioventricular interaction is very challenging. In this paper, we propose a biophysically detailed electromechanical model of the whole human heart that considers both atrial and ventricular contraction. Our model includes: i) an anatomically accurate whole-heart geometry; ii) a comprehensive myocardial fiber architecture; iii) a biophysically detailed microscale model for the active force generation; iv) a 0D closed-loop model of the circulatory system; v) the fundamental interactions among the different core models; vi) specific constitutive laws and model parameters for each cardiac region. Concerning the numerical discretization, we propose an efficient segregated-intergrid-staggered scheme and we employ recently developed stabilization techniques that are crucial to obtain a stable formulation in a four-chamber scenario. We are able to reproduce the healthy cardiac function for all the heart chambers, in terms of pressure-volume loops, time evolution of pressures, volumes and fluxes, and three-dimensional cardiac deformation, with unprecedented matching (to the best of our knowledge) with the expected physiology. We also show the importance of considering atrial contraction, fibers-stretch-rate feedback and suitable stabilization techniques, by comparing the results obtained with and without these features in the model. The proposed model represents the state-of-the-art electromechanical model of the iHEART ERC project and is a fundamental step toward the building of physics-based digital twins of the human heart.
△ Less
Submitted 25 July, 2022;
originally announced July 2022.
-
A matrix-free high-order solver for the numerical solution of cardiac electrophysiology
Authors:
Pasquale Claudio Africa,
Matteo Salvador,
Paola Gervasio,
Luca Dede',
Alfio Quarteroni
Abstract:
We propose a matrix-free solver for the numerical solution of the cardiac electrophysiology model consisting of the monodomain nonlinear reaction-diffusion equation coupled with a system of ordinary differential equations for the ionic species. Our numerical approximation is based on the high-order Spectral Element Method (SEM) to achieve accurate numerical discretization while employing a much sm…
▽ More
We propose a matrix-free solver for the numerical solution of the cardiac electrophysiology model consisting of the monodomain nonlinear reaction-diffusion equation coupled with a system of ordinary differential equations for the ionic species. Our numerical approximation is based on the high-order Spectral Element Method (SEM) to achieve accurate numerical discretization while employing a much smaller number of Degrees of Freedom than first-order Finite Elements. We combine vectorization with sum-factorization, thus allowing for a very efficient use of high-order polynomials in a high performance computing framework. We validate the effectiveness of our matrix-free solver in a variety of applications and perform different electrophysiological simulations ranging from a simple slab of cardiac tissue to a realistic four-chamber heart geometry. We compare SEM to SEM with Numerical Integration (SEM-NI), showing that they provide comparable results in terms of accuracy and efficiency. In both cases, increasing the local polynomial degree $p$ leads to better numerical results and smaller computational times than reducing the mesh size $h$. We also implement a matrix-free Geometric Multigrid preconditioner that results in a comparable number of linear solver iterations with respect to a state-of-the-art matrix-based Algebraic Multigrid preconditioner. As a matter of fact, the matrix-free solver proposed here yields up to 45$\times$ speed-up with respect to a conventional matrix-based solver.
△ Less
Submitted 31 January, 2023; v1 submitted 10 May, 2022;
originally announced May 2022.
-
An open tool based on lifex for myofibers generation in cardiac computational models
Authors:
Pasquale C. Africa,
Roberto Piersanti,
Marco Fedele,
Luca Dede',
Alfio Quarteroni
Abstract:
Modeling the whole cardiac function involves the solution of several complex multi-physics and multi-scale models that are highly computationally demanding, which call for simpler yet accurate, high-performance computational tools. Despite the efforts made by several research groups, no software for whole-heart fully-coupled cardiac simulations in the scientific community has reached full maturity…
▽ More
Modeling the whole cardiac function involves the solution of several complex multi-physics and multi-scale models that are highly computationally demanding, which call for simpler yet accurate, high-performance computational tools. Despite the efforts made by several research groups, no software for whole-heart fully-coupled cardiac simulations in the scientific community has reached full maturity yet. In this work we present the first publicly released package of lifex, a high-performance Finite Element solver for multi-physics and multi-scale problems developed in the framework of the iHEART project. The goal of lifex is twofold. On the one side, it aims at making in silico experiments easily reproducible and accessible to a wide community of users, including those with a background in medicine or bio-engineering. On the other hand, as an academic research library lifex can be exploited by scientific computing experts to explore new mathematical models and numerical methods within a robust development framework. lifex has been developed with a modular structure and will be released bundled in different modules. The tool presented here proposes an innovative generator for myocardial fibers based on Laplace-Dirichlet Rule-Based Methods, which are the essential building blocks for modeling the electrophysiological, mechanical and electromechanical cardiac function, from single-chamber to whole-heart simulations. This report comes with an extensive technical and mathematical documentation to welcome new users to the core structure of a prototypical lifex application and to provide them with a possible approach to include the generated cardiac fibers into more sophisticated computational pipelines.
△ Less
Submitted 7 October, 2022; v1 submitted 10 January, 2022;
originally announced January 2022.
-
A reduced 3D-0D FSI model of the aortic valve including leaflet curvature
Authors:
Ivan Fumagalli,
Luca Dede',
Alfio Quarteroni
Abstract:
We introduce an innovative lumped-parameter model of the aortic valve, designed to efficiently simulate the impact of valve dynamics on blood flow. Our reduced model includes the elastic effects associated with the leaflets' curvature and the stress exchanged with the blood flow. The introduction of a lumped-parameter model based on momentum balance entails an easier calibration of the model param…
▽ More
We introduce an innovative lumped-parameter model of the aortic valve, designed to efficiently simulate the impact of valve dynamics on blood flow. Our reduced model includes the elastic effects associated with the leaflets' curvature and the stress exchanged with the blood flow. The introduction of a lumped-parameter model based on momentum balance entails an easier calibration of the model parameters: phenomenological-based models, on the other hand, typically have numerous parameters. This model is coupled to 3D Navier-Stokes equations describing the blood flow, where the moving valve leaflets are immersed in the fluid domain by a resistive method. A stabilized finite element method with a BDF time scheme is adopted for the discretization of the coupled problem, and the computational results show the suitability of the system in representing the leaflet motion, the blood flow in the ascending aorta, and the pressure jump across the leaflets. Both physiological and stenotic configurations are investigated, and we analyze the effects of different treatments for the leaflet velocity on the blood flow.
△ Less
Submitted 13 April, 2025; v1 submitted 1 June, 2021;
originally announced June 2021.