mprm icon indicating copy to clipboard operation
mprm copied to clipboard

Some issues (errors) about this work

Open 072jiajia opened this issue 3 years ago • 1 comments

Thanks for bringing the idea of attention to wsss in point cloud! I met two issues in this work

In https://github.com/plusmultiply/mprm/blob/master/datasets/Scannet_subcloud.py#L798 You make the center of the sub-cloud different every time, does it mean that we still need point-level labels to get the sub-cloud-level labels? because the sub-clouds generated by the same seeds might be slightly different.

I think your attention submodules are implemented incorrectly In short, it should be stacked_length = inputs['stacked_length_out'] in https://github.com/plusmultiply/mprm/blob/master/models/network_blocks_mprm.py#L968 https://github.com/plusmultiply/mprm/blob/master/models/network_blocks_mprm.py#L1026

072jiajia avatar Apr 22 '21 15:04 072jiajia

For the second problem, The error can be checkout by modifying vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv def body(start_ind, batch_inds_0, x, xn): batch_length = tf.gather(stacked_length, batch_inds_0) end_ind = start_ind + batch_length # end_ind = start_ind + stacked_length[batch_inds_0] query = x1[start_ind:end_ind] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ to vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv def body(start_ind, batch_inds_0, x, xn): batch_length = tf.gather(stacked_length, batch_inds_0) end_ind = start_ind + batch_length debug_dummy_feature = x1[end_ind-1] zero = tf.reduce_mean(debug_dummy_feature) * 0. query = x1[start_ind:end_ind] + zero ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

It will come up with an Out of Range Error. This error didn't occur because when "slicing" a tensor, if the index is out of range, it will return tensors with size 0 So the dimension still matches the original one

But in fact, it becomes an attention module crossing some parts of other batches, which is different from what is written in the paper

072jiajia avatar Apr 22 '21 15:04 072jiajia