title: Assigning random colour from RGB into a image
body: <p>I am implement a picture using OpenCV with Python, the requirement is to assign random R,G,B colour to every pixel into the image.</p>
  
  <p>Here is my current code:</p>
  
  <pre><code>red, green, blue = (255, 0, 0), (0, 255, 0), (0, 0, 255)
  rgb = [red, green, blue]
  image = img_gen(width, height, rgb_color = random.choice(rgb))
  
  width, height = 640, 480
  
  def img_gen(width, height, rgb_color=(0, 0, 0)):
    ...
      for x in range (0, width):
        for y in range (0, height):
            # what code should be inserted here?
  </code></pre>
  
  <p>I can now implement a picture with assigning only one random choice to fill in the whole image, but I want to know hot to access to every "pixel".</p>