From 198e6274337de3150b01800e96bc8491368a1866 Mon Sep 17 00:00:00 2001 From: "Adam Ginsburg (keflavich)" Date: Sun, 16 Jun 2024 12:10:38 -0400 Subject: [PATCH] add descs --- spectral_cube/cube_utils.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/spectral_cube/cube_utils.py b/spectral_cube/cube_utils.py index 0585dca38..f2db02e16 100644 --- a/spectral_cube/cube_utils.py +++ b/spectral_cube/cube_utils.py @@ -1142,7 +1142,7 @@ def update(self, n=1): output_array=output_array, output_footprint=output_footprint, reproject_function=reproject_interp, - progressbar=tqdm if verbose else False, + progressbar=tqdm(desc='reproject_and_coadd') if verbose else False, intermediate_memmap=True, block_sizes=(None if spectral_block_size is None else [(spectral_block_size, cube.shape[1], cube.shape[2]) @@ -1159,7 +1159,7 @@ def update(self, n=1): output_array=output_array, output_footprint=output_footprint, reproject_function=reproject_interp, - progressbar=tqdm if verbose else False, + progressbar=tqdm(desc='reproject_and_coadd') if verbose else False, ) elif method == 'channel': log_("Using Channel method") @@ -1217,7 +1217,7 @@ def two_closest_channels(cube, channel): # exclude any cubes with invalid spatial slices (could happen if whole slices are masked out) keep1 = [all(x > 1 for x in cube[ch1:ch2, slices[1], slices[2]].shape) - for (ch1, ch2), slices, cube in std_tqdm(zip(chans, mincube_slices, cubes))] + for (ch1, ch2), slices, cube in std_tqdm(zip(chans, mincube_slices, cubes), desc='keepcheck')] if sum(keep1) < len(keep1): log.warn(f"Dropping {len(keep1)-sum(keep1)} cubes out of {len(keep1)} because they have invalid (empty) slices") @@ -1228,7 +1228,7 @@ def two_closest_channels(cube, channel): if kp else None # placeholder, will drop this below but need to retain list shape for (ch1, ch2), slices, cube, kp in std_tqdm(zip(chans, mincube_slices, cubes, keep1), - delay=5, desc='Subcubes') + delay=5, desc='Subcubes (conv)') ] if ii == 0: cube1 = scubes[0] @@ -1304,7 +1304,7 @@ def two_closest_channels(cube, channel): reproject_function=reproject_interp, input_weights=wthdus, #block_size=[2,-1,-1], - progressbar=partial(tqdm, desc='coadd') if verbose else False, + progressbar=partial(tqdm, desc=f'coadd ch{ii}') if verbose else False, match_background=False, )