Cannot successfully run mxnet in R on windows - r

I've spent all day trying to figure out how to work mxnet GPU in R on windows. The package installs fine, but on library(mxnet) I get an error:
Error: package or namespace load failed for ‘mxnet’:
.onLoad failed in loadNamespace() for 'mxnet', details:
call: inDL(x, as.logical(local), as.logical(now), ...)
error: unable to load shared object 'C:/Users/Po/Documents/R/win-library/3.4/mxnet/libs/x64/libmxnet.dll':
LoadLibrary failure: The specified module could not be found.
Really been taken for a ride with all the 'help' topics. This seems to be a common issue but not widely applicable solution. I've downloaded and updated: CUDA, CUDAnn, NVIDIA drivers, OpenBLAS, cmake, opencv, MS visual studio, git, mlbench, mingw, MS visual cpp community.... the list goes on.
Some solutions say building and compiling is a work around, but frankly building and compiling is so far out of scope I've had to download half dozen programs just to be left with instructions "Use CMake to create a Visual Studio solution in ./build." What does that even mean.
I have checked the directory and am sure libmxnet.dll exists. I feel like I am missing something obvious.

I will help you resolve this.
I have checked the directory and am sure libmxnet.dll exists. I feel like
I am missing something obvious.
if libmxnet.dll exists, and yet we get the missing module error, it means one or more DLLs on which libmxnet.dll depends is missing.
Can you please download Process Monitor from "https://live.sysinternals.com/Procmon.exe" and capture file system activity.
The instructions are
Download "https://live.sysinternals.com/Procmon.exe"
Start "Procmon.exe"
Click Ctrl + L to bring filter UI
Choose "Path" , "ends with", ".dll" then "include" filter from
"Display entries matching these conditions"
Click ok. We have configured Procmon to monitor DLL activity
Now try to reproduce the issue which leads to missing module error
From Process Monitor, Choose File | Save option ( or press Ctrl + S )
Ensure that "native process monitor format (PML)" is chosen
Ensure events displayed using current filter is chosen
Generate the PML file.
Mail the PML file to me at eftiquar#gmail.com

To build and install MXNet yourself, you need the following dependencies. Install the required dependencies:
If [Microsoft Visual Studio 2017(https://www.visualstudio.com/thank-you-downloading-visual-studio/?sku=Community&rel=15) is not already installed, download and install it. You can download and install the free community edition.
Download and Install CMake GUI version if it is not already installed.
Download and install OpenCV.
Unzip the OpenCV package.
Set the environment variable "OpenCV_DIR" to the value "OpenCV build directory".
If you don't have the Intel Math Kernel Library (MKL) installed, download and install OpenBlas.
Set the environment variable "OpenBLAS_HOME" to point to the "OpenBLAS" directory that contains the "include" and "lib" directories. Typically, you can find the directory in "C:\Program files (x86)\OpenBLAS\".
Download and install CuDNN. To get access to the download link, register as an NVIDIA community user.
After you have installed all of the required dependencies, build the MXNet source code:
Download the MXNet source code from GitHub.
Open native tools command prompt for Visual Studio 2017( choose x64 or x86 native as required)
Start CMake GUI tool installed previously, from within this command prompt
In the CMake tool UI, "Browse Source" button and navigate to folder where MXNet source is downloaded. For example -"/GitHub/incubator-mxnet"
Create a folder under "/GitHub/incubator-mxnet", say releasex64
Click "Browse Build.." and choose folder created above
Click "Configure" button, a dialog prompt appears for choosing generator
Choose appropriate generator, for example Visual Studio 2017 Win64, if building for x64
Retain "use default native compilers" option
Click Finish
Click "Open Project" to open the generated project in Visual Studio IDE
Choose "ALL_BUILD" and build the configuration that you want to build
Find libmxnet.dll under the folder created in step 5 above for example "\GitHub\incubator-mxnet\releasex64\Debug\libmxnet.dll"

Related

How can I open edumips.jar?

I want to run edumips.jar. Whenever I try to open, Java control panel is opened.
When I execute:
strong text
It is first time to download java and excecute .jar file.
What I want:
Please tell me what I'm doing wrong...
UPDATE: there is now an MSI installer for EduMIPS64 which allows you to install and run the simulator without worrying about installing a JRE and configuring it: https://github.com/EduMIPS64/edumips64/releases/download/v1.2.8/EduMIPS64-1.2.8.msi (version 1.2.8 was released at the time of updating this answer, there might be more recent ones).
You need to make sure the Java runtime is associated with the .jar extension to open it with double-click.
To open it once, try right-clicking on the JAR file select Open With... and find the Java runtime binary (it's "OpenJDK Platform Binary" on my Windows machine).
You may also be able to fix this by re-installing the Java Runtime (JRE): usually installers associate .jar files to the Java binary automatically.
Worst case, if Java is installed and the PATH is set up correctly, you can run it from the command line by using the command java -jar edumips64-1.2.6-standalone.jar.
To open the command line, press Win+x and choose Windows PowerShell. Your JAR might be in the Downloads directory so try java -jar Downloads\edumips64-1.2.6-standalone.jar.

Where does the Qt sqlite plugin look for extension libraries

I have made the appropriate modification as found in this thread to enable the Qt sqlite plugin to load extensions. However, when I run SELECT load_extension('spatialite_mod'), I now get the error The specified module could not be found
On a Windows Qt installation, where do I need to put the spatialite_mod.dll file so that it can be found a runtime? I have already tried putting it in the binary directory without any success.
This turned out to be a multi-part problem.
The answer to the original question is that Qt looks for the libraries in the working directory (QDir::currentPath()) and in the Windows PATH.
Part 1:
On Windows, the specified module could not be found error also can mean that one of mod_spatialite.dll dependencies was not found. In my case, I had forgotten to move these dependencies to the same directory as mod_spatialite.dll. They include:
libgcc_s_dw2-1.dll
libstdc++-6.dll
libsqlite3-0.dll
libxml2-2.dll
zlib1.dll
libfreexl-1.dll
libgeos_c-1.dll
libgeos-3-5-0.dll
libiconv-2.dll
liblzma-5.cll
libproj-9.dll
Part 2:
The libgcc_s_dw2-1.dll and libstdc++-6.dll libraries shipped with libspatialite do not work with Windows 10. Read more about this here and here. They would crash the program when loaded. The fix for me was to grab the same libraries from my Qt installation at C:\Qt\5.11.3\mingw53_32.

Cannot find c:\Users\qt\work\install\lib\Qt5Widgetsd.lib when compiling QtWebEngine examples

I downloaded Qt5.6 VS2013 32bit and try to run the official example of QtWebEngine.
I just followed the instruction but
When linking it gives out an error of
LNK1104 file not found c:\Users\qt\work\install\lib\Qt5Widgetsd.lib.
However, I have no idea of where this path c:\Users\qt\work\install\lib\ comes from.
I did text search in all directories of example folder and no hits other than generated files(makefiles and pdbs).
I also checked system environment variables but no hits.
Furthermore, I checked Qt Creator'r Projects panel and its Build Environment and still no hits.
Did I miss something?
P.S. this error was given out by linking DemoBrowser example of QtWebEngineWidgets pro
The link is generated by qmake when it generates the build scrip from the qt project file (*.pro). It is based from the qmake application path that is generaly installed together with the libraries (check you qt kit setup to change it if needed: Jst browse to qmake.exe application).
Then try regenerate the build script. It should fix the issue.
You may also have issue with installation not being in debug mode; you are trying to use Qt5Widgetsd.lib library instead of the non-debug one Qt5Widgets.lib

Creating Qt Statically "The system cannot find the specified file"

After running configure -static in C:\Qt\Qt5.1.0\Source, I ran mingw32-make. and I get this error (at the bottom of image).
System cannot find the specified file http://puu.sh/3tSh4.png
What files am I missing? I am using Qt 5.1.0, I have downloaded qt-everywhere-opensource-src-5.1.0-rc2.zip and extracted it into C:\Qt\Qt5.1.0\Source, Installed Perl64 in C:\Qt\Qt5.1.0\Source\, ran the prompt as admin, and I have followed this guide:
http://qt-project.org/doc/qt-4.8/deployment-windows.html#linking-the-application-to-the-static-version-of-qt
Building v8 needs python installed and in path make sure that you have it, see more information here especially the requirements to build Qt on windows.

Link error while building with command scons compiler=msvc

I am trying to build a program using the command scons compiler = msvc. During this action a link error appears: LNK1181: cannot open input file 'QtCore4.lib'. I have installed Qt for Windows from http://qt.nokia.com/downloads (the free version) and tried to find the requested lib file, but only found the same dll file.
Any advice on how to proceed would be most appreciated.
It seems I have built Ot using debug option. Without it creates all the necessary libraries.

Resources