mirror of
https://github.com/Vision-CAIR/MiniGPT-4.git
synced 2025-04-04 18:10:47 +00:00
Update minigpt_base.py
This commit is contained in:
parent
f91ef5f724
commit
9d8335c1f5
@ -9,7 +9,7 @@ from minigpt4.common.registry import registry
|
||||
from minigpt4.models.base_model import BaseModel
|
||||
from transformers import StoppingCriteria, StoppingCriteriaList
|
||||
|
||||
|
||||
from minigpt4.conversation.conversation import StoppingCriteriaSub
|
||||
|
||||
class MiniGPTBase(BaseModel):
|
||||
"""
|
||||
@ -399,4 +399,4 @@ class MiniGPTBase(BaseModel):
|
||||
for i in range(all_losses.shape[0]):
|
||||
all_losses[i, num_cand[i]:] = 9999
|
||||
output_class_ranks = torch.argsort(all_losses, dim=-1)
|
||||
return output_class_ranks.tolist()
|
||||
return output_class_ranks.tolist()
|
||||
|
Loading…
Reference in New Issue
Block a user