我正在使用 LSTM 进行情绪分类,并且我有三个可选类 - 负面/正面/中性。
我想知道是否有一种方法可以使用单个输出进行此分类,该输出将在 -1:1 的范围内,而 -1 是中性类,0 是负类,1 是正类。
我知道sigmoid函数从 0 到 1,tanh从 -1 到 1,所以使用tanh可能是一个很好的引导,但是使用单个输出分类到三个不同的类仍然有意义吗?
我正在使用 LSTM 进行情绪分类,并且我有三个可选类 - 负面/正面/中性。
我想知道是否有一种方法可以使用单个输出进行此分类,该输出将在 -1:1 的范围内,而 -1 是中性类,0 是负类,1 是正类。
我知道sigmoid函数从 0 到 1,tanh从 -1 到 1,所以使用tanh可能是一个很好的引导,但是使用单个输出分类到三个不同的类仍然有意义吗?
Basically it's rather more useful to have three units for each class rather than one - which in the end gives you a score helpful in assigning appropriate class. The intuition behind this is the following :
So, to sum up - to have an efficient model which works with final output between -1 :1 you need to have the same units in your network as will do the job in case with three outputs. Moreover - you need to add additional complexity which will make the outputs from "positive" and "negative" units less significant in neutral case. So - that would rather hurt your training than help in anything.