Update app.py
Browse files
app.py
CHANGED
@@ -96,7 +96,7 @@ def evaluate(
|
|
96 |
subset: str,
|
97 |
samples: str,
|
98 |
pass_k: str="1,5,10",
|
99 |
-
parallel: int =
|
100 |
min_time_limit: float = 1,
|
101 |
max_as_limit: int = 30 * 1024,
|
102 |
max_data_limit: int = 30 * 1024,
|
@@ -105,7 +105,7 @@ def evaluate(
|
|
105 |
no_gt: bool = False,
|
106 |
):
|
107 |
pass_k = [int(k.strip()) for k in pass_k.split(',') if k.strip().isdigit()]
|
108 |
-
if parallel
|
109 |
n_workers = max(1, multiprocessing.cpu_count() // 2)
|
110 |
else:
|
111 |
n_workers = parallel
|
|
|
96 |
subset: str,
|
97 |
samples: str,
|
98 |
pass_k: str="1,5,10",
|
99 |
+
parallel: int = -1,
|
100 |
min_time_limit: float = 1,
|
101 |
max_as_limit: int = 30 * 1024,
|
102 |
max_data_limit: int = 30 * 1024,
|
|
|
105 |
no_gt: bool = False,
|
106 |
):
|
107 |
pass_k = [int(k.strip()) for k in pass_k.split(',') if k.strip().isdigit()]
|
108 |
+
if not parallel:
|
109 |
n_workers = max(1, multiprocessing.cpu_count() // 2)
|
110 |
else:
|
111 |
n_workers = parallel
|