microsoft / SwinBERT

Research code for CVPR 2022 paper "SwinBERT: End-to-End Transformers with Sparse Attention for Video Captioning"
https://arxiv.org/abs/2111.13196
MIT License
237 stars 35 forks source link

FileNotFoundError: [Errno 2] No such file or directory: 'datasets/MSVD/frame_tsv/train_32frames.img.tsv' #45

Open PureEidolon opened 1 year ago

PureEidolon commented 1 year ago

05/09/2023 23:31:40 - INFO - __main__ - Init model from scratch. 05/09/2023 23:31:40 - INFO - __main__ - Model total parameters: 136106810 05/09/2023 23:31:41 - INFO - __main__ - yaml_file:MSVD/train_32frames.yaml Traceback (most recent call last): File "src/tasks/run_caption_VidSwinBert.py", line 679, in <module> main(args) File "src/tasks/run_caption_VidSwinBert.py", line 657, in main train_dataloader = make_data_loader(args, args.train_yaml, tokenizer, args.distributed, is_train=True) File "/videocap/src/datasets/vl_dataloader.py", line 87, in make_data_loader dataset = build_dataset(args, yaml_file, tokenizer, is_train=is_train) File "/videocap/src/datasets/vl_dataloader.py", line 22, in build_dataset return dataset_class(args, yaml_file, tokenizer, tensorizer, is_train, args.on_memory) File "/videocap/src/datasets/vision_language_tsv.py", line 364, in __init__ super(VisionLanguageTSVYamlDataset, self).__init__( File "/videocap/src/datasets/vision_language_tsv.py", line 44, in __init__ self.visual_tsv = self.get_tsv_file(self.visual_file) File "/videocap/src/datasets/vision_language_tsv.py", line 129, in get_tsv_file tsv_path = find_file_path_in_yaml(tsv_file, self.root) File "/videocap/src/utils/load_files.py", line 73, in find_file_path_in_yaml raise FileNotFoundError( FileNotFoundError: [Errno 2] No such file or directory: 'datasets/MSVD/frame_tsv/train_32frames.img.tsv'

When I try to train with MSVD dataset, the above error is reported What should I do to solve this problem?

duhuan35 commented 1 year ago

Have you solved it yet

Markkk111 commented 1 year ago

Hi , I also meet this trouble ,have you solved it?Thanks!

Alwen233 commented 1 year ago

需要下载数据集,并运行代码,生成train_32frames.img.tsv以及val_32frames.img.tsv这些需要的文件,官方没有提供

myccver commented 11 months ago

try this: https://blog.csdn.net/qq_45270993/article/details/133753980?csdn_share_tail=%7B%22type%22%3A%22blog%22%2C%22rType%22%3A%22article%22%2C%22rId%22%3A%22133753980%22%2C%22source%22%3A%22qq_45270993%22%7D

tunghsuht commented 4 months ago

I also meet this trouble. Here's how I do it. First, you need to download the MSDV dataset raw videos and put them in the datasets/MSVD/videos/. Then run the extract_frames.py which in prepro dir, note that the args of --num_frames is 32; it will extract several frames and save them to 32frames dir. Finally, run the create_image_frame_tsv.py also in prepro dir and you'll get the train_32frames.img.tsv, train_32frames.img.lineidx. Hope this helps!