Added roi helper function