Fix to handle null strides in DLPack tensor (#18510)
authorBram Wasti <bwasti@fb.com>
Thu, 4 Apr 2019 07:24:16 +0000 (00:24 -0700)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Thu, 4 Apr 2019 07:28:13 +0000 (00:28 -0700)
commit095f88e0934f5503cb3d01dbb7065d3c0be8e860
tree45567056915dd467c8cc4d442d0f1ff2cb4b3c18
parente5e2110a8ead028c863a7f449273bf6ee90bc423
Fix to handle null strides in DLPack tensor (#18510)

Summary:
DLPack can have non-strided tensors, which is represented by a nullptr in the place of dl_tensor.strides.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/18510

Differential Revision: D14647328

Pulled By: bwasti

fbshipit-source-id: 5364282810a5772cfc2319fc8133fe86fdd84dd1
aten/src/ATen/DLConvertor.cpp
aten/src/ATen/test/dlconvertor_test.cpp