Discussion:
Should the input node has values between 0 and 1?
Sang Chul Choi
2007-03-15 22:03:33 UTC
Permalink
Hi,

I have a simple question (I hope). I used the fann and
the values of input node were 0 or 1. Now, I think that I need
to give a real number between -4 and 3. Can I use this real number
for the input node? Or, should I manange to convert this number
between -1 and 1 or between 0 and 1?

Thank you,

Sang Chul

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Steffen Nissen
2007-03-16 06:40:25 UTC
Permalink
Inputs can be arbitrary numbers, so between -4 and 3 is no problem.
Post by Sang Chul Choi
Hi,
I have a simple question (I hope). I used the fann and
the values of input node were 0 or 1. Now, I think that I need
to give a real number between -4 and 3. Can I use this real number
for the input node? Or, should I manange to convert this number
between -1 and 1 or between 0 and 1?
Thank you,
Sang Chul
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Fann-general mailing list
https://lists.sourceforge.net/lists/listinfo/fann-general
--
Steffen Nissen - http://MySpace.com/SteffenNissen
Project Administrator - Fast Artificial Neural Network Library (fann)
http://fann.sf.net
Chris Spencer
2007-03-16 13:10:31 UTC
Permalink
I was unaware FANN had the ability to accept unbounded values. I was
under the impression that all input/output is assumed scaled between
-1 and +1 and must otherwise be scaled to within this range. What then
are fann_scale_input_train_data, fann_scale_output_train_data, and
fann_scale_train_data used for if FANN doesn't care about the scale
you provide?

Regards,
Chris
Post by Steffen Nissen
Inputs can be arbitrary numbers, so between -4 and 3 is no problem.
Post by Sang Chul Choi
Hi,
I have a simple question (I hope). I used the fann and
the values of input node were 0 or 1. Now, I think that I need
to give a real number between -4 and 3. Can I use this real number
for the input node? Or, should I manange to convert this number
between -1 and 1 or between 0 and 1?
Thank you,
Sang Chul
-------------------------------------------------------------------------
Post by Sang Chul Choi
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share
your
Post by Sang Chul Choi
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Post by Sang Chul Choi
_______________________________________________
Fann-general mailing list
https://lists.sourceforge.net/lists/listinfo/fann-general
--
Steffen Nissen - http://MySpace.com/SteffenNissen
Project Administrator - Fast Artificial Neural Network Library (fann)
http://fann.sf.net
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Fann-general mailing list
https://lists.sourceforge.net/lists/listinfo/fann-general
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Daniel Scott
2007-03-16 13:29:08 UTC
Permalink
Post by Chris Spencer
I was unaware FANN had the ability to accept unbounded values. I was
under the impression that all input/output is assumed scaled between
-1 and +1 and must otherwise be scaled to within this range. What then
are fann_scale_input_train_data, fann_scale_output_train_data, and
fann_scale_train_data used for if FANN doesn't care about the scale
you provide?
In my experience, the best ANN performance is obtained when you take
your real values data, scale it to be within -1, 1 and then use the
scaled inputs to train the network. If you retain the scaling
parameters, you can then use the ANN on real test data by similar
scaling of the test set.

You can use unscaled data, but I've found that it often causes
over/underflow of the weights/biases.

Hope this helps,

Dan

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Seth Price
2007-03-16 13:44:17 UTC
Permalink
http://leenissen.dk/fann/html/files/fann_data-
h.html#fann_activationfunc_enum

Most functions are "span: -1<y<1" or "span: 0<y<1", but not all.
~Seth
Post by Chris Spencer
I was unaware FANN had the ability to accept unbounded values. I was
under the impression that all input/output is assumed scaled between
-1 and +1 and must otherwise be scaled to within this range. What then
are fann_scale_input_train_data, fann_scale_output_train_data, and
fann_scale_train_data used for if FANN doesn't care about the scale
you provide?
Regards,
Chris
Post by Steffen Nissen
Inputs can be arbitrary numbers, so between -4 and 3 is no problem.
Post by Sang Chul Choi
Hi,
I have a simple question (I hope). I used the fann and
the values of input node were 0 or 1. Now, I think that I need
to give a real number between -4 and 3. Can I use this real number
for the input node? Or, should I manange to convert this number
between -1 and 1 or between 0 and 1?
Thank you,
Sang Chul
---------------------------------------------------------------------
----
Post by Sang Chul Choi
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share
your
Post by Sang Chul Choi
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?
page=join.php&p=sourceforge&CID=DEVDEV
Post by Sang Chul Choi
_______________________________________________
Fann-general mailing list
https://lists.sourceforge.net/lists/listinfo/fann-general
--
Steffen Nissen - http://MySpace.com/SteffenNissen
Project Administrator - Fast Artificial Neural Network Library (fann)
http://fann.sf.net
---------------------------------------------------------------------
----
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?
page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Fann-general mailing list
https://lists.sourceforge.net/lists/listinfo/fann-general
----------------------------------------------------------------------
---
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?
page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Fann-general mailing list
https://lists.sourceforge.net/lists/listinfo/fann-general
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Steffen Nissen
2007-03-16 15:37:49 UTC
Permalink
I can elaborate a bit on this.

The inputs are completely independent of the activation function, so no
matter which activation function there is used, the inputs can be in any
range. The outputs on the other hand do depend on the the activation
function, so the outputs are bounded by the activation function (see
http://leenissen.dk/fann/html/files/fann_data-h.html#fann_activationfunc_enum
).

I do however not recommend using inputs that are too large (more than a
couple of hundred), since all the parameters, weights etc. are geared
towards inputs in the -1 to 1 range. This is why people often scale the
inputs too.

Regards,
Steffen
Post by Seth Price
http://leenissen.dk/fann/html/files/fann_data-
h.html#fann_activationfunc_enum
Most functions are "span: -1<y<1" or "span: 0<y<1", but not all.
~Seth
Post by Chris Spencer
I was unaware FANN had the ability to accept unbounded values. I was
under the impression that all input/output is assumed scaled between
-1 and +1 and must otherwise be scaled to within this range. What then
are fann_scale_input_train_data, fann_scale_output_train_data, and
fann_scale_train_data used for if FANN doesn't care about the scale
you provide?
Regards,
Chris
Post by Steffen Nissen
Inputs can be arbitrary numbers, so between -4 and 3 is no problem.
Post by Sang Chul Choi
Hi,
I have a simple question (I hope). I used the fann and
the values of input node were 0 or 1. Now, I think that I need
to give a real number between -4 and 3. Can I use this real number
for the input node? Or, should I manange to convert this number
between -1 and 1 or between 0 and 1?
Thank you,
Sang Chul
---------------------------------------------------------------------
----
Post by Sang Chul Choi
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share
your
Post by Sang Chul Choi
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?
page=join.php&p=sourceforge&CID=DEVDEV
Post by Sang Chul Choi
_______________________________________________
Fann-general mailing list
https://lists.sourceforge.net/lists/listinfo/fann-general
--
Steffen Nissen - http://MySpace.com/SteffenNissen
Project Administrator - Fast Artificial Neural Network Library (fann)
http://fann.sf.net
---------------------------------------------------------------------
----
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?
page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Fann-general mailing list
https://lists.sourceforge.net/lists/listinfo/fann-general
----------------------------------------------------------------------
---
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?
page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Fann-general mailing list
https://lists.sourceforge.net/lists/listinfo/fann-general
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Fann-general mailing list
https://lists.sourceforge.net/lists/listinfo/fann-general
--
Steffen Nissen - http://MySpace.com/SteffenNissen
Project Administrator - Fast Artificial Neural Network Library (fann)
http://fann.sf.net
Loading...