SA-Kenan/04_Spurerkennung/dev/del_images.py

26 lines
520 B
Python
Raw Normal View History

2022-05-09 20:30:26 +02:00
# -*- coding: utf-8 -*-
"""
Created on Tue Mar 1 19:06:33 2022
@author: Kenan
Bilder lsöchen die über einer bestimmten schutterspeed sind
"""
import sys, os
folder_path=r"U:\bwsyncshare\images_input"
files = [f for f in os.listdir(folder_path) if f.endswith('.png')]
for i, file in enumerate(files):
for ss in range(250,2050,50):
ss_str=str(ss)
if ss_str in file:
try:
os.remove(os.path.join(folder_path, file))
except:
pass