Desktop GPU encoding using gstreamer in WINDOWS - windows

I have developed the gstreamer GPU encoding on Nvidia Jetson Tx2. but now i am
trying for Desktop Nvidia GPU encoding using gstreamer.
I am not able get "omxh264enc" in the listed supported elements using
"gst-inspect-1.0.exe".
so, i want to do hardware encoding on* desktop GPU* using Gstreamer.
Kindly guide me in right direction, or any sample command line or program
for desktop gpu supported encoding.
Note: i am trying on laptop gpu + visual studio 2015
Regards,
adi

Depends on your GPU hardware. There is nvenc for NVIDIA and msdk for Intel at least. It may be that you have to build these elements yourself as they require proprietary libraries from 3rd party vendors that GStreamer can't redistribute. There is no omx on PC, that one is used for embedded devices primarily.

Related

SyCL ComputeCpp: issues with the matrix_multiply SDK example

I just managed to install successfully the SyCL ComputeCpp + OpenCL (from CUDA) and running cmake to generate the samples VS2019 sln, successfully.
I've tried to run the matrix_multiply example ONLY, for now.
It ran successfully using the Intel FPGA emulator as a default device.
Changing the devices to the Device CPU worked well as well.
Choosing the host device, took ages without exiting.
When I tried to change the device to the nVidia, the GeForce GTX 1650 Ti.
I got this expection error from there ComputeCpp:RT0100, etc etc.
Googling a bit, I found I'd probably have to output the PTX instead of the SPIR.
So I regenerated the sln using -DCOMPUTECPP_BITCODE=ptx64
After doing that, the kernel ran successfully on the nVidia GPU.
My first question is: is that needed since nVidia does NOT support spir yet at the time of this writing, but only PTX?
However this broke the other devices, which are now reporting:
[ComputeCpp:RT0107] Failed to create program from binary
This happens now for all devices: Intel GPU, Device CPU, Device FPGA (While were formerly working)
Inspecting the .sycl I found now SYCL_matrix_multiply_cpp_bin_nvptx64[].
My question is: how to support nVidia with ptx and "normal" devices with spir altogether in the same exe? I did a menĂ¹ from which the user can choose to play with, but now it's working only for nVidia.
What am I doing wrong, please?
I would expect to be able to run the same .sycl code for all the devices despite it contains ptx or spir. How to manage for that?
EDIT: I just tried to retarget the bitcode to spirv64, since the computecpp_info told me all my devices are supposed to support it.
However, now no device is anymore working with that setting :-(

NvAPI on Kepler 20 card

I'm trying to use NVAPI to get GPU information.
But NvAPI fails to return the data on K20c with NVIDIA_DEVICE_NOT_FOUND
I'm using Windows Server 2012 & the display is driven by Onboard chip.
Is NvApi supported on K20 cards?
Please guide
Usually this is due to the wrong driver being loaded (nouveau instead of nvidia - you can check it with lsmod). Other option is to download and install up-to-date drivers from NVidia.
The command nvidia-smi should work at least and report GPU information.
K20c cards are supported by NVML interface provided Nvidia
https://developer.nvidia.com/nvidia-management-library-nvml
This Library provides the monitoring & managing information.

Offline compilation for AMD and NVIDIA OpenCL Kernels without cards installed

I was trying to figure out a way to perform offline compilation of OpenCL kernels without installing Graphics cards. I have installed the SDK's.
Does anyone has any experience with compiling OpenCL Kernels without having the graphics cards installed for both any one of them NVIDIA or AMD.
I had asked a similar question on AMD forums
(http://devgurus.amd.com/message/1284379).
NVIDIA forums for long are in accessible so couldn't get any help from there.
Thanks
AMD has an OpenCL extension for compiling binaries for devices that are not present on the system. The extension is called cl_amd_offline_devices. Pass the property CL_CONTEXT_OFFLINE_DEVICES_AMD when creating a context and all of AMDs supported devices are reported and can be used to create binaries as if they were present on the system.
Check out their OpenCL programming guide at http://developer.amd.com/tools/hc/AMDAPPSDK/assets/AMD_Accelerated_Parallel_Processing_OpenCL_Programming_Guide.pdf for more info
No need to graphic card, you can compile OpenCL programs for CPU too. If you have Intel or AMD CPU this idea works. Download latest OpenCL SDK from corresponding manufacturer website and compile OpenCL program:
Intel OpenCL SDK
AMD APP

OpenCV 2.3 (C++,QtGui), Problem Initializing some specific USB Devices and Setups

I'm playing around with OpenCV since a while and I found some strange behavior of some specific capturing devices (PS3 Eye, Logitech C940, iSight) even on different Platforms.
Using OpenCV in Windows: All cams mentioned above work well. But when I want to use 2 cams and therefore create a second capture it will depend on the devices that I use in my Dual Cam Setup.
PS3 Eye + C940: no problems
2x C940: no problems
2x PS3 Eye: No chance, only the specific device that was connected first will initialize. The other PS3 Eye cannot be used the same time...No error events and no information about the problem is shown.
Now using OpenCV in MacOSX 10.7 (same for 10.6.x) there's different problems using the same devices and even the same QtGui-Application with 2 independent GLWidgets for displaying cv output in the QtGui.
Every Setup is great as long as it doesn't use a PS Eye in Mac OS. I tried macam and several other tools, but I just cannot get OpenCV to init this cam in OSX (I bought 3 for my project so hardware probs not very likely).
I'm still wondering where the problem is...Maybe 2 PS Eye's would work in OSX if a single one did? I can't tell.
I can even capture from 2x Logitech FULL HD Webcams simultaniously with nice performance.
Any Idea where Limitation could be with Dual PS Eye in Windows? Perhaps USB? And why can't OpenCV in OSX Capture from PSEye but macam can access the cam?
I just want to understand what's happening. Perhaps anyone of you found a way to use at least a singe PS Eye in OSX? Or is this just not possible? Can't opencv somehow use the macam component?
Video capturing is very platform-dependent area. So difference between Windows and OS X is rather expected than wondering. OpenCV utilizes a lot of video capturing APIs to support as many device models as possible. At the moment (OpenCV 2.3.1) it uses following libs/APIs on the back-end:
Windows:
DirectShow (thought VideoInput library)
Microsoft's Video for Windows (VfW) API
CMU 1394 Digital Camera Driver
Matrox Imaging Library (MIL) (opt)
OpenNI camera drivers (opt)
XIMEA API for XIMEA devices (opt)
Linux:
libdc1394 (API v1 or API v2) - IIDC standard compliant cameras (opt)
PvAPI for Prosilica GigE Vision cameras (opt)
unicap - The uniform API for image acquisition devices (opt)
video4linux (V4L or V4L2) (opt)
OpenNI camera drivers (for Kinect) (opt)
XINE (opt)
XIMEA API for XIMEA devices (opt)
OS X:
QuickTime (opt)
QTKit (if no QuickTime, these two are mutually exclusive in OpenCV)
OpenNI camera drivers (opt)
XIMEA API for XIMEA devices (opt)
Android:
builtin Android camera
* (opt) - these interfaces are optional - can be turned on or off during the OpenCV build and may require some additional SDK.
About PS3 Eye - on Windows, it is most probably some limitation of VideoInput library or installed driver. On OS X - first, ensure that your OpenCV is built with QuickTime support. And second, ensure that macam.component is correctly installed into the QuickTime. Here is a quote from their FAQ:
Why can't I use my webcam with other applications?
You can. Please copy the macam.component into the
/Library/QuickTime/ directory (for access by all users on the system)
or into the ~/Library/QuickTime/ (for access by only that user). If
you have a previous copy, please delete it first. A restart is usually
not needed, but if you have trouble, it's a good thing to try. To
verify that your installation works, test with a simple program such
as HackTVCarbon, VideoViewer, or BTV.

ATI Stream SDK on ubuntu 9.04

I have used ATI Stream SDK on windows XP SP3 and implemented one algorithm on GPU. But Now I am interested in scaling this algorithm on multiple GPUs on mutiple machines I switched to UBUNTU to use MPI ( To send messages ).
I googled this but I got references for installation on SLES and RHEL but I am looking for UBUNTU 9.04.
Thanks
GG
AMD is switching to OpenCL based API soon. May be it will be worthwhile holding your horses till the OpenCL API stabilizes. Cuda is far ahead of the curve in terms of GPU usability, there is a nice project called MAGMA which is bringing together the LAPACK library for joint CPU-GPU usage.
I know of people who are using the ATI Stream SDK and ACML-GPU on Ubuntu without any special problems -- that is, no problems that they wouldn't have on any other Linux distro.
If you can get the Catalyst drivers installed correctly (which in this case will probably mean compiling your kernel modules) and your X windows configured correctly (especially DRI module, and there are security issues if you want Stream to work with remote access) it should work.
I'm tempted to ask/comment how you plan to share GPUs between multiple MPI processes, but that's probably wandering off-topic.

Resources