Unverified Commit 0dceac02 authored by Sergii Dymchenko's avatar Sergii Dymchenko Committed by GitHub
Browse files

Fix non-existing parameters in docstrings (#7025)

parent 93723b48
...@@ -275,7 +275,7 @@ class SmoothnessLoss(nn.Module): ...@@ -275,7 +275,7 @@ class SmoothnessLoss(nn.Module):
""" """
Args: Args:
images: tensor of shape (D1, D2, ..., DN, C, H, W) images: tensor of shape (D1, D2, ..., DN, C, H, W)
depths: tensor of shape (D1, D2, ..., DN, 1, H, W) vals: tensor of shape (D1, D2, ..., DN, 1, H, W)
Returns: Returns:
smoothness loss of shape (D1, D2, ..., DN) smoothness loss of shape (D1, D2, ..., DN)
......
...@@ -951,7 +951,7 @@ def create_random_string(length: int, *digits: str) -> str: ...@@ -951,7 +951,7 @@ def create_random_string(length: int, *digits: str) -> str:
Args: Args:
length (int): Number of characters in the generated string. length (int): Number of characters in the generated string.
*characters (str): Characters to sample from. If omitted defaults to :attr:`string.ascii_lowercase`. *digits (str): Characters to sample from. If omitted defaults to :attr:`string.ascii_lowercase`.
""" """
if not digits: if not digits:
digits = string.ascii_lowercase digits = string.ascii_lowercase
......
...@@ -585,8 +585,9 @@ class TestNMS: ...@@ -585,8 +585,9 @@ class TestNMS:
def _reference_nms(self, boxes, scores, iou_threshold): def _reference_nms(self, boxes, scores, iou_threshold):
""" """
Args: Args:
box_scores (N, 5): boxes in corner-form and probabilities. boxes: boxes in corner-form
iou_threshold: intersection over union threshold. scores: probabilities
iou_threshold: intersection over union threshold
Returns: Returns:
picked: a list of indexes of the kept boxes picked: a list of indexes of the kept boxes
""" """
......
...@@ -117,7 +117,7 @@ def get_weight(name: str) -> WeightsEnum: ...@@ -117,7 +117,7 @@ def get_weight(name: str) -> WeightsEnum:
def get_model_weights(name: Union[Callable, str]) -> WeightsEnum: def get_model_weights(name: Union[Callable, str]) -> WeightsEnum:
""" """
Retuns the weights enum class associated to the given model. Returns the weights enum class associated to the given model.
.. betastatus:: function .. betastatus:: function
...@@ -137,7 +137,6 @@ def _get_enum_from_fn(fn: Callable) -> WeightsEnum: ...@@ -137,7 +137,6 @@ def _get_enum_from_fn(fn: Callable) -> WeightsEnum:
Args: Args:
fn (Callable): The builder method used to create the model. fn (Callable): The builder method used to create the model.
weight_name (str): The name of the weight enum entry of the specific model.
Returns: Returns:
WeightsEnum: The requested weight enum. WeightsEnum: The requested weight enum.
""" """
......
...@@ -25,7 +25,7 @@ class BalancedPositiveNegativeSampler: ...@@ -25,7 +25,7 @@ class BalancedPositiveNegativeSampler:
def __call__(self, matched_idxs: List[Tensor]) -> Tuple[List[Tensor], List[Tensor]]: def __call__(self, matched_idxs: List[Tensor]) -> Tuple[List[Tensor], List[Tensor]]:
""" """
Args: Args:
matched idxs: list of tensors containing -1, 0 or positive values. matched_idxs: list of tensors containing -1, 0 or positive values.
Each tensor corresponds to a specific image. Each tensor corresponds to a specific image.
-1 values are ignored, 0 are considered as negatives and > 0 as -1 values are ignored, 0 are considered as negatives and > 0 as
positives. positives.
......
...@@ -2123,7 +2123,7 @@ class ElasticTransform(torch.nn.Module): ...@@ -2123,7 +2123,7 @@ class ElasticTransform(torch.nn.Module):
def forward(self, tensor: Tensor) -> Tensor: def forward(self, tensor: Tensor) -> Tensor:
""" """
Args: Args:
img (PIL Image or Tensor): Image to be transformed. tensor (PIL Image or Tensor): Image to be transformed.
Returns: Returns:
PIL Image or Tensor: Transformed image. PIL Image or Tensor: Transformed image.
......
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