class_docstr: Hyperbolic attention model that combines reflections and rotations.
class_docstr_tok: ["Hyperbolic","attention","model","that","combines","reflections","and","rotations","."]
code: def __init__(self, sizes, args):
      super(AttH, self).__init__(sizes, args)
      self.sim = "dist"
  
      # reflection
      self.ref = tf.keras.layers.Embedding(
          input_dim=sizes[1],
          output_dim=self.rank,
          embeddings_initializer=self.initializer,
          embeddings_regularizer=self.rel_regularizer,
          name="reflection_weights",
      )
  
      # rotation
      self.rot = tf.keras.layers.Embedding(
          input_dim=sizes[1],
          output_dim=self.rank,
          embeddings_initializer=self.initializer,
          embeddings_regularizer=self.rel_regularizer,
          name="rotation_weights",
      )
  
      # attention
      self.context_vec = tf.keras.layers.Embedding(
          input_dim=sizes[1],
          output_dim=self.rank,
          embeddings_initializer=self.initializer,
          embeddings_regularizer=self.rel_regularizer,
          name="context_embeddings",
      )
      self.scale = tf.keras.backend.ones(1) / np.sqrt(self.rank)
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  from kg_hyp_emb.models.base import KGModel
  from kg_hyp_emb.utils import euclidean
  from kg_hyp_emb.utils import hyperbolic
  import numpy
  import tensorflow
label_desc: Use image node_id 1 to create a new AttH object from inherited base classes: BaseH with example: obj = AttH(sizes, args)