Notes: CUDA / OpenCL with Nvidia Optimus under Ubuntu 16.04

NVidia 375 once again changed how OpenCL programs on Ubuntu 16.04 need to be invocated.

  1. Do the bumblebee dance
  2. Check that /etc/OpenCL/vendors/nvidia.icd contains libnvidia-opencl.so.1
  3. Maybe link libOpenCL.so to the expected location to enable standard OpenCL programs like darktable: sudo ln -s /usr ...
Weiterlesen ...


Notes: CUDA / OpenCL with Nvidia Optimus under Ubuntu 15.04

After struggling for two days to get OpenCL and Cuda working on my new shiny Kubuntu 15.04 and none of the usual tricks working, here are my notes:

  1. Do the bumblebee dance
  2. Check that /etc/OpenCL/vendors/nvidia.icd contains libnvidia-opencl.so.1
  3. Maybe sudo ln -s /usr/lib ...
Weiterlesen ...


Making LibreOffice theme work in KDE / Plasma 5

So I made the switch to Kubuntu since they upgraded to KDE / Plasma 5 (which is really nice, btw) and noticed LibreOffice is almost unusable since the default KDE theme Breeze is not supported. Lo and behold, this is an issue since 2012: https://bugs.documentfoundation.org/show_bug.cgi?id ...

Weiterlesen ...


Let's share a secret!

Assume you have a secret that should only be revealed when several participants team up with their corresponding shares. Say, you have a CA certificate in a big company and you don't trust one person alone to behave themself.

Adi Shamir presented in "How to share a secret" a ...

Weiterlesen ...


Running Phabricator on uberspace

Phabricator is usually run on root servers, but with a few changes it will run on your uberspace domain just fine.

$ cd /var/www/virtual/$USER/
$ mkdir phabricator
$ cd phabricator
$ git clone git://github.com/facebook/libphutil.git
$ git clone git://github.com/facebook/arcanist.git
$ git clone git://github ...
Weiterlesen ...


Spatialite and SQLAlchemy

To be able to use Spatialite under SQLAlchemy (or GEOAlchemy), it must be loaded with every new connection to the DB. Since SQLAlchemy can and will tear down and create new connections to the DB at some time, we must register a hook that is invoked at connection creation time ...

Weiterlesen ...


Spatialite auf uberspace.de

Um Spatialite auf uberspace.de zu nutzen, reichen einige wenige Kommandos:

toast arm geos

lädt und kompiliert die Geometry Engine, und:

toast add http://download.osgeo.org/proj/proj-4.8.0.tar.gz
toast arm proj

kompiliert PROJ.4. Die URL ist dabei natürlich an das jüngste Release von der ...

Weiterlesen ...


Unicode __repr__ and IPython

Unicode __repr__ and __str__ functions that return non-ascii characters result on my IPython installation in a stack trace. Try this:

In [1]: class Foo(object):
...:     def __repr__(self):
...:         return u"äöü"

In [2]: Foo()
Out[2]: ---------------------------------------------------------------------------
UnicodeEncodeError                        Traceback (most recent call last)
<ipython-input-2-bbcd91f35259> in <module>()
----> 1 Foo ...
Weiterlesen ...


DPCM analyzed

I am currently building a little recordable music chip, like the Nuvoton ISD chips, but using nothing more than a microcontroller. Since these chips have quite little flash memory, I need to compress the audio samples. One way to do that is differential pulse-code modulation. It's a very low-complexity ...

Weiterlesen ...