Skip to content

Instantly share code, notes, and snippets.

View Seanny123's full-sized avatar
💭
>.<

Sean Aubin Seanny123

💭
>.<
View GitHub Profile
@Seanny123
Seanny123 / interactive_log_final.py
Last active January 19, 2022 15:04
EE4208 Laplacian of Gaussian Edge Detector
import math
import numpy as np
import matplotlib.pyplot as plot
import matplotlib.cm as cm
import sys
import pylab
from matplotlib.widgets import Slider
range_inc = lambda start, end: range(start, end+1) #Because this is easier to write and read
@Seanny123
Seanny123 / show_log.py
Created April 11, 2014 09:22
EE4208 plotting the Laplacian of Gaussian mask
import numpy as np
import math
from mpl_toolkits.mplot3d import Axes3D
import matplotlib.pyplot as plt
import sys
import pylab
from matplotlib.widgets import Slider
#from IPython.core import ultratb
#sys.excepthook = ultratb.FormattedTB(mode='Verbose',
# color_scheme='Linux', call_pdb=1)
@Seanny123
Seanny123 / canny.py
Created April 12, 2014 14:28
EE4208 Canny edge detector
import numpy as np
import matplotlib.pyplot as plot
import matplotlib.cm as cm
import sys
import pylab
import math
import scipy
# Mostly implemented by Matt Cumming
@Seanny123
Seanny123 / interactive_log_experimental.py
Created April 13, 2014 06:12
EE4208 Laplacian of Gaussian using alternative method for checking the zero crossings
import cv2
import math
import numpy as np
import matplotlib.pyplot as plot
import matplotlib.cm as cm
import sys
import pylab
from matplotlib.widgets import Slider
@Seanny123
Seanny123 / test.py
Created October 14, 2014 18:59
Sharing dictionary of objects between processes
import multiprocessing
class Dog():
def __init__(self, name = "joe"):
self.name = name
def bark(self):
print("woof")
mg = multiprocessing.Manager()
dt = dict()
@Seanny123
Seanny123 / get_anaconda_links.py
Created November 4, 2014 16:23
How to get the link for the most recent version of Anaconda
@Seanny123
Seanny123 / basic_prod.py
Created September 30, 2015 17:18
Connection Bug
import nengo
import nengo.spa as spa
D = 32
model = spa.SPA()
with model:
model.vision = spa.Buffer(D)
model.speech = spa.Buffer(D)
model.memory = spa.Memory(D)
@Seanny123
Seanny123 / assoc_mem.py
Created October 22, 2015 18:22
Associative Memories
import nengo
from nengo import spa
D = 32
vo = spa.Vocabulary(D)
vo.parse("A + B + C")
vo2 = spa.Vocabulary(D/2)
vo2.parse("D + E + F")
model = spa.SPA(vocabs=[vo, vo2])
@Seanny123
Seanny123 / dict_mem.py
Created October 22, 2015 18:40
dict mem
import nengo
from nengo import spa
D = 32
vo = spa.Vocabulary(D)
vo.parse("A + B + C")
vo2 = spa.Vocabulary(D/2)
vo2.parse("D + E + F")
model = spa.SPA()
@Seanny123
Seanny123 / count_test.py
Created November 21, 2015 20:55
Counting test
import nengo
from nengo import spa
import numpy
from collections import OrderedDict
print(numpy.version.version)
D = 64
vocab = spa.Vocabulary(D, unitary=["ONE"])