Annotate dunder functions

Summary: Annotate the (return type of the) following dunder functions across the codebase: `__init__()`, `__len__()`, `__getitem__()`

Reviewed By: nikhilaravi

Differential Revision: D29001801

fbshipit-source-id: 928d9e1c417ffe01ab8c0445311287786e997c7c
This commit is contained in:
Patrick Labatut
2021-06-24 15:18:19 -07:00
committed by Facebook GitHub Bot
parent 35855bf860
commit 64289a491d
35 changed files with 79 additions and 79 deletions

View File

@@ -21,7 +21,7 @@ class GraphConv(nn.Module):
output_dim: int,
init: str = "normal",
directed: bool = False,
):
) -> None:
"""
Args:
input_dim: Number of input features per vertex.

View File

@@ -15,7 +15,7 @@ EPS = 0.00001
class Cube:
def __init__(self, bfl_vertex: Tuple[int, int, int], spacing: int = 1):
def __init__(self, bfl_vertex: Tuple[int, int, int], spacing: int = 1) -> None:
"""
Initializes a cube given the bottom front left vertex coordinate
and the cube spacing

View File

@@ -26,7 +26,7 @@ class SubdivideMeshes(nn.Module):
but different vertex positions.
"""
def __init__(self, meshes=None):
def __init__(self, meshes=None) -> None:
"""
Args:
meshes: Meshes object or None. If a meshes object is provided,