pankaj9075rawat's picture
Upload folder using huggingface_hub
6d64b51 verified
raw
history blame contribute delete
520 Bytes
# print("entered main.py")
import uvicorn
import os
if __name__ == "__main__":
# even though uvicorn is running on 0.0.0.0 check 127.0.0.1 from the browser
if "code" in os.getcwd():
uvicorn.run("app:app", host="0.0.0.0", port=8001, log_level="debug",
proxy_headers=True, reload=True)
else:
# for running locally from IDE without docker
uvicorn.run("app.app:app", host="0.0.0.0", port=8001, log_level="debug",
proxy_headers=True, reload=True)