question in src/eval.py
Closed this issue · 2 comments
Hi, thank you for the brilliant work!
In src/eval.py, there is an argument called args.temporal_annotation_file, but the file path corresponding to this parameter is not specified in the code. Which file should this parameter correspond to? I'm looking forward to your help.
Hi, thanks for your interest in our work!
The temporal_annotation_file
should contain the temporal annotations of testing videos. If you’re looking at scripts/07_eval.sh, note that I haven’t specified any annotation file here, as this script is meant for videos for which you may not have labels. However, if you’re using slurm/ucf_crime/07_eval.sh or slurm/xd_violence/07_eval.sh, you’ll see that temporal_annotation_file
points to a specific file.
You can download the datasets from the links provided to see these files. Each row is the annotation for a video and should contain:
- The name of the video (e.g., Abuse028_x264.mp4).
- The category of the anomaly (e.g., Abuse), note that this is not used.
- The time windows of the anomalies, formatted as start_frame end_frame of each instance of anomaly. For example, 165 240 -1 -1 indicates that the anomaly occurs from frame 165 to 240. The -1 values mean no anomalous event instance and are used as padding with the video with the highest number of anomaly instances.
Let me know if this helps!
Thanks a lot! The problem has been solved!