fix
Browse files- modeling_phi4mm.py +1 -0
modeling_phi4mm.py
CHANGED
|
@@ -2100,6 +2100,7 @@ class Phi4MMForCausalLM(Phi4MMPreTrainedModel, GenerationMixin):
|
|
| 2100 |
output_hidden_states if output_hidden_states is not None else self.config.output_hidden_states
|
| 2101 |
)
|
| 2102 |
return_dict = return_dict if return_dict is not None else self.config.use_return_dict
|
|
|
|
| 2103 |
|
| 2104 |
if isinstance(input_mode, torch.Tensor):
|
| 2105 |
# len(input_mode) == num_beams in beam search, and all elements of input_mode should have the same value
|
|
|
|
| 2100 |
output_hidden_states if output_hidden_states is not None else self.config.output_hidden_states
|
| 2101 |
)
|
| 2102 |
return_dict = return_dict if return_dict is not None else self.config.use_return_dict
|
| 2103 |
+
num_logits_to_keep = num_logits_to_keep if num_logits_to_keep is not None else 0
|
| 2104 |
|
| 2105 |
if isinstance(input_mode, torch.Tensor):
|
| 2106 |
# len(input_mode) == num_beams in beam search, and all elements of input_mode should have the same value
|