title: dumping queue into list/array in python
body: <p>I am running a number of threads and collecting there result on a queue. I would like to dump it into array or list so that I can do indexing and retrieve those results. Each of the elements in  the queue is a array of dimension n. I would like to access those arrays. Would you please let me know, how would i do it?</p>
  
  <pre><code> def dump_queue(model_queue):
   queue_list = []
   for i in iter(model_queue.get,'STOP'):
           queue_list.append(i)
    return queue_list
  
  
  
  
  aux_model=train_svm(np.array(trainExample),np.array(trainLabel))
  model_queue.put(aux_model.coef_)
  </code></pre>
  
  <p>Thus the arrays are the learned model parameters of <code>svm</code>. model_queue is shared among the threads. I want to access each of the model parameters vectors not each of the entries of a model parameters.</p>