Skip to content

Instantly share code, notes, and snippets.

View holtgrewe's full-sized avatar
💭
For science! 🏥 🔬 💻

Manuel Holtgrewe holtgrewe

💭
For science! 🏥 🔬 💻
View GitHub Profile
// Term, TermMap, and directly related types ---------------------------------
public interface Prefix extends Serializable {
public ByteString getValue();
}
public interface TermID extends Comparable <TermID>, Serializable {
public Prefix getPrefix();
public int getID();
}
@holtgrewe
holtgrewe / setup.py
Created February 26, 2018 14:29
MWE for setup.py
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Note: To use the 'upload' functionality of this file, you must:
# $ pip install twine
import io
import os
import sys
from shutil import rmtree
#!/usr/bin/env python3
"""Tool to cleanup the scratch directories on BIH HPC."""
import argparse
import datetime
import logging
import os
from os.path import join, dirname, normpath, islink, exists, isdir
import pathlib
import re
@holtgrewe
holtgrewe / kayobe-config.diff
Created November 16, 2021 08:31
Required patches to kayobe, kolla-ansible (both branches stable/xena) and kolla-configuration to have the seed hypervisor, seed, and bare metal hosts configured with Rocky Linux.
diff --git a/etc/kayobe/bifrost.yml b/etc/kayobe/bifrost.yml
index 0bfcec7..00d4651 100644
--- a/etc/kayobe/bifrost.yml
+++ b/etc/kayobe/bifrost.yml
@@ -23,10 +23,10 @@
# Diskimage-builder configuration.
# DIB base OS element. Default is {{ os_distribution }}.
-#kolla_bifrost_dib_os_element:
+kolla_bifrost_dib_os_element: "centos"
@holtgrewe
holtgrewe / 01-prepare.md
Last active June 9, 2022 14:49
Setup varfish-server development in WSL2 (Ubuntu 22.04 LTS)

The setup was done on a recent version of Windows 10 with Windows Subsystem for Linux Version 2 (WSL2).

First, install WSL 2, e.g., following this tutorial

  • Note that the whole thing appears to be a bit convoluted, you start out with wsl.exe --install
  • Then you can install latest LTS Ubuntu 22.04 with the Microsoft Store
  • Once complete, you probably end up with a WSL 1 (one!) that you can conver to version 2 (two!) with wsl --set-version Ubuntu-22.04 2 or similar.
  • WSL2 has some advantages including running a full Linux kernel but is even slower in I/O to the NTFS Windows mount.
  • Everything that you do will be inside the WSL image.
// ##INFO=<ID=AC,Number=A,Type=Integer,Description="Alternate allele count for samples">
/// Alternate allele count for samples.
pub ac: Option<i32>,
// ##INFO=<ID=AN,Number=1,Type=Integer,Description="Total number of alleles in samples">
/// Total number of alleles in samples.
pub an: Option<i32>,
// ##INFO=<ID=AF,Number=A,Type=Float,Description="Alternate allele frequency in samples">
/// Alternate allele frequency in samples.
pub af: Option<f32>,
// ##INFO=<ID=rf_tp_probability,Number=1,Type=Float,Description="Random forest prediction probability for a site being a true variant">
// ##INFO=<ID=non_cancer_AC_asj_female,Number=A,Type=Integer,Description="Alternate allele count for female samples of Ashkenazi Jewish ancestry in the non_cancer subset">
// ##INFO=<ID=non_cancer_AN_asj_female,Number=1,Type=Integer,Description="Total number of alleles in female samples of Ashkenazi Jewish ancestry in the non_cancer subset">
// ##INFO=<ID=non_cancer_AF_asj_female,Number=A,Type=Float,Description="Alternate allele frequency in female samples of Ashkenazi Jewish ancestry in the non_cancer subset">
// ##INFO=<ID=non_cancer_nhomalt_asj_female,Number=A,Type=Integer,Description="Count of homozygous individuals in female samples of Ashkenazi Jewish ancestry in the non_cancer subset">
// ##INFO=<ID=AC_raw,Number=A,Type=Integer,Description="Alternate allele count for samples, before removing low-confidence genotypes">
// ##INFO=<ID=AN_raw,Number=1,Type=Integer,Description="Total number of alleles in samples, before removing low-confidence genotypes">
// ##INFO=<ID=AF_raw,Num