lixinsu / lion Goto Github PK
View Code? Open in Web Editor NEWsemantic matching toolkit
License: Apache License 2.0
semantic matching toolkit
License: Apache License 2.0
The word_dict is not passed to the function and limit max text length
Detect the number of classes in the training set, rather than manually setting classes
add script in data/datset_utils
This dataset is smaller than both QQP and SNLI, it has only 10k training data. It's more convenient to first test model performance in this dataset.
Configure logging and add some necessary log
Existing implementation cannot support vars
param[k]=v
and param.k=v
ignore is already on
Traceback (most recent call last):
File "lion/training/trainer.py", line 33, in
train_model('lion/configs/test_bimpm_1.yaml')
File "lion/training/trainer.py", line 25, in train_model
model.train_epoch(train_loader)
File "/home/fanyixing/users/mxy/lion/lion/training/model.py", line 85, in train_epoch
for ex in tqdm(data_loader):
File "/home/fanyixing/users/wangsu/anaconda3/envs/pytorch/lib/python3.6/site-packages/tqdm/_tqdm.py", line 979, in iter
for obj in iterable:
File "/home/fanyixing/users/wangsu/anaconda3/envs/pytorch/lib/python3.6/site-packa
ges/torch/utils/data/dataloader.py", line 336, in next
return self._process_next_batch(batch)
File "/home/fanyixing/users/wangsu/anaconda3/envs/pytorch/lib/python3.6/site-packa
ges/torch/utils/data/dataloader.py", line 357, in _process_next_batch
raise batch.exc_type(batch.exc_msg)
TypeError: Traceback (most recent call last):
File "/home/fanyixing/users/wangsu/anaconda3/envs/pytorch/lib/python3.6/site-packa
ges/torch/utils/data/dataloader.py", line 106, in worker_loop
samples = collate_fn([dataset[i] for i in batch_indices])
File "/home/fanyixing/users/wangsu/anaconda3/envs/pytorch/lib/python3.6/site-packa
ges/torch/utils/data/dataloader.py", line 106, in
samples = collate_fn([dataset[i] for i in batch_indices])
File "/home/fanyixing/users/mxy/lion/lion/data/dataset.py", line 26, in getitem
return self.vectorize(self.examples[index])
File "/home/fanyixing/users/mxy/lion/lion/data/dataset.py", line 56, in vectorize
Bchar = torch.LongTensor([make_char(char_dict, w) for w in ex['Btokens']])
File "/home/fanyixing/users/mxy/lion/lion/data/dataset.py", line 56, in
Bchar = torch.LongTensor([make_char(char_dict, w) for w in ex['Btokens']])
File "/home/fanyixing/users/mxy/lion/lion/data/dataset.py", line 48, in make_char
return [char_dict(t) for t in token[:8]] + [char_dict(t_) for t_ in token[-8:]]
File "/home/fanyixing/users/mxy/lion/lion/data/dataset.py", line 48, in │
return [char_dict(t_) for t_ in token[:8]] + [char_dict(t_) for t_ in token[-8:]]
TypeError: 'Dictionary' object is not callable
support ernie, xlnet, bert, roberta 中文
https://arxiv.org/pdf/1511.04108.pdf
baseline
add esim model
For ner or pos label mapping, there is no need for unk and null tok.
Now, esim and bmipm model use 1 mask value, but bert use 0 mask value.
Unify the mask mechanism which use 0 mask value, this is also consistent with tf.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.