Download code/text_classifier/temp.py from shahidul034/readCtrl_lambda: direct link, hf CLI and curl.
- Browser
- Download file 423 Bytes
-
https://huggingface.co/shahidul034/readCtrl_lambda/resolve/main/code/text_classifier/temp.py
- Command line
-
hf download hf://shahidul034/readCtrl_lambda/code/text_classifier/temp.py
-
curl -L -o temp.py https://huggingface.co/shahidul034/readCtrl_lambda/resolve/main/code/text_classifier/temp.py
423 Bytes
| import os | |
| os.environ["CUDA_DEVICE_ORDER"]="PCI_BUS_ID" | |
| os.environ["CUDA_VISIBLE_DEVICES"] = "1" | |
| from transformers import AutoTokenizer, AutoModelForCausalLM | |
| name = "google/gemma-3-4b-it" # or your Gemma 3 variant | |
| tokenizer = AutoTokenizer.from_pretrained(name) | |
| model = AutoModelForCausalLM.from_pretrained(name) | |
| print(tokenizer.eos_token, tokenizer.eos_token_id) | |
| print(model.config.eos_token, model.config.eos_token_id) | |