Skip to content
New issue

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

"DeprecationWarning: This process is multi-threaded, use of fork() may lead to deadlocks in the child." since OpenVINO 2025.0.0 #28944

Closed
Dobiasd opened this issue Feb 12, 2025 · 2 comments · Fixed by #28905
Assignees
Labels
bug Something isn't working category: Python API OpenVINO Python bindings priority: high High piority
Milestone

Comments

@Dobiasd
Copy link

Dobiasd commented Feb 12, 2025

Calling openvino.convert_model results in having multiple lines of the following warning being printed:

/usr/local/lib/python3.12/multiprocessing/popen_fork.py:66: DeprecationWarning: This process (pid=8) is multi-threaded, use of fork() may lead to deadlocks in the child.
#13 2.534   self.pid = os.fork()

This started with OpenVINO version 2025.0.0 and was not yet the case with version 2024.6.0.

I'm unsure if this is a problem, but I thought at least reporting it might be a good idea.

Here is a minimal example to reproduce the warning (and the difference between the two versions):

FROM python:3.12.7

RUN apt-get update && apt-get install -y libgl1-mesa-glx

RUN pip install --no-cache-dir --upgrade numpy==1.26.4 tensorflow==2.18.0

RUN echo 'import keras\n\
import openvino as ov\n\
base = keras.applications.ResNet50(input_shape=(224, 224, 3), weights="imagenet", include_top=True)\n\
image_input = keras.layers.Input(shape=(224, 224, 3), name="input_layer")\n\
ov_model = ov.convert_model(keras.Model(inputs=image_input, outputs=base(image_input), name="image_model"))' >> main.py

ADD "https://www.random.org/cgi-bin/randbyte?nbytes=10&format=h" skipcache

RUN pip install --no-cache-dir openvino==2024.6.0
RUN python main.py

RUN pip install --no-cache-dir openvino==2025.0.0
RUN python main.py

Command:

docker build --rm --progress=plain .
@mlukasze
Copy link
Contributor

we are aware of the problem and solution is under development
#28905

@mlukasze mlukasze added category: Python API OpenVINO Python bindings priority: high High piority labels Feb 12, 2025
@mlukasze mlukasze added this to the 2025.1 milestone Feb 12, 2025
@Dobiasd
Copy link
Author

Dobiasd commented Feb 12, 2025

Ah, great. Thanks a lot! 👍

@andrei-kochin andrei-kochin removed their assignment Feb 12, 2025
@avitial avitial added the bug Something isn't working label Feb 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working category: Python API OpenVINO Python bindings priority: high High piority
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants