Added imageratio check