1. A system comprising: at least one processor coupled to a memory; an input module to receive an input image; an image blocks module to represent the input image as a plurality of blocks, the plurality of blocks being organized into a first number of columns and a first number of rows; a sample generator to generate a representative sample image from the input image based on a sampling rule, the sample generator to: sample each row from the first number of rows, for each row starting from a different column position and to generate a subset of the plurality of blocks, and identify the subset of the plurality of blocks as the representative sample image; a statistics generator to generate statistics of transform coefficients obtained for the representative sample image; a custom probability tables generator to generate, using the at least one processor, custom probability tables utilizing the representative sample image and the statistics generated for the representative sample image; and an entropy coder to encode the input image utilizing the custom probability tables generated based on the statistics generated for the representative sample image.