Hi Sunil!



 Sunil_Sharma1:

I want to learn the kernels given like this


If you want your kernels to be equal to the non-textual G_x and G_y you
gave, why don’t you just set them to be equal, rather than try to “learn”
them?
In a related point, it is true that your G_x and G_y satisfy your desired
constraint, and, indeed, loss_constrain takes on its minimum value of
zero with them.  But so do many, many other pairs of 3x3 matrices.  So
there is no reason that training with loss_constrain will result in kernels
that are close to G_x and G_y.
Best.
K. Frank