Changed to collect image ratio in the run once and calculate image dimensions per run