Impractical! No Way! why would that not work just fine and, like a real steam engine you'd have to stop and top up water and oil ( and probably change batteries).
I remember steam in the UK before it got replaced by horrible diesels and diesel electrics on main lines and 3rd rail electrics around where I lived, mostly commuter trains.
Bring back steam engines.