Skip to content

Instantly share code, notes, and snippets.


Brock Palen brockpalen

View GitHub Profile
brockpalen / matlab-gpu-ex2.m
Last active Aug 29, 2015
Example of using Matlab with GPUS and doing all computation on the GPU
View matlab-gpu-ex2.m
%Brock Palen 1/2014
%To compare against a single core run:
% hwloc-bind core:0 matlab -r gen\(1e4\) #first core
% hwloc-bind socket:0 matlab -r gen\(1e4\) #first socket all cores
function gen(dim)
if ischar(dim)
brockpalen / globus-connect-server.conf
Last active Aug 29, 2015
Globus Connect Server config file, for creating a GridFTP Globus endpoint using University of Michigan CiLogin for OAuth.
View globus-connect-server.conf
; Globus User Configuration
; These settings configure how to contact Globus when
; creating or modifying an endpoint.
; Globus user name. If not set, or left at its default, then the
; value of GLOBUS_USER environment variable is used, falling back to
; prompting if it is not present.
brockpalen / hfss2014
Last active Aug 29, 2015
hfss/2014.0.0 shared memory parallel example PBS script
View hfss2014
#PBS -N jobname
#PBS -A account_flux
#PBS -l qos=flux
#PBS -l walltime=1:00:00,nodes=1:ppn=12,pmem=3800mb
#PBS -q flux
brockpalen /
Last active Aug 29, 2015
Running VNC on the Flux Cluster
#create an ssh tunnel vis flux-xfer to the machine with our VNC Display.
#this example works for Mac, Linux, and Cygwin
#find your vnchost and display number:
ls -rt ~/.vnc/
# eg:
# eg: <== host running vnc
# eg: 1 <== display number
brockpalen /
Last active Aug 29, 2015
#build hydra with PBS support
tar -xzf hydra-3.1.tar.gz
cd hydra-3.1
#configure with needed path to
#<toque install prefix>/lib/
./configure \
--prefix=<install prefix> \
--with-toque=<torque install prefix> \
brockpalen /
Last active Aug 29, 2015
Building your own Xsede Single Sign On Service
tar -xjf gt<version>-all-source-installer.tar.bz2
cd gt<version>-all-source-installer
./configure --prefix=/home/brockp/gt5.0.4
make globus-data-management-client
make gsi-myproxy
make install
brockpalen / gridftp-log
Last active Aug 29, 2015
example gridftp log entry
View gridftp-log
"message" => "[3743] Wed Jul 16 09:34:54 2014 :: Transfer stats: DATE=20140716133454.587582 PROG=globus-gridftp-server NL.EVNT=FTP_INFO START=20140716133453.570157 USER=brockp FILE=/tmp/brockp/linux_x64_64_sfx.exe BUFFER=87380 BLOCK=262144 NBYTES=280590752 VOLUME=/ STREAMS=4 STRIPES=1 DEST=[] TYPE=RETR CODE=226",
brockpalen /
Last active Aug 29, 2015
Demenstrate the use of MATLAB MCC to make standalone executables.
#compile source on Flux
module load matlab/2014a
mcc -m implicitthreads.m
brockpalen / benchmarkpct.m
Created Jan 10, 2015
MATLAB Parallel Computing Toolbox Demo
View benchmarkpct.m
function benchmarkpct(ncpus)
sched= findResource('scheduler', 'type', 'mpiexec') ;
set(sched, 'EnvironmentSetMethod', 'setenv')
set(sched, 'MpiexecFileName', '/home/software/rhel6/mpiexec/bin/mpiexec')
%get current mpi library
View mpiLibConf.m
function [lib, extras] = mpiLibConf
%MATLAB MPI Library overloading for Infiniband and Ethernet Networks
% place in ~/matlab/mpiLibConf.m
% Update to point to your MPICH / Intel MPI etc location
% mvapich has two extra libraries and
% use # ldd /home/software/rhel6/mvapich2/1.8/lib/
% Any libraries from the mpich/mvapich install location need to be included in extras