From dc1872083ae8bd33e9f127b58a42894a1b7b56d1 Mon Sep 17 00:00:00 2001 From: biggerfish Date: Sat, 1 Jan 2022 04:44:17 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=AF=E6=8C=81=E6=9B=B4=E5=A4=9A=E8=A7=86?= =?UTF-8?q?=E9=A2=91=E6=A0=BC=E5=BC=8F:mkv,=20mov,=20avi...?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/photo_classifier.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/photo_classifier.py b/src/photo_classifier.py index 1d6a7b1..30e523f 100644 --- a/src/photo_classifier.py +++ b/src/photo_classifier.py @@ -19,8 +19,8 @@ from win32com.propsys import propsys, pscon class Classifier(): mode = 'prod' # 开发模式(dev)还是产品模式(prod) - IMAGE_EXTENTIONS = ['jpg', 'jpeg', 'bmp', 'png'] - VIDEO_EXTENTIONS = ['mp4'] + IMAGE_EXTENTIONS = ['jpg', 'jpeg', 'bmp', 'png', 'tif', 'gif'] + VIDEO_EXTENTIONS = ['mp4', 'avi', 'rmvb', 'mkv', 'exe', 'mov', 'ppt', 'amr', 'mpg'] TEST_TABLE = 'TEST_PHOTO' TABLE = 'PHOTO' PHOTO_NO_DATE_KEYS = ['EXIF ExifVersion'] @@ -144,7 +144,7 @@ class Classifier(): record = cursor.fetchone() if str(record) != 'None': os.remove(file_path) - raise Exception('重复照片 {} --> 删除'.format(file_path)) + raise Exception('重复文件 {} --> 删除'.format(file_path)) except Exception as e: raise e