We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
import time from fastapi import FastAPI from modelscope.pipelines import pipeline from pydantic import BaseModel semantic_cls = pipeline('rex-uninlu', model='damo/nlp_deberta_rex-uninlu_chinese-base', model_revision='v1.2.1') app = FastAPI() class Item(BaseModel): input: str fields: object @app.post("/damo/rex-uninlu") def uie(item: Item): start = time.time() return { 'data': semantic_cls(input=item.input, schema=item.fields), 'took': time.time() - start }
用FastAPI对外提供了接口, 在阿里云FC里部署, 实例并发度10, 多线程调用的时候就会出现下面的报错 Pipeline related: @Firmament-cyou @wenmengzhou
The text was updated successfully, but these errors were encountered:
wenmengzhou
No branches or pull requests
用FastAPI对外提供了接口, 在阿里云FC里部署, 实例并发度10, 多线程调用的时候就会出现下面的报错
Pipeline related: @Firmament-cyou @wenmengzhou
The text was updated successfully, but these errors were encountered: