Commit Graph

197 Commits

Author SHA1 Message Date
FengZiYjun
0430067faf update 2018-08-31 11:51:56 +08:00
FengZiYjun
501ffb26c5 optimize CWS example
- see test_fastNLP.py
- update interpret_word_seg_results in fastnlp.py
- delete useless data to increase git clone speed
2018-08-31 11:23:40 +08:00
FengZiYjun
ab55f25e20 Updates to Trainer/Tester/fastnlp
1. Tester has a parameter "print_every_step" to control printing. print_every_step == 0 means NO print.
2. Tester's evaluate return (list of) floats, rather than torch.cuda.tensor
3. Trainer also has a parameter "print_every_step". The same usage.
4. In training, validation steps are not shown.
5. Updates to code comments.
6. fastnlp.py is ready for CWS. test_fastNLP.py works.
2018-08-31 10:46:56 +08:00
FengZiYjun
9d6b0daa99 Prepare for CWS service:
- specify the name of the config file and the name of corresponding section where model init params store.
- fastnlp.py needs load_pickle to get dictionary size and the number of labels
- other minor adjustments
2018-08-30 11:45:47 +08:00
FengZiYjun
625b72691b edit fastnlp run method, get ready for CWS
- change inputs of fastnlp from string to list of strings
- adopt flexible outputs according to diff tasks
2018-08-29 23:26:32 +08:00
Coet
b76d3d0827
Merge pull request #51 from xuyige/test_code
Test code
2018-08-29 17:05:18 +08:00
xuyige
beee885689 add test code for testing variational rnn 2018-08-29 15:28:22 +08:00
xuyige
2bc54c6d17 add test code for testing masked rnn 2018-08-29 15:27:59 +08:00
xuyige
b362a810e0 fix a bug in testing code 2018-08-29 15:26:50 +08:00
xuyige
c77621292b fix a bug in char_language_model.py 2018-08-29 15:26:18 +08:00
xuyige
650838d118 fix a bug in step() of MaskedRNNBase 2018-08-29 15:10:43 +08:00
xuyige
8899b44add fix a bug 2018-08-28 17:19:10 +08:00
xuyige
7a54a20908 add codes testing utils 2018-08-28 17:18:36 +08:00
xuyige
246908bf45 find a bug that bilinear must have bias 2018-08-28 17:18:09 +08:00
xuyige
08e924b54f add test code for testing preprocess.py 2018-08-28 17:17:07 +08:00
xuyige
812160493e add test code for testing trainer 2018-08-28 17:16:19 +08:00
xuyige
e58295d657 add test code for testing other modules 2018-08-28 13:40:12 +08:00
xuyige
ff37b03670 add test code for testing loader 2018-08-28 13:39:46 +08:00
xuyige
d6d92010e0 add test code for testing action.py 2018-08-28 13:39:28 +08:00
Coet
96391d6ab3
Merge pull request #46 from fastnlp/modify-readme-example
modify readme example
2018-08-24 19:15:16 +08:00
Xipeng Qiu
47ddb24d1d modify readme example 2018-08-24 11:52:13 +08:00
Coet
9b7ad27616
Merge pull request #44 from choosewhatulike/master
add MLP decoder
2018-08-24 09:48:39 +08:00
Coet
aea53c1833
Merge pull request #43 from FengZiYjun/master
New Trainer Initialization Interface
2018-08-24 09:47:40 +08:00
choosewhatulike
b54713d283 add MLP decoder 2018-08-23 23:29:53 +08:00
FengZiYjun
2df8eb740a Updates to core, loader:
- add Loss, Optimizer
- change Trainer & Tester initialization interface: two styles of definition provided
- handle Optimizer construction and loss function definition in a hard manner
- add argparse in task-specific scripts. (seq_labeling.py & text_classify.py)
- seq_labeling.py & text_classify.py work
2018-08-22 19:10:12 +08:00
Coet
ceac3f2e1f
Merge pull request #38 from FengZiYjun/new_updates
New updates
2018-08-22 10:18:46 +08:00
Coet
edb3b1341b
Merge pull request #2 from FengZiYjun/new_updates
New updates
2018-08-21 13:46:58 +08:00
Coet
c871d66ed7
Merge pull request #37 from keezen/master
Update metrics and figure in readme.
2018-08-21 10:12:45 +08:00
FengZiYjun
fac830e1cd fix bugs and clean up 2018-08-20 19:25:19 +08:00
lyhuang
6fe431833a docs/requirements 2018-08-20 17:46:14 +08:00
lyhuang
f2676d8927 docs更新
设置了模板,对fastNLP文件夹下的内容生成了文档
2018-08-20 17:22:26 +08:00
Ke Zhen
3ab8950d8d Update metrics and figure in readme. 2018-08-20 14:51:10 +08:00
FengZiYjun
4c8c2dfdb8 updates to core, loader, test:
- move preprocess.py from loader/ to core/
- changes to interface of preprocess: 1. add run method, to run the main processing 2. add cross validation split 3. add return value 4. merge subclasses
- Trainer supports cross validation
- add data as arguments in Trainer.train & Tester.test
- add readme.example.py, to run the example program shown in README.md
- other corresponding changes
2018-08-19 16:21:14 +08:00
Coet
fc7dd7eced
Merge pull request #33 from FengZiYjun/master
Updates to cores, loader, saver
2018-08-18 16:50:45 +08:00
Coet
836f05a8cc
Merge pull request #1 from FengZiYjun/FengZiYjun-patch-1
Update .travis.yml
2018-08-17 19:34:05 +08:00
Coet
1d000d3e39
Update .travis.yml 2018-08-17 19:28:38 +08:00
Coet
dfe0945893
Update .travis.yml 2018-08-17 19:14:01 +08:00
Xipeng Qiu
2f83010d9d
Merge pull request #32 from choosewhatulike/master
add a new chinese word segmentation model
2018-08-17 17:20:03 +08:00
FengZiYjun
80baf35765 add logging in Trainer & Tester
- see fastNLp/saver/logger.py to know how to create and use a logger
- a log file named "train_test.log" will be created in the same dir as the main file where the program starts
- this file records all important events happened in Trainer & Tester's methods
2018-08-17 11:16:13 +08:00
Ziyuan Feng
9e29fb2262 Merge branch 'master' of https://github.com/fastnlp/fastNLP 2018-08-17 09:22:49 +08:00
choosewhatulike
fb20e87321 add chinese word segmentation model 2018-08-17 00:07:38 +08:00
Xipeng Qiu
ad3b59b11c
Update README.md 2018-08-17 00:05:33 +08:00
Coet
9bc30f1705
Merge pull request #29 from keezen/master
Update readme, conv and max_pool
2018-08-16 22:10:13 +08:00
Coet
ffe7c26369
Merge branch 'master' into more_code_comments 2018-08-16 21:46:36 +08:00
Xipeng Qiu
abbe423dbe
Update README.md 2018-08-16 15:42:27 +08:00
choosewhatulike
1146ef0825 fix test_metrics 2018-08-15 21:41:10 +08:00
Coet
964cc2dc26
Merge pull request #25 from fastnlp/create_issue_templates
Update issue templates
2018-08-15 21:30:45 +08:00
FengZiYjun
929a595c4c Merge branch 'master' of https://github.com/fastNLP/fastNLP into to_merge
# Conflicts:
#	fastNLP/core/metrics.py
#	fastNLP/core/predictor.py
2018-08-15 21:07:55 +08:00
Ke Zhen
7f23b40ad7 Update readme, conv and max_pool 2018-08-15 20:27:05 +08:00
FengZiYjun
4bbeaebe96 Updates to cores, action, loader:
- rename Inference to Predictor
- rename Trainer.prepare_input to Trainer.load_train_data, load data_train.pkl only
- add __contains__ method to config Section class
- more code comments
- more elegant make_batch & data_iterator: Samplers return batch samples instead of batch indices
2018-08-15 20:12:20 +08:00