Skip to content

Instantly share code, notes, and snippets.

View RoboDonut's full-sized avatar
🦧

Daniel RoboDonut

🦧
  • Wherobots
  • Oregon
View GitHub Profile
@ElijahLynn
ElijahLynn / pipe_to_docker_examples
Last active July 2, 2024 01:27
How to pipe to `docker exec` examples
# These examples assume you have a container currently running.
# 1 Pipe from a file
sudo docker exec --interactive CONTAINER_NAME /bin/bash < the_beginning.sh | tee the_beginning_output.txt`
#2a Pipe by piping
echo "echo This is how we pipe to docker exec" | sudo docker exec --interactive CONTAINER_NAME /bin/bash -
# python pca_multiband.py input.jpeg output.tif
# n-band image -> PCA -> n-band TIFF image
# with lots of hackety assumptions
# (e.g., output is same type as input)
from sys import argv
import rasterio as rio
import numpy as np
from sklearn import decomposition
@rgdonohue
rgdonohue / README.md
Last active January 11, 2023 21:43
Batch Geocoding Script with GeoPy
@jtornero
jtornero / vincenty
Created September 16, 2015 06:41
Python implementation of Vincenty's direct formula
def vinc_pt(f, a, phi1, lembda1, alpha12, s ) :
import math
"""
Returns the lat and long of projected point and reverse azimuth
given a reference point and a distance and azimuth to project.
lats, longs and azimuths are passed in decimal degrees
Returns ( phi2, lambda2, alpha21 ) as a tuple
Parameters:
===========
f: flattening of the ellipsoid
@clhenrick
clhenrick / README.md
Last active April 1, 2024 14:55
PostgreSQL & PostGIS cheatsheet (a work in progress)
@jgravois
jgravois / index.html
Last active October 12, 2015 01:54
add webmap from JSON instead of ArcGIS Online in Viewer.
<script type="text/javascript" src="./config/webmap.js"></script>
<!--existing tag-->
<script type="text/javascript" src="//js.arcgis.com/3.10/"></script>