Update PxCorpus.py
Browse files- PxCorpus.py +2 -2
PxCorpus.py
CHANGED
|
@@ -74,9 +74,9 @@ class StringIndex:
|
|
| 74 |
print(key in self.vocab_struct)
|
| 75 |
|
| 76 |
if (key in self.vocab_struct) == False:
|
| 77 |
-
return
|
| 78 |
|
| 79 |
-
return t in self.vocab_struct[key]
|
| 80 |
|
| 81 |
_VOCAB = StringIndex(vocab=open("./vocabulary_nachos_lowercased.txt","r").read().split("\n"))
|
| 82 |
|
|
|
|
| 74 |
print(key in self.vocab_struct)
|
| 75 |
|
| 76 |
if (key in self.vocab_struct) == False:
|
| 77 |
+
return "is_oov"
|
| 78 |
|
| 79 |
+
return "is_not_oov" if t in self.vocab_struct[key] else "is_oov"
|
| 80 |
|
| 81 |
_VOCAB = StringIndex(vocab=open("./vocabulary_nachos_lowercased.txt","r").read().split("\n"))
|
| 82 |
|