From 9d8335c1f5c3285e1aa93589e023f65f1fde2340 Mon Sep 17 00:00:00 2001 From: Xiang Li <44761952+lx709@users.noreply.github.com> Date: Fri, 27 Oct 2023 14:11:11 +0300 Subject: [PATCH] Update minigpt_base.py --- minigpt4/models/minigpt_base.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/minigpt4/models/minigpt_base.py b/minigpt4/models/minigpt_base.py index cd051ec..22c4251 100644 --- a/minigpt4/models/minigpt_base.py +++ b/minigpt4/models/minigpt_base.py @@ -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() \ No newline at end of file + return output_class_ranks.tolist()