[PR] Update handling of image sizes