Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -194,7 +194,15 @@ if (runModel=='1'):
|
|
194 |
model.save_pretrained(model_path)
|
195 |
tokenizer.save_pretrained(tokenizer_path)
|
196 |
|
|
|
|
|
|
|
|
|
197 |
|
|
|
|
|
|
|
|
|
198 |
|
199 |
else:
|
200 |
print('Load Pre-trained')
|
|
|
194 |
model.save_pretrained(model_path)
|
195 |
tokenizer.save_pretrained(tokenizer_path)
|
196 |
|
197 |
+
# Check for specific files in the model directory
|
198 |
+
model_files = os.listdir(model_path)
|
199 |
+
model_files = [file for file in model_files if file.endswith(('pytorch_model.bin', 'config.json'))]
|
200 |
+
print("Specific files in model directory:", model_files)
|
201 |
|
202 |
+
# Check for specific files in the tokenizer directory
|
203 |
+
tokenizer_files = os.listdir(tokenizer_path)
|
204 |
+
tokenizer_files = [file for file in tokenizer_files if file.endswith(('tokenizer.json', 'vocab.txt'))]
|
205 |
+
print("Specific files in tokenizer directory:", tokenizer_files)
|
206 |
|
207 |
else:
|
208 |
print('Load Pre-trained')
|