Skip to content

Instantly share code, notes, and snippets.

View duanemalcolm's full-sized avatar

Duane Malcolm duanemalcolm

  • Auckland, New Zealand
View GitHub Profile
import numpy as np
import shapefile
import sys
from scipy.spatial import cKDTree
import scipy.optimize
def ellipse(x, theta):
phi = x[4]
r = 1 / np.sqrt((np.cos(theta)) ** 2 + (np.sin(theta)) ** 2)