def get_params(self):
    """
    Provides access to the model's parameters.
    Works arounds the non-availability of graph collections in
                    eager mode.
    :return: A list of all Variables defining the model parameters.
    """
    assert tf.executing_eagerly()
    out = []

    # Collecting params from each layer.
    for layer_name in self.layers:
      out += self.get_layer_params(layer_name)
    return out