MinkowskiEngine icon indicating copy to clipboard operation
MinkowskiEngine copied to clipboard

How to recompose sparse tensor after batch-wise decomposition?

Open ghost opened this issue 4 years ago • 1 comments
trafficstars

Hi,

I am trying to extend OverlapPredator.Mink to support batch training. Predator is composed of three modules: a Minkowski encoder, a GNN and a Minkowski decoder. After the encoder, I have to perform batch-wise decomposition for the GNN. Then after the GNN, I have to recompose a sparse tensor which shares the coordinate_manager and coordinate_key_map with the sparse tensor from the encoder. How should I implement this?

Thanks.

ghost avatar Mar 31 '21 16:03 ghost

You can use the function ME.utils.batched_coordinates to recreate batched coordinates. For features, you can simply concatenate along the 0th dim.

chrischoy avatar Apr 07 '21 05:04 chrischoy