class_docstr: Standard Variational Autoencoders (VAE) for Collaborative Filtering implementation.
docstr: Build and compile model.
code: def _create_model(self):
      """Build and compile model."""
      # Encoding
      self.x = Input(shape=(self.original_dim,))
      self.dropout_encoder = Dropout(self.drop_encoder)(self.x)
      self.h = Dense(self.intermediate_dim, activation="tanh")(
          self.dropout_encoder
      )
      self.z_mean = Dense(self.latent_dim)(self.h)
      self.z_log_var = Dense(self.latent_dim)(self.h)
  
      # Sampling
      self.z = Lambda(
          self._take_sample, output_shape=(self.latent_dim,)
      )([self.z_mean, self.z_log_var])
  
      # Decoding
      self.h_decoder = Dense(self.intermediate_dim, activation="tanh")
      self.dropout_decoder = Dropout(self.drop_decoder)
      self.x_bar = Dense(self.original_dim, activation="softmax")
      self.h_decoded = self.h_decoder(self.z)
      self.h_decoded_ = self.dropout_decoder(self.h_decoded)
      self.x_decoded = self.x_bar(self.h_decoded_)
  
      # Training
      self.model = Model(self.x, self.x_decoded)
      self.model.compile(
          optimizer=tf.keras.optimizers.legacy.Adam(
              learning_rate=0.001
          ),
          loss=self._get_vae_loss,
      )
  
imports: import numpy
  import matplotlib.pyplot
  import seaborn
  import tensorflow
  from tensorflow.keras.layers import *
  from tensorflow.keras.models import Model
  from tensorflow.keras.losses import binary_crossentropy
  from tensorflow.keras import backend
  from tensorflow.keras.callbacks import ReduceLROnPlateau, Callback
  from recommenders.evaluation.python_evaluation import ndcg_at_k
label_desc: Use image node_id 2 for calling the StandardVAE obj's underlying member method code with example usage: obj._create_model() without return types