diff options
author | IOhannes m zmölnig <zmoelnig@users.sourceforge.net> | 2005-05-20 11:06:37 +0000 |
---|---|---|
committer | IOhannes m zmölnig <zmoelnig@users.sourceforge.net> | 2005-05-20 11:06:37 +0000 |
commit | c89e29e887882518062265c5f376ea047b10f756 (patch) | |
tree | 6b1af6429b8d6b62ac5aeb31f704dc22165845b1 | |
parent | bcd05dad0d74950486845bd52472b4c22fcd7721 (diff) |
raised the max.number of inputs/outputs (i needed more of them...)
checks whether max.# IOputs is exceeded (and not just reached)
svn path=/trunk/externals/ann/; revision=3037
-rwxr-xr-x | src/ann_mlp.c | 12 | ||||
-rwxr-xr-x | src/ann_td.c | 8 |
2 files changed, 10 insertions, 10 deletions
diff --git a/src/ann_mlp.c b/src/ann_mlp.c index 326bc6d..6db3238 100755 --- a/src/ann_mlp.c +++ b/src/ann_mlp.c @@ -19,8 +19,8 @@ #define TRAIN 0 #define RUN 1 -#define MAXINPUT 100 -#define MAXOUTPUT 100 +#define MAXINPUT 256 +#define MAXOUTPUT 256 static t_class *ann_mlp_class; @@ -75,15 +75,15 @@ static void createFann(t_ann_mlp *x, t_symbol *sl, int argc, t_atom *argv) if (argc>5) learning_rate = atom_getfloat(argv++); - if (num_input>=MAXINPUT) + if (num_input>MAXINPUT) { - error("too many inputs, maximum allowed is MAXINPUT"); + error("too many inputs, maximum allowed is %d",MAXINPUT); return; } - if (num_output>=MAXOUTPUT) + if (num_output>MAXOUTPUT) { - error("too many outputs, maximum allowed is MAXOUTPUT"); + error("too many outputs, maximum allowed is %d", MAXOUTPUT); return; } diff --git a/src/ann_td.c b/src/ann_td.c index 73aa364..d7dcf3e 100755 --- a/src/ann_td.c +++ b/src/ann_td.c @@ -19,8 +19,8 @@ #define TRAIN 0 #define RUN 1 -#define MAXINPUT 100 -#define MAXOUTPUT 100 +#define MAXINPUT 256 +#define MAXOUTPUT 256 static t_class *ann_td_class; @@ -108,13 +108,13 @@ static void createFann(t_ann_td *x, t_symbol *sl, int argc, t_atom *argv) if (argc>6) learning_rate = atom_getfloat(argv++); - if ((num_input * x->frames)>=MAXINPUT) + if ((num_input * x->frames)>MAXINPUT) { error("too many inputs, maximum allowed is %f", MAXINPUT/x->frames); return; } - if (num_output>=MAXOUTPUT) + if (num_output>MAXOUTPUT) { error("too many outputs, maximum allowed is MAXOUTPUT"); return; |