code: public void setImageGradient(D derivX , D derivY ) {
  		InputSanityCheck.checkSameShape(derivX,derivY);
  		if( derivX.stride != derivY.stride || derivX.startIndex != derivY.startIndex )
  			throw new IllegalArgumentException("stride and start index must be the same");
  
  		savedAngle.reshape(derivX.width,derivX.height);
  		savedMagnitude.reshape(derivX.width,derivX.height);
  
  		imageDerivX.wrap(derivX);
  		imageDerivY.wrap(derivY);
  
  		precomputeAngles(derivX);
  	}
docs: Sets the gradient and precomputes pixel orientation and magnitude
  
  @param derivX image derivative x-axis
  @param derivY image derivative y-axis