Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -14,6 +14,7 @@ import yaml
|
|
14 |
from gradio_logsview.logsview import Log, LogsView, LogsViewRunner
|
15 |
from mergekit.config import MergeConfiguration
|
16 |
from clean_community_org import garbage_collect_empty_models
|
|
|
17 |
|
18 |
has_gpu = torch.cuda.is_available()
|
19 |
|
@@ -158,7 +159,7 @@ def garbage_collect():
|
|
158 |
print(f"Error running garbage collection: {e}")
|
159 |
|
160 |
|
161 |
-
def schedule_garbage_collection(interval_seconds=
|
162 |
while True:
|
163 |
time.sleep(interval_seconds)
|
164 |
garbage_collect()
|
|
|
14 |
from gradio_logsview.logsview import Log, LogsView, LogsViewRunner
|
15 |
from mergekit.config import MergeConfiguration
|
16 |
from clean_community_org import garbage_collect_empty_models
|
17 |
+
import spaces
|
18 |
|
19 |
has_gpu = torch.cuda.is_available()
|
20 |
|
|
|
159 |
print(f"Error running garbage collection: {e}")
|
160 |
|
161 |
|
162 |
+
def schedule_garbage_collection(interval_seconds=0):
|
163 |
while True:
|
164 |
time.sleep(interval_seconds)
|
165 |
garbage_collect()
|