Io error handling

Neciu - please add error handling to convert.py