Skip to content

Instantly share code, notes, and snippets.

@ohnorobo
ohnorobo / partition_bug.py
Created November 10, 2020 18:37
A minimal reproduction for a beam partitioning bug
# based on zdenulo's example at
# https://gist.github.com/zdenulo/99877307981b4d372df5a662d581a5df
import logging
import apache_beam as beam
from apache_beam.options.pipeline_options import PipelineOptions
from apache_beam.io.gcp import bigquery
from google.cloud import bigquery as cloud_bigquery
@ohnorobo
ohnorobo / setup_output.txt
Last active September 3, 2020 20:45
Example running setup.py with and without egg_info for Apache Beam
Running setup without egg_info
python setup.py sdist --dist-dir /tmp/tmpn4hbl9jb
running sdist
running egg_info
creating <package-name>.egg-info
writing <package-name>.egg-info/PKG-INFO
writing dependency_links to <package-name>.egg-info/dependency_links.txt
writing requirements to <package-name>.egg-info/requires.txt
@ohnorobo
ohnorobo / breakexample.py
Last active August 29, 2015 14:16
example of segfault in mpl basemap
from mpl_toolkits.basemap import Basemap
# works
boundaries = (42.88679, 41.187053, -69.858861, -73.508142)
north, south, east, west = boundaries
b = Basemap(projection="lcc",
llcrnrlon=west,
llcrnrlat=south,
urcrnrlon=east,
urcrnrlat=north,
brew --config
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew.git
HEAD: 7bf8a8cdd46a79832b403ce29372f4a6e6386e6c
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: quad-core 64-bit ivybridge
OS X: 10.9.5-x86_64
Xcode: 6.0.1
1. Finish master enrollment, log in again
2. Click on "Enrollment" > "Enrollment Add Classes"
3. They'll be a box that says "Add to Temporary Course List:" with the button "My Requirements" selected. Click the "Search" button
4. This will bring up a "Course list for Incoming Exchange students and Visiting students" menu, with two drop downs
- "<your faculty> Electives for Incoming Exchange students" (this will be open)
- "Courses offered by other faculties" (this will be closed)
5. Open the dropdown you want
6. Select the name of the class you want to add, it will show you some class info and and different sections.
7. For the section you want click "Select"
8. Then click "next" a bunch and the class will be added.
@ohnorobo
ohnorobo / ijulia_server_setup.md
Last active January 29, 2016 01:33
setting up an IJulia server on a default digitalocean instance

start up an instance with ubuntu 12.04 LTS

###Install Julia 0.2

http://julialang.org/downloads/

sudo add-apt-repository ppa:staticfloat/juliareleases
sudo add-apt-repository ppa:staticfloat/julia-deps
sudo apt-get update

sudo apt-get install julia

@ohnorobo
ohnorobo / pantry pickup json
Created November 16, 2013 04:32
json of the data from https://github.com/codeforboston/pantry_pickup to be turned into geojson for testing finda
[
{
"address": "3 Charleton St.",
"city": "Everett",
"email": "[email protected]",
"google_cal": [
{
"end": {
"dateTime": "2013-06-03T16:00:00-04:00"
},