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
{ | |
"cells": [ | |
{ | |
"cell_type": "markdown", | |
"metadata": {}, | |
"source": [ | |
"#Testing out PlanetaryImage" | |
] | |
}, | |
{ |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
{ | |
"0044ML0205000000E1_DXXX.img": { | |
"url": "http://" | |
}, | |
"0778ML0033700000400205E01_XXXX.LBL": { | |
"url": "http://", | |
"datafile": "0778ML0033700000400205E01_XXXX.LBL", | |
"skip": "True" | |
}, | |
"0778ML0033700000400205I01_XXXX.LBL": { |
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 | |
from glob import glob | |
def file_dir_glob_list(inlist=None): | |
"""Given a list of files, directories or globs, returns a fully expanded | |
list of files | |
""" | |
file_list = [] | |
if inlist: |
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 numpy as np | |
dt = np.dtype([ | |
('time', [('min', int), ('sec', int)]), | |
('temp', float) | |
]) | |
# create array with dtype | |
x = np.zeros((5,5), dtype=dt) |
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 bash | |
# rebundle.sh - Rebundles, uploads and registers an AMI. | |
# For blogpost: | |
# http://blog.crunch.io/user-managed-kernel-amis-from-existing-ubuntu | |
# Austin Godber <godber@crunch.io> | |
if [ `id -u` != '0' -o "$AWS_USER_ID" == "" ]; then | |
echo "ERROR: You must run this with 'sudo -E' or as the root user" | |
exit 1 |
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
ec2-run-instances ami-2d4aa444 \ | |
--instance-type m1.small \ | |
--region us-east-1 \ | |
--key ${EC2_KEYPAIR_US_EAST_1} |
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 bash | |
# prep.sh - Prepares an Ubuntu AMI for Rebundling | |
# For blogpost: | |
# http://blog.crunch.io/user-managed-kernel-amis-from-existing-ubuntu | |
# Austin Godber <godber@crunch.io> | |
if [ `id -u` != '0' ]; then | |
echo "ERROR: You must run this with 'sudo -E' or as the root user" | |
exit 1 |
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
cd /tmp | |
wget -q http://gist.github.com/raw/481553/04b30b8a4ea2c9cb5b757844f48ba7fa02f03de8/prep.sh | |
sudo -E bash prep.sh | |
# scp your keys to the AMI as instructed by prep.sh | |
vi /mnt/tmp/environment # set you AWS credentials and paths | |
. /mnt/tmp/environment | |
sudo wget -q -O /boot/grub/menu.lst http://gist.github.com/raw/481560/6e70d54e1dc6ea43130916ed054cf56cd33cb97f/menu.lst | |
cd /mnt/tmp/ | |
wget -q http://gist.github.com/raw/481551/af5a315b59f9b7e4874880491d0cc6dc5f3c7b9c/rebundle.sh | |
vi rebundle.sh # set your bucket |