Spaces:
Runtime error
Runtime error
Ariel
commited on
Commit
β’
006608e
1
Parent(s):
d972dd4
update phrases
Browse files- SolarPanelDetector.py +9 -10
SolarPanelDetector.py
CHANGED
@@ -1,7 +1,6 @@
|
|
1 |
from ultralytics import YOLO
|
2 |
from PIL import Image
|
3 |
import requests
|
4 |
-
import os
|
5 |
import random
|
6 |
|
7 |
model = YOLO('detector.pt')
|
@@ -93,17 +92,17 @@ def solar_panel_predict(image, conf=0.45):
|
|
93 |
Tuple of (annotated image, prediction message)
|
94 |
"""
|
95 |
negative_setences = [
|
96 |
-
"No solar panels yet
|
97 |
-
"It's lonely up here without solar panels
|
98 |
-
"Your roof could be a superhero in disguise
|
99 |
-
"Clear skies, empty roof
|
100 |
-
"No panels detected β but don't worry
|
101 |
|
102 |
positive_sentences = [
|
103 |
-
"Solar panels detected: You're not just saving money
|
104 |
-
"Roof status: Sunny side up
|
105 |
-
"You've got solar power
|
106 |
-
"Green alert: Your roof is now a climate hero's cape
|
107 |
"Solar panels spotted: Your roof is now officially a member of the Renewable Energy Rockstars Club! βπ±"]
|
108 |
|
109 |
results = model(image, stream=True, conf=conf)
|
|
|
1 |
from ultralytics import YOLO
|
2 |
from PIL import Image
|
3 |
import requests
|
|
|
4 |
import random
|
5 |
|
6 |
model = YOLO('detector.pt')
|
|
|
92 |
Tuple of (annotated image, prediction message)
|
93 |
"""
|
94 |
negative_setences = [
|
95 |
+
"No solar panels yet?\nYour roof is a blank canvas waiting for a green masterpiece! π¨π±",
|
96 |
+
"It's lonely up here without solar panels.\nImagine the sun-powered parties you're missing! ππ",
|
97 |
+
"Your roof could be a superhero in disguise.\nJust needs its solar cape! π¦ΈββοΈβοΈ",
|
98 |
+
"Clear skies, empty roof.\nIt's the perfect opportunity to harness the sun! π€οΈπ",
|
99 |
+
"No panels detected β but don't worry,\nit's never too late to join the solar revolution and be a ray of hope! ππ‘"]
|
100 |
|
101 |
positive_sentences = [
|
102 |
+
"Solar panels detected: You're not just saving money,\nyou're also charging up Mother Earth's good vibes! ππ",
|
103 |
+
"Roof status: Sunny side up!\nYour panels are turning rays into awesome days! βοΈπ",
|
104 |
+
"You've got solar power!\nNow your roof is cooler than a polar bear in sunglasses. π»ββοΈπΆοΈ",
|
105 |
+
"Green alert: Your roof is now a climate hero's cape!\nSolar panels are saving the day, one ray at a time. π¦ΈββοΈπ",
|
106 |
"Solar panels spotted: Your roof is now officially a member of the Renewable Energy Rockstars Club! βπ±"]
|
107 |
|
108 |
results = model(image, stream=True, conf=conf)
|