12 Commits

Author SHA1 Message Date
xingjun.wang
48c0d2a9af add 1.6 2023-05-22 10:53:18 +08:00
yuze.zyz
605cd7f44a [to #42322933] NLP 1030 Refactor
Features:
1. Refactor the directory structure of nlp models. All model files are placed into either the model folder or the task_model folder
2. Refactor all the comments to google style
3. Add detail comments to important tasks and nlp models, to list the description of the model, and its preprocessor&trainer
4. Model Exporting now supports a direct all to TorchModelExporter(no need to derive from it)
5. Refactor model save_pretrained method to support direct running(independent from trainer)
6. Remove the judgement of Model in the pipeline base class, to support outer register models running in our pipelines
7. Nlp trainer now has a NLPTrainingArguments class , user can pass arguments into the dataclass, and use it as a normal cfg_modify_fn, to simplify the operation of modify cfg.
8. Merge the BACKBONES and the MODELS, so user can get a backbone with the Model.from_pretrained call
9. Model.from_pretrained now support a task argument, so user can use a backbone and load it with a specific task class.
10. Support Preprocessor.from_pretrained method
11. Add standard return classes to important nlp tasks, so some of the pipelines and the models are independent now, the return values of the models will always be tensors, and the pipelines will take care of the conversion to numpy and the following stuffs.
12. Split the file of the nlp preprocessors, to make the dir structure more clear.

Bugs Fixing:
1. Fix a bug that lr_scheduler can be called earlier than the optimizer's step
2. Fix a bug that the direct call of Pipelines (not from pipeline(xxx)) throws error
3. Fix a bug that the trainer will not call the correct TaskDataset class
4. Fix a bug that the internal loading of dataset will throws error in the trainer class
        Link: https://code.alibaba-inc.com/Ali-MaaS/MaaS-lib/codereview/10490585
2022-10-25 12:26:25 +08:00
lingcai.wl
7a49fa1cc6 [to #44657982] add unittest for demo and demotest utils
unittest for demo service
        Link: https://code.alibaba-inc.com/Ali-MaaS/MaaS-lib/codereview/10006180
2022-09-08 14:08:51 +08:00
ly119399
16139cefb6 [to #42322933] modify space task name 2022-08-10 14:27:47 +08:00
ly119399
8246174104 [to #43627720] pipeline task_oriented_conversation
Link: https://code.alibaba-inc.com/Ali-MaaS/MaaS-lib/codereview/9608407
2022-08-04 09:10:15 +08:00
wenmeng.zwm
d55525bfb6 [to #43112771] requirements check and lazy import support 2022-07-27 17:29:16 +08:00
wenmeng.zwm
4814b198f0 [to #43112534] taskdataset refine and auto placement for data and model
* refine taskdataset interface
 * add device placement for trainer
 * add device placement for pipeline
 * add config checker and fix model placement bug
 * fix cycling import
 * refactor model init for translation_pipeline
 * cv pipelines support kwargs


Link: https://code.alibaba-inc.com/Ali-MaaS/MaaS-lib/codereview/9463076
2022-07-23 11:08:43 +08:00
智丞
154c61fc25 add test cases 2022-07-04 13:48:54 +08:00
智丞
1307b52699 space outputs normalization 2022-06-30 16:05:09 +08:00
ly119399
d422510158 fix bug 2022-06-30 11:17:38 +08:00
智丞
1cc1b3c637 revise based on comment except chinease comment 2022-06-27 14:28:05 +08:00
智丞
a1af728079 refactor space 2022-06-23 12:11:41 +08:00