7 ms·
With some changes - yes. I did this in my experimental project: https://github.com/indutny/resistenz/blob/master/python/model.py#L102-L106 https://github.com/in
by indutny 8y ago
With some changes - yes. I did this in my experimental project: https://github.com/indutny/resistenz/blob/master/python/model.py#L102-L106 https://github.com/indutny/resistenz/blob/master/python/mode...
The idea is to add an extra 2 params to the output of each classifier cell. Then do L2 normalization on them ( https://github.com/indutny/resistenz/blob/master/python/model.py#L268 https://github.com/indutny/resistenz/blob/master/python/mode... ) and treat them as a cosine/sine pair.
The loss in this case would be the Euclidean distance between the actual and predicted pairs, which is equal to "2 * (1 - cos(x-y))".