code: def _normalize_sequence(array, value, fname):
      """
      values = _normalize_sequence(array, value, fname)
  
      If `value` is a sequence, checks that it has an element for each dimension
      of `array`. Otherwise, returns a sequence that repeats `value` once for
      each dimension of array.
  
      Parameters
      ----------
      array : ndarray
      value : sequence or scalar
      fname : str
          Function name. Used in error messages
  
      Returns
      -------
      values : sequence
      """
      try:
          value = list(value)
      except TypeError:
          return [value for s in array.shape]
      if len(value) != array.ndim:
          raise ValueError(
              "mahotas.%s: argument is sequence, but has wrong size (%s for an array of %s dimensions)"
              % (fname, len(value), array.ndim)
          )
      return value
  
file_path: mahotas/mahotas/internal.py
imports: import numpy
label_desc: Use image node_id 3 for calling a global function with example usage: _normalize_sequence(array, value, fname) and returns: value, unknown