ZihanWang314
commited on
Commit
·
ee6abc6
1
Parent(s):
9dec5d5
update
Browse files
README.md
CHANGED
|
@@ -127,7 +127,9 @@ configs:
|
|
| 127 |
'E': 'The nail on the right side of the motorcycle exhaust pipe'
|
| 128 |
},
|
| 129 |
'video_metadata': {
|
| 130 |
-
'CLIP-reference-interval': [180.0, 240.0], # Time interval of the
|
|
|
|
|
|
|
| 131 |
'frame_count': 14155, # Total number of frames in the video
|
| 132 |
'frame_rate': 30.0, # Frame rate of the video
|
| 133 |
'duration': 471.8333435058594, # Duration of the video in seconds
|
|
@@ -141,6 +143,8 @@ configs:
|
|
| 141 |
}
|
| 142 |
}
|
| 143 |
```
|
|
|
|
|
|
|
| 144 |
#### Dataset exploration
|
| 145 |
|
| 146 |
add hyperlink to demo
|
|
@@ -168,8 +172,7 @@ print(dataset)
|
|
| 168 |
#### Video Source Download
|
| 169 |
|
| 170 |
TODO: We plan to provide a script of how to download a subset from [Ego4d](https://ego4d-data.org/).
|
| 171 |
-
|
| 172 |
-
|
| 173 |
```bash
|
| 174 |
pip install ego4d
|
| 175 |
|
|
@@ -180,6 +183,20 @@ ego4d --output_directory=your_path/videos/ \
|
|
| 180 |
|
| 181 |
python process_videos_to_clips.py
|
| 182 |
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 183 |
|
| 184 |
|
| 185 |
#### Dataset Statistics Summary
|
|
|
|
| 127 |
'E': 'The nail on the right side of the motorcycle exhaust pipe'
|
| 128 |
},
|
| 129 |
'video_metadata': {
|
| 130 |
+
'CLIP-reference-interval-vclip': [180.0, 240.0], # Time interval of the "vclip" that is considered to be important by CLIP. this is calculated by (CLIP-reference-interval-video - vclip-interval-in-video[0])
|
| 131 |
+
'CLIP-reference-interval-video': [180.0, 240.0], # Time interval of the "video" that is considered to be important by CLIP. This is originally from the **Ego4D dataset**, used in our work for annotators to quickly locate in the video.
|
| 132 |
+
'vclip_interval_in_video': [0.0, 480.06667277018227], # the vclip start and end second, i.e., for [a, b], the vclip starts at the a second of the video, ends at the b second of the video
|
| 133 |
'frame_count': 14155, # Total number of frames in the video
|
| 134 |
'frame_rate': 30.0, # Frame rate of the video
|
| 135 |
'duration': 471.8333435058594, # Duration of the video in seconds
|
|
|
|
| 143 |
}
|
| 144 |
}
|
| 145 |
```
|
| 146 |
+
|
| 147 |
+
|
| 148 |
#### Dataset exploration
|
| 149 |
|
| 150 |
add hyperlink to demo
|
|
|
|
| 172 |
#### Video Source Download
|
| 173 |
|
| 174 |
TODO: We plan to provide a script of how to download a subset from [Ego4d](https://ego4d-data.org/).
|
| 175 |
+
For now, you can refer to their official guide [here](https://github.com/facebookresearch/Ego4d/tree/main/ego4d/cli). Your code would be look like the follows:
|
|
|
|
| 176 |
```bash
|
| 177 |
pip install ego4d
|
| 178 |
|
|
|
|
| 183 |
|
| 184 |
python process_videos_to_clips.py
|
| 185 |
```
|
| 186 |
+
Please find [video_uid.txt](https://huggingface.co/datasets/LVHaystack/LongVideoHaystack/blob/main/video_uid.txt) in our repo, or you can generate it by:
|
| 187 |
+
|
| 188 |
+
```python
|
| 189 |
+
import datasets
|
| 190 |
+
metadata = datasets.load_dataset("LVHaystack/LongVideoHaystack-metadata")
|
| 191 |
+
with open("video_uids.txt", "w") as file:
|
| 192 |
+
for video_id in metadata['video_id']:
|
| 193 |
+
file.write(video_id + " ")
|
| 194 |
+
```
|
| 195 |
+
|
| 196 |
+
then, you need to transform them to video clips:
|
| 197 |
+
```python
|
| 198 |
+
```
|
| 199 |
+
|
| 200 |
|
| 201 |
|
| 202 |
#### Dataset Statistics Summary
|