I guess you can create a new Operator class similar to KL and add the regulation term regularizer_func(weight) to the loss function:
However, you need to scaled it properly - not sure what is the correct way to do so.
I guess you can create a new Operator class similar to KL and add the regulation term regularizer_func(weight) to the loss function:
However, you need to scaled it properly - not sure what is the correct way to do so.