dot-getGradients function

.getGradients