MCPcopy Create free account
hub / github.com/Zhiyuan-R/Tiger-Diffusion / forward

Method forward

modules/pointnet.py:101–113  ·  view source on GitHub ↗
(self, inputs)

Source from the content-addressed store, hash-verified

99 self.mlp = SharedMLP(in_channels=in_channels, out_channels=out_channels, dim=1)
100
101 def forward(self, inputs):
102 if len(inputs) == 3:
103 points_coords, centers_coords, centers_features, temb = inputs
104 points_features = None
105 else:
106 points_coords, centers_coords, centers_features, points_features, temb = inputs
107 interpolated_features = F.nearest_neighbor_interpolate(points_coords, centers_coords, centers_features)
108 interpolated_temb = F.nearest_neighbor_interpolate(points_coords, centers_coords, temb)
109 if points_features is not None:
110 interpolated_features = torch.cat(
111 [interpolated_features, points_features], dim=1
112 )
113 return self.mlp(interpolated_features), points_coords, interpolated_temb

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected