Fix EXIF DateTimeOriginal population

pull/1567/head
Piero Toffanin 2023-01-18 14:13:06 -05:00
rodzic f0e716f28b
commit 0118fcb5a6
2 zmienionych plików z 2 dodań i 1 usunięć

Wyświetl plik

@ -23,6 +23,7 @@ class SrtFileParser:
# SRT metadata is not standarized, we support the following formats:
# DJI mavic air 2
# 1
# 00:00:00,000 --> 00:00:00,016
# <font size="36">SrtCnt : 1, DiffTime : 16ms

Wyświetl plik

@ -213,7 +213,7 @@ class Video2Dataset:
img = Image.open(io.BytesIO(buf))
entry = srt_parser.get_entry(elapsed_time) if srt_parser is not None else None
elapsed_time_str = (elapsed_time + (self.date_now - datetime.datetime(1900, 1, 1))).strftime("%Y:%m:%d %H:%M:%S.%f")
elapsed_time_str = (elapsed_time + (self.date_now - datetime.datetime(1900, 1, 1))).strftime("%Y:%m:%d %H:%M:%S")
# Exif dict contains the following keys: '0th', 'Exif', 'GPS', '1st', 'thumbnail'
# Set the EXIF metadata