Skip to content

Commit

Permalink
Fix: Float to Int
Browse files Browse the repository at this point in the history
  • Loading branch information
suk-6 committed Sep 21, 2023
1 parent 6afde69 commit 7a742be
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ async def serverHandler(websocket, path):
bboxRatio = (bboxArea / imageArea) * 100 # 퍼센트로 표현

bboxCoords['ratio'] = bboxRatio
bboxCoords['power'] = 1 + (bboxRatio / 100) * (255 - 1) # 진동 세기
bboxCoords['power'] = int(1 + (bboxRatio / 100) * (255 - 1)) # 진동 세기

annos.append(bboxCoords)

Expand Down

0 comments on commit 7a742be

Please sign in to comment.