code: def _validate_dense_shape(dense_shape):
      """
      'dense_shape', as opposed to 'dense.shape', is the shape of the 'dense'
      matrix sans the 'label_idx' axis, i.e.
      (c, t, z, y, z)
      """
      ndim = len(DENSE_SHAPE_NAMES)
      assert (
          dense_shape is None or len(dense_shape) == ndim
      ), f"dense_shape must be length {ndim}, omitting '{DENSE_AXIS.label_idx.name}' dim"
  
imports: from enum import Enum
  import numpy
  from numpy.random.mtrand import RandomState
  import scipy.sparse
  import centrosome.index
label_desc: Use image node_id 2 for calling a global function with example usage: _validate_dense_shape(dense_shape) without return types