Filter löschen
Filter löschen

hardlim returns 0.5 and 1 !!

1 Ansicht (letzte 30 Tage)
Morteza
Morteza am 27 Mär. 2019
Beantwortet: Garrett Beard am 3 Dez. 2021
I have a binarry classification problem with 0-1 classes. I used 3layered neural network with "hardlim" as the activation function of output layer and "tansig" for hidden and input layer. I am wonderfull why my predicted output contains 0.5 and 1 instead of 0-1 !!
Does MATLAB automatically normalizes data when we use it's standard function for NN? Or I should manually normalize data?
  5 Kommentare
Hugo Fournier
Hugo Fournier am 24 Feb. 2020
Same problem here. Have you found a solution?
Morteza
Morteza am 25 Feb. 2020
Unfortunately No. We can replace 0.5 by 0.

Melden Sie sich an, um zu kommentieren.

Akzeptierte Antwort

Garrett Beard
Garrett Beard am 3 Dez. 2021
'net variable'.output.processFcns = {}
By default, the neural network class applies mapminmax to the output vector. Remove the normalization and you will get [0, 1] for outputs.

Weitere Antworten (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by