Update PxCorpus.py
Browse files- PxCorpus.py +2 -2
PxCorpus.py
CHANGED
@@ -36,8 +36,6 @@ of 55 participants (38% non-experts, 25% doctors, 36% medical practitioners), ma
|
|
36 |
|
37 |
_URL = "https://zenodo.org/record/6524162/files/pxslu.zip?download=1"
|
38 |
|
39 |
-
_VOCAB = StringIndex(vocab=open("./vocabulary_nachos_lowercased.txt","r").read().split("\n"))
|
40 |
-
|
41 |
class StringIndex:
|
42 |
|
43 |
def __init__(self, vocab):
|
@@ -63,6 +61,8 @@ class StringIndex:
|
|
63 |
def find(self, term):
|
64 |
return term in self.vocab_struct[(term[0], len(term))]
|
65 |
|
|
|
|
|
66 |
class PxCorpus(datasets.GeneratorBasedBuilder):
|
67 |
|
68 |
BUILDER_CONFIGS = [
|
|
|
36 |
|
37 |
_URL = "https://zenodo.org/record/6524162/files/pxslu.zip?download=1"
|
38 |
|
|
|
|
|
39 |
class StringIndex:
|
40 |
|
41 |
def __init__(self, vocab):
|
|
|
61 |
def find(self, term):
|
62 |
return term in self.vocab_struct[(term[0], len(term))]
|
63 |
|
64 |
+
_VOCAB = StringIndex(vocab=open("./vocabulary_nachos_lowercased.txt","r").read().split("\n"))
|
65 |
+
|
66 |
class PxCorpus(datasets.GeneratorBasedBuilder):
|
67 |
|
68 |
BUILDER_CONFIGS = [
|