echo "\nPrep/Setup"
echo "~~~~~~~~~~"
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# needs to be run as root | |
# download and install EPD and gfortran | |
mkdir /tmp/hpc3 | |
cd /tmp/hpc3 | |
curl -L -o e.zip http://bit.ly/hpc_3 | |
unzip e.zip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# user local install | |
export CLAW=~/opt/clawpack | |
mkdir -p $CLAW | |
cp -R /opt/clawpack/* $CLAW | |
export PATH=/Library/Frameworks/EPD64.framework/Versions/Current/bin:$PATH | |
export RIEMANN=$CLAW/riemann | |
export PYCLAW=$CLAW/pyclaw |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
====================================================================== | |
ERROR: test_1d_acoustics | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/aron/.virtualenvs/pyclaw/lib/python2.7/site-packages/nose/case.py", line 197, in runTest | |
self.test(*self.arg) | |
File "/Users/aron/sandbox/clawpack/clawpack/pyclaw/util.py", line 126, in test_app | |
raise VerifyError(err) | |
VerifyError: /Users/aron/sandbox/clawpack/pyclaw/apps/acoustics_1d_homogeneous/acoustics.py | |
******************************************************************************** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cimport cython | |
cimport numpy as np | |
import numpy as np | |
DTYPE = np.float | |
ctypedef np.float DTYPE_t | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import sys | |
import time | |
import numpy as np | |
import matplotlib as mpl | |
mpl.use('Qt4Agg') | |
mpl.rcParams['backend.qt4']='PySide' | |
mpl.rcParams['toolbar'] = 'None' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import cv | |
import os | |
import sys | |
from skimage import io | |
from skimage.transform import pyramid_expand | |
from skimage import img_as_ubyte | |
import numpy as np |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
! Sample rp2 module for an application where the material parameters | |
! are piecewise constant, with one set of values for x < xdiscont | |
! and another set for x > xdiscont. | |
! Rather than storing values in aux arrays, the rpaux derived type | |
! could be modified to contain x values a the cell centers. | |
! rpt2 not yet written and this hasn't been tried, so may be bugs! | |
module rp2_pwconst_acoustics_module |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from numba import autojit | |
import numpy as np | |
import numpy.testing as npt | |
import time | |
import gc | |
def usr(x, y, s=0.9, n=10): | |
scores = 1.0 / (1.0 + 1/12.0 * np.abs(x-y).sum(axis=1)) | |
scores = scores[scores>=s] | |
scores.sort() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
#!/usr/bin/python | |
# | |
# Created by Albert Au Yeung (2010) | |
# http://www.quuxlabs.com/blog/2010/09/matrix-factorization-a-simple-tutorial-and-implementation-in-python/#source-code | |
# | |
# Modifications by Josh Hemann and Aron Ahmadia | |
# | |
# An implementation of matrix factorization | |
# |
OlderNewer