Commit 7b546055 authored by mibaumgartner's avatar mibaumgartner
Browse files

fix

parent ac24a62a
...@@ -267,6 +267,15 @@ class AnchorGenerator2D(torch.nn.Module): ...@@ -267,6 +267,15 @@ class AnchorGenerator2D(torch.nn.Module):
# self._cache.clear() # self._cache.clear()
return anchors return anchors
def num_anchors_per_location(self) -> List[int]:
"""
Number of anchors per resolution
Returns:
List[int]: number of anchors per positions for each resolution
"""
return [len(s) * len(a) for s, a in zip(self.sizes, self.aspect_ratios)]
def get_num_acnhors_per_level(self) -> List[int]: def get_num_acnhors_per_level(self) -> List[int]:
""" """
Number of anchors per resolution Number of anchors per resolution
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment