Added blocks, bug fixes

Added block code to feed RasterToArray smaller rasters.
working on fixing issue with sampling array
various cleanup