Skip to content
Honghan Wu edited this page Oct 28, 2016 · 6 revisions

Welcome to the psychometric_neuroatonomy wiki!

  • [Description of Manual Curation Process - from Christine](Curation Process)
  • [List of Tools and Resources](tools and resources)
  • [List of Testing Papers](Test Papers)

setup stanford parser for nltk

  • download Stanford parser zip file and English language model jar file from http://nlp.stanford.edu/software/lex-parser.shtml#Download
  • change the name of model file (e.g., stanford-english-corenlp-2016-01-10-models.jar) into stanford-parser-x.x.x-models.jar (e.g., stanford-parser-6.1.0-models.jar)
  • unzip parser zip file
  • put the jar files in unzipped parser file folder and the model jar file into your system environment variable classpath
  • unzip the model jar file (we will need a path of its edu/stanford/nlp/models/lexparser/englishPCFG.ser.gz file for initialising parser instance)
  • now you are ready to do your parsing like the following.
parser = StanfordParser(
        model_path="/Users/jackey.wu/Documents/working/libraries/"
                   "stanford-english-corenlp-2016-01-10-models/"
                   "edu/stanford/nlp/models/lexparser/englishPCFG.ser.gz")
sentences = parser.raw_parse(s)
    for line in sentences:
        for sentence in line:
            print sentence

install required libraries on centos

sudo yum install gcc
sudo yum install gcc-c++
sudo yum install python-devel
sudo yum install tkinter
sudo yum -y install freetype-devel
sudo yum install numpy
sudo yum install matplotlib
sudo yum install libxslt-devel libxml2-devel
sudo yum install python-lxml

sudo easy_install httplib2
sudo easy_install bs4
sudo easy_install xlrd
sudo easy_install pyquery
sudo easy_install plotly

sudo apt-get update
sudo apt-get install python-poppler-qt4