8000 Adjust timeout parameter · potatochip/corenlp-python@8f19638 · GitHub
[go: up one dir, main page]

Skip to content

Commit 8f19638

Browse files
committed
Adjust timeout parameter
1 parent 81282ee commit 8f19638

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# A Python wrapper of Stanford Core NLP
1+
# A Python wrapper of Stanford Core NLP tools
22

33
This is a fork of [stanford-corenlp-python](https://github.com/dasmith/stanford-corenlp-python).
44

corenlp/corenlp.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ def clean_up():
241241
# the idea here is that you increase the timeout as a
242242
# function of the text's length.
243243
# max_expected_time = max(5.0, 3 + len(to_send) / 5.0)
244-
max_expected_time = max(300.0, 3 + len(to_send) / 10.0)
244+
max_expected_time = max(300.0, len(to_send) / 2)
245245

246246
# repeated_input = self.corenlp.except("\n") # confirm it
247247
t = self.corenlp.expect(["\nNLP> ", pexpect.TIMEOUT], timeout=max_expected_time)

0 commit comments

Comments
 (0)
0