docstr: Combine images to make a grayscale one
          
docstr_tok: ["Combine","images","to","make","a","grayscale","one"]
code: def run_combine(self, workspace, image):
      """Combine images to make a grayscale one"""
      input_image = image.pixel_data
      channels, contributions = list(
          zip(*self.channels_and_contributions())
      )
      denominator = sum(contributions)
      channels = numpy.array(channels, int)
      contributions = numpy.array(contributions) / denominator
  
      output_image = numpy.sum(
          input_image[:, :, channels]
          * contributions[numpy.newaxis, numpy.newaxis, :],
          2,
      )
      image = Image(output_image, parent_image=image)
      workspace.image_set.add(self.grayscale_name.value, image)
  
      workspace.display_data.input_image = input_image
      workspace.display_data.output_image = output_image
  
imports: import re
  import matplotlib.colors
  import numpy
  from cellprofiler_core.image import Image
  from cellprofiler_core.module import Module
  from cellprofiler_core.setting import Binary
  from cellprofiler_core.setting import HiddenCount
  from cellprofiler_core.setting import SettingsGroup
  from cellprofiler_core.setting import ValidationError
  from cellprofiler_core.setting.choice import Choice
  from cellprofiler_core.setting.do_something import DoSomething
  from cellprofiler_core.setting.do_something import RemoveSettingButton
  from cellprofiler_core.setting.subscriber import ImageSubscriber
  from cellprofiler_core.setting.text import Float
  from cellprofiler_core.setting.text import ImageName
  from cellprofiler_core.setting.text import Integer
label_desc: Use image node_id 13 for calling the ColorToGray obj's underlying member method code with example usage: obj.run_combine(workspace, image) without return types