code: def get_voices(
      extra_voice_dirs: List[str] = [],
  ):  # pylint: disable=dangerous-default-value
      dirs = extra_voice_dirs
      voices: Dict[str, List[str]] = {}
      for d in dirs:
          subs = os.listdir(d)
          for sub in subs:
              subj = os.path.join(d, sub)
              if os.path.isdir(subj):
                  voices[sub] = list(glob(f"{subj}/*.npz"))
                  # fetch audio files if no npz files are found
                  if len(voices[sub]) == 0:
                      voices[sub] = list(glob(f"{subj}/*.wav")) + list(
                          glob(f"{subj}/*.mp3")
                      )
      return voices
  
imports: import logging
  import os
  import re
  from glob import glob
  from typing import Dict, List
  import librosa
  import numpy
  import torch
  import torchaudio
  import tqdm
  from encodec.utils import convert_audio
  from scipy.special import softmax
  from torch.nn import functional
  from TTS.tts.layers.bark.hubert.hubert_manager import HubertManager
  from TTS.tts.layers.bark.hubert.kmeans_hubert import CustomHubert
  from TTS.tts.layers.bark.hubert.tokenizer import HubertTokenizer
  from TTS.tts.layers.bark.load_model import clear_cuda_cache, inference_mode
label_desc: Use image node_id 4 for calling a global function with example usage: get_voices(extra_voice_dirs) and returns: voices