Is xvfb (with Mesa 19.2) compatible with Vulkan? - vulkan

I'm trying to run a Vulkan-based graphical application on a headless Ubuntu 19.10 virtual machine, via xvfb.
Starting from a bare Ubuntu 19.10 image (created using lxc), I prep the machine as follows:
> sudo apt update
> sudo apt install -y xvfb mesa-vulkan-drivers vulkan-tools
I then run the following two commands:
In Terminal 1: Start XVFB
Xvfb :1 -screen 0 1024x768x24
In Terminal 2: Run vulkaninfo
> DISPLAY=:1 vulkaninfo
==========
VULKANINFO
==========
Vulkan Instance Version: 1.1.114
/build/vulkan-tools-IZAxVX/vulkan-tools-1.1.114.0+dfsg1/vulkaninfo/vulkaninfo.c:5884:
failed with VK_ERROR_INITIALIZATION_FAILED
(Running my own custom Vulkan application yields a similar failure.)
From what I understand, Xvfb depends on mesa, and I'm using Mesa 19.2.1
And, based on the Mesa 19.2.1 release notes, it is supposed to support Vulkan:
"Mesa 19.2.1 implements the Vulkan 1.1 API, but the version reported by the apiVersion property of the VkPhysicalDeviceProperties struct depends on the particular driver being used."
Question: Is it reasonable to expect that vulkan apps would work with xvfb on Ubuntu 19.10, especially since the latest mesa releases claim to support Vulkan?
Versions of relevant some packages that I'm using:
> apt-cache show xvfb | grep Version
Version: 2:1.20.5+git20191008-0ubuntu1
> apt-cache show mesa-vulkan-drivers | grep Version
Version: 19.2.1-1ubuntu1
> apt-cache show libvulkan1 | grep Version
Version: 1.1.114.0-1
> apt-cache show vulkan-tools | grep Version
Version: 1.1.114.0+dfsg1-1

Related

PackagesNotFoundError When Trying to Install intel_extension_for_pytorch

I am trying to conda install intel_extension_for_pytorch but I keep getting the following error in the command line:
PackagesNotFoundError: The following packages are not available from current channels:
intel_extension_for_pytorch
this is the command that I am using
conda install intel_extension_for_pytorch
edit:
System Info:
Microsoft Windows [Version 10.0.19044.2006]
Processor 11th Gen Intel(R) Core(TM) i7-1185G7 # 3.00GHz, 2995 Mhz, 4 Core(s), 8 Logical Processor(s)
Currently, the Intel Extension for PyTorch is only supported by Linux OS. Try on a recent Linux version, it should work there.
Check out the docs for more info: https://www.intel.com/content/www/us/en/developer/tools/oneapi/extension-for-pytorch.html

Installing Rakudo on Android with ARM processor architecture

I am trying to install Rakudo on my Android with armv7l processor architecture using Termux.
I tried compiling from source, but it didn't work. Then someone pointed out the Termux user its-pointless and his package for this, but that package does not work on my phone.
How can I run Raku on my phone while it is offline? I'm open to solutions not using Termux.
Termux on SSH results:
u0_a74#localhost ~/rakudo [100]> pkg show rakudo -a
Package: rakudo Version: 2020.05 Maintainer: Termux members #termux
Installed-Size: 37.7 MB Depends: moarvm Homepage: https://rakudo.org
Download-Size: 5062 kB APT-Manual-Installed: yes APT-Sources:
https://its-pointless.github.io/files/24 termux/extras arm Packages
Description: Perl 6 implementation on top of Moar virtual machine
Package: rakudo Version: 2020.01-1 Maintainer: Fredrik Fornwall
#fornwall Installed-Size: 93.1 MB Depends: moarvm Homepage:
https://rakudo.org Download-Size: 10.9 MB APT-Sources:
https://its-pointless.github.io/files/24 termux/extras arm Packages
Description: Perl 6 implementation on top of Moar virtual machine
u0_a74#localhost ~/rakudo> raku
CANNOT LINK EXECUTABLE "raku": cannot locate symbol "ffi_type_double"
referenced by "/data/data/com.termux/files/usr/lib/libmoar.so"...
u0_a74#localhost ~/rakudo> raku --version
CANNOT LINK EXECUTABLE "raku": cannot locate symbol "ffi_type_double"
referenced by "/data/data/com.termux/files/usr/lib/libmoar.so"...
u0_a74#localhost ~/rakudo> raku --help
CANNOT LINK EXECUTABLE "raku": cannot locate symbol "ffi_type_double"
referenced by "/data/data/com.termux/files/usr/lib/libmoar.so"...
u0_a74#localhost ~/rakudo> uname -a
Linux localhost 3.4.42-g3d041de #1 SMP PREEMPT Sat Dec 24 19:56:29 PST
2016 armv7l Android
Does it have to be on Termux? I have successfully installed Raku on Android via UserLand, using Debian SSH. sudo apt-get install rakudo works.

screen fails on NetBSD, reporting "poll: Invalid argument"

I have installed and used screen many times on several different operating systems. Recently I installed it on a NetBSD-8.0 virtual machine.
$ sudo pkgin install screen
calculating dependencies...done.
1 package to install:
screen-4.8.0nb1
0 to refresh, 0 to upgrade, 1 to install
0B to download, 1098K to install
proceed ? [Y/n] Y
installing screen-4.8.0nb1...
screen-4.8.0nb1: setting permissions on /usr/pkg/bin/screen-4.8.0 (o=root, g=wheel, m=4511)
screen-4.8.0nb1: adding /usr/pkg/bin/screen to /etc/shells
screen-4.8.0nb1: registering info file /usr/pkg/info/screen.info
===========================================================================
$NetBSD: MESSAGE,v 1.5 2005/12/28 17:53:24 reed Exp $
[snip]
===========================================================================
pkg_install warnings: 0, errors: 0
reading local summary...
processing local summary...
marking screen-4.8.0nb1 as non auto-removable
However, when I went to use it, I got an immediate failure.
$ uname -mrs
NetBSD 8.0 amd64
$ ls -l /usr/pkg/bin/screen
lrwxr-xr-x 1 root wheel 12 Apr 6 02:50 /usr/pkg/bin/screen -> screen-4.8.0
$ groups
users wheel
$ screen
poll: Invalid argument
This problem persists even when I first remove, then reinstall the screen package. Any suggestions as to what's wrong?
My guess is that the system used to build binary packages for 8.0 (as of the 8.0_2020Q1 pkgsrc release) is no longer quite compatible with the NetBSD-8.0 release. It is likely running on a newer release, inside a chroot(8) sandbox.
I would recommend using NetBSD-9.0 instead, as that is the latest NetBSD release, or NetBSD-8.2, as that is the latest release in the netbsd-8 branch. Using the latest NetBSD and pkgsrc releases provides better coverage against unpatched vulnerabilities.
However, if you want to keep using NetBSD-8.0, you can get a working screen(1) from the 8.0_2019Q4 pkgsrc release. To have pkgin(1) pull from that release, edit the /usr/pkg/etc/pkgin/repositories.conf file to use this repository URL:
http://ftp.NetBSD.org/pub/pkgsrc/packages/NetBSD/amd64/8.0_2019Q4/All
There is currently likely just one line in the file that is not commented out, and it points to a URL with just 8.0 in it (which on the server is a symbolic link to the latest pkgsrc release). Just replace that line, or comment it out and add the above line.
Then remove and re-install screen:
sudo pkgin remove screen && sudo pkgin install screen

Ninja Build throw error

I am trying to do ninja build as below
gn gen PathToBinary --args='is_debug=false symbol_level=0 proprietary_codecs=true ffmpeg_branding="Chrome" use_cfi_diag=true enable_nacl=false treat_warnings_as_errors = true'
ninja -C PathToBinary path
It throw error as
[1/10551] ACTION //cc/proto:proto_internal_gen(//build/toolchain/linux:clang_x64)
FAILED: pyproto/cc/proto/memory_allocation_pb2.py gen/cc/proto/memory_allocation.pb.cc gen/cc/proto/memory_allocation.pb.h
python ../../tools/protoc_wrapper/protoc_wrapper.py --include cc/proto/cc_proto_export.h --protobuf gen/cc/proto/memory_allocation.pb.h --proto-in-dir ../../cc/proto --proto-in-file memory_allocation.proto --use-system-protobuf=0 -- ./protoc --cpp_out dllexport_decl=CC_PROTO_EXPORT:gen/cc/proto --python_out pyproto/cc/proto
./protoc: /usr/lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by ./protoc)
./protoc: /usr/lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.20' not found (required by ./protoc)
please help to fix thanks.
OS Details
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 14.04.5 LTS
Release: 14.04
Codename: trusty

Command to get sm version of gpu in current machine

Is there a command to get the sm version of the gpu in given machine. Here is my use case: I build and run same cuda kernel on multiple machines. So I was wondering if there is a command which can detect sm version of gpu on the given system and pass that as arguement to nvcc:
$ nvcc -arch=`gpuarch -device 0` mykernel.cu
I found https://gist.github.com/f0k/63a664160d016a491b2cbea15913d549. I find this is best solution. You just need python.