title: Mixing multiple tf.data.Dataset?
body: <p>I have three datasets D1, D2, D3, that are outputting the same type of data. What I'm trying to do is to output randomdly D1 or D2 or D3 from one unique pipeline. I tried to use <code>tf.data.Dataset.zip((D1, D2, D3))</code> but then I don't know how to flatten its output in order to shuffle it and then have an output like <code>D1_element, D3_element,D1_element , D2_element ...</code>
  Here is a small example:</p>
  
  <pre><code>import tensorflow as tf
  
  D1 = tf.data.Dataset.range(1,5)
  D2 = tf.data.Dataset.range(5,10)
  D3 = tf.data.Dataset.range(10,15)
  
  zip = tf.data.Dataset.zip((D1,D2,D2))
  ...
  </code></pre>