Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -24,7 +24,7 @@ transformers.logging.set_verbosity_error()
|
|
24 |
|
25 |
|
26 |
|
27 |
-
def image_to_query(
|
28 |
"""
|
29 |
input: Image
|
30 |
|
@@ -32,7 +32,7 @@ def image_to_query(image):
|
|
32 |
|
33 |
output: Query for the LLM
|
34 |
"""
|
35 |
-
image = Image.open(
|
36 |
classifier = pipeline("image-classification", model = "nprasad24/bean_classifier")
|
37 |
|
38 |
scores = classifier(image)
|
|
|
24 |
|
25 |
|
26 |
|
27 |
+
def image_to_query(imagefile):
|
28 |
"""
|
29 |
input: Image
|
30 |
|
|
|
32 |
|
33 |
output: Query for the LLM
|
34 |
"""
|
35 |
+
image = Image.open(imagefile)
|
36 |
classifier = pipeline("image-classification", model = "nprasad24/bean_classifier")
|
37 |
|
38 |
scores = classifier(image)
|