ErrorNotInitailized

Mar 11, 2013 at 8:35 PM
I reinstalled Cudafy and when I brought the dll file into my project and imported Cudafy, Cudafy.Host, and Cudafy.Translator, I wrote the line (in Visual Basic.NET):

Dim km As CudafyModule = CudafyTranslator.Cudafy()

And I got back the following message:

ErrorNotInitialized

This sub was put in above it:

Sub New()
    ' This call is required by the designer.
    InitializeComponent()

    ' Add any initialization after the InitializeComponent() call.
End Sub

So it looks like it should be initialized. Does anyone know what's going on?
Coordinator
Mar 21, 2013 at 10:49 AM
The .NET call to InitializeComponent has nothing to do with CUDA. The error you have is from CUDA via CUDAfy. However I am very surprised if you got this call from the call to Cudafy( ).
There can be issues when you have your code to be initialized within a Form. Can you retry your code from a simple console application, perhaps a VB port of one of the example projects?
Mar 21, 2013 at 9:07 PM
It turns out it was actually this line that was giving me the ErrorNotInitialized:

Dim gpu As GPGPU = CudafyHost.GetDevice(CudafyModes.Target)

It gave it to me in a console application as well. Could this mean the GPU driver is not working properly?
Mar 21, 2013 at 9:46 PM
The case is now closed. Somehow the driver got uninstalled and I reinstalled it and the error went away.
Sep 18, 2013 at 1:21 AM
which driver got uninstalled?
Any idea how that would happen?
Did you need to reinstall Cudafy completely?
I am getting the same error.
Coordinator
Sep 18, 2013 at 7:14 AM
Not re-install Cudafy, but re-install the NVIDIA driver. Make sure that your GPU actually shows up correctly. Can also try re-boot.
Sep 18, 2013 at 10:47 AM
Edited Sep 18, 2013 at 11:34 AM
I've downloaded the latest Nvidia driver from their website, and used their installer. I'm now on 320.49, and then rebooted.
I still get the same error.
Any other ideas? Does it link to the nvidia drivers directly somewhere in the code? Can I manually update it?
How do I make sure that my "GPU shows up correctly"?
Coordinator
Sep 18, 2013 at 2:07 PM
You don't happen to be using a laptop with dual graphics? It could be that Optimus is turning off the GPU or not using it for Visual Studio. If so then you may need to explicitly set that Visual Studio uses the NVIDIA GPU.
Sep 18, 2013 at 9:30 PM
no, it's a single GPU pc.
Are there some controls I should check somewhere anyhow?



Sep 20, 2013 at 10:51 PM
after upgrading to cudafy v1.26, re-installing nvidia graphics card drivers, and re-installing the nvidia CUDA SDK, this now works.

Unfortunately I do not know which one of those fixed the problem.