diff --git a/python/paddle/vision/datasets/flowers.py b/python/paddle/vision/datasets/flowers.py index 29c6ace6f5eefd04d24f691491c83e341fb809d3..448d6efb52beca953de7981312e8f9131e6fb05d 100644 --- a/python/paddle/vision/datasets/flowers.py +++ b/python/paddle/vision/datasets/flowers.py @@ -128,6 +128,13 @@ class Flowers(Dataset): scio = try_import('scipy.io') + # double check data download + self.label_file = _check_exists_and_download(self.label_file, LABEL_URL, + LABEL_MD5, 'flowers', True) + + self.setid_file = _check_exists_and_download(self.setid_file, SETID_URL, + SETID_MD5, 'flowers', True) + self.labels = scio.loadmat(self.label_file)['labels'][0] self.indexes = scio.loadmat(self.setid_file)[self.flag][0]