Added client with interface to have the possibility to react to emotions

This commit is contained in:
DJE98
2023-09-30 15:56:17 +02:00
parent 7a68a8cb74
commit 60b8fe71db
3 changed files with 66 additions and 0 deletions

17
hackathon/own_robot.py Normal file
View File

@@ -0,0 +1,17 @@
from robot import Robot
import cv2 as cv
from cli import print_emotions
import os
class OwnRobot(Robot):
count = 0
def update(self, image, emotions):
self.count += 1
if self.count > 10:
self.count = 1
print_emotions(emotions)
cv.imwrite(os.sep.join(["img", f"ownRobot{self.count}.png"]), image)