Skip to content

Instantly share code, notes, and snippets.

View danabauer's full-sized avatar

Dana Bauer danabauer

  • Philadelphia
  • 01:27 (UTC -05:00)
View GitHub Profile
@danabauer
danabauer / jupyter-tips.md
Last active October 12, 2017 19:03
interactive notebook and notebook-like tools

GDAL on OS X

This will resolve issues with GDAL on OS X in your virtualenv:

  • brew install gdal
  • From OUTSIDE a virtualenv (try, deactivate), run this command to find your system site-packages directory: python -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())"
    • Chances are this will be /Library/Python/2.7/site-packages
    • Note: this is where pip install ... packages are placed
  • Copy the gdal-XXX.pth file to the site-packages directory of your virtual environment.
  • Find your site packages directory for your virtual env by running the earlier command, python -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())", from inside an activated virtualenv.
@danabauer
danabauer / pip-install-gdal.md
Created May 2, 2017 20:08 — forked from cspanring/pip-install-gdal.md
Installing GDAL in a Python virtual environment

Installing GDAL in a Python virtual environment

Get gdal development libraries:

$ sudo apt-add-repository ppa:ubuntugis/ubuntugis-unstable
$ sudo apt-get update
$ sudo apt-get install libgdal-dev

Create and activate a virtual environment:

@danabauer
danabauer / python-project-structure.txt
Last active March 17, 2021 14:25
ways to structure python projects
https://coderwall.com/p/lt2kew/python-creating-your-project-structure
+ bin
- project
+ project
- main.py
+ lib
+ tests
'''
Use Case 2
Find the most recently acquired image in imagery published in the last 48 hours:
Get all products in Grid-UTM catalog intersecting a rectangular AOI defined by the upper left and lower right
coordinates (a field in United States, Iowa) published within the last 48 hours. Download the most recently
acquired analytic asset regardless of provider.
'''
'''
Use case 1
Scrape the catalog for an AOI/TOI: Filter the RapidEye Grid-UTM catalog for products in an AOI
(United States in Iowa) with an acquisition period between "2014-04-01" and "2014-09-15" with a maximum
cloud cover value of "20%." Download all of the analytic assets.
'''
import requests
from datetime import datetime
import pytz
@danabauer
danabauer / eyeo-job-titles.md
Last active June 13, 2017 08:01
Job titles at the 2012 Eyeo Festival

Job titles at Eyeo 2012

  • computational designer
  • computational graphics designer
  • computational artist
  • computational data artist
  • computational botanist
  • critical engineer
  • data philospher
  • a truth and beauty operator