Closed machanic closed 7 years ago
Hey, you should check both multi_stage_meanfield as well as the meanfield_iteration code.
Hi @sharpstill,
Unfortunately, we don't have enough bandwidth to answer this kind of queries in detail. But please note that there's no discrepancy between what's written in the paper and the implementation. Please find my short answers to your queries below:
1.) Line 143 - line 153 of meanfield_iteration.cpp does exactly this weighting.
2.) Line 155 does this. It's just a different way of implementing it, but the effect is the same.
3.) & 4.) Again, these computations agree with the steps described in the paper. Please refer to the documentation of the relevant Caffe functions and the BLAS API for help.
1. where is weighting filter outputs step in source code? I notice that the paper said there is weighting filter outputs step , but the source code meanfield_iteration.cpp in line 155 directly omit this step?
2. the paper and the code written about 1x1 conv don't match? in the paper said that the compatibility transform there is 1x1 conv to sovle this weight linear combination: meanfield_iteration.cpp in line 155~162 directly omit this 1x1 conv?
vector<bool> eltwise_propagate_down(2, true);
why is 2 set here, because sum_topvec only have 2 element in it?3. in meanfield_iteration.cpp line : 182:
caffe_cpu_gemm<Dtype>(CblasNoTrans, CblasTrans, channels_, channels_, num_pixels_, (Dtype) 1., pairwise_.cpu_diff() + pairwise_.offset(n), message_passing_.cpu_data() + message_passing_.offset(n), (Dtype) 1., this->blobs_[2]->mutable_cpu_diff());
why transpose messagepassing matrix here?4. again in line 190
caffe_cpu_gemm<Dtype>(CblasTrans, CblasNoTrans, channels_, num_pixels_, channels_, (Dtype) 1., this->blobs_[2]->cpu_data(), pairwise_.cpu_diff() + pairwise_.offset(n), (Dtype) 0., message_passing_.mutable_cpu_diff() + message_passing_.offset(n));
why transpose this->blobs_[2] here?