-
-
Notifications
You must be signed in to change notification settings - Fork 24
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
Update or drop the activation script that sets CUDA_PATH
?
#206
Comments
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
Possible options:
|
If we drop the activation scripts, would it make sense to have some way to silence this CuPy warning about Can understand that warning in the general case. However for Conda packaging with a known layout, wonder if that warning is more confusing to users (and whether users setting it would cause hard to diagnose issues with Conda packages) |
We can certainly do that. (We can patch it here for v12, and upstream the patch for v13.) @kmaehashi Do I miss anything? |
FWIW Numba uses this trick to check for a Conda environment. Maybe CuPy could leverage similar logic? |
Oh we already have a detection mechanism via reading the json file shipped with the conda cupy package, so detecting whether inside a conda env is not a problem. |
(btw why wouldn't Numba just check if the env var |
The logic was added in PR ( numba/numba#4096 ). Though don't see a mention of this consideration If I had to guess, it is so that it will work even if the environment is not activated |
The warning in question is to notify users about (possibly) missing CUDA shared library installation on Windows. In conda environment this should not happen as dependencies are satisfied by the package manager. I think it's fine to disable this warning in conda environment. -> I've made a PR for this: #8051 Despite that, I guess it's better to avoid modifying |
@leofang encouraged me to comment here. What is the primary reason |
FWIW the warning referenced above was removed in CuPy 13 ( cupy/cupy#8076 ) Are there any other action items before making this change? |
Not trying to be noisy but wanted to capture more detail. Likewise, if another library built with CFFI bindings (or similar) relies on the environment variable |
Thanks all, the new build has the activation scripts purged. @mtjrider would it be possible if you retry your workflow with the latest |
Wonder if we should mark the previous CuPy 13.0.0 builds broken so that users only get packages without the activation script when installing CuPy 13.0.0 Edit: After offline discussion with @leofang and @mtjrider , we thought this would be a reasonable change. Filed issue ( #255 ) to track and document next steps |
Currently we point
CUDA_PATH
to the conda env prefixcupy-feedstock/recipe/activate.sh
Line 8 in 1788a9c
because we wanted to mimic a real CTK existing somewhere that's visible at run time to CuPy. The activation (deactivation) script is called when the conda env containing a CuPy package is activated (deactivated), during which
CUDA_PATH
is set (unset). However, this trick is only applicable to the "old" layout (pre-CUDA 12). For CUDA 12, this would likely not work very well. I think we'd need something likeexport CUDA_PATH=$CONDA_PREFIX/targets/${targetDir}
at least, for the new layout.Also, in the past I've occasionally heard complaints about us overwriting
CUDA_PATH
for users. It may prompt the consideration of dropping it all together. But unfortunately I do not have time to investigate the consequence of doing so.cc: @jakirkham @kmaehashi
The text was updated successfully, but these errors were encountered: