how to convert tensor to numpy array pytorch in version 0.4 code example Example: convert pytorch tensor to numpy na = a.to('cpu').numpy()