Added imgsize function