last caption timestamp fix
Browse files- yttemporal180m.py +3 -1
yttemporal180m.py
CHANGED
|
@@ -126,7 +126,9 @@ class yttemporal180m(datasets.GeneratorBasedBuilder):
|
|
| 126 |
"video_url": url,
|
| 127 |
"caption": caption,
|
| 128 |
"timestamp_start": timestamp_start,
|
| 129 |
-
"timestamp_stop": timestamp_stop
|
|
|
|
|
|
|
| 130 |
"meta": json.dumps(
|
| 131 |
metadata_dict, default=json_serializer, indent=2
|
| 132 |
),
|
|
|
|
| 126 |
"video_url": url,
|
| 127 |
"caption": caption,
|
| 128 |
"timestamp_start": timestamp_start,
|
| 129 |
+
"timestamp_stop": timestamp_stop
|
| 130 |
+
if el["time"] != last_caption_timestamp
|
| 131 |
+
else last_caption_timestamp,
|
| 132 |
"meta": json.dumps(
|
| 133 |
metadata_dict, default=json_serializer, indent=2
|
| 134 |
),
|