Small typo in `utilities.py`

Bug report

Summary

The warning here is wrongfully raised because there is both if not and !=

Simple fix is to remove the not on this line