alexgkendall / caffe-segnet

Implementation of SegNet: A Deep Convolutional Encoder-Decoder Architecture for Semantic Pixel-Wise Labelling

Home Page:http://mi.eng.cam.ac.uk/projects/segnet/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Weighted Softmax Loss

atanas1054 opened this issue · comments

Hello,

I want to use just the weighted softmax layer in SegNet without actually using the SegNet architecture. How can I just take the weighted softmax layer and compile it on the latest caffe version?

Try to copy the files src/caffe/layers/softmax_loss_layer.cpp and .cu and include/caffe/layers/softmax_loss_layer.hpp

Also check src/caffe/proto/caffe.proto and see if the LossParameter "class_weighting" is there.

Hope it works.

Hey,
There is no include/caffe/layers/softmax_loss_layer.hpp

This repo is based on an old version of caffe.

the repo here: https://github.com/TimoSaemann/caffe-segnet-cudnn5 has the layers factored out into individual header files. (see there's no "vision_layers.hpp", "loss_layers.hpp", etc.). I think this is how the most updated caffe does it still.

https://github.com/TimoSaemann/caffe-segnet-cudnn5/blob/master/include/caffe/layers/softmax_loss_layer.hpp

It's working now. Thank you.