code: public static void fillUniform(GrayF64 img, Random rand , double min , double max) {
  		double range = max-min;
  
  		double[] data = img.data;
  
  		for (int y = 0; y < img.height; y++) {
  			int index = img.getStartIndex() + y * img.getStride();
  			for (int x = 0; x < img.width; x++) {
  				data[index++] = rand.nextDouble()*range+min;
  			}
  		}
  	}
docs: Sets each value in the image to a value drawn from an uniform distribution that has a range of min &le; X &lt; max.
  
  @param img Image which is to be filled.  Modified,
  @param rand Random number generator
  @param min Minimum value of the distribution, inclusive
  @param max Maximum value of the distribution, inclusive