[to #42362425] fix audio_requirement and refine quickstart, changelog doc

* make audio requirements optional
 * add changelog for version v0.2
 * add numpy constraint for compatibility with tensorflow1.15
 * update faq
 * fix nlp requiring tensorflow
 * add torchvision to multimodal dependency
 * bump version from 0.2.1 to 0.2.2
 * add warning msg when tensorflow is not installed
 
Link: https://code.alibaba-inc.com/Ali-MaaS/MaaS-lib/codereview/9268278
This commit is contained in:
wenmeng.zwm
2022-07-05 21:44:33 +08:00
parent cf194ef6cd
commit 274cf6ffa9
18 changed files with 245 additions and 114 deletions

View File

@@ -1,21 +1,6 @@
modelscope.pipelines package
============================
.. automodule:: modelscope.pipelines
:members:
:undoc-members:
:show-inheritance:
Subpackages
-----------
.. toctree::
:maxdepth: 4
modelscope.pipelines.audio
modelscope.pipelines.cv
modelscope.pipelines.multi_modal
modelscope.pipelines.nlp
Submodules
----------
@@ -25,8 +10,6 @@ modelscope.pipelines.base module
.. automodule:: modelscope.pipelines.base
:members:
:undoc-members:
:show-inheritance:
modelscope.pipelines.builder module
-----------------------------------

View File

@@ -1,3 +1,60 @@
## v 0.2.2 (05/07/2022)
Second internal release.
### Highlights
### Algorithms
#### CV
* add cv-person-image-cartoon pipeline
* add action recognition pipeline
* add ocr detection pipeline
* add animal recognition model
* add cmdssl video embedding extraction pipeline
#### NLP
* add speech AEC pipeline
* add palm2.0
* add space model
* add MPLUG model
* add dialog_intent, dialog_modeling, dialog state tracking pipleline
* add maskedlm model and fill_mask pipeline
* add nli pipeline
* add sentence similarity pipeline
* add sentiment_classification pipeline
* add text generation pipeline
* add translation pipeline
* add chinese word segmentation pipeline
* add zero-shot classification
#### Audio
* add tts pipeline
* add kws kwsbp pipline
* add linear aec pipeline
* add ans pipeline
#### Multi-Modal
* add image captioning pipeline
* add multi-modal feature extraction pipeline
* add text to image synthesis pipeline
* add VQA pipeline
### Framework
* add msdataset interface
* add hub interface and cache support
* support multiple models in single pipeline
* add default model configuration for each pipeline
* remove task field image and video, using cv instead
* dockerfile support
* multi-level tests support
* sphinx-docs use book theme
* formalize the output of pipeline and make pipeline reusable
* pipeline refactor and standardize module_name
* self-host repo support
### Bug Fix
* support kwargs in pipeline
* fix errors in task name definition
## v 0.1.0 (20/05/2022)
First internal release for pipeline inference

View File

@@ -41,3 +41,8 @@ reference: [https://huggingface.co/docs/tokenizers/installation#installation-fro
```shell
pip install -f https://download.pytorch.org/whl/torch_stable.html -i https://pypi.tuna.tsinghua.edu.cn/simple -r requirements.txt
```
### 4. zsh: no matches found: model_scope-0.2.2-py3-none-any.whl[all]
mac终端的zsh 对于[]需要做转义,执行如下命令
```shell
pip install model_scope\[all\] -f https://modelscope.oss-cn-beijing.aliyuncs.com/releases/repo.html
```

View File

@@ -29,15 +29,15 @@ ModelScope doc
change_log.md
.. toctree::
:maxdepth: 10
:caption: API Doc
.. .. toctree::
.. :maxdepth: 10
.. :caption: API Doc
api/modelscope.preprocessors
api/modelscope.models
api/modelscope.pipelines
api/modelscope.fileio
api/modelscope.utils
.. api/modelscope.preprocessors
.. api/modelscope.models
.. api/modelscope.pipelines
.. api/modelscope.fileio
.. api/modelscope.utils
Indices and tables

View File

@@ -1,6 +1,8 @@
# 快速开始
ModelScope Library目前支持tensorflowpytorch深度学习框架进行模型训练、推理 在Python 3.7+, Pytorch 1.8+, Tensorflow1.15+Tensorflow 2.6上测试可运行。
注: 当前630版本仅支持python3.7 以及linux环境其他环境(mac,windows等)支持预计730完成。
ModelScope Library目前支持tensorflowpytorch深度学习框架进行模型训练、推理 在Python 3.7+, Pytorch 1.8+, Tensorflow1.13-1.15Tensorflow 2.x上测试可运行。
注: 当前630版本 `语音相关`的功能仅支持 python3.7,tensorflow1.13-1.15的`linux`环境使用。 其他功能可以在windows、mac上安装使用。
## python环境配置
首先,参考[文档](https://docs.anaconda.com/anaconda/install/) 安装配置Anaconda环境
@@ -25,7 +27,12 @@ pip install --upgrade tensorflow
### pip安装
执行如下命令:
```shell
pip install model_scope[all] -f https://modelscope.oss-cn-beijing.aliyuncs.com/releases/0.2/repo.html
pip install "model_scope[all]" -f https://modelscope.oss-cn-beijing.aliyuncs.com/releases/repo.html
```
如需体验`语音功能`,请`额外`执行如下命令:
```shell
pip install "model_scope[audio]" -f https://modelscope.oss-cn-beijing.aliyuncs.com/releases/repo.html
```
### 使用源码安装
适合本地开发调试使用,修改源码后可以直接执行
@@ -38,9 +45,16 @@ cd modelscope
```
安装依赖并设置PYTHONPATH
```shell
pip install -r requirements.txt
pip install -e ".[all]" -f https://modelscope.oss-cn-beijing.aliyuncs.com/releases/repo.html
export PYTHONPATH=`pwd`
```
注: 6.30版本需要把cv、nlp、multi-modal领域依赖都装上7.30号各个领域依赖会作为选装,用户需要使用哪个领域安装对应领域依赖即可。
如需使用语音功能,请执行如下命令安装语音功能所需依赖
```shell
pip install -e ".[audio]" -f https://modelscope.oss-cn-beijing.aliyuncs.com/releases/repo
```
### 安装验证
安装成功后,可以执行如下命令进行验证安装是否正确
```shell