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 | |
import itertools | |
# update rule for neuron x1 | |
def update_1((a, b, c)): | |
test = c-b+2 | |
if (test > 0): | |
new = 1 | |
elif (test == 0): | |
new = a |
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
file_path = expanduser('results/pickles/image-mlp.prm') | |
layers = [] | |
layers.append(DataLayer(nout=100)) | |
layers.append(FCLayer(nout=10, activation=RectLin())) | |
layers.append(FCLayer(nout=3, activation=RectLin())) | |
layers.append(FCLayer(nout=3, activation=Logistic())) | |
layers.append(CostLayer(cost=CrossEntropy())) | |
backend = gen_backend(rng_seed=0) |
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 logging | |
logging.basicConfig(level=40) | |
logger = logging.getLogger() | |
from neon.backends import gen_backend | |
from neon.layers import FCLayer, DataLayer, CostLayer | |
from neon.models import MLP | |
from neon.transforms import RectLin, Logistic, CrossEntropy | |
from neon.experiments import FitPredictErrorExperiment |
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
{ | |
"cells": [ | |
{ | |
"cell_type": "markdown", | |
"metadata": {}, | |
"source": [ | |
"# Deep learning experiments on artificial generated signals\n", | |
"\n", | |
"First we need to setup the environment and import all the necessary stuff." | |
] |
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 logging | |
logging.basicConfig(level=40) | |
logger = logging.getLogger() | |
from neon.backends import gen_backend | |
from neon.layers import FCLayer, DataLayer, CostLayer | |
from neon.models import MLP | |
from neon.models import DBN | |
from neon.transforms import RectLin, Logistic, CrossEntropy |
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
package com.AwesomeSoft; | |
import org.canova.api.records.reader.RecordReader; | |
import org.canova.api.split.FileSplit; | |
import org.canova.image.recordreader.ImageRecordReader; | |
import org.deeplearning4j.datasets.canova.RecordReaderDataSetIterator; | |
import org.deeplearning4j.datasets.iterator.DataSetIterator; | |
import org.deeplearning4j.nn.conf.MultiLayerConfiguration; | |
import org.deeplearning4j.nn.conf.NeuralNetConfiguration; | |
import org.deeplearning4j.nn.conf.layers.OutputLayer; |