class_docstr: XiaoiceSing module for Singing Voice Synthesis.
  
  This is a module of XiaoiceSing. A high-quality singing voice synthesis system which
  employs an integrated network for spectrum, F0 and duration modeling. It follows the
  main architecture of FastSpeech while proposing some singing-specific design:
      1) Add features from musical score (e.g.note pitch and length)
      2) Add a residual connection in F0 prediction to attenuate off-key issues
      3) The duration of all the phonemes in a musical note is accumulated to
      calculate the syllable duration loss for rhythm enhancement (syllable loss)
  .. _`XiaoiceSing: A High-Quality and Integrated Singing Voice Synthesis System`:
      https://arxiv.org/pdf/2006.06261.pdf
code: def _reset_parameters(
      self, init_type: str, init_enc_alpha: float, init_dec_alpha: float
  ):
      # initialize parameters
      if init_type != "pytorch":
          initialize(self, init_type)
  
      # initialize alpha in scaled positional encoding
      if self.encoder_type == "transformer" and self.use_scaled_pos_enc:
          self.encoder.embed[-1].alpha.data = torch.tensor(
              init_enc_alpha
          )
      if self.decoder_type == "transformer" and self.use_scaled_pos_enc:
          self.decoder.embed[-1].alpha.data = torch.tensor(
              init_dec_alpha
          )
  
imports: import logging
  from typing import Dict, Optional, Tuple
  import torch
  import torch.nn.functional
  from typeguard import check_argument_types
  from espnet2.svs.abs_svs import AbsSVS
  from espnet2.svs.xiaoice.loss import XiaoiceSing2Loss
  from espnet2.torch_utils.device_funcs import force_gatherable
  from espnet2.torch_utils.initialize import initialize
  from espnet.nets.pytorch_backend.conformer.encoder import Encoder
  from espnet.nets.pytorch_backend.e2e_tts_fastspeech import FeedForwardTransformerLoss
  from espnet.nets.pytorch_backend.fastspeech.duration_predictor import DurationPredictor
  from espnet.nets.pytorch_backend.fastspeech.length_regulator import LengthRegulator
  from espnet.nets.pytorch_backend.nets_utils import make_non_pad_mask, make_pad_mask
  from espnet.nets.pytorch_backend.tacotron2.decoder import Postnet
  from espnet.nets.pytorch_backend.transformer.embedding import PositionalEncoding, ScaledPositionalEncoding
  from espnet.nets.pytorch_backend.transformer.encoder import Encoder
label_desc: Use image node_id 6 for calling the XiaoiceSing obj's underlying member method code with example usage: obj._reset_parameters(init_type, init_enc_alpha, init_dec_alpha) without return types