title: NLTK: why does nltk not recognize the CLASSPATH variable for stanford-ner?
body: <p>This is my code</p>
  
  <pre><code>from nltk.tag import StanfordNERTagger
  st = StanfordNERTagger('english.all.3class.distsim.crf.ser.gz')
  </code></pre>
  
  <p>And i get   </p>
  
  <pre><code>NLTK was unable to find stanford-ner.jar! Set the CLASSPATH
    environment variable.
  </code></pre>
  
  <p>This is what my <code>.bashrc</code> looks like in ubuntu</p>
  
  <pre><code>export CLASSPATH=/home/wolfgang/Downloads/stanford-ner-2015-04-20/stanford-ner-3.5.2.jar
  export STANFORD_MODELS=/home/wolfgang/Downloads/stanford-ner-2015-04-20/classifiers
  </code></pre>
  
  <p>Also, i tried printing the environmental variable in python this way</p>
  
  <pre><code>import os
  os.environ.get('CLASSPATH')
  </code></pre>
  
  <p>And i recieve </p>
  
  <pre><code>'/home/wolfgang/Downloads/stanford-ner-2015-04-20/stanford-ner-3.5.2.jar'
  </code></pre>
  
  <p>Therefore the variables are being SET!</p>
  
  <p>What is wrong then? </p>
  
  <p>Why doe'snt nltk recognize my environmental variables?</p>