Histograms are discrete by nature, so the gradients don’t make much sense / would be zero.
So you cannot use this in your objective function much as you cannot optimise classification accuracy.
Best regards
Thomas