glitchgan.tf.model_components¶
TensorFlow/Keras model components for cDVGAN.
Architecture is identical to the original TF reference implementation. Lambda layers have been replaced with proper subclassed layers for compatibility with Keras 3 and correct model serialisation.
Module Contents¶
- class glitchgan.tf.model_components.ArgmaxLayer(*, activity_regularizer=None, trainable=True, dtype=None, autocast=True, name=None, **kwargs)[source]¶
Bases:
keras.layers.LayerReturn the argmax along the last axis as int32.
- class glitchgan.tf.model_components.ReduceSumDotLayer(*, activity_regularizer=None, trainable=True, dtype=None, autocast=True, name=None, **kwargs)[source]¶
Bases:
keras.layers.LayerCompute element-wise product and sum along axis 1 (keepdims).
- glitchgan.tf.model_components.get_discriminator_model(in_shape=8192, num_classes=NUM_CLASSES, print_summary=False)[source]¶
- glitchgan.tf.model_components.get_derivative_discriminator_model(in_shape=8191, num_classes=NUM_CLASSES, print_summary=False)[source]¶