Hi,
I have used the conda virtual environment to build the master branch.
OS: Ubuntu 16.04.2 LTS (GNU/Linux 4.4.0-83-generic x86_64)
Python version: Python3
Driver Version: 375.66
conda create --name pytorch_master
source activate pytorch_master
export CMAKE_PREFIX_PATH=/home/user2/.conda/envs/pytorch_master/
git clone https://github.com/pytorch/pytorch
cd pytorch
conda install numpy pyyaml mkl setuptools cmake gcc cffi
conda install -c soumith magma-cuda80

And if I run python setup.py install directly, it will incur an import error:
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
Fatal Python error: Py_Initialize: Unable to get the locale encoding
ImportError: No module named 'encodings'

Current thread 0x00007faeabc48700 (most recent call first):
[1]    12644 abort (core dumped)  python setup.py install

My solution to this is to deactivate the virtual environment and re-enter it again. This time I can install the PyTorch without any problem.
But no matter what program I am trying to run, as long as it uses CudaTensor, it would crash with a segmentation fault as above.
I am wondering if it’s because of the conda virtual envs. If I would like to install the bleeding edge version of python in a virtual env, could you please shed some light on the best way to do this?
Thanks,
Danlu