Spaces:
Sleeping
Sleeping
Update app.py
Browse files43 unmodified lines4445464748495051525354555643 unmodified linespredicted_class = max(confidences, key=confidences.get)# === Custom output sesuai kondisi ===if predicted_class == "Open":custom_message = "kamu dalam keadaan tidak mengantuk"elif predicted_class == "Close":custom_message = "kamu dalam keadaan mengantuk"else:custom_message = "kondisi tidak terdeteksi"return custom_message, confidences43 unmodified lines44454647484950515253545556575843 unmodified linespredicted_class = max(confidences, key=confidences.get)# === Custom output sesuai kondisi ===custom_message = "" # INISIALISASI WAJIBlabel = predicted_class.lower()if label == "open":custom_message = "kamu dalam keadaan tidak mengantuk"elif label in ["close", "closed"]:custom_message = "kamu dalam keadaan mengantuk"else:custom_message = "kondisi tidak terdeteksi"return custom_message, confidences
app.py+8-6