gpuR icon indicating copy to clipboard operation
gpuR copied to clipboard

NVIDIA GPU ViennaCL fatal error (Windows 10)

Open CodeSmith92 opened this issue 6 years ago • 10 comments

Hi,

I've been trying (and failing) to download gpuR from Rstudio. I have the most recent versions of R and R-tools. And I set the environmental variables as such:

Sys.setenv(OPENCL_LIB64 = "C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v10.0/lib/x64") Sys.setenv(OPENCL_INC = "C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v10.0/include") Sys.setenv(CUDA_HOME="C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v10.0") Sys.setenv(PATH=paste(Sys.getenv("PATH"), "C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v10.0/bin", sep = ":"))

However, I keep getting the following error message at the very end of the download:

Error: package or namespace load failed for 'gpuR': .onAttach failed in attachNamespace() for 'gpuR', details: call: initContexts() error: ViennaCL: FATAL ERROR: ViennaCL encountered an unknown OpenCL error. Most likely your OpenCL SDK or driver is not installed properly. In some cases, this error is due to an invalid global work size or several kernel compilation errors. If you think that this is a bug in ViennaCL, please report it at [email protected] and supply at least the following information:

  • Operating System
  • Which OpenCL implementation (AMD, NVIDIA, etc.)
  • ViennaCL version Many thanks in advance! Error: loading failed Execution halted *** arch - x64 Error: package or namespace load failed for 'gpuR': .onAttach failed in attachNamespace() for 'gpuR', details: call: initContexts() error: ViennaCL: FATAL ERROR: ViennaCL encountered an unknown OpenCL error. Most likely your OpenCL SDK or driver is not installed properly. In some cases, this error is due to an invalid global work size or several kernel compilation errors. If you think that this is a bug in ViennaCL, please report it at [email protected] and supply at least the following information:
  • Operating System
  • Which OpenCL implementation (AMD, NVIDIA, etc.)
  • ViennaCL version Many thanks in advance! Error: loading failed Execution halted ERROR: loading failed for 'i386', 'x64'
  • removing 'H:/My Documents/R/win-library/3.5/gpuR' In R CMD INSTALL Warning in install.packages : installation of package ‘gpuR’ had non-zero exit status

Do you have any idea what's going wrong here? From what I've checked, the SDK was properly downloaded, and the NVIDIA drivers are up to date. Is the CUDA_HOME variable maybe set improperly? Any help would be greatly appreciated!

Thank you!

CodeSmith92 avatar Dec 10 '18 06:12 CodeSmith92

Is this the CRAN release or the develop version from this repository?

cdeterman avatar Dec 10 '18 20:12 cdeterman

It's the CRAN release using install.packages('gpuR')

CodeSmith92 avatar Dec 10 '18 21:12 CodeSmith92

Please try installing the develop version with the following

devtools::install_github('cdeterman', ref = 'develop')

I have made some updates in this branch that may address the issue. I want to confirm if it is still a problem here. Thanks.

cdeterman avatar Dec 11 '18 17:12 cdeterman

I got the same error. Here's the end of the configuration output (please let me know if you need to see the whole output):

Rd warning: C:/Users/dcorrell/AppData/Local/Temp/RtmpSc5dzi/R.INSTALL1804790825f7/gpuR/man/pmax.Rd:21: file link 'pmax' in package 'base' does not exist and so has been treated as a topic Rd warning: C:/Users/dcorrell/AppData/Local/Temp/RtmpSc5dzi/R.INSTALL1804790825f7/gpuR/man/pmax.Rd:21: file link 'pmin' in package 'base' does not exist and so has been treated as a topic pmin.vclVector html
pocl_check html
print.gpuMatrix html
qr-methods html
qr.R-methods html
Rd warning: C:/Users/dcorrell/AppData/Local/Temp/RtmpSc5dzi/R.INSTALL1804790825f7/gpuR/man/qr.R-methods.Rd:26: file link 'qr.R' in package 'base' does not exist and so has been treated as a topic Rd warning: C:/Users/dcorrell/AppData/Local/Temp/RtmpSc5dzi/R.INSTALL1804790825f7/gpuR/man/qr.R-methods.Rd:26: file link 'qr.Q' in package 'base' does not exist and so has been treated as a topic setContext html
set_device_context html
setup_opencl html
solve-methods html
svd-methods html
synchronize html
t-methods html
typeof-gpuR-methods html
vclMatrix-class html
vclMatrix-crossprod html
vclMatrix-methods html
vclMatrix.colSums html
vclVector-class html
vclVector-methods html
zgpuMatrix-class html
zvclMatrix-class html
** building package indices ** installing vignettes ** testing if installed package can be loaded *** arch - i386 Error: package or namespace load failed for 'gpuR': .onAttach failed in attachNamespace() for 'gpuR', details: call: initContexts() error: ViennaCL: FATAL ERROR: ViennaCL encountered an unknown OpenCL error. Most likely your OpenCL SDK or driver is not installed properly. In some cases, this error is due to an invalid global work size or several kernel compilation errors. If you think that this is a bug in ViennaCL, please report it at [email protected] and supply at least the following information:

  • Operating System
  • Which OpenCL implementation (AMD, NVIDIA, etc.)
  • ViennaCL version Many thanks in advance! Error: loading failed Execution halted *** arch - x64 Error: package or namespace load failed for 'gpuR': .onAttach failed in attachNamespace() for 'gpuR', details: call: initContexts() error: ViennaCL: FATAL ERROR: ViennaCL encountered an unknown OpenCL error. Most likely your OpenCL SDK or driver is not installed properly. In some cases, this error is due to an invalid global work size or several kernel compilation errors. If you think that this is a bug in ViennaCL, please report it at [email protected] and supply at least the following information:
  • Operating System
  • Which OpenCL implementation (AMD, NVIDIA, etc.)
  • ViennaCL version Many thanks in advance! Error: loading failed Execution halted ERROR: loading failed for 'i386', 'x64'
  • removing 'H:/My Documents/R/win-library/3.5/gpuR' In R CMD INSTALL Error in i.p(...) : (converted from warning) installation of package ‘C:/Users/dcorrell/AppData/Local/Temp/Rtmp63f9Ev/file1db84d2342fe/gpuR_2.0.3.tar.gz’ had non-zero exit status In addition: Warning messages: 1: In untar2(tarfile, files, list, exdir) : skipping pax global extended headers 2: In untar2(tarfile, files, list, exdir) : skipping pax global extended headers

CodeSmith92 avatar Dec 12 '18 21:12 CodeSmith92

@SmittyD-92 what is your Windows 10 version? I wonder if this is related to the issue #144.

cdeterman avatar Dec 20 '18 16:12 cdeterman

I got the same error on Arch Linux, so it's probably not Windows-related. It went away when I installed all the NVidia and OpenCL packages on Arch. Here's the list; it's probably similar for other distros:

  clinfo \
  clpeak-git \
  compute-runtime-bin \
  cuda \
  cudnn \
  nvidia \
  nvidia-settings \
  opencl-headers \
  opencl-nvidia \
  pocl \

Notes:

  1. This is an HP Omen dual-booted Windows 10 Pro and Arch Linux. The GPU is an NVidia 1050Ti.
  2. compute-runtime-bin is the Intel OpenCL driver for the Intel GPU. So, including pocl I have three OpenCL devices in Arch.

znmeb avatar Dec 20 '18 18:12 znmeb

@SmittyD-92 did any of the information by @znmeb help? Is something perhaps missing in your installation?

cdeterman avatar Jan 10 '19 19:01 cdeterman

Similar issue here: I was able to install gpuR on one windows machine (windows 7) and one mac, but could not install on a second windows machine (windows 10, v1903, OS build 18362.657; NVIDIA Quadro P2000) from either CRAN or GitHub (devel version; not to nitpick, but the devtools code above is missing the repo). Messages:

Error: package or namespace load failed for 'gpuR': .onAttach failed in attachNamespace() for 'gpuR', details: call: initContexts() error: ViennaCL: FATAL ERROR: ViennaCL encountered an unknown OpenCL error. Most likely your OpenCL SDK or driver is not installed properly. In some cases, this error is due to an invalid global work size or several kernel compilation errors. If you think that this is a bug in ViennaCL, please report it at [email protected] and supply at least the following information:

  • Operating System
  • Which OpenCL implementation (AMD, NVIDIA, etc.)
  • ViennaCL version Many thanks in advance! Error: loading failed Execution halted ERROR: loading failed
  • removing 'C:/Users/godom/Documents/R/win-library/3.6/gpuR' Warning in install.packages : installation of package ‘gpuR’ had non-zero exit status

Per reading through Issue #49, I have Rtools 35 installed. I've installed the GitHub version of RViennaCL. I've re-installed both curl and httr.

As a note, I originally had R 3.6.1, and the package install wouldn't even get past the C++/Fortran message. After I upgraded to R 3.6.2, I was able to get past that issue to this ViennaCL one.

gabrielodom avatar Feb 27 '20 22:02 gabrielodom

Hi, I am encountering a similar error message while installation:


** installing vignettes
** testing if installed package can be loaded from temporary location
Error: package or namespace load failed for 'gpuR':
 .onAttach failed in attachNamespace() for 'gpuR', details:
  call: initContexts()
  error: ViennaCL: FATAL ERROR: ViennaCL encountered an unknown OpenCL error. Most likely your OpenCL SDK or driver is not installed properly. In some cases, this error is due to an invalid global work size or several kernel compilation errors.
If you think that this is a bug in ViennaCL, please report it at [email protected] and supply at least the following information:
 * Operating System
 * Which OpenCL implementation (AMD, NVIDIA, etc.)
 * ViennaCL version
Many thanks in advance!
Error: loading failed
Execution halted
ERROR: loading failed
* removing 'C:/Users/naman/OneDrive/Documents/R/win-library/3.6/gpuR'
Warning in install.packages :
  installation of package ‘gpuR’ had non-zero exit status
  • Operating System: Windows 10, 64-bit
  • Which OpenCL implementation: NVIDIA
  • ViennaCL version: 1.7.1

Any help would be much appreciated!

Additionally I was unable to install the git version of gpuR. Error in utils::download.file(url, path, method = method, quiet = quiet, : cannot open URL 'https://api.github.com/repos/cdeterman/gpuR/tarball/develop'

namanpaul avatar May 22 '20 22:05 namanpaul