# HG changeset patch
# User boulanni
# Date 1275456889 14400
# Node ID 269c39f55134fe9b78c8b556b6443a2460f27ec1
# Parent 84f42fe05594a0016d14484d8b09ce972980bd42
Added demo source files
diff -r 84f42fe05594 -r 269c39f55134 demo/Test1.mxml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/demo/Test1.mxml Wed Jun 02 01:34:49 2010 -0400
@@ -0,0 +1,327 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ imdraw.width || y<0 || y>imdraw.height) {
+ stop_drawing(e)
+ return
+ }*/
+ can2.graphics.lineTo(x, y);
+ changeDrawing()
+ changeImage()
+ e.updateAfterEvent();
+ }
+
+ private function changeDrawing():void{
+ var bitmapDataObject2:BitmapData = new BitmapData(32, 32, false, 0x00000000);
+ var rect:Rectangle = new Rectangle(0, 0, 32, 32);
+ var m:Matrix = new Matrix()
+ m.scale(32/imdraw.width, 32/imdraw.height)
+ bitmapDataObject2.draw(can2,m,null,null,null,true);
+ var myBitmap:Bitmap = new Bitmap(bitmapDataObject2);
+ imdraw.source = myBitmap;
+ }
+
+ private var ready:Boolean = false;
+ private var cache:Number;
+ public function RandNormal(sigma:Number):Number {
+ ready = !ready;
+ if (!ready) return cache * sigma;
+ var x:Number = Math.sqrt(-2 * Math.log(Math.random())), y:Number = Math.random()
+ cache = x * Math.cos(2*Math.PI*y);
+ return x * Math.sin(2*Math.PI*y) * sigma;
+ }
+
+ private function changeImage():void{
+
+ var bitmapDataObject2:BitmapData = new BitmapData(32, 32, false, 0x00000000);
+
+ var can3:Sprite = new Sprite()
+ var x:Number, y:Number, l:int, t:Number, w:int, c:uint, n:uint
+ n = int(0.999 + 3*rat.value)
+ for(var j:uint=0; j
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Shallow MLP 500 h.u. /NIST
+ Deep SDA 3x1000 h.u. /P07
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff -r 84f42fe05594 -r 269c39f55134 demo/default.php
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/demo/default.php Wed Jun 02 01:34:49 2010 -0400
@@ -0,0 +1,48 @@
+
+Demo
+
+
+
Deep Self-Taught Learning for Handwritten Character Recognition
+
+
+This demo allows you to compare two neural network detectors of handwritten characters:
+
+
A shallow multi-layer perceptron (MLP) with one hidden layer of 500 units;
+
A deep network trained with stacked denoising autoencoders (SDA) of 1000 hidden units each.
+
+Both classifiers are trained on P07, a distribution that combines multiple datasets and stochastic transformations.
+
+
+
+The demo provides real-time detection of characters as you draw (left panel) and apply transforms (middle panel) similar to the ones in P07. The three best results are shown (right panel) along with the confidence of the detector.
+