title: ValueError: too many values to unpack scikitlearn.train
body: <p>I am doing sentiment analysis now and I wanna test the accuracy of some classifiers. If I didn't convert trainset to dict, the error is <code>"AttributeError: 'tuple' object has no attribute 'iterkeys'"</code>
  However after I converted it to dict, I received the error:</p>
  
  <pre><code>Traceback (most recent call last):
    File "E:\Python27\accuracy.py", line 204, in &lt;module&gt;
      print 'BernoulliNB`s accuracy is %f' %score(BernoulliNB())
    File "E:\Python27\accuracy.py", line 200, in score
      classifier.train(trainset)
      File "E:\Python27\lib\site-packages\nltk\classify\scikitlearn.py", line 93, in train
          for fs, label in labeled_featuresets:
      ValueError: too many values to unpack
  </code></pre>
  
  <p>partially code:</p>
  
  <pre><code>trainset = extracted_pos_features[50:]+extracted_neg_features[50:]
  testset = extracted_pos_features[:50]+extracted_neg_features[:50]
  dict1 = {}
  for i,j in trainset:
      dict1.setdefault(j,[]).append(i)
  
  trainset = dict1
  
  test, tag_test = zip(*testset)
  
  def score(classifier):
      classifier = SklearnClassifier(classifier)
      classifier.train(trainset)
      pred = classifier.batch_classify(test)
      return accuracy_score(tag_test, pred)
  
  print 'BernoulliNB`s accuracy is %f' %score(BernoulliNB())
  </code></pre>
  
  <p>There are two keys in dict1 'neg' and 'pos' with multiple values respectively :</p>
  
  <p>dict1</p>
  
  <pre><code>{'neg': [('tone', 'ultimately'), ('tragedy', 'core'), ('ultimately', 'dulls'), ('update', 'dreary'), ('version', 'looks'), ('voice', 'lack'), ('worst', 'film'), ('yarn', 'eloquent'), ('makes', 'little'), ('makes', 'maryam'), ('remain', 'true'), ('screen', 'time'), ('sluggish', 'time'), ('thesis', 'makes'), ('time', 'machine'), ('true', 'chan'), ('true', 'original'), ('unashamedly', 'makes'), ('time', 'true')], 
  
  'pos': [('rock', 'destined'), ('schwarzenegger', 'van'), ('screenplay', 'curls'), ('segal', 'gorgeously'), ('slice', 'asian'), ('snappy', 'screenplay'), ('somehow', 'pulls'), ('sometimes', 'movies'), ('splash', 'arnold'), ('start', 'emerges'), ('steers', 'snappy'), ('steven', 'segal'), ('top', 'game'), ('trilogy', 'huge'), ('van', 'damme'), ('vision', 'effective'), ('wasabi', 'start'), ('words', 'adequately'), ('cat', 'offers'), ('emerges', 'rare'), ('game', 'offers'), ('offers', 'refreshingly'), ('rare', 'combination'), ('rare', 'issue'), ('offers', 'rare')]}
  </code></pre>
  
  <p>Do anyone knows how do fix it? 
  Thank you so much.</p>