Spaces:
Runtime error
Runtime error
NORLIE JHON MALAGDAO
commited on
Update app.py
Browse files
app.py
CHANGED
|
@@ -66,7 +66,22 @@ def seed_everything(seed=42):
|
|
| 66 |
|
| 67 |
seed_everything()
|
| 68 |
|
| 69 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 70 |
|
| 71 |
# Import series of helper functions for our notebook
|
| 72 |
from helper_functions import create_tensorboard_callback, plot_loss_curves, unzip_data, compare_historys, walk_through_dir, pred_and_plot
|
|
|
|
| 66 |
|
| 67 |
seed_everything()
|
| 68 |
|
| 69 |
+
import requests
|
| 70 |
+
|
| 71 |
+
# URL of the file
|
| 72 |
+
url = "https://raw.githubusercontent.com/mrdbourke/tensorflow-deep-learning/main/extras/helper_functions.py"
|
| 73 |
+
|
| 74 |
+
# Send a GET request to the URL
|
| 75 |
+
response = requests.get(url)
|
| 76 |
+
|
| 77 |
+
# Check if the request was successful
|
| 78 |
+
if response.status_code == 200:
|
| 79 |
+
# Save the content to a file
|
| 80 |
+
with open("helper_functions.py", "wb") as f:
|
| 81 |
+
f.write(response.content)
|
| 82 |
+
print("File downloaded successfully.")
|
| 83 |
+
else:
|
| 84 |
+
print("Failed to download the file.")
|
| 85 |
|
| 86 |
# Import series of helper functions for our notebook
|
| 87 |
from helper_functions import create_tensorboard_callback, plot_loss_curves, unzip_data, compare_historys, walk_through_dir, pred_and_plot
|