Cleaning up code + Removed STATE=False from rhf module