Where to find cuda.rule files for cuda 4.1 - c++

I am a beginner in CUDA,I am trying to run the examples given in GPU Computing SDK but it is giving me following error.
File: C:\NVIDIA Corporation\NVIDIA GPU Computing SDK 4.1\C\src\vectorAdd\vectorAdd_vs2008.vcproj
Line: 22
Column: 4
Error Message:
Custom build rules file 'C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\VCProjectDefaults\NvCudaRuntimeApi.rules' was not found or failed to load.
The file 'C:\NVIDIA Corporation\NVIDIA GPU Computing SDK 4.1\C\src\vectorAdd\vectorAdd_vs2008.vcproj' has failed to load.
Can anybody please tell what m i missing and where can I get this rules file as I am not able to find it in SDK.
Thanks,Any suggestion will be very helpful.

Have you installed the CUDA Toolkit? The "SDK" is basically a set of examples, you will need the Toolkit as well since it includes the compiler itself.
When you install the CUDA Toolkit (available here) it will install the NvCudaRuntimeApi.rules into the Visual Studio directory. If for any reason it cannot find Visual Studio (you install VS after CUDA, for instance), you can find the rules file in \extras\visual_studio_integration\rules.
Once you've installed the Toolkit and got the SDK samples working, check out this post for how to get started with your own project (or this post for VS2010).

Related

How do I solve the Visual studio 2019 'invalid profile ms_6_5' error when building a solution?

Specs are Window 10 Pro, VS 2019.16.8.3, MS DX12 shader samples.
I installed VS2019 just for this project to migrate my shader efforts into.
1>D3D12MeshletGenerator.cpp
3>dxc failed : Unknown argument: '-Qembed_debug'
2>FXC : error : invalid profile ms_6_5
This:
D3D12_FEATURE_DATA_D3D12_OPTIONS7 comes up undefined in the cpp source file.
What is odd is I was getting file extraction errors in the standard explorer zip extraction but not in 7zip. In both cases this profile error comes and I am not sure how to fix.
I am looking at this in two ways:
Are there problems with the source files or am I missing something in the VS profile area of Visual Studio configuration or usage experience?
I hope I have included everything to make this request clear and enable expeditious recovery.
Thank you in advance.
You need to install the Windows 10 SDK (19041).
D3D12_FEATURE_DATA_D3D12_OPTIONS7 was added to d3d12.h for this release.
The DXIL Compiler (DXC.EXE which unfortunately Visual Studio still calls 'FXC' in the output) was updated to support amplification & mesh shaders,
To install the new SDK you need to run the Visual Studio Installer and then select the optional component Windows 10 SDK (19041).
For reasons I'm not privy to, it only shows up under the UWP workload and in individual components. It's not visible under the "Game Development for C++" or "Desktop development with C++".

Build OpenCascade for VS2017

Usecase: I intend to use the OpenCascade C++ library in my C++ project. I need to do simple polyline offsetting and polygon scaling down.
So I am attempting to install the OpenCascade C++ library on my Windows 10 64bit machine to use in Visual Studio 17. My first attempt was to use the windows installer then run the batch files (env.bat, custom.bat). But I have read on this forum that the windows installer wont work for Visual Studio 2017 - is that correct?
So I have now followed the build instructions here. And now I have opened the sample projects in Visual Studio 2017. When I try to build the project I get the following errors for each of the sample projects:
Error MSB8036 The Windows SDK version 8.1 was not found. Install the required version of Windows SDK or change the SDK version in the project property pages or by right-clicking the solution and selecting "Retarget solution". TKQADraw C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Platforms\x64\PlatformToolsets\v141\Toolset.targets 36
Any advice on what I have done wrong? Maybe I didn't build it properly following these steps? Also, given my usecase above, do I need to do all this if I just want to use OpenCascade in a limited way?
Is there documentation or a link on how I create a new Visual Studio C++ project and link all the OpenCascade libraries?
As the error says, you haven't installed the correct SDK version, or maybe the version you installed is out dated. Check the SDK install and try again.

Visual Studio 2013 OpenCL header file not found error [duplicate]

I am currently using Intel's OpenCL SDK platform for heterogeneous parallel programming (OpenCL). I am using Visual Studio 2010 Ultimate for this. My system doesn't have any GPU in it. I have worked on CUDA SDK platform for opencl programming. This the first time I am using Intel's OpenCL SDK for opencl programming.
I have tried some basic platform, device, context identifying/creating/defining codes from 'OpenCL in Action' book. They all worked fine. So we can consider that visual studio is properly configured.
Now, I am trying to build a 'Hello World' program in visual studio which gives me following error:
Error MSB3721: The command ""C:\Program Files (x86)\Intel\OpenCL SDK\3.0\bin\x86\ioc32.exe" -cmd=build -input="E:\Menu\Google\programs\1code\feb\10feb2014\OpenCL\OpenCL\hello.cl" -output="Debug\hello.out" -VS -device=CPU -simd=default -bo=" "" exited with code -1073741511. C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\BuildCustomizations\IntelOpenCL.targetS
Now my questions are:
What is the significance of this 'Error MSB3721'?
Is this a programming related error or something is wrong with the 'OpenCL + Visual Studio' configuration?
I am trying to be as specific as possible in this question. Let me know if I have not providing enough information and help me out. I really appreciate your concern.
I don't know what it is, but i had the same problem when there was some *.cl file in my project. Just remove it from project (not from disk)! Anyway you will be able to read your source from this *.cl file, but when this file presents in project it causes en error. I don't know why.
I think the cause of the error is Intel codebuilder configuration or infinite loop in .cl file.
Please check if your error can be resolved by below two changes.
If you build your project as the Codebuilder project (e.g. Empty Opencl Project for Windows),
1-1. Right click your project and select properties
1-2. Select OpenCL Code Builder tab
1-3. If your device is configured as Intel(R) CPU (-device=CPU), then change it to your GPU device (e.g. Intel(R) Graphics (-device=GPU) in my case)
If you face the same error, then check if your .cl file contains the infinite loop such as while(1) or for(;;)
I've got the same error. Changing solution platform from x32 to x64 fixed it (I've got x64 machine).

Installing OpenCV 2.4.10 on Windows 8.1 with VS 2013

I am trying to install opencv 2.4.10 on Windows 8.1. Normally I install OpenCV without any third party libraries but this time I am trying to install some libraries like CStripes, Eigen, OpenExr, CUDA 6.5, AMD Blas and Fft.
I am using Visual Studio 2013 64-bit. OpenCV installation without any third party library completes without any issues but with 3rd party libraries it is unsuccessful. I was following the installation procedure given here.
The issue that I noticed is that during the installation the system cannot find the .lib and .dll files e.g.
LINK : fatal error LNK1181: cannot open input file '..\..\lib\Release\opencv_contrib2410.lib'
file INSTALL cannot find "E:/opencv/build/bin/Release/opencv_gpu2410.dll".
I ran the installation as an admin but I was still getting the same errors.
You can view the Visual Studio build log here and Cmake build log here.
Please help me out.
Search for "Error" in the Visual Studio logs. There is clearly a CUDA error being thrown:
E:/opencv/sources/modules/gpu/src/nvidia/core/NCV.cu(356): error : namespace "std" has no member "max"
It seems as though you need to add #include <algorithm> for this to work (as suggested here).
I would also suggest that you raise this as a bug on the OpenCV tracker!

Intel OpenCL SDK - where are the header files?

I'm trying to use OpenCL on my ultrabook with Iris graphics, therefore I've installed the Intel OpenCL SDK 2013 (the one from here: http://software.intel.com/en-us/vcsource/tools/opencl-sdk).
Trying to do something with it, however I fail to find the directory where the header file (CL/cl.h) is stored... there's no include subdirectory in the install location, and also no headers in the Visual Studio / SDK folders... a search for cl.h on my C: drive also didn't give any results.
What am I doing wrong? Do I have to install anything else to get the headers?
I've only used the AMD OpenCL SDK before, there the headers are neatly located in an include subdirectory of the installation folder...
Turns out the installer didn't run through properly. The last page looked inconspicous and had a nice Finish button, but only the Runtime got installed, but not the Application SDK. The Installer says something like "Installation ended prematurely because of an error" (no more specific information as to what error it was that had occured).
The reason is that the Installer doesn't seem to like my Visual C++ 2010 Express Edition.
Deactivating the "Visual Studio (2010) integration" made the installation be successful, and made the includes turn up.
For me, it's under:
C:\Program Files (x86)\Intel\OpenCL SDK\<version>\include\CL\cl.h
Are you sure the installation was completed successfully? Do you have a bin folder under the OpenCL SDK folder?
For the current version of the SDK, it is at:
C:\Program Files (x86)\IntelSWTools\system_studio_2020\OpenCL\sdk\include
As installed by intel_sdk_for_opencl_applications_2020.3.494.zip downloaded from https://software.intel.com/content/www/us/en/develop/tools/opencl-sdk.html