fix the UnicodeDecodeError when sort the local files