From ebb43f5da13a16875094c7a10bd100384f20f45b Mon Sep 17 00:00:00 2001 From: Parth Nobel Date: Mon, 23 Dec 2024 11:31:51 -0800 Subject: [PATCH] Adds tqdm --- randalo/adelie_integration.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/randalo/adelie_integration.py b/randalo/adelie_integration.py index 5d8a227..6726409 100644 --- a/randalo/adelie_integration.py +++ b/randalo/adelie_integration.py @@ -5,6 +5,7 @@ import scipy.sparse as sp import time import torch +from tqdm import tqdm import randalo as ra @@ -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)