Created
October 13, 2013 11:59
-
-
Save anonymous/6961481 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
DEFINE A GRID | |
dg 4,1, [LINEAR_NODE_TYPE or STANDARD_NODE_TYPE] | |
mg Grid1 | |
CONNECT NODES WITHIN GRID[S] | |
connectnodes nth_node(Grid1, n), nth_node(Grid1, n) | |
- THROUGHOUT TWO GRIDS | |
connectnodes first_node(input), first_node(output) | |
[ALL NODES IN GRIDS] | |
connect input, output | |
SET WEIGHTS | |
- [THROUGHOUT ALL THE NET] set_weights 0.95 | |
- [ONE AT A TIME]: | |
let wire_ID = nth_output_wire(nth_node(input_grid,1), 1) | |
set_wire_weight wire_ID, 0.2 | |
OR | |
set_weightsbetnodes input_node,output_node,1.5 | |
LOAD DATA IN ARRAY | |
float inputs[4] | |
loadfloatarray inputs, "TEST1.DAT" | |
LOOP | |
int i = 0 | |
for i=0 to 3 | |
set_node_output nth_node(Grid1, i), inputs[i] | |
next i | |
UPDATE | |
updategrid Grid1 | |
drawgrid Grid1 | |
drawwires | |
DELAY | |
ms_delay 200 | |
GRAPH | |
graph_default_gridtype 0 | |
graph_default_axislabel "Input:", "Output" | |
graph_default_range 0, 0, 99, 1 | |
makegraph third_node_output | |
- To activate: | |
graph_active third_node_output | |
- To draw | |
plot float(i), node_output(nth_node(Grid1, 2)), YELLOW |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment