Did you install PyTorch from source? setup.py creates a version.py file in torch/version.py. It should look like:
__version__ = '0.2.0+53fe804'
debug = False
cuda = '8.0.61'

depending on your build setup but you should definitely have a line that says __version__ = ...
Re-run setup.py and make sure the file is being created.