fit_image: Use calloc() to fix reproducibility issue