I am new to the programming in python and getting confused with the oops concept in python. I know super()
is used to use the methods defined in the parent class, but I can't understand why the parent class itself using the super()
keyword.
class BahdanauAttention(tf.keras.Model):
def __init__(self, units):
super(BahdanauAttention, self).__init__()
self.W1 = tf.keras.layers.Dense(units)
self.W2 = tf.keras.layers.Dense(units)
self.V = tf.keras.layers.Dense(1)