Skip to content

Commit 0400e6c

Browse files
committed
[Backend Tester] Reduce log verbosity / spam
ghstack-source-id: ffceed5 ghstack-comment-id: 3177730920 Pull-Request: #13312
1 parent 5592c71 commit 0400e6c

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

backends/test/harness/stages/serialize.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
try:
1414
from executorch.extension.pybindings.portable_lib import ( # @manual
1515
_load_for_executorch_from_buffer,
16+
Verification,
1617
)
1718
except ImportError as e:
1819
logger.warning(f"{e=}")
@@ -39,7 +40,9 @@ def graph_module(self) -> None:
3940

4041
def run_artifact(self, inputs):
4142
inputs_flattened, _ = tree_flatten(inputs)
42-
executorch_module = _load_for_executorch_from_buffer(self.buffer)
43+
executorch_module = _load_for_executorch_from_buffer(
44+
self.buffer, program_verification=Verification.Minimal
45+
)
4346
executorch_output = copy.deepcopy(
4447
executorch_module.run_method("forward", tuple(inputs_flattened))
4548
)

backends/test/suite/runner.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
import re
44
import time
55
import unittest
6+
import warnings
67

78
from datetime import timedelta
89
from typing import Any
@@ -250,7 +251,11 @@ def build_test_filter(args: argparse.Namespace) -> TestFilter:
250251
def runner_main():
251252
args = parse_args()
252253

253-
begin_test_session()
254+
# Suppress deprecation warnings for export_for_training, as it generates a
255+
# lot of log spam. We don't really need the warning here.
256+
warnings.simplefilter("ignore", category=FutureWarning)
257+
258+
begin_test_session(args.report)
254259

255260
if len(args.suite) > 1:
256261
raise NotImplementedError("TODO Support multiple suites.")

0 commit comments

Comments
 (0)