docstr: Return the image groupings of the image sets in an image set list
  
  returns a tuple of key_names and group_list:
  key_names - the names of the keys that identify the groupings
  group_list - a sequence composed of two-tuples.
               the first element of the tuple has the values for
               the key_names for this group.
               the second element of the tuple is a sequence of
               image numbers comprising the image sets of the group
  For instance, an experiment might have key_names of 'Metadata_Row'
  and 'Metadata_Column' and a group_list of:
  [ ({'Row':'A','Column':'01'), [0,96,192]),
    (('Row':'A','Column':'02'), [1,97,193]),... ]
docstr_tok: ["Return","the","image","groupings","of","the","image","sets","in","an","image","set","list","returns","a","tuple","of","key_names","and","group_list",":","key_names","-","the","names","of","the","keys","that","identify","the","groupings","group_list","-","a","sequence","composed","of","two-tuples",".","the","first","element","of","the","tuple","has","the","values","for","the","key_names","for","this","group",".","the","second","element","of","the","tuple","is","a","sequence","of","image","numbers","comprising","the","image","sets","of","the","group","For","instance",",","an","experiment","might","have","key_names","of","'Metadata_Row'","and","'Metadata_Column","'","and","a","group_list","of",":","[","(","{","'Row","'",":","'","A","'",",","'Column","'",":","'01","'",")",",","[","0,96,192","]",")",",","(","(","'Row","'",":","'","A","'",",","'Column","'",":","'02","'",")",",","[","1,97,193","]",")",",","...","]"]
code: def get_groupings(self, workspace):
      """Return the image groupings of the image sets in an image set list
  
      returns a tuple of key_names and group_list:
      key_names - the names of the keys that identify the groupings
      group_list - a sequence composed of two-tuples.
                   the first element of the tuple has the values for
                   the key_names for this group.
                   the second element of the tuple is a sequence of
                   image numbers comprising the image sets of the group
      For instance, an experiment might have key_names of 'Metadata_Row'
      and 'Metadata_Column' and a group_list of:
      [ ({'Row':'A','Column':'01'), [0,96,192]),
        (('Row':'A','Column':'02'), [1,97,193]),... ]
      """
      if not self.wants_groups:
          return
      key_list = self.get_grouping_tags_or_metadata()
      m = workspace.measurements
      for key in key_list:
          if key not in m.get_feature_names("Image"):
              if key.startswith(C_METADATA):
                  key = key[len(C_METADATA) + 1 :]
              workspace.pipeline.report_prepare_run_error(
                  self,
                  (
                      'The groups module is misconfigured. "%s" was chosen as\n'
                      "one of the metadata tags, but that metadata tag is not\n"
                      "defined in the Metadata module."
                  )
                  % key,
              )
              return None
      return key_list, m.get_groupings(key_list)
  
imports: import numpy
  from ..constants.image import CT_OBJECTS
  from ..constants.measurement import COLTYPE_INTEGER, COLTYPE_VARCHAR, IMAGE
  from ..constants.measurement import C_FILE_NAME
  from ..constants.measurement import C_METADATA
  from ..constants.measurement import C_OBJECTS_FILE_NAME
  from ..constants.measurement import C_OBJECTS_PATH_NAME
  from ..constants.measurement import C_PATH_NAME
  from ..constants.measurement import EXPERIMENT
  from ..constants.measurement import GROUP_INDEX
  from ..constants.measurement import GROUP_NUMBER
  from ..constants.measurement import GROUP_LENGTH
  from ..constants.measurement import M_GROUPING_TAGS
  from ..measurement import Measurements
  from ..module import Module
  from ..pipeline import Pipeline
  from ..setting import Binary
  from ..setting import Divider
  from ..setting import HTMLText
  from ..setting import HiddenCount
  from ..setting import SettingsGroup
  from ..setting import Table
  from ..setting.choice import Choice
  from ..setting.do_something import DoSomething
  from ..setting.do_something import RemoveSettingButton
  from ..utilities.image import image_resource
label_desc: Use image node_id 12 for calling the Groups obj's underlying member method code with example usage: obj.get_groupings(workspace) and returns: key_list,  m, None