Skip to content

cpu_thread_num does't work with docker image python:3.9.16-slim-buster #1577

@shao77622

Description

@shao77622

Environment

FastDeploy version: e.g 0.8.0 or the latest code in develop branch

root@1cfb49fa663e:/home/aiBox# pip list
Package Version


anyio 3.6.2
asgiref 3.6.0
certifi 2022.12.7
charset-normalizer 3.1.0
click 8.1.3
faiss-cpu 1.7.3
fastapi 0.93.0
fastdeploy-python 1.0.4
fastdeploy-tools 0.0.5
h11 0.14.0
idna 3.4
numpy 1.24.2
opencv-python 4.7.0.72
Pillow 9.4.0
pip 22.0.4
pydantic 1.10.6
PyYAML 6.0
requests 2.28.2
schedule 1.1.0
setuptools 58.1.0
sniffio 1.3.0
starlette 0.25.0
tqdm 4.65.0
typing_extensions 4.5.0
urllib3 1.26.14
uvicorn 0.16.0
wheel 0.38.4

OS Platform: e.g. Linux x64 / Windows x64 / Mac OSX 12.1(arm or intel)

Linux 1cfb49fa663e 5.10.104-linuxkit #1 SMP Wed Mar 9 19:05:23 UTC 2022 x86_64 GNU/Linux

Hardware: e.g. Nvidia GPU 3080Ti CUDA 11.2 CUDNN 8.3
macbook pro 2019 i9 8 core
Program Language: e.g. Python 3.8

Python 3.9.16 (main, Mar 1 2023, 15:52:45)
[GCC 8.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.

import sys
print(sys.version_info)
sys.version_info(major=3, minor=9, micro=16, releaselevel='final', serial=0)
print(sys.version)
3.9.16 (main, Mar 1 2023, 15:52:45)
[GCC 8.3.0]

Problem description

Please attach the log file if there's problem happend.
fastdeploy infer always use 1 cpu , with max 100%, the option.set_cpu_thread_num() does't work .
But without docker, just run on mac aconda python 3.9 , it works!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions