From 9df353ebeaabcf584f49eb6945a408c7d5c18557 Mon Sep 17 00:00:00 2001 From: Dmitry Volodin Date: Thu, 1 Jul 2021 21:52:09 +0300 Subject: [PATCH] Add milliseconds to filenames --- orcasound_processing.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/orcasound_processing.py b/orcasound_processing.py index 1c0eeb4a..234b83d8 100644 --- a/orcasound_processing.py +++ b/orcasound_processing.py @@ -30,7 +30,7 @@ def create_readable_name(directory, timestamp): Resulting name will look like `directory`/%Y-%m-%dT%H-%M-%S.wav""" return path.join( directory, - f"{datetime.utcfromtimestamp(timestamp).strftime('%Y-%m-%dT%H-%M-%S')}.wav", + f"{datetime.utcfromtimestamp(timestamp).strftime('%Y-%m-%dT%H-%M-%S-%f')[:-3]}.wav", )