🤖 AI Summary
Cardiac electrophysiology (CEP) simulation has long relied on high-performance computing resources—particularly multi-core CPUs—hindering its broader adoption in research and clinical practice. To address this, we present the first PyTorch-based, GPU-accelerated finite-element framework enabling end-to-end differentiable CEP simulation. Our method integrates automatic differentiation, tensor parallelism, and hybrid explicit/implicit time integration to efficiently solve large-scale 3D cardiac meshes. Numerical accuracy is rigorously validated against analytical solutions and via N-version benchmarking. Experiments demonstrate up to数十-fold speedup over CPU-based implementations on representative 3D models, with simulation results matching gold-standard solvers to high fidelity. The framework is open-source, cross-platform, deployment-friendly, and imposes no commercial usage restrictions. By substantially lowering hardware requirements, it advances the democratization of CEP simulation for both scientific and clinical applications.
📝 Abstract
Cardiac electrophysiology (CEP) simulations are increasingly used for understanding cardiac arrhythmias and guiding clinical decisions. However, these simulations typically require high-performance computing resources with numerous CPU cores, which are often inaccessible to many research groups and clinicians. To address this, we present TorchCor, a high-performance Python library for CEP simulations using the finite element method on general-purpose GPUs. Built on PyTorch, TorchCor significantly accelerates CEP simulations, particularly for large 3D meshes. The accuracy of the solver is verified against manufactured analytical solutions and the $N$-version benchmark problem. TorchCor is freely available for both academic and commercial use without restrictions.