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
# inspired by https://openmaya.quora.com/How-to-implement-Voronoi-with-Python-for-Maya | |
import numpy as np | |
import random | |
import math | |
class MBoundingBox: | |
def __init__(self): | |
self.xyz = None |
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
# set aliases | |
. ~/.bash_aliases | |
new-alias() { | |
local last_command=$(echo `history |tail -n2 |head -n1` | sed 's/[0-9]* //') | |
echo alias $1="'""$last_command""'" >> ~/.bash_aliases | |
. ~/.bash_aliases | |
} |
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 | |
from scipy.interpolate import RectBivariateSpline, bisplev | |
class ParaSurf(object): | |
def __init__(self, u, v, xyz, bbox=[-0.25, 1.25, -0.5, 1.5], ku=3, kv=3): | |
"""Parametric (u,v) surface approximation over a rectangular mesh. | |
Parameters | |
---------- |