Skip to content

desi_preproc_darks ragged nested sequences deprecation #2592

@sbailey

Description

@sbailey

From /global/cfs/cdirs/desi/spectro/redux/daily/run/scripts/night/20260112/pdark-20260112-00331478-a0123456789-47729488.log:

/global/common/software/desi/perlmutter/desiconda/20240425-2.2.0/code/desispec/main/py/desispec/scripts/preproc_darks_mpi.py:193: VisibleDeprecationWarning: Creating an ndarray from ragged nested sequences (which is a list-or-tuple of lists-or-tuples-or ndarrays with different lengths or shapes) is deprecated. If you meant to do this, you must specify 'dtype=object' when creating the ndarray.
  all_data_header_cams = np.array(all_data_header_cams)

At best this is a deprecated feature that will stop working in a future version of numpy. At worst this isn't doing what we intend it to do and it is a bug.

Investigate what all_data_header_cams is prior to wrapping it with np.array(...) and what the intended result is meant to be, and update.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions