Solved by ptrblck in post #2 
              
              
                You are probably looking into the master branch of torchvision, which might differ from your current installed version. 
A few weeks ago there was a small refactoring, which added permanent data and target variables instead of train_data etc. 
Have a look at this diff.