Spaces:
Sleeping
Sleeping
Hjgugugjhuhjggg
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -63,7 +63,7 @@ class S3ModelLoader:
|
|
63 |
except EnvironmentError:
|
64 |
logging.info(f"Model {model_name} not found in S3. Downloading...")
|
65 |
try:
|
66 |
-
with tqdm(unit="B", unit_scale=True, desc=f"Downloading {model_name}") as t:
|
67 |
model = AutoModelForCausalLM.from_pretrained(model_name, token=HUGGINGFACE_HUB_TOKEN, _tqdm=t)
|
68 |
tokenizer = AutoTokenizer.from_pretrained(model_name, token=HUGGINGFACE_HUB_TOKEN)
|
69 |
logging.info(f"Downloaded {model_name} successfully.")
|
|
|
63 |
except EnvironmentError:
|
64 |
logging.info(f"Model {model_name} not found in S3. Downloading...")
|
65 |
try:
|
66 |
+
with tqdm(unit="B", unit_scale=True, desc=f"Downloading {model_name}", disable=False) as t:
|
67 |
model = AutoModelForCausalLM.from_pretrained(model_name, token=HUGGINGFACE_HUB_TOKEN, _tqdm=t)
|
68 |
tokenizer = AutoTokenizer.from_pretrained(model_name, token=HUGGINGFACE_HUB_TOKEN)
|
69 |
logging.info(f"Downloaded {model_name} successfully.")
|