A number of tube lines in London also has this. Central Line, (parts of) Jubilee Line, both do if I recall. Those lines are "semi-automatic" where the driver is providing oversight and operates the doors whilst the train will automatically drive. Driver can override easily.
In Germany, trains have a system called "Notbremsüberbrückung" / NBÜ. This system overrides the passenger emergency brake in tunnels... basically (i'm shortening it a bit here), as soon as the last carriage leaves the platform (in an underground) or the train can't fully stop before entering a tunnel, the e-brake is disabled, and only re-enabled when the train enters a platform / exits the tunnel.
There's nothing preventing automated trains from using the same principle. Additionally, tunnels can be retrofit with cameras or motion detectors, to further prevent something larger than a rat from getting in a dangerous position.