Spaces:
Running
on
Zero
Running
on
Zero
Lord-Raven
commited on
Commit
·
573c10d
1
Parent(s):
aef28a9
Messing with fastAPI.
Browse files
app.py
CHANGED
@@ -52,7 +52,7 @@ def classify(data_string, request: gradio.Request):
|
|
52 |
# else:
|
53 |
start_time = time.time()
|
54 |
result = {}
|
55 |
-
if (
|
56 |
result = zero_shot_classification_cpu(data)
|
57 |
else:
|
58 |
result = zero_shot_classification_gpu(data)
|
|
|
52 |
# else:
|
53 |
start_time = time.time()
|
54 |
result = {}
|
55 |
+
if ('cpu' in data):
|
56 |
result = zero_shot_classification_cpu(data)
|
57 |
else:
|
58 |
result = zero_shot_classification_gpu(data)
|