Replace:
.@{:i}, \/\*\*\< {:n}.*$
With:
\t\2, // \1
Replace:
.@{:i}, \/\*\*\< {:n}.*$
With:
\t\2, // \1
function play(iteration) { | |
var ctrl = { | |
up: function() { window.gm.inputManager.emit('move', 0); return window.gm.moved; }, | |
right: function() { window.gm.inputManager.emit('move', 1); return window.gm.moved; }, | |
down: function() { window.gm.inputManager.emit('move', 2); return window.gm.moved; }, | |
left: function() { window.gm.inputManager.emit('move', 3); return window.gm.moved; } | |
}; | |
while(!window.gm.over && !window.gm.won) { | |
if(!iteration(ctrl)) { |
import numpy as np | |
from sklearn.datasets import load_iris | |
from sklearn.tree import DecisionTreeClassifier | |
from matplotlib import pyplot as plt | |
# fetch data | |
iris = load_iris() | |
classes = {} | |
for cls in (0,1,2): | |
classes[cls] = np.array([v for k, v in zip(iris.target, iris.data) if k == cls]) |
license: gpl-3.0 | |
border: no | |
height: 1060 |
license: apache-2.0 |