home *** CD-ROM | disk | FTP | other *** search
- csv3.1 !file format is Control Strategy Version 3.1
- ! Aug 88 (art1.nnc) ART 1 Network
- !************************************************************************
- !* *
- !* ART 1 Network Control Strategy *
- !* *
- !* *
- !* This control strategy assumes the following layers: *
- !* *
- !* layer 0: Input Buffer *
- !* *
- !* layer 1: Input Size Layer (1 PE ) *
- !* layer 2: Input Active Layer ( 1 PE ) *
- !* layer 3: F2 Active Layer ( 1 PE ) *
- !* layer 4: Gain Control Layer ( 1 PE ) *
- !* layer 5: ART F1 Layer *
- !* *
- !* layer 6: F1 size layer ( 1 PE ) *
- !* layer 7: Vigilance Layer ( 1 PE ) *
- !* layer 8: Reset Layer ( 1 PE ) *
- !* layer 9: ART F2 Layer *
- !* *
- !* In the ART 1 Network diagram the layers must be positioned *
- !* geometrically in this order from bottom to top of the screen. *
- !* *
- !************************************************************************
- !
- !MASK label op-code operands comment
- L_saR_sa trace aux3 ! 0 set trace option to aux3
- L_saRi_a cset recall,1 ! 1 Initialize recall count
- L_saR_sa cset wrk2,0 ! 2 work counter
- !
- ! Zero out layers
- !
- L_saRi_a lset in ! 3 Input Layer
- L_saRi_a @init math o=0 ! 4 Zero out layer
- L_saRi_a lset cur,1 ! 5 next layer
- L_saRi_a lcmp abs,9 ! 6 At F2 layer ?
- L_saRi_a blt @init ! 7 loop till done
- L_saRi_a math o=0 ! 8 Zero out F2 layer
- !
- ! Get input
- !
- L_saRi_a lset in ! 9 input layer
- L___Ri_a io read ! 10 get input data (recall)
- L_saR___ io lrnin ! 11 get input data (learn)
- !
- ! Process Input Layer
- !
- L___Ri_a math sum|rnoise|tran|output ! 12
- L_saR___ math sum|lnoise|tran|output|fire !13
- !
- ! START OF MAIN RECALL LOOP
- !
- ! Gain Control - process each of the layers in the attentional subsystem.
- !
- L_saR_sa @rloop lset in,1 ! 14 Start of gain control layers
- L_saR_sa @gain math sum|tran|output|fire ! 15 Process layers
- L_saR_sa lset cur,1 ! 16 next layer
- L_saR_sa lcmp abs,5 ! 17 At F1 layer ?
- L_saR_sa blt @gain ! 18 loop till done
- !
- ! F1 Activity
- !
- L_saR_sa math sum|tran|output|fire ! 19 Top Down filter
- L_saR_sa io wrstep ! 20 Show activity to userio
- L_saR_sa fcmp lflag,36 ! 21 check for user abort
- L_saR_sa banz @end ! 22 break out of loop
- !
- ! Alternate between bottom up filter and reset calculations
- !
- L_saR_sa ccmp wrk2,0 ! 23 Filter or reset ?
- L_saR_sa bne @reset ! 24 do reset calculations
- !
- ! F2 Activity: skip F2 filter except for first time through to
- ! improve speed; values are stored in tran anyway.
- !
- L_saR_sa cset wrk2,1 ! 25 next time do reset
- L_saR_sa lset abs,9 ! 26 F2 layer
- L_saR_sa ccmp recall,1 ! 27 First time through ?
- L_saR_sa bne @skipf ! 28 Skip filter
- L_saR_sa math sum|tran|fire ! 29 F2 filter
- L_saR_sa @skipf math output|e=w|fire ! 30 Competitive output
- L_saR_sa br @rloop ! 31 continue
- !
- ! Calculate Reset - process each of the layers in the orienting subsystem
- !
- L_saR_sa @reset cset wrk2,0 ! 32 next time do filter
- L_saR_sa lset abs,6 ! 33 Start of reset layers
- L_saR_sa @rstlp math sum|tran|output|fire ! 34 Process layers
- L_saR_sa lset cur,1 ! 35 next layer
- L_saR_sa lcmp abs,9 ! 36 At F2 layer ?
- L_saR_sa blt @rstlp ! 37 loop till done
- !
- !
- ! Propagate reset wave
- !
- L_saR_sa lset abs,9 ! 38 F2 layer
- L_saR_sa math set|reset|fire ! 39 reset PEs
- L_saR_sa cadd recall,1 ! 40 increment recall counter
- !
- ! Determine if pattern match has been found. If so, go and update LTM,
- ! if not, continue recall.
- !
- L_saR_sa cset wrk1,0 ! 41 Initialize wrk1
- L_saR_sa math e-=w|cterr|fire ! 42 pre/post resonance error
- L_saR_sa ccmp wrk1,0 ! 43 = 0 ?
- L_saR_sa beq @learn ! 44 steady state, update LTM
- L_s_R_s_ eos ! 45 End of a recall step
- L_saR_sa br @rloop ! 46 continue update
- !
- ! Update Long Term Memory
- L_saR___ @learn lset abs,5 ! 47 F1 layer
- L_saR___ cset wrk1,0 ! 48 Initialize wrk1
- L_saR___ math e=o|cterr|learn|fire ! 49 Store |X| in wrk1, top-down LTM
- L_saR___ lset abs,9 ! 50 F2 layer
- L_saR___ math learn|fire ! 51 Update bottom up LTM
- !
- ! Show output to userio
- !
- L_saR_sa @end lset abs,9 ! 52 F2 layer
- L___R_sa io write ! 53 Write recall output
- L_saR___ io lrnrslt ! 54 Write learn output
- LisaRisa trace 0 ! 55 turn off any trace function
-