code: def test_composite():
      r = numpy.random.RandomState()
      r.seed(41)
      images = [r.uniform(size=(11, 13)) for _ in range(5)]
      colors = [r.randint(0, 255, size=3) for _ in range(5)]
      weights = r.uniform(low=1.0 / 255, high=1.5, size=5).tolist()
      color_names = [
          "#%02x%02x%02x" % tuple(color.tolist()) for color in colors
      ]
      workspace, module = make_workspace(
          cellprofiler.modules.graytocolor.SCHEME_COMPOSITE,
          images,
          colors=color_names,
          weights=weights,
      )
      module.run(workspace)
      output = workspace.image_set.get_image(
          OUTPUT_IMAGE_NAME
      ).pixel_data
      assert output.shape[:2] == images[0].shape
      assert output.shape[2] == 3
      for i in range(3):
          channel = sum(
              [
                  image * weight * float(color[i]) / 255
                  for image, color, weight in zip(
                      images, colors, weights
                  )
              ]
          )
          numpy.testing.assert_array_almost_equal(
              output[:, :, i], channel
          )
  
file_path: CellProfiler/tests/frontend/modules/test_graytocolor.py
imports: import numpy
  import six.moves
  import os
  import cellprofiler_core.image
  import cellprofiler_core.measurement
  import cellprofiler.modules.graytocolor
  import cellprofiler_core.object
  import cellprofiler_core.pipeline
  import cellprofiler_core.workspace
  import tests.frontend.modules
label_desc: Use image node_id 6 for calling a global function with example usage: test_composite() without return types