DAMO-NLP-SG / VideoLLaMA2

VideoLLaMA 2: Advancing Spatial-Temporal Modeling and Audio Understanding in Video-LLMs
Apache License 2.0
717 stars 48 forks source link

ModuleNotFoundError: No module named 'torchvision.transforms.functional_tensor #28

Closed deepakHonakeri05 closed 2 months ago

deepakHonakeri05 commented 2 months ago

Hi,

I'm fine tuning video llama2 on custom dataset. I get the following error. I have kept the same directory structure as mentioned in the README file.

I have tried upgrading torch and torchvision : pip install --upgrade torch torchvision

Also I have tried uninstalling and reinstalling : pip uninstall torch torchvision && pip install torch torchvision.

Please help!

ALSA lib confmisc.c:855:(parse_card) cannot find card '0' ALSA lib conf.c:5178:(_snd_config_evaluate) function snd_func_card_inum returned error: No such file or directory ALSA lib confmisc.c:422:(snd_func_concat) error evaluating strings ALSA lib conf.c:5178:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory ALSA lib confmisc.c:1334:(snd_func_refer) error evaluating name ALSA lib conf.c:5178:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:5701:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2664:(snd_pcm_open_noupdate) Unknown PCM default ALSA lib confmisc.c:855:(parse_card) cannot find card '0' ALSA lib conf.c:5178:(_snd_config_evaluate) function snd_func_card_inum returned error: No such file or directory ALSA lib confmisc.c:422:(snd_func_concat) error evaluating strings ALSA lib conf.c:5178:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory ALSA lib confmisc.c:1334:(snd_func_refer) error evaluating name ALSA lib conf.c:5178:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:5701:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2664:(snd_pcm_open_noupdate) Unknown PCM default Traceback (most recent call last): File "/content/VideoLLaMA2/videollama2/train_flash_attn.py", line 9, in from videollama2.train import train File "/content/VideoLLaMA2/./videollama2/train.py", line 33, in from pytorchvideo.transforms import ApplyTransformToKey, ShortSideScale, UniformTemporalSubsample File "/usr/local/lib/python3.10/dist-packages/pytorchvideo/transforms/init.py", line 3, in from .augmix import AugMix # noqa File "/usr/local/lib/python3.10/dist-packages/pytorchvideo/transforms/augmix.py", line 6, in from pytorchvideo.transforms.augmentations import ( File "/usr/local/lib/python3.10/dist-packages/pytorchvideo/transforms/augmentations.py", line 9, in import torchvision.transforms.functional_tensor as F_t ModuleNotFoundError: No module named 'torchvision.transforms.functional_tensor' Traceback (most recent call last): File "/content/VideoLLaMA2/videollama2/train_flash_attn.py", line 9, in from videollama2.train import train File "/content/VideoLLaMA2/./videollama2/train.py", line 33, in from pytorchvideo.transforms import ApplyTransformToKey, ShortSideScale, UniformTemporalSubsample File "/usr/local/lib/python3.10/dist-packages/pytorchvideo/transforms/init.py", line 3, in from .augmix import AugMix # noqa File "/usr/local/lib/python3.10/dist-packages/pytorchvideo/transforms/augmix.py", line 6, in from pytorchvideo.transforms.augmentations import ( File "/usr/local/lib/python3.10/dist-packages/pytorchvideo/transforms/augmentations.py", line 9, in import torchvision.transforms.functional_tensor as F_t ModuleNotFoundError: No module named 'torchvision.transforms.functional_tensor bin/python3 Traceback (most recent call last): File "/usr/local/bin/torchrun", line 8, in sys.exit(main()) File "/usr/local/lib/python3.10/dist-packages/torch/distributed/elastic/multiprocessing/errors/init.py", line 347, in wrapper return f(*args, **kwargs) File "/usr/local/lib/python3.10/dist-packages/torch/distributed/run.py", line 879, in main run(args) File "/usr/local/lib/python3.10/dist-packages/torch/distributed/run.py", line 870, in run elastic_launch( File "/usr/local/lib/python3.10/dist-packages/torch/distributed/launcher/api.py", line 132, in call return launch_agent(self._config, self._entrypoint, list(args)) File "/usr/local/lib/python3.10/dist-packages/torch/distributed/launcher/api.py", line 263, in launch_agent raise ChildFailedError( torch.distributed.elastic.multiprocessing.errors.ChildFailedError:

videollama2/train_flash_attn.py FAILED

deepakHonakeri05 commented 2 months ago

I solved the issue by downgrading torch to 2.0.1

Sorry!