RemiFabre commited on
Commit
ba448b6
·
1 Parent(s): c3a844c
src/reachy_mini_conversation_app/console.py CHANGED
@@ -8,8 +8,8 @@ import asyncio
8
  import logging
9
  from typing import List
10
 
11
- from librosa import resample
12
  from fastrtc import AdditionalOutputs, audio_to_int16, audio_to_float32
 
13
 
14
  from reachy_mini import ReachyMini
15
  from reachy_mini_conversation_app.openai_realtime import OpenaiRealtimeHandler
@@ -30,7 +30,7 @@ class LocalStream:
30
  # Allow the handler to flush the player queue when appropriate.
31
  self.handler._clear_queue = self.clear_audio_queue
32
 
33
- # Hack to avoid the first lenghty call to resample at runtime.
34
  # This is likely caused by cache initialization overhead.
35
  import numpy as np
36
  resample(np.array([0.0]), orig_sr=1, target_sr=1)
 
8
  import logging
9
  from typing import List
10
 
 
11
  from fastrtc import AdditionalOutputs, audio_to_int16, audio_to_float32
12
+ from librosa import resample
13
 
14
  from reachy_mini import ReachyMini
15
  from reachy_mini_conversation_app.openai_realtime import OpenaiRealtimeHandler
 
30
  # Allow the handler to flush the player queue when appropriate.
31
  self.handler._clear_queue = self.clear_audio_queue
32
 
33
+ # Hack to avoid the first lenghty call to resample at runtime.
34
  # This is likely caused by cache initialization overhead.
35
  import numpy as np
36
  resample(np.array([0.0]), orig_sr=1, target_sr=1)