Hard Reset XIAOMI Mi 5s - Restore Factory Settings in XIAOMI
XIAOMI Mi 5 HARD RESET / Wipe Data / Restore MIUI Software
How to Hard Reset XIAOMI Mi 5 - Factory Reset by Find My Device
Hard Reset will erase all of your data
All described operations you are doing at your own risk.