Spaces:
Runtime error
Runtime error
Mohamad-Jaallouk
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -21,7 +21,6 @@ class ModelProcessor:
|
|
21 |
|
22 |
|
23 |
@torch.inference_mode()
|
24 |
-
@spaces.GPU
|
25 |
def process_data_and_compute_statistics(self, prompt):
|
26 |
# Tokenize the prompt and move to the device
|
27 |
tokens = self.tokenizer(
|
@@ -67,7 +66,7 @@ class ModelProcessor:
|
|
67 |
|
68 |
processor = ModelProcessor()
|
69 |
|
70 |
-
|
71 |
def detect(prompt):
|
72 |
prediction = processor.process_data_and_compute_statistics(prompt)
|
73 |
if prediction == 1:
|
|
|
21 |
|
22 |
|
23 |
@torch.inference_mode()
|
|
|
24 |
def process_data_and_compute_statistics(self, prompt):
|
25 |
# Tokenize the prompt and move to the device
|
26 |
tokens = self.tokenizer(
|
|
|
66 |
|
67 |
processor = ModelProcessor()
|
68 |
|
69 |
+
@spaces.GPU
|
70 |
def detect(prompt):
|
71 |
prediction = processor.process_data_and_compute_statistics(prompt)
|
72 |
if prediction == 1:
|