The yaml loader just being called yaml overwrote loading the external yaml library in the file itself. Simple fix by renaming module to yml.py.