New functions to automatically crop images given crop coordinates