s6.nn.ops package¶
Submodules¶
s6.nn.ops.layers module¶
- class s6.nn.ops.layers.SoftArgmax2d(beta: float = 10.0)¶
Bases:
ModuleSoft-argmax on 2D heatmaps with a learnable beta parameter.
- forward(heatmap: Tensor) Tensor¶
Define the computation performed at every call.
Should be overridden by all subclasses.
Note
Although the recipe for forward pass needs to be defined within this function, one should call the
Moduleinstance afterwards instead of this since the former takes care of running the registered hooks while the latter silently ignores them.
- s6.nn.ops.layers.soft_argmax_2d(heatmap: Tensor, beta: float = 10.0) Tensor¶
Apply soft-argmax on 2D heatmaps to extract keypoint coordinates in normalized [0,1).