class_docstr: Multi-head attention layer for queries independent from keys/values.
  
  Parameters
  ----------
  att_dim_in
      Attention dimension (number of hidden units)
  heads
      Number of attention heads
  att_dim_out
      Output dimension (number of output units)
  dropout
      Dropout rate on attention scores
class_docstr_tok: ["Multi-head","attention","layer","for","queries","independent","from","keys\/values",".","Parameters","--","--","--","--","--","att_dim_in","Attention","dimension","(","number","of","hidden","units",")","heads","Number","of","attention","heads","att_dim_out","Output","dimension","(","number","of","output","units",")","dropout","Dropout","rate","on","attention","scores"]
code: def __init__(
      self,
      att_dim_in: int = 32,
      heads: int = 8,
      att_dim_out: int = 32,
      dropout: float = 0.0,
      **kwargs,
  ) -> None:
      super().__init__(
          att_dim_in, heads, att_dim_out, dropout, **kwargs
      )
  
      with self.name_scope():
          self.dense_pre_att_q = mx.gluon.nn.Dense(
              units=self.att_dim_in, flatten=False
          )
          self.dense_pre_att_k = mx.gluon.nn.Dense(
              units=self.att_dim_in, flatten=False
          )
          self.dense_pre_att_v = mx.gluon.nn.Dense(
              units=self.att_dim_in, flatten=False
          )
  
imports: from typing import Dict, Optional, Tuple
  import mxnet
  from mxnet.gluon import HybridBlock
  from gluonts.mx import Tensor
label_desc: Use image node_id 1 to create a new MultiHeadAttention object from inherited base classes: MultiHeadAttentionBase with example: obj = MultiHeadAttention(att_dim_in, heads, att_dim_out, dropout)