summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorMohamed Omran <mohamed.omran@gmail.com>2014-09-20 19:01:28 +0200
committerMatthias Plappert <matthiasplappert@me.com>2015-08-10 11:15:50 +0200
commit1ce3380f172336cadaa649a6e077a42a246a534d (patch)
treee552b7b1abe88ccec4c0d5b421d057e18918eb4f /examples
parent7bd2959b80fbf945d28b1c1041410ba1d8b59e3d (diff)
downloadcaffeonacl-1ce3380f172336cadaa649a6e077a42a246a534d.tar.gz
caffeonacl-1ce3380f172336cadaa649a6e077a42a246a534d.tar.bz2
caffeonacl-1ce3380f172336cadaa649a6e077a42a246a534d.zip
Implement AdaDelta; add test cases; add mnist examples
Diffstat (limited to 'examples')
-rw-r--r--examples/mnist/lenet_adadelta_solver.prototxt22
-rw-r--r--examples/mnist/mnist_autoencoder_solver_adadelta.prototxt17
-rwxr-xr-xexamples/mnist/train_mnist_autoencoder_adadelta.sh4
3 files changed, 43 insertions, 0 deletions
diff --git a/examples/mnist/lenet_adadelta_solver.prototxt b/examples/mnist/lenet_adadelta_solver.prototxt
new file mode 100644
index 00000000..b77b451d
--- /dev/null
+++ b/examples/mnist/lenet_adadelta_solver.prototxt
@@ -0,0 +1,22 @@
+# The train/test net protocol buffer definition
+net: "examples/mnist/lenet_train_test.prototxt"
+# test_iter specifies how many forward passes the test should carry out.
+# In the case of MNIST, we have test batch size 100 and 100 test iterations,
+# covering the full 10,000 testing images.
+test_iter: 100
+# Carry out testing every 500 training iterations.
+test_interval: 500
+# The base learning rate, momentum and the weight decay of the network.
+momentum: 0.95
+weight_decay: 0.0005
+# Display every 100 iterations
+display: 100
+# The maximum number of iterations
+max_iter: 10000
+# snapshot intermediate results
+snapshot: 5000
+snapshot_prefix: "examples/mnist/lenet_adadelta"
+# solver mode: CPU or GPU
+solver_mode: GPU
+solver_type: ADADELTA
+delta: 1e-6
diff --git a/examples/mnist/mnist_autoencoder_solver_adadelta.prototxt b/examples/mnist/mnist_autoencoder_solver_adadelta.prototxt
new file mode 100644
index 00000000..cc4f0bbb
--- /dev/null
+++ b/examples/mnist/mnist_autoencoder_solver_adadelta.prototxt
@@ -0,0 +1,17 @@
+net: "examples/mnist/mnist_autoencoder.prototxt"
+test_state: { stage: 'test-on-train' }
+test_iter: 500
+test_state: { stage: 'test-on-test' }
+test_iter: 100
+test_interval: 500
+test_compute_loss: true
+momentum: 0.95
+display: 100
+max_iter: 65000
+weight_decay: 0.0005
+snapshot: 10000
+snapshot_prefix: "examples/mnist/mnist_autoencoder_adadelta_train"
+# solver mode: CPU or GPU
+solver_mode: GPU
+solver_type: ADADELTA
+delta: 1e-8
diff --git a/examples/mnist/train_mnist_autoencoder_adadelta.sh b/examples/mnist/train_mnist_autoencoder_adadelta.sh
new file mode 100755
index 00000000..4be0ebdd
--- /dev/null
+++ b/examples/mnist/train_mnist_autoencoder_adadelta.sh
@@ -0,0 +1,4 @@
+#!/bin/bash
+
+./build/tools/caffe train \
+ --solver=examples/mnist/mnist_autoencoder_solver_adadelta.prototxt