Skip to content
Snippets Groups Projects
Commit fdb36e31 authored by zverkov's avatar zverkov
Browse files

check model location

parent e045996b
No related branches found
No related tags found
No related merge requests found
......@@ -42,7 +42,7 @@ class MistralAgent(object):
self.padding_side = "right"
self.model = AutoModelForCausalLM.from_pretrained("./agents/mistral_model/model",
quantization_config=bnb_config,
device_map=device_map)
device_map="auto")
self.model.config.use_cache = True # For faster generation
......@@ -76,6 +76,7 @@ class MistralAgent(object):
# self.sep_id = self.tokenizer.sep_token_id
self.device = 'cuda' if torch.cuda.is_available() else 'cpu'
print(self.device)
# self.model = self.model.to(self.device)
self.model.eval()
......
......@@ -11,3 +11,4 @@ scipy
sentencepiece
torch
tqdm
protobuf
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment