Skip to content

Instantly share code, notes, and snippets.

Avatar

Mark Reid mreid

View GitHub Profile
View Tally.java
package demo;
import java.io.BufferedReader;
import java.io.FileReader;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
import java.util.HashMap;
import java.util.List;
@mreid
mreid / crossval.sh
Created Jul 21, 2009
Bash script for doing cross validation
View crossval.sh
#!/usr/bin/perl -w
# -*-perl-*-
# $Id: crossval,v 1.1.1.1 2003/04/02 02:06:05 mreid Exp $
#
# NAME
# crossval - Run Aleph on a collection of cross validation sets.
#
# SYNOPSIS
# crossval [--aleph ALEPH] [--yap YAP] [--param ALEPH_SETTING] [--set ALEPH_SETTING]
# EXP_BASE BACKGROUND DATA_PATTERN
View gitrm.sh
# One-liner to add files to a git changeset that have been already deleted from
# the filesystem. (Surely there must be an easier way?)
git status | ruby -ne '$_ =~ /deleted:\s+(.*)/; `git rm #{$1}` unless $1.nil?'