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

Lack of support for Windows/CUDA in Python 3.8 and 3.9 #5697

Closed
evrial opened this issue Nov 4, 2020 · 13 comments · Fixed by #5874 or #6436
Closed

Lack of support for Windows/CUDA in Python 3.8 and 3.9 #5697

evrial opened this issue Nov 4, 2020 · 13 comments · Fixed by #5874 or #6436
Labels
contributions welcome external contributions welcome feature request request for unsupported feature or enhancement

Comments

@evrial
Copy link

evrial commented Nov 4, 2020

I hate to say but Python 3.8 released on 27-Jan-2018, (nearly two years ago) still Microsoft didn't manage to make support. In my humble opinion thats pathetic. Would you guys please update us with your development progress on this path? Thanks and God bless you all and your families. I hope you have a peaceful President election. Please wear masks and stay safe.

@snnn snnn added api:Python feature request request for unsupported feature or enhancement labels Nov 4, 2020
@faxu
Copy link
Contributor

faxu commented Nov 6, 2020

Python 3.8 support is available for everything except Windows GPU and Linux ARM. Those will be added in the next release. What setup do you have?

@snnn
Copy link
Member

snnn commented Nov 6, 2020

There is a big incompatible change in python 3.8, we haven't find a way to solve it yet.

python/cpython@2438cdf
https://bugs.python.org/issue36085

@honglei
Copy link

honglei commented Nov 7, 2020

How about suppport on Python3.9? Python 3.9.0 is now available, and you can already test 3.10.0a1!

@snnn
Copy link
Member

snnn commented Nov 17, 2020

Sorry, it is not started yet.

@ivanst0
Copy link
Member

ivanst0 commented Nov 20, 2020

There are two distinct issues which probably won't be fixed at same time:

  1. Lack of support for Windows/CUDA in Python 3.8 (i.e. onnxruntime_gpu-*-cp38-cp38-win_amd64.whl not available on PyPI).
  2. Lack of support for Python 3.9 in general.

Could you please change the title of this issue to make it clear what it refers to and open a new issue for the other one (if there is no existing issue covering it)?

@evrial evrial changed the title Python 3.8 and newer Lack of support for Windows/CUDA in Python 3.8 and 3.9 Nov 20, 2020
@evrial
Copy link
Author

evrial commented Nov 20, 2020

Thanks for clarification, updated as you suggested. I wish the complete support of the recent Python will be a new norm with Guido in your team.

@ivanst0
Copy link
Member

ivanst0 commented Nov 26, 2020

@snnn, would it be possible to invoke os.add_dll_directory() (for Python 3.8 and newer) from __init__.py after finding CUDA location from environment variables? A robust implementation would also require exposing CUDA version to Python code.

Has anyone looked (or plans to look) at this?

@snnn snnn added the contributions welcome external contributions welcome label Nov 26, 2020
@snnn
Copy link
Member

snnn commented Nov 26, 2020

I don't have any good ideas. Welcome to contribute yours!

@evrial
Copy link
Author

evrial commented Nov 26, 2020

Maybe ask the user to put CUDA location in some config file as fallback if all else fails

@honglei
Copy link

honglei commented Nov 26, 2020

where nvcc

C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2\bin\nvcc.exe

nvcc -V

nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2019 NVIDIA Corporation
Built on Wed_Oct_23_19:32:27_Pacific_Daylight_Time_2019
Cuda compilation tools, release 10.2, V10.2.89

@ivanst0
Copy link
Member

ivanst0 commented Nov 26, 2020

OK, I'll try to come up with a fix.

@ivanst0
Copy link
Member

ivanst0 commented Nov 26, 2020

Here is a potential solution: #5956
Although it doesn't handle all CUDA versions, this might be already sufficient to enable Python 3.8 build in CI and publish a Windows version of onnxruntime-gpu package for Python 3.8.

@ivanst0
Copy link
Member

ivanst0 commented Nov 27, 2020

After PR #5956 onnxruntime-gpu package can be built for Python 3.8 and Python 3.9, so I think this issue can be closed now.

The remaining issues are tracked in
#5963 - onnxruntime-gpu package not available for Python 3.8 on Windows
#5962 - onnxruntime-gpu built for Python 3.8/Windows doesn't support CUDA versions other than 10.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contributions welcome external contributions welcome feature request request for unsupported feature or enhancement
Projects
None yet
5 participants