Rename NewCriterionTest to CriterionTest. (#44056)

Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/44056

Test Plan: Imported from OSS

Reviewed By: zou3519

Differential Revision: D23482573

Pulled By: gchanan

fbshipit-source-id: dde0f1624330dc85f48e5a0b9d98fb55fdb72f68
This commit is contained in:
Gregory Chanan
2020-09-03 10:26:53 -07:00
committed by Facebook GitHub Bot
parent 7d95eb8633
commit 5973b44d9e
4 changed files with 8 additions and 8 deletions

View File

@ -21,7 +21,7 @@ TorchNNModuleTestParams = namedtuple(
# Unique identifier for this module config (e.g. "BCELoss_weights_cuda")
'module_variant_name',
# An instance of an NN test class (e.g. `NewCriterionTest`) which stores
# An instance of an NN test class (e.g. `CriterionTest`) which stores
# necessary information (e.g. input / target / extra_args) for running the Python test
'test_instance',
@ -184,7 +184,7 @@ def move_cpp_tensors_to_device(cpp_tensor_stmts, device):
return ['{}.to("{}")'.format(tensor_stmt, device) for tensor_stmt in cpp_tensor_stmts]
def is_criterion_test(test_instance):
return isinstance(test_instance, common_nn.NewCriterionTest)
return isinstance(test_instance, common_nn.CriterionTest)
# This function computes the following:
# - What variable declaration statements should show up in the C++ parity test function