code: def read_frames(
      wav_file, frame_duration_ms=30, yield_remainder=False
  ):
      audio_format = read_audio_format_from_wav_file(wav_file)
      frame_size = int(audio_format.rate * (frame_duration_ms / 1000.0))
      while True:
          try:
              data = wav_file.readframes(frame_size)
              if (
                  not yield_remainder
                  and get_pcm_duration(len(data), audio_format) * 1000
                  < frame_duration_ms
              ):
                  break
              yield data
          except EOFError:
              break
  
imports: import collections
  import ctypes
  import io
  import math
  import numpy
  import os
  import pyogg
  import tempfile
  import wave
  from .helpers import LimitingPool
  from collections import namedtuple
  from .io import open_remote, remove_remote, copy_remote, is_remote_path
label_desc: Use image node_id 9 for calling a global function with example usage: read_frames(wav_file, frame_duration_ms, yield_remainder) without return types