class_docstr: Encoder architecture.
class_docstr_tok: ["Encoder","architecture","."]
docstr: Instantiate model.
  
  Args:
    name: Name of the layer.
    num_down: How many downsampling layers to use.
    num_filters_base: Num filters to base multiplier on.
    num_filters_bottleneck: Num filters to output for bottleneck (latent).
docstr_tok: ["Instantiate","model",".","Args",":","name",":","Name","of","the","layer",".","num_down",":","How","many","downsampling","layers","to","use",".","num_filters_base",":","Num","filters","to","base","multiplier","on",".","num_filters_bottleneck",":","Num","filters","to","output","for","bottleneck","(","latent",")","."]
code: def __init__(
      self,
      name="Encoder",
      num_down=4,
      num_filters_base=60,
      num_filters_bottleneck=220,
  ):
      """Instantiate model.
  
      Args:
        name: Name of the layer.
        num_down: How many downsampling layers to use.
        num_filters_base: Num filters to base multiplier on.
        num_filters_bottleneck: Num filters to output for bottleneck (latent).
      """
      self._num_down = num_down
  
      model = [
          tf.keras.layers.Conv2D(
              filters=num_filters_base, kernel_size=7, padding="same"
          ),
          ChannelNorm(),
          tf.keras.layers.ReLU(),
      ]
  
      for i in range(num_down):
          model.extend(
              [
                  tf.keras.layers.Conv2D(
                      filters=num_filters_base * 2 ** (i + 1),
                      kernel_size=3,
                      padding="same",
                      strides=2,
                  ),
                  ChannelNorm(),
                  tf.keras.layers.ReLU(),
              ]
          )
  
      model.append(
          tf.keras.layers.Conv2D(
              filters=num_filters_bottleneck,
              kernel_size=3,
              padding="same",
          )
      )
  
      super(Encoder, self).__init__(layers=model, name=name)
  
imports: import collections
  from compare_gan.architectures import abstract_arch
  from compare_gan.architectures import arch_ops
  import numpy
  import tensorflow.compat.v1
  import tensorflow_compression
  from hific.helpers import ModelMode
label_desc: Use image node_id 1 to create a new Encoder object from inherited base classes: tf.keras with example: obj = Encoder(name, num_down, num_filters_base, num_filters_bottleneck)