code: def get_channel_index_from_name(chname):
      """Get the MWS channel index from the channel name."""
      chindex = MWS_CHANNEL_NAMES_TO_NUMBER.get(chname, 0) - 1
      if 0 <= chindex < 24:
          return chindex
      raise AttributeError(f"Channel name {chname!r} not supported")
  
imports: import logging
  from datetime import datetime
  import dask.array
  import numpy
  from netCDF4 import default_fillvals
  from .netcdf_utils import NetCDF4FileHandler
label_desc: Use image node_id 1 for calling a global function with example usage: get_channel_index_from_name(chname) and returns: chindex