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
# | |
# Create and reload an image with | |
# 0 1 2 3 4 5 6 7 8 9 visible | |
# | |
from pylab import * | |
rcParams['font.family'] = 'monospace' | |
rcParams['font.size'] = 96 | |
rcParams['figure.figsize'] = (20, 4) | |
rcParams['figure.subplot.top'] = .9 | |
rcParams['figure.subplot.wspace'] = .2 |
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
if sys.platform != 'darwin': | |
wx.RendererNative.Get().DrawItemSelectionRect( | |
window, dc, rect, flags) | |
elif flags & wx.CONTROL_SELECTED: | |
if flags & wx.CONTROL_FOCUSED: | |
color = wx.SystemSettings.GetColour(wx.SYS_COLOUR_HIGHLIGHT) | |
else: | |
color = wx.SystemSettings.GetColour(wx.SYS_COLOUR_INACTIVECAPTION) | |
old_brush = dc.Brush | |
new_brush = wx.Brush(color) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
Install Microsoft SDK for Windows 7 | |
Install JDK 8 64-bit | |
Install Python 2.7 | |
Install Git for Windows (and choose the option that lets you run git from the Windows command-line) | |
Install CMake (https://cmake.org/download) (choose the option to aqdd CMake to the system PATH for current user) | |
pip install --upgrade pip | |
pip install virtualenv | |
# | |
# The wheels (.whl) from Christoph Gohlke's site can be installed like this: | |
# pip install c:/Users/<me>/Downloads/mywheel_amd64.whl |
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
oMMy | |
+++++++++++++++++++++++++++++++++++++hMMd++++++++++++++++++++++++++++++++++++++++++++++++++++: | |
MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMh | |
MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMh | |
MMMsooooooooooohMMMNNMMMMMMMmdyyhyhhhmMMmhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhdddMMMMMMMMMMh | |
MMM:-----------oMMMh+sdNMMMMMNdhsoooohMMdoooooooooooooooooooooooooooosssssssssssyyhMMMMMMMMMMh | |
MMM/-----------oMMMh/:/+sdNMMMMMNNdyshMMdoooooooooooooooooooooooooooosssssssssssyyhMMMMMMMMMMh | |
MMM/-----------:hMMd/:-:::/ohmNMMMMMNNMMmsooooooooooooooooooooooooooosssssssssssyyhMMMMMMMMMMh | |
MMM/::::::::::::hMMd/:---::::/+shdNMMMMMMNmdyyooooooooooooooooooooooosssssssssssyyhMMMMMMMMMMh | |
MMM/::::::::::::hMMd/-----:::::://+oyhmNNMMMMMNNdhhssoooooooooooooooosssssssssssyyhMMMMMMMMMMh |
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
def rotate(direction, index): | |
return direction[-index:] + direction[:-index] | |
def make_kernel(convolution_mask): | |
k = list(convolution_mask) | |
k.insert(4, 0) | |
return np.array(k).reshape(3, 3) | |
def kirsch(img): | |
convolution_mask = [5, -3, -3, -3, -3, -3, 5, 5] |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
OlderNewer