Modifying RNN CuDNN example code to use CUDNN_DATA_INT8 - recurrent-neural-network

The RNN example (RNN_example.cu) that is in cudnn_samples_v7 is set up to use CUDNN_DATA_FLOAT. I'd like to modify it to use CUDNN_DATA_INT8. When I globally made this change, compiled and run, I get the following runtime errors:
$ ./RNN_int8 20 2 512 64 0
cuDNN Error: CUDNN_STATUS_NOT_SUPPORTED RNN_example_int8.cu 285
cuDNN Error: CUDNN_STATUS_NOT_SUPPORTED RNN_example_int8.cu 302
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 309
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 310
cuDNN Error: CUDNN_STATUS_NOT_SUPPORTED RNN_example_int8.cu 326
cuDNN Error: CUDNN_STATUS_NOT_SUPPORTED RNN_example_int8.cu 328
CUDA Error: out of memory RNN_example_int8.cu 330
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 373
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 402
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 373
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 402
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 373
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 402
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 373
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 402
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 482
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 516
cuDNN Error: CUDNN_STATUS_BAD_PARAM RNN_example_int8.cu 541
For example, the error at line 309 is running this code:
cudnnErrCheck(cudnnSetFilterNdDescriptor(wDesc, CUDNN_DATA_INT8, CUDNN_TENSOR_NCHW, 3, dimW));
I suspect the format type (CUDNN_TENSOR_HCHW) isn't correct for the data type - is that the correct hypothesis? If so, what format is needed here?

CuDNN currently doesn't support INT8 RNN, we suggest you use FP16 input output to achieve better performance than float. If you use Volta be sure to turn on CUDNN_TENSOR_OP_MATH to get hardware acceleration.
All supported config combinations of cuDNN RNN can be found here
https://docs.nvidia.com/deeplearning/sdk/cudnn-developer-guide/index.html#features-of-rnn-functions
Let us know if you have any other issues!

Related

how to fix Out of memory in wordpress

I experience a problem with memory limit in wordpress :
When I try to uplod an image, the site crashes and I find that in the logs :
[31-Oct-2020 16:28:45 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 65536 bytes) in /var/www/webroot/ROOT/wp-content/plugins/jetpack/class.jetpack-plan.php on line 233
[31-Oct-2020 16:28:45 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 65536 bytes) in /var/www/webroot/ROOT/wp-content/plugins/woocommerce/includes/admin/class-wc-admin-settings.php on line 54
[31-Oct-2020 16:28:45 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 65536 bytes) in /var/www/webroot/ROOT/wp-content/plugins/jetpack/class.jetpack-plan.php on line 233
[31-Oct-2020 16:28:52 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 20480 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/mo.php on line 323
[31-Oct-2020 16:28:52 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 135168 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/streams.php on line 118
[31-Oct-2020 16:28:57 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 4096 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/mo.php on line 315
[31-Oct-2020 16:28:57 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 135168 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/streams.php on line 118
[31-Oct-2020 16:28:59 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 20480 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/mo.php on line 323
[31-Oct-2020 16:28:59 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 135168 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/streams.php on line 118
[31-Oct-2020 16:29:04 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 20480 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/mo.php on line 323
[31-Oct-2020 16:29:04 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 135168 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/streams.php on line 118
I've put 1024 as max memory in php.ini, in .htaccess and wp-config. php info says that there is 1024 mb in max memory usage but the problem persists.
What can I do to fix that?

How to install R package "curl" on SUSE SLE if "recipe for target 'curl.so' failed

I'm trying to install curl (as sudoer), but I get this error.
> install.packages("curl", lib = .Library)
...
/usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/ld: cannot find -lcurl
collect2: error: ld returned 1 exit status
/usr/lib64/R/share/make/shlib.mk:6: recipe for target 'curl.so' failed
make: *** [curl.so] Error 1
ERROR: compilation failed for package ‘curl’
* removing ‘/usr/lib64/R/library/curl’
...
I'm working with a SUSE SLE 12.4
> cat /etc/SuSE-release
SUSE Linux Enterprise Server 12 (x86_64)
VERSION = 12
PATCHLEVEL = 4
Seems like it doesn't find ld
If you need other information, I would be more than happy to provide them.

Issues installing packages in R: "dyld: lazy symbol binding failed"

I'm trying to install tidyverse and tidycensus, among other packages, and I'm getting a similar error for all of them. I'm working on a Mac. I've tried installing the dependencies separately, but I get similar error. I've tried installing RTools, but that didn't change anything. I wish I could give more information, but I've never encountered an error like this.
Here's the code:
install.packages("tidyverse")
And here's the output:
also installing the dependency ‘broom’
There is a binary version available but the source version is later:
binary source needs_compilation
broom 0.5.6 0.7.0 FALSE
trying URL 'https://cran.rstudio.com/bin/macosx/contrib/4.0/tidyverse_1.3.0.tgz'
Content type 'application/x-gzip' length 432989 bytes (422 KB)
==================================================
downloaded 422 KB
The downloaded binary packages are in
/var/folders/6k/0tw5jym93c762cchf9bym93w0000gn/T//RtmpNdVhZw/downloaded_packages
installing the source package ‘broom’
trying URL 'https://cran.rstudio.com/src/contrib/broom_0.7.0.tar.gz'
Content type 'application/x-gzip' length 604195 bytes (590 KB)
==================================================
downloaded 590 KB
dyld: lazy symbol binding failed: Symbol not found: _utimensat
Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libR.dylib (which was built for Mac OS X 10.13)
Expected in: /usr/lib/libSystem.B.dylib
dyld: Symbol not found: _utimensat
Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libR.dylib (which was built for Mac OS X 10.13)
Expected in: /usr/lib/libSystem.B.dylib
/Library/Frameworks/R.framework/Resources/bin/INSTALL: line 34: 20265 Done echo 'tools:::.install_packages()'
20266 Abort trap: 6 | R_DEFAULT_PACKAGES= LC_COLLATE=C "${R_HOME}/bin/R" $myArgs --no-echo --args ${args}
Warning in install.packages :
installation of package ‘broom’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/6k/0tw5jym93c762cchf9bym93w0000gn/T/RtmpNdVhZw/downloaded_packages’

Installing TensorRT gives "Packages File not found" error

While installing TensorRT, the below error occurred. I have already installed cuda 9.0 and cudnn 7.0.5. How do I avoid this error?
Err:5 file:/var/cuda-repo-9-0-local Packages File not found - /var/cuda-repo-9-0-local/Packages (2: No such file or directory)

error duirng loading "xlsx" library in R

I got the following errors after installing and require the xlsx library in R:
> install.packages("xlsx")
trying URL 'http://cran.cnr.Berkeley.edu/bin/macosx/contrib/3.0/xlsx_0.5.5.tgz'
Content type 'application/x-gzip' length 395421 bytes (386 Kb)
opened URL
==================================================
downloaded 386 Kb
> require(xlsx)
Loading required package: xlsx
Error : .onAttach failed in attachNamespace() for 'xlsx', details:
call: .jnew("org/apache/poi/xssf/usermodel/XSSFWorkbook")
error: java.lang.NoClassDefFoundError: org/apache/xmlbeans/XmlObject
Tried and hunted around and can't figure out the problem. Does anyone know what the problem is?
The xlsx package doesn't support the latest Mac R version 3.01 & 3.02 but it works well under R 3.0. Use gdata::read.xls is recommended if so.

Resources