Coder Social home page Coder Social logo

Comments (6)

107350qin avatar 107350qin commented on June 1, 2024 2

fastapi启动之后本身系统就在一个事件循环中,你不能再创建其他事件了。
你可以把
uvicorn.run(app, host='0.0.0.0', port=6006, workers=1)
注释掉,使用
asyncio.run(hello())
来运行指定方法

from self-llm.

KMnO4-zx avatar KMnO4-zx commented on June 1, 2024

fastapi 不要在jupyter notebook里运行

from self-llm.

chaoskklt avatar chaoskklt commented on June 1, 2024

谢谢大佬深夜回答,我是小白。我在autodl只找到用jupyter notebook 编写和运行代码的地方。大佬能否再细致讲解一下

from self-llm.

KMnO4-zx avatar KMnO4-zx commented on June 1, 2024

在左侧界面 右键“创建文件” xxx.py 你可以自己摸索摸索

from self-llm.

chaoskklt avatar chaoskklt commented on June 1, 2024

谢谢

from self-llm.

KMnO4-zx avatar KMnO4-zx commented on June 1, 2024
image

from self-llm.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.