type check for torch.testing._internalcodegen:* (#45368)

Summary:
part of `torch.testing._internal.*` effort

Pull Request resolved: https://github.com/pytorch/pytorch/pull/45368

Reviewed By: malfet

Differential Revision: D23950512

Pulled By: walterddr

fbshipit-source-id: 399f712d12cdd9795b0136328f512c3f86a15f24
This commit is contained in:
Rong Rong 2020-09-28 13:56:00 -07:00 committed by Facebook GitHub Bot
parent 7a4c417ed3
commit 986af53be2
2 changed files with 3 additions and 4 deletions

View File

@ -53,9 +53,6 @@ ignore_errors = True
[mypy-torch.distributed.*] [mypy-torch.distributed.*]
ignore_errors = True ignore_errors = True
[mypy-torch.testing._internal.codegen.*]
ignore_errors = True
[mypy-torch.testing._internal.hypothesis_utils.*] [mypy-torch.testing._internal.hypothesis_utils.*]
ignore_errors = True ignore_errors = True

View File

@ -2,6 +2,8 @@ import torch
import numpy as np import numpy as np
import argparse import argparse
from typing import Dict
# debug print # debug print
DEBUG_PRINT = False DEBUG_PRINT = False
@ -71,7 +73,7 @@ def random_topology_test(seed, *inp_tensor_list):
return get_root(dependency_map[x], dependency_map) return get_root(dependency_map[x], dependency_map)
else: else:
return x return x
d_map = {} d_map: Dict[int, int] = {}
num_sets = num_tensor num_sets = num_tensor
candidate = list(range(num_tensor)) candidate = list(range(num_tensor))