Cannot import model from transformers library

#1
by fultoncannon - opened

has anyone successfully imported this model and used it in a notebook? I even downloaded all the files manually, but can't seem to figure out how to import them from the folder that I downloaded them to since there are multiple model files

import torch

from accelerate import Accelerator
from datasets import load_dataset
from transformers import AutoTokenizer, AutoModelForCausalLM
from torch.utils.data import Dataset, DataLoader

accelerator = Accelerator()

model_name = "HuggingFaceH4/mistral-7b-grok"

tokenizer = AutoTokenizer.from_pretrained(model_name)
tokenizer.pad_token = tokenizer.eos_token

model = AutoModelForCausalLM.from_pretrained(model_name)
....

Sign up or log in to comment