Automatic recovery of corrupted maps