title: Save 2 channels of pixels of an image in png format
body: <p>According to scipy documentation it is possible to save single channel of an image like so;</p>
  
  <pre><code>&gt;&gt;&gt; x = np.zeros((255, 255))
  &gt;&gt;&gt; x = np.zeros((255, 255), dtype=np.uint8)
  &gt;&gt;&gt; x[:] = np.arange(255)
  &gt;&gt;&gt; imsave('/tmp/gradient.png', x)
  </code></pre>
  
  <p>And 3 channels of an image like so:</p>
  
  <pre><code>&gt;&gt;&gt; rgb = np.zeros((255, 255, 3), dtype=np.uint8)
  &gt;&gt;&gt; rgb[..., 0] = np.arange(255)
  &gt;&gt;&gt; rgb[..., 1] = 55
  &gt;&gt;&gt; rgb[..., 2] = 1 - np.arange(255)
  &gt;&gt;&gt; imsave('/tmp/rgb_gradient.png', rgb)
  </code></pre>
  
  <p>However is it possible to save only 2 channels of an image as png? I have tried to mimic the above code with only 2 channels, I am greeted with the following error:</p>
  
  <pre><code>ValueError: 'arr' does not have a suitable array shape for any mode.
  </code></pre>