From c0e2db3bd4f4297de44d75ac660b860c0da1933d Mon Sep 17 00:00:00 2001 From: jerad fields Date: Wed, 5 Feb 2025 14:44:25 -0600 Subject: [PATCH] ensure correct dtype on windows (#1452) --- .changeset/hungry-bees-tie.md | 5 +++++ .../livekit/plugins/turn_detector/eou.py | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 .changeset/hungry-bees-tie.md diff --git a/.changeset/hungry-bees-tie.md b/.changeset/hungry-bees-tie.md new file mode 100644 index 000000000..1ccec4d54 --- /dev/null +++ b/.changeset/hungry-bees-tie.md @@ -0,0 +1,5 @@ +--- +"livekit-plugins-turn-detector": patch +--- + +fix incorrect dtype on windows diff --git a/livekit-plugins/livekit-plugins-turn-detector/livekit/plugins/turn_detector/eou.py b/livekit-plugins/livekit-plugins-turn-detector/livekit/plugins/turn_detector/eou.py index 67dd88d17..68af80666 100644 --- a/livekit-plugins/livekit-plugins-turn-detector/livekit/plugins/turn_detector/eou.py +++ b/livekit-plugins/livekit-plugins-turn-detector/livekit/plugins/turn_detector/eou.py @@ -102,7 +102,9 @@ def run(self, data: bytes) -> bytes | None: truncation=True, ) # Run inference - outputs = self._session.run(None, {"input_ids": inputs["input_ids"]}) + outputs = self._session.run( + None, {"input_ids": inputs["input_ids"].astype("int64")} + ) eou_probability = outputs[0][0] end_time = time.perf_counter()