title: Pandas convert array column into multiple columns with a condition
body: <p>I have a pandas data frame with 2 columns:</p>
  
  <ul>
  <li>embedding as an array column and size of embedding = <em>size_of_embedding</em></li>
  <li>language</li>
  </ul>
  
  <p>like this:</p>
  
  <pre><code>embedding              language
  [0.1 0.2 0.3]           fr
  [0.1 0.4 0.4]           en
  [0.8 0.1 0.1]           fr
  </code></pre>
  
  <p>Given a beginning integer <em>n = 10</em>, for each value of embedding column, I want to add a column to the above data frame like this:</p>
  
  <pre><code>embedding            language          feature1     feature2  feature3
  [0.1 0.2 0.3]          fr              10:0.1        11:0.2    12:0.3
  [0.1 0.4 0.4]          en              13:0.1        14:0.4    15:0.4
  [0.8 0.1 0.1]          fr              10:0.8        11:0.1    12:0.1
  </code></pre>
  
  <p>So, feature1 = 1st embedding value, feature2 = 2nd embedding value .... For the next language the beginning feature value = <em>n+size_of_embedding:</em>.
  So, for each language, the number of columns added is exactly equal to the size_of_embedding array. and for each next language encountered, we start with <em>n+size_of_embedding:</em>. Is there an easy way of doing this? Thanks.</p>