Text this: Solving the inverse problem of electrocardiography in a realistic environment