Skip to content

Commit

Permalink
Adds tqdm
Browse files Browse the repository at this point in the history
  • Loading branch information
PTNobel committed Dec 23, 2024
1 parent c0cfa70 commit ebb43f5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion randalo/adelie_integration.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import scipy.sparse as sp
import time
import torch
from tqdm import tqdm

import randalo as ra

Expand Down Expand Up @@ -98,7 +99,7 @@ def get_alo_for_sweep(y, state, risk_fun, step=1):
times = np.empty_like(lmda)
r2 = np.empty_like(lmda)

for out_i, i in enumerate(range(0, L, step)):
for out_i, i in tqdm(enumerate(range(0, L, step))):
t0 = time.monotonic()
randalo = adelie_state_to_randalo(y, y_hat[i], state, adelie_state, loss, J, i)
output[out_i] = randalo.evaluate(risk_fun)
Expand Down

0 comments on commit ebb43f5

Please sign in to comment.