home *** CD-ROM | disk | FTP | other *** search
- inst4.0 ! 07-Aug-90 (dnnasamp.ins) DNNA InstaNet
- !****************************************************************
- !* *
- !* Digital Neural Network Architecture Builder *
- !* sample XOR problem *
- !****************************************************************
-
-
- ! *** Load the Control Strategy and LRS if needed
-
- @LdCS "backprop" !control strategy
- @LdLR "backprop" !L/R schedule
-
- =netn "InstaNet (tm) Digital Neural Network Arch. version 2.0 07-Aug-90"
-
- =DRcF 1 !recall re-display on
- =DRcN 1 !show each recall
-
- ! *** Build the Input Layer ***
-
- @LLdf !load default layer to mi_layer structure
- =LDln "In" !layer name
- =Lpes 2 !2 PEs for XOR
- =Ltrn "Linear" !buffer
- =LDsp 6 !spacing
- =x 100 !place to put layer on screen
- =y 80
- #Incl "stdnwgtf.iif" !standard # weight fields
- @LAdd !add the input layer
- =x 130 !position hidden & output over center
-
- ! *** Build the first hidden Layer ***
-
- @LLdf !start with default layer again
- =LDln "Hidden 1" !layer name
- =Lpes 3 !Three Hidden PEs
- =Lsum "DNNA" !DNNA sum function
- =Ltrn "DNNA" !DNNA transfer function
- =Llrn "Delta-Rule" !Standard Delta learning rule
- +y 60 !up higher on display
- #Incl "stdnwgtf.iif" !standard # weight fields
- @LAdd
-
- ! *** Connect Hidden Layer to Bias & Input Layers ***
-
- =SPEl LayN !current layer
- @SlPE !select it as destination (sb already)
- =NPEl -1 !near to bias term (source)
- @NrPE
- =cnwt 1.0 !connection weight
- =cnty WVar !variable
- =cnsc WAbs !absolute
- @LCFl !fully connect to bias element
- =NPEl 0 !input layer
- @NrPE
- @LCFl !fully connect to input layer
- =n0 LayN !save current layer for later
-
-
- ! *** Build the output layer & connect it to prior layer & bias term ***
-
- @LLdf !load default layer to mi_layer structure
- =LDln "Out" !layer name
- =Lpes 1 !1 output PE
- =Lsum "DNNA" !DNNA sum function
- =Ltrn "DNNA" !DNNA transfer function
- =Llrn "Delta-Rule" !Standard Delta learning rule
- +y 60
- #Incl "stdnwgtf.iif" !standard # weight fields
- @LAdd !add the output layer
- =n7 LayN !save for stdprobe
-
- =SPEl LayN !current layer
- @SlPE !select it as destination (sb already)
- =NPEl -1 !near to bias term (source)
- @NrPE
- @LCFl !fully connect to bias element
- =NPEl n0 !previous layer
- @NrPE
- @LCFl !fully connect to input layer
-
- ! *** Select Control Strategy & L/R Schedule ***
-
- =LrnN 2000 !learn counter for LearnN
- @LLsl !load super layer
- =Lax1 1 !epoch size of 1
- =Lctl "backprop" !backprop control strategy
- =Llrs "backprop" !backprop L/R Schedule
- =Llnn "sample" !name of learn input
- =Lrcn "sample" !name of recall output
- #Incl "stdioset.iif" !standard I/O settings
- =Lscl -1.0 !input low-value
- =Loff 1.0 !input high-value
- =Llow 0.2 !output low-value
- =Lhgh 0.8 !output high-value
- =DLnN 1 !learn count for Check Points
- =MWLF 1 !turn on weight limiting
- =WtVl 0.99 !max value for weight limiting
- @SVsl !save it back
- !
- =n5 0.0
- =n6 1.0
- =n4 &Out
- #Incl "stdprobe.iif" !Standard probe include file
- !
- =jogl -.1 !lower limit for jog
- =jogh +.1 !upper limit for jog
- =seed 257 !starting seed number
- @seed !set the seed
- @Nini !initialize the network
-
- @LLsl !load super layer
- =Lepc 0 !set learn counter to zero
- @SVsl !save it back
- @EOF
-
-