Replace sys.exit calls by exceptions

Replacing sys.exit by exceptions is probably more "pythonesque", at least in readPHYfile()
I am not sure that an exception is actually what you want in the main(), maybe the sys.exit with the print statement is more user-friendly.