Sshanu / Relation-Classification-using-Bidirectional-LSTM-Tree

TensorFlow Implementation of the paper "End-to-End Relation Extraction using LSTMs on Sequences and Tree Structures" and "Classifying Relations via Long Short Term Memory Networks along Shortest Dependency Paths" for classifying relations
MIT License
185 stars 41 forks source link

cannot execute the file preprocessing.py completely #20

Open radhikagupta6 opened 4 years ago

radhikagupta6 commented 4 years ago

LookupError Traceback (most recent call last)

in () 9 e1_text = text 10 e1_text_ = " ".join(e1_text) ---> 11 e1_text = tokenizer.tokenize(e1_text) 12 text.append(t[0]) 13 e11= t[0] F:\anaconda\lib\site-packages\nltk\tokenize\stanford.py in tokenize(self, s) 85 """ 86 cmd = ['edu.stanford.nlp.process.PTBTokenizer'] ---> 87 return self._parse_tokenized_output(self._execute(cmd, s)) 88 89 def _execute(self, cmd, input_, verbose=False): F:\anaconda\lib\site-packages\nltk\tokenize\stanford.py in _execute(self, cmd, input_, verbose) 97 98 # Configure java. ---> 99 config_java(options=self.java_options, verbose=verbose) 100 101 # Windows is incompatible with NamedTemporaryFile() without passing in delete=False. F:\anaconda\lib\site-packages\nltk\internals.py in config_java(bin, options, verbose) 60 env_vars=['JAVAHOME', 'JAVA_HOME'], 61 verbose=verbose, ---> 62 binary_names=['java.exe'], 63 ) 64 F:\anaconda\lib\site-packages\nltk\internals.py in find_binary(name, path_to_bin, env_vars, searchpath, binary_names, url, verbose) 695 return next( 696 find_binary_iter( --> 697 name, path_to_bin, env_vars, searchpath, binary_names, url, verbose 698 ) 699 ) F:\anaconda\lib\site-packages\nltk\internals.py in find_binary_iter(name, path_to_bin, env_vars, searchpath, binary_names, url, verbose) 679 """ 680 for file in find_file_iter( --> 681 path_to_bin or name, env_vars, searchpath, binary_names, url, verbose 682 ): 683 yield file F:\anaconda\lib\site-packages\nltk\internals.py in find_file_iter(filename, env_vars, searchpath, file_names, url, verbose, finding_dir) 637 msg += '\n\n For more information on %s, see:\n <%s>' % (filename, url) 638 div = '=' * 75 --> 639 raise LookupError('\n\n%s\n%s\n%s' % (div, msg, div)) 640 641 LookupError: =========================================================================== NLTK was unable to find the java file! Use software specific configuration paramaters or set the JAVAHOME environment variable. ===========================================================================