Skip to content

Instantly share code, notes, and snippets.

View GjjvdBurg's full-sized avatar

Gertjan van den Burg GjjvdBurg

View GitHub Profile
@GjjvdBurg
GjjvdBurg / dynamo.py
Last active August 13, 2020 12:58
Helper class for running a function on different parameters, in parallel, using a simple disk-based JSON cache (using only the standard library).
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Helper class for running a function on different parameters, in parallel,
using a disk-based cache.
Author: G.J.J. van den Burg
License: MIT License
Copyright: 2020, G.J.J. van den Burg
@GjjvdBurg
GjjvdBurg / AN_R_VIRTUAL_ENVIRONMENT.md
Last active June 20, 2019 13:31
A simple "virtual environment" for R

This creates a "virtualenv" for R that can be setup through the command line and that works with Rscript (which packrat doesn't (easily)).

Basic usage:

$ mkdir -p ./rlibs
$ bash R_setup.sh Rpackages.txt ./rlibs

where Rpackages.txt is a file with one package per line, for example:

@GjjvdBurg
GjjvdBurg / README.md
Last active July 9, 2018 16:52
Patch for Qt5 compilation of AUR nextcloud-client package

This is a patch to fix the nextcloud client compilation instructions with Qt5. This avoids the Unknown CMake command "qt5_use_modules" error. See nextcloud/desktop#376 for details.

To use this patch:

  • Save the patch below as /tmp/client.patch
  • Download the package snapshot from the AUR: https://aur.archlinux.org/packages/nextcloud-client/
  • Unpack the nextcloud-client.tar.gz file and change directory into the nextcloud-client directory
  • Open the PKGBUILD file for editing
  • After line 28 of the PKGBUILD file, as the last line of the prepare() section, add: git apply /tmp/client.patch
  • Continue installation as normal (makepkg -si)
@GjjvdBurg
GjjvdBurg / mlpack_local_build.md
Last active March 29, 2017 15:51
Building mlpack and armadillo locally without root access

Steps I needed to take to compile mlpack successfully on a box without root access.

Running Ubuntu 16.04 with the following configuration of ATLAS, BLAS, and LAPACK:

ii  libatlas-base-dev                      3.10.2-9                        amd64        Automatically Tuned Linear Algebra Software, generic static
ii  libatlas-dev                           3.10.2-9                        amd64        Automatically Tuned Linear Algebra Software, C header files
ii  libatlas3-base                         3.10.2-9                        amd64        Automatically Tuned Linear Algebra Software, generic shared
ii  libblas-common                         3.6.0-2ubuntu2                  amd64        Dependency package for all BLAS implementations
ii  libblas-dev                            3.6.0-2ubuntu2                  amd64        Basic Linear Algebra Subroutines 3, static library