Adding a utility function to test non-negativity of an image