Artificial intelligence predicts when heart will fail