Update app.py
Browse files
app.py
CHANGED
@@ -12,6 +12,9 @@ from transformers import (
|
|
12 |
LlamaTokenizer,
|
13 |
)
|
14 |
|
|
|
|
|
|
|
15 |
MAX_MAX_NEW_TOKENS = 1024
|
16 |
DEFAULT_MAX_NEW_TOKENS = 50
|
17 |
MAX_INPUT_TOKEN_LENGTH = 512
|
|
|
12 |
LlamaTokenizer,
|
13 |
)
|
14 |
|
15 |
+
|
16 |
+
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
17 |
+
|
18 |
MAX_MAX_NEW_TOKENS = 1024
|
19 |
DEFAULT_MAX_NEW_TOKENS = 50
|
20 |
MAX_INPUT_TOKEN_LENGTH = 512
|