mirror of
https://github.com/facebookresearch/faiss.git
synced 2026-10-11 22:50:00 +00:00
Replace finite() with std::isfinite(). (#1341)
Summary: Pull Request resolved: https://github.com/facebookresearch/faiss/pull/1341 Test Plan: Imported from OSS Reviewed By: mdouze Differential Revision: D23234968 Pulled By: beauby fbshipit-source-id: f7ba7bd473e05f2ba4d0ca555bc78965f5aa3fd1
This commit is contained in:
committed by
Facebook GitHub Bot
parent
7b615ed5d9
commit
7cc320e438
@@ -289,7 +289,7 @@ void Clustering::train_encoded (idx_t nx, const uint8_t *x_in,
|
||||
// reports.
|
||||
const float *x = reinterpret_cast<const float *>(x_in);
|
||||
for (size_t i = 0; i < nx * d; i++) {
|
||||
FAISS_THROW_IF_NOT_MSG (finite (x[i]),
|
||||
FAISS_THROW_IF_NOT_MSG (std::isfinite (x[i]),
|
||||
"input contains NaN's or Inf's");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user