I am trying to integrate Differential Privacy in my code, but the code is working fine only when I am using microbatch size as 1, other than that it is throwing the error. I even tried keeping it equal to the batch size. But the error is still not resolved.
EXACT ERROR:
ValueError: Dimension size must be evenly divisible by 50 but is 1 for '{{node Reshape}} = Reshape[T=DT_FLOAT, Tshape=DT_INT32](sparse_categorical_crossentropy/weighted_loss/value, Reshape/shape)' with input shapes: [], [2] and with input tensors computed as partial shapes: input[1] = [50,?].