diff --git a/python/paddle/dataset/common.py b/python/paddle/dataset/common.py index 35155a2de2d22..4695b633ffa0f 100644 --- a/python/paddle/dataset/common.py +++ b/python/paddle/dataset/common.py @@ -18,7 +18,6 @@ import importlib import os import pickle -import re import shutil import sys import tempfile @@ -72,11 +71,6 @@ def md5file(fname): def download(url, module_name, md5sum, save_name=None): - module_name = re.match("^[a-zA-Z0-9_/\\-]+$", module_name).group() - if isinstance(save_name, str): - save_name = re.match( - "^(?:(?!\\.\\.)[a-zA-Z0-9_/\\.-])+$", save_name - ).group() dirname = os.path.join(DATA_HOME, module_name) if not os.path.exists(dirname): os.makedirs(dirname)