code: def _set_speaker_input(self, aux_input: Dict):
      d_vectors = aux_input.get("d_vectors", None)
      speaker_ids = aux_input.get("speaker_ids", None)
  
      if d_vectors is not None and speaker_ids is not None:
          raise ValueError(
              "[!] Cannot use d-vectors and speaker-ids together."
          )
  
      if speaker_ids is not None and not hasattr(self, "emb_g"):
          raise ValueError(
              "[!] Cannot use speaker-ids without enabling speaker embedding."
          )
  
      g = speaker_ids if speaker_ids is not None else d_vectors
      return g
  
imports: from typing import Callable, Dict, Tuple
  import torch
  import torch.nn.functional
  from coqpit import Coqpit
  from torch import nn
  from TTS.tts.layers.delightful_tts.conformer import Conformer
  from TTS.tts.layers.delightful_tts.encoders import PhonemeLevelProsodyEncoder, UtteranceLevelProsodyEncoder, get_mask_from_lengths
  from TTS.tts.layers.delightful_tts.energy_adaptor import EnergyAdaptor
  from TTS.tts.layers.delightful_tts.networks import EmbeddingPadded, positional_encoding
  from TTS.tts.layers.delightful_tts.phoneme_prosody_predictor import PhonemeProsodyPredictor
  from TTS.tts.layers.delightful_tts.pitch_adaptor import PitchAdaptor
  from TTS.tts.layers.delightful_tts.variance_predictor import VariancePredictor
  from TTS.tts.layers.generic.aligner import AlignmentNetwork
  from TTS.tts.utils.helpers import generate_path, maximum_path, sequence_mask
label_desc: Use image node_id 5 for calling the AcousticModel obj's underlying member method code with example usage: obj._set_speaker_input(aux_input) and returns: g