mirror of
https://gitee.com/fastnlp/fastNLP.git
synced 2024-12-02 20:27:35 +08:00
sst loader中增加一列raw_words
This commit is contained in:
parent
cb3cb8bc5c
commit
d401bd2208
@ -134,6 +134,7 @@ class SST2Loader(CSVLoader):
|
||||
info = DataBundle()
|
||||
for name, path in paths.items():
|
||||
dataset = self.load(path)
|
||||
dataset.apply_field(lambda words:words.copy(), field_name='words', new_field_name='raw_words')
|
||||
datasets[name] = dataset
|
||||
|
||||
def wordtochar(words):
|
||||
|
Loading…
Reference in New Issue
Block a user