Skip to content

Commit e0ed58a

Browse files
committed
Add explicit steps to ranges
1 parent ff04aca commit e0ed58a

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

nx/lib/nx/binary_backend/matrix.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ defmodule Nx.BinaryBackend.Matrix do
177177

178178
# QR iteration for eigenvalues and eigenvectors
179179
{eigenvals_diag, eigenvecs} =
180-
Enum.reduce_while(1..max_iter, {h, q_h}, fn _, {a_old, q_old} ->
180+
Enum.reduce_while(1..max_iter//1, {h, q_h}, fn _, {a_old, q_old} ->
181181
# QR decomposition
182182
{q_now, r_now} = qr_decomposition(a_old, n, n, eps)
183183

nx/lib/nx/shape.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1856,7 +1856,7 @@ defmodule Nx.Shape do
18561856
end
18571857

18581858
# batch axes must be increasing starting from 0
1859-
valid_batch_axes = Enum.to_list(0..(length(b1) - 1))
1859+
valid_batch_axes = Enum.to_list(0..(length(b1) - 1)//1)
18601860

18611861
# ensure normalized batch axis of left is valid value
18621862
if left_batched? and b1 != valid_batch_axes do

0 commit comments

Comments
 (0)