MCPcopy Create free account
hub / github.com/VDIGPKU/HENet / encode_decode

Method encode_decode

mmdet3d/models/segmentors/encoder_decoder.py:77–90  ·  view source on GitHub ↗

Encode points with backbone and decode into a semantic segmentation map of the same size as input. Args: points (torch.Tensor): Input points of shape [B, N, 3+C]. img_metas (list[dict]): Meta information of each sample. Returns: torch.Ten

(self, points, img_metas)

Source from the content-addressed store, hash-verified

75 return x
76
77 def encode_decode(self, points, img_metas):
78 """Encode points with backbone and decode into a semantic segmentation
79 map of the same size as input.
80
81 Args:
82 points (torch.Tensor): Input points of shape [B, N, 3+C].
83 img_metas (list[dict]): Meta information of each sample.
84
85 Returns:
86 torch.Tensor: Segmentation logits of shape [B, num_classes, N].
87 """
88 x = self.extract_feat(points)
89 out = self._decode_head_forward_test(x, img_metas)
90 return out
91
92 def _decode_head_forward_train(self, x, img_metas, pts_semantic_mask):
93 """Run forward function and calculate loss for decode head in

Callers 3

forward_dummyMethod · 0.95
slide_inferenceMethod · 0.95
whole_inferenceMethod · 0.95

Calls 2

extract_featMethod · 0.95

Tested by

no test coverage detected