Skip to content

Instantly share code, notes, and snippets.

@pansapiens
pansapiens / Dockerfile
Created Mar 23, 2021
rnasik in docker (via conda/mamba)
View Dockerfile
FROM continuumio/miniconda3
#
# docker build -t pansapiens/rnasik:latest -t pansapiens/rnasik:1.5.4 .
# docker run --rm -it -v $(pwd):/data pansapiens/rnasik --help
#
RUN conda install --yes -c conda-forge mamba
RUN mamba install --yes -c bioconda -c conda-forge -c serine -c serine/label/dev -c anaconda -c defaults -c r -c conda-forge/label/broken \
python=3.6 rnasik=1.5.4 qualimap=2.2.2b=0 "pandas<1" && \
View test_signals.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View Mutable Instruments - Firmware upload process.md

How to get firmware onto mutable modules

On Ubuntu 20.04.

(I have not yet tried the Black Magic Probe and gdb parts)

Install compiler

First install the arm compiler:

@pansapiens
pansapiens / Dockerfile
Last active Aug 12, 2020
bcl-convert in Docker / Singularity
View Dockerfile
FROM centos:7
#
# You'll need to download bcl-convert-3.6.3-1.el7.x86_64.rpm from
# https://support.illumina.com/downloads/bcl-convert-downloads.html
# Yay clickwrap licenses !
#
# Building:
#
# docker build -t bcl-convert:latest -t bcl-convert:3.6.3 .
# sudo singularity build bcl-convert.sif docker-daemon://bcl-convert:latest
@pansapiens
pansapiens / Dockerfile
Last active Jul 21, 2020
biobloom in Docker
View Dockerfile
FROM ubuntu:18.04
RUN apt-get -y update && \
apt-get -y install git build-essential autogen autotools-dev automake \
libsdsl-dev libsdsl3 libsparsehash-dev zlib1g-dev libboost-all-dev libgomp1 && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*
WORKDIR /
RUN git clone --depth 1 --branch 2.3.2 https://github.com/bcgsc/biobloom.git && \
cd /biobloom && \
git submodule update --init && ./autogen.sh && \
@pansapiens
pansapiens / _README.md
Last active Nov 10, 2020
The Aspera ascp key you are looking for
View _README.md

Installing and running ascp is a PITA.

Here's the private key you need (at least for NCBI/ENA downloads).

ascp is now available in a Docker container. This makes things easier.

Do this:

# We need the not-actually-secret private key that comes packaged with Aspera Connect but is inexplicably not used as the default
# when no key is specified. Here's one I prepared earlier.
@pansapiens
pansapiens / kmer_vector_example.ipynb
Created May 11, 2020
k-mer counts as input feature vectors in Python
View kmer_vector_example.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@pansapiens
pansapiens / custom_environments_in_jupyter.ipynb
Last active Jul 21, 2020
Using custom environments in Jupyter
View custom_environments_in_jupyter.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View aaindex.py
import urllib.request as request
from collections import defaultdict
def parse_aaindex2(lines, default=None):
"""
Parse the lines of an AAIndex2 substitution matrix, return a dict of the entire database keyed by
AAIndex identifier.
The aaindex[id]['matrix'] dictionary is the same structure as Biopython's `Bio.SubsMat.MatrixInfo`
substitution matricies.