FlowRead / test_load.py
jobbler's picture
Fix tokenizer extra_special_tokens crash and stabilize transformers
bd01d05
raw
history blame contribute delete
361 Bytes
from transformers import AutoTokenizer, AutoModelForCausalLM
try:
hf_model_id = "unsloth/gemma-4-E2B"
print("Loading tokenizer...")
tokenizer = AutoTokenizer.from_pretrained(hf_model_id)
print("Loading model...")
model = AutoModelForCausalLM.from_pretrained(hf_model_id)
except Exception as e:
import traceback
traceback.print_exc()