Spaces:
Paused
Paused
testing2
Browse files
app.py
CHANGED
|
@@ -21,9 +21,9 @@ MAX_INPUT_TOKEN_LENGTH = 4096
|
|
| 21 |
if torch.cuda.is_available():
|
| 22 |
model_id = "codys12/MergeLlama-7b"
|
| 23 |
model = AutoModelForCausalLM.from_pretrained(model_id, torch_dtype=torch.float16, device_map=0, cache_dir="/data")
|
| 24 |
-
tokenizer = AutoTokenizer.from_pretrained(
|
| 25 |
-
tokenizer.pad_token = tokenizer.eos_token
|
| 26 |
-
tokenizer.padding_side = "right"
|
| 27 |
|
| 28 |
|
| 29 |
@spaces.GPU
|
|
|
|
| 21 |
if torch.cuda.is_available():
|
| 22 |
model_id = "codys12/MergeLlama-7b"
|
| 23 |
model = AutoModelForCausalLM.from_pretrained(model_id, torch_dtype=torch.float16, device_map=0, cache_dir="/data")
|
| 24 |
+
tokenizer = AutoTokenizer.from_pretrained("codellama/CodeLlama-7b-hf", trust_remote_code=True)
|
| 25 |
+
#tokenizer.pad_token = tokenizer.eos_token
|
| 26 |
+
#tokenizer.padding_side = "right"
|
| 27 |
|
| 28 |
|
| 29 |
@spaces.GPU
|