@@ -991,43 +991,43 @@ def test_apply_chat_template_video_frame_sampling(self):
991991 self .assertEqual (len (out_dict_with_video [self .videos_input_name ]), 1 )
992992 self .assertEqual (len (out_dict_with_video [self .videos_input_name ][0 ]), num_frames )
993993
994- # Load with `video_fps ` arg
995- video_fps = 1
994+ # Load with `fps ` arg
995+ fps = 1
996996 out_dict_with_video = processor .apply_chat_template (
997997 messages ,
998998 add_generation_prompt = True ,
999999 tokenize = True ,
10001000 return_dict = True ,
1001- video_fps = video_fps ,
1001+ fps = fps ,
10021002 return_tensors = "pt" ,
10031003 )
10041004 self .assertTrue (self .videos_input_name in out_dict_with_video )
10051005 self .assertEqual (len (out_dict_with_video [self .videos_input_name ]), 1 )
1006- self .assertEqual (len (out_dict_with_video [self .videos_input_name ][0 ]), video_fps * 10 )
1006+ self .assertEqual (len (out_dict_with_video [self .videos_input_name ][0 ]), fps * 10 )
10071007
10081008 # Whan `do_sample_frames=False` no sampling is done and whole video is loaded, even if number of frames is passed
1009- video_fps = 1
1009+ fps = 1
10101010 out_dict_with_video = processor .apply_chat_template (
10111011 messages ,
10121012 add_generation_prompt = True ,
10131013 tokenize = True ,
10141014 return_dict = True ,
10151015 do_sample_frames = False ,
1016- video_fps = video_fps ,
1016+ fps = fps ,
10171017 return_tensors = "pt" ,
10181018 )
10191019 self .assertTrue (self .videos_input_name in out_dict_with_video )
10201020 self .assertEqual (len (out_dict_with_video [self .videos_input_name ]), 1 )
10211021 self .assertEqual (len (out_dict_with_video [self .videos_input_name ][0 ]), 300 )
10221022
1023- # Load with `video_fps ` and `num_frames` args, should raise an error
1023+ # Load with `fps ` and `num_frames` args, should raise an error
10241024 with self .assertRaises (ValueError ):
10251025 out_dict_with_video = processor .apply_chat_template (
10261026 messages ,
10271027 add_generation_prompt = True ,
10281028 tokenize = True ,
10291029 return_dict = True ,
1030- video_fps = video_fps ,
1030+ fps = fps ,
10311031 num_frames = num_frames ,
10321032 )
10331033
0 commit comments