PointNetFeatureBlock

class maze.perception.blocks.feed_forward.point_net.PointNetFeatureBlock(*args: Any, **kwargs: Any)

PointNet block allowing to embed a variable sized set of point observations into a fixed size feature vector via the PointNet mechanics. (https://arxiv.org/abs/1612.00593 from Stanford University).

The block processed the input with one input transformation, two 1d convolutions each followed by an optional batch normalization and a non linearity. Then an optional feature transformation is applied before a final convolutional layer. Lastly a masked global pooling block is used to pool all values in the point dimension resulting in a two dimensional vector (batch_dim, feature_dim). The mask for pooling is an optional parameter.

Parameters
  • in_keys – One key identifying the input tensors, a second optional one identifying the masking tensor.

  • out_keys – One key identifying the output tensors.

  • in_shapes – List of input shapes.

  • embedding_dim – The embedding dimension to use throughout the block, this is also specifies the dimension of the output. (Paper: 1024)

  • pooling_func_name – A string in (‘max’, ‘mean’, ‘sum’) specifying the pooling function to use. (Paper: ‘max’)

  • use_feature_transform – Whether to use the feature transformation after the second convolution. (Paper: True)

  • use_batch_norm – Specify whether to use batch_norm (is disables for batches of size <2).

  • non_lin – The non-linearity to apply after each layer.

normalized_forward(block_input: Dict[str, torch.Tensor]) → Dict[str, torch.Tensor]

(overrides ShapeNormalizationBlock)

implementation of ShapeNormalizationBlock interface