Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
theomonnom committed Feb 1, 2024
1 parent a92851b commit ea594e7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
5 changes: 3 additions & 2 deletions examples/face_landmark/face_landmark.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,14 +111,15 @@ async def frame_loop(video_stream: rtc.VideoStream) -> None:
buffer = frame_event.frame
buffer = buffer.convert(rtc.VideoBufferType.RGBA)


arr = np.frombuffer(buffer.data, dtype=np.uint8)
arr = arr.reshape((buffer.height, buffer.width, 4))
arr = cv2.cvtColor(arr, cv2.COLOR_RGBA2RGB)

mp_image = mp.Image(image_format=mp.ImageFormat.SRGB, data=arr)

detection_result = landmarker.detect_for_video(mp_image, frame_event.timestamp_us)
detection_result = landmarker.detect_for_video(
mp_image, frame_event.timestamp_us
)

draw_landmarks_on_image(arr, detection_result)

Expand Down
1 change: 0 additions & 1 deletion livekit-rtc/livekit/rtc/audio_stream.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ class AudioFrameEvent:
frame: AudioFrame



class AudioStream:
"""AudioStream is a stream of audio frames received from a RemoteTrack."""

Expand Down

0 comments on commit ea594e7

Please sign in to comment.