Skip to content

Instantly share code, notes, and snippets.

Avatar

Isaac Hodes ihodes

View GitHub Profile
View keybase.md

Keybase proof

I hereby claim:

  • I am ihodes on github.
  • I am isaachodes (https://keybase.io/isaachodes) on keybase.
  • I have a public key whose fingerprint is C093 FCAE CDC9 A4FA 0531 4AFF AE11 6745 B9BD A8EB

To claim this, I am signing this object:

View tims_pipeline.ml
#use "topfind";;
#thread
#require "coclobas.ketrew_backend,biokepi,cmdliner,nonstd,sosa,csv";;
(* You must have a biokepi_machine.ml file in this directory that has a
`biokepi_machine` defined at the top level. *)
#use "biokepi_machine.ml"
open Nonstd
module String = Sosa.Native_string
View tavis_workflow.ml
#use "topfind";;
#thread
#require "coclobas.ketrew_backend,biokepi,cmdliner,nonstd";;
(* You must have a biokepi_machine.ml file in this directory that has a
biokepi_machine defined at the top level. *)
#use "biokepi_machine.ml"
open Nonstd
View poly.ml
utop # class intlist (l: int list) =
object
method empty = (l = [])
method fold f acc = List.fold_left f acc l
end;;
Error: Some type variables are unbound in this type: class intlist : int list ->
object
method empty : bool
method fold : ('a -> int -> 'a) -> 'a -> 'a
end
View wf.ml
#use "topfind"
#thread
#require "nonstd"
#require "hamkepi"
#require "ketrew"
#require "biokepi"
View vcfs.py
# coding: utf-8
"""Module with methods for ingesting VCFs into Impala tables.
Need to have an open tunnel (e.g. ssh demeter -L 21050:demeter-csmau08-10:21050)
with ControlMaster enabled.
"""
import base64
import ibis
import subprocess
View upload_and_post_vcf
#! /bin/sh
SCRIPT_NAME=$(basename $0)
short_usage()
{
echo "Cf : $SCRIPT_NAME [--help]"
}
long_usage()
{
View main.rs
./src/main.rs:58:13: 58:107 error: cannot infer an appropriate lifetime for lifetime parameter 'r in function call due to conflicting requirements
./src/main.rs:58 filtered.skip_while(|l| from_str::<uint>(l.clone().unwrap().as_slice()).unwrap() | bf == 1u )
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./src/main.rs:58:33: 58:105 note: first, the lifetime cannot outlive the expression at 58:32...
./src/main.rs:58 filtered.skip_while(|l| from_str::<uint>(l.clone().unwrap().as_slice()).unwrap() | bf == 1u )
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./src/main.rs:58:33: 58:105 note: ...so type `|&core::result::Result<collections::string::String, std::io::IoError>| -> bool` of expression is valid during the expression
./src/main.rs:58 filtered.skip_whi
View pyth.py
def tokenize(string):
# reversed because we want to consume a pre-order stack of tokens
return string.replace('(', ' ( ').replace(')', ' ) ').replace('\'', ' \' ').split()[::-1]
def read_expression(tokens):
expression = []
token = tokens.pop()
if token == '(':
while True:
View pyth.py
def tokenize(string):
return string.replace('(', ' ( ').replace(')', ' ) ').split()
def parse(tokens):
expression, estack = [], []
for token in tokens:
if token is '(':
You can’t perform that action at this time.