Error-Mitigated Quantum Metrology via Virtual Purification.