Spaces:
Runtime error
Runtime error
refactor: title
Browse files
app.py
CHANGED
@@ -8,8 +8,8 @@ processor = CLIPProcessor.from_pretrained("tokenizer")
|
|
8 |
|
9 |
def generate_answer(image):
|
10 |
|
11 |
-
|
12 |
-
|
13 |
inputs = processor(text=classes, images=image, return_tensors="pt", padding=True)
|
14 |
outputs = model(**inputs)
|
15 |
logits_per_image = outputs.logits_per_image
|
|
|
8 |
|
9 |
def generate_answer(image):
|
10 |
|
11 |
+
classes = ['A picture of a room filled with abundant natural light with a lot or few windows regardless of whether it is night, without objects that prevent the light from passing through.','a picture of room in the dark','A picture of a living room with Artificial lights like lamps or headlamps']
|
12 |
+
clas = ['natural_light','no_light', 'artificial_light']
|
13 |
inputs = processor(text=classes, images=image, return_tensors="pt", padding=True)
|
14 |
outputs = model(**inputs)
|
15 |
logits_per_image = outputs.logits_per_image
|