Skip to content

Instantly share code, notes, and snippets.

View chrismullins's full-sized avatar

Christopher Mullins chrismullins

View GitHub Profile
@chrismullins
chrismullins / CMakeLists.txt
Last active August 29, 2015 14:04
superbuild-meshkit
cmake_minimum_required(VERSION 2.8)
include(ExternalProject)
include(superbuild.cmake)
@chrismullins
chrismullins / build-clang.sh
Created January 30, 2015 16:53
build clang trunk
basedir=`pwd`
echo $basedir
installdir=llvm-clang-install
mkdir $installdir
svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm
mkdir llvm-build && cd llvm-build
$basedir/llvm/configure --prefix=$basedir/$installdir && make -j8 && make install
cd $basedir
svn co http://llvm.org/svn/llvm-project/cfe/trunk clang
@chrismullins
chrismullins / scatter_roi_files.py
Created August 7, 2015 21:56
Separate filelist and roi_summary file into separate txt files.
import argparse
import os
import sys
from itertools import izip
import collections
import errno
"""
This script takes two files: a list of form 'filename,slice#', and another
tab-delimited list of mean values for each ROI. Every line should line up.
@chrismullins
chrismullins / build_python.sh
Created August 7, 2015 22:08
Build python 2.7.10 on linux
#/bin/bash
mkdir python2710 && cd python2710
wget https://www.python.org/ftp/python/2.7.10/Python-2.7.10.tgz --no-check-certificate
gunzip Python-2.7.10.tgz
tar xf Python-2.7.10.tar
cd Python-2.7.10
./configure
make
@chrismullins
chrismullins / video-encoding-with-ffmpeg.sh
Created March 7, 2013 01:58
Encoding video with ffmpeg for COMP715
# first, get ffmpeg
git clone git://source.ffmpeg.org/ffmpeg.git ffmpeg
# next, configure it
cd ffmpeg
./configure --disable-yasm
# build it (-j<# of cores>)
make
@chrismullins
chrismullins / test-flip-functions.m
Last active December 15, 2015 21:49
Run MATLAB test with xunit
% Once XUnit is installed, you can run this test by navigating to this directory and typing "runtests" into your MATLAB prompt.
%
% Output Variable name should be "test_suite"
% | Make sure the test name either begins or ends with "test"
% | |
% | |
function test_suite = testMyFunctions
initTestSuite;
% Here is the first test!
@chrismullins
chrismullins / CMakeLists.txt
Last active December 15, 2015 21:49
A CTest example so minimalistic that it is probably not useful to anyone. Enjoy!
cmake_minimum_required(VERSION 2.8)
project(CTest-Example)
add_executable(CTest-Example CTest-Example)
enable_testing()
add_test(NAME YeahhhTest COMMAND ${CMAKE_COMMAND} -E echo 'Yeahh')
@chrismullins
chrismullins / backup_chromebook_image.sh
Last active December 21, 2015 00:47
Backup a disk image using dd
#/bin/bash
dd if=/dev/sdb of=/mnt/BackupDisk_2TB/Chromebook_BACKUP_IMAGE
@chrismullins
chrismullins / PKGBUILD.sh
Last active December 27, 2015 22:12
Test PKGBUILD for Lightscreen
# Maintainer: Chris <christopher.r.mullins g-mail>
pkgname=lightscreen
pkgver=2.0
pkgrel=1
pkgdesc='Simple tool to automate the tedious process of saving and cataloging screenshots'
arch=('i686' 'x86_64')
url='http://lightscreen.com.ar/'
depends=('qt4')
license=('GPL')
@chrismullins
chrismullins / PKGBUILD.sh
Created December 31, 2015 20:07
PKGBUILD for ITK
# Maintainer: Andrzej Giniewicz <gginiu@gmail.com>
# Contributor: Chris <christopher.r.mullins g-mail>
# Contributor: Thomas Dziedzic < gostrc at gmail >
# Contributor: joel schaerer <joel.schaerer@laposte.net>
pkgname=insight-toolkit
pkgver=4.8.2
pkgrel=2
pkgdesc='Cross-platform system that provides developers with an extensive suite of software tools for image analysis'
arch=('i686' 'x86_64')