Vision-CAIR / MiniGPT4-video

Official code for Goldfish model for long video understanding and MiniGPT4-video for short video understanding
https://vision-cair.github.io/Goldfish_website/
BSD 3-Clause "New" or "Revised" License
559 stars 60 forks source link

if subtitles is None model gives an error .... how to infere without subtitles? #40

Open Mohand995 opened 1 month ago

rajendrac3 commented 4 weeks ago

In generate_prediction() function in minigpt4_video_inference.py file, instead of if gen_subtitles change it to if not gen_subtitles: This will download openai's whisper model and generate subtitles.

amansahu278 commented 1 week ago

You could also pass subtitles as an empty list to match_frames_and_subtitles, inside the prepare_input method, in minigpt4_video_inference.py Make sure to comment out the call to extract_subtitles since that fails for subtitle_path=None The above changes would reduce the model to working only with the image frames.