Removed deprecation warnings on gradients

As well as deprecated ways to call these methods.