[js/node] fix CUDA artifact installation script for Linux/x64 #22984
+38
−6
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Background: There is a max size limit for NPM package, so it is impossible to include CUDA binaries inside
onnxruntime-node
. I made the install script js/node/script/install.js for onnxruntime-node to allow users to download the CUDA binaries from github.Before 1.18.x, there are both onnxruntime-win-x64-gpu-1.18.0.zip and onnxruntime-win-x64-gpu-cuda12-1.18.0.zip in the github release assets, containing the CUDA v11 bits and CUDA v12 bits.
--onnxruntime-node-install-cuda[=v11]
will download filehttps://github.com/microsoft/onnxruntime/releases/download/v{VERSION}/onnxruntime-win-x64-gpu-{VERSION}.zip
--onnxruntime-node-install-cuda=v12
will download filehttps://github.com/microsoft/onnxruntime/releases/download/v{VERSION}/onnxruntime-win-x64-gpu-cuda12-{VERSION}.zip
Since 1.19.x, CUDA v12 became default and the
onnxruntime-win-x64-gpu-cuda12-{VERSION}.zip
is no longer provided in Github release assets.This PR updates installation script to fix it for CUDA v12. However, it may be difficult for CUDA v11 since the steps are quite complicated to automate. Added a few lines of instructions instead.
fixes #22877