Skip to content

Commit f0a4827

Browse files
committed
fronebius warning
1 parent f5d67d6 commit f0a4827

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

torchmdnet/extensions/neighbors/neighbors_cpu.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
using std::tuple;
99
using torch::arange;
1010
using torch::div;
11-
using torch::frobenius_norm;
11+
using torch::linalg_vector_norm;
1212
using torch::full;
1313
using torch::hstack;
1414
using torch::index_select;
@@ -99,7 +99,7 @@ forward_impl(const std::string& strategy, const Tensor& positions, const Tensor&
9999
deltas.index_put_({Slice(), 0}, deltas.index({Slice(), 0}) -
100100
scale1 * box_vectors.index({pair_batch, 0, 0}));
101101
}
102-
distances = frobenius_norm(deltas, 1);
102+
distances = linalg_vector_norm(deltas, 2, 1);
103103
mask = (distances < cutoff_upper) * (distances >= cutoff_lower);
104104
neighbors = neighbors.index({Slice(), mask});
105105
deltas = deltas.index({mask, Slice()});

0 commit comments

Comments
 (0)