Giter VIP home page Giter VIP logo

gkotsis / negation-detection Goto Github PK

View Code? Open in Web Editor NEW
55.0 6.0 20.0 855 KB

Negation detection NLP tool. If you use the code, please cite George Gkotsis, Sumithra Velupillai, Anika Oellrich, Harry Dean, Maria Liakata and Rina Dutta. Don't Let Notes Be Misunderstood: A Negation Detection Method for Assessing Risk of Suicide in Mental Health Records, Computational Linguistics and Clinical Psychology 2016

Python 100.00%

negation-detection's Issues

Can i use this source code in windows 7 32 bit operating system?

I have tried to install "stanford_corenlp_pywrapper" in windows 7 32 bit OS, there are showed this error "AttributeError: 'module' object has no attribute 'mkfifo' in line number 170" of the file sockwrap.py while i am giving sample data into "stanford_corenlp_pywrapper" . Please help me how to install and use this system in windows 7 32 bit OS.

'NoneType' object is not subscriptable


TypeError Traceback (most recent call last)
in ()
1 import negation_detection
2 sentence = "ZZZZ reported no recent periods of low mood, discussed how in the past she made many suicide attempts"
----> 3 negation_detection.predict(sentence, 'suicide')

1 frames
/content/negation-detection/negation_detection.py in predict(sentence, keyword, asBoolean)
433 return processReturnResult(rs, asBoolean)
434
--> 435 def predict(sentence, keyword, asBoolean=True):
436 sentence = preprocess(sentence, keyword)
437 tokens = findSentencePTreeToken(sentence, keyword)

/content/negation-detection/negation_detection.py in preprocess(sentence, keyword)
147 for s in tmp:
148 import ipdb; ipdb.set_trace()
--> 149 rs = proc.parse_doc(s)
150 for e in rs['sentences']:
151 newS = ""

TypeError: 'NoneType' object is not subscriptable

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.