Check NAN in C++

Hi,

Is there any API to check whether a tensor has any NAN value?

Thanks,
Afshin

Check https://github.com/pytorch/pytorch/pull/15722/files . It isn’t in the 1.0 release, but that’s how you could implement it.

2 Likes

Thanks for the hint. Do you know when it would be added to the stable version?

It will be in our next 1.1 release.

1 Like