Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
qingyunqu committed Aug 24, 2024
1 parent 42a4e54 commit ceae8bd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion compiler/python/byteir/compile.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from enum import Enum
from pathlib import Path
import os
from shutil import copymode
from typing import Union

from . import ir
from .passmanager import PassManager
Expand Down
8 changes: 4 additions & 4 deletions tests/numerical_test/execute.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,9 +149,9 @@ def compile_and_run_mlir(mhlo_file, target, workdir, verbose, mode="numerical",
torch_outputs = data_generator.generate_torch_outputs(cur_device)

if mode == "numerical":
brt_backend.run(torch_inputs, torch_outputs)
brt_backend.run_with_outputs(torch_inputs, torch_outputs)
else:
avg_time = brt_backend.profile(torch_inputs, torch_outputs)
avg_time = brt_backend.profile_with_outputs(torch_inputs, torch_outputs)
return TestResult(
unique_name=unique_name,
compilation_error=None,
Expand Down Expand Up @@ -246,9 +246,9 @@ def compile_and_run_torch(test, target, workdir, verbose, mode="numerical"):
try:
brt_backend = BRTBackend(output_mlir_file_name, cur_device)
if mode == "numerical":
brt_backend.run(torch_inputs, torch_outputs)
brt_backend.run_with_outputs(torch_inputs, torch_outputs)
else:
avg_time = brt_backend.profile(torch_inputs, torch_outputs)
avg_time = brt_backend.profile_with_outputs(torch_inputs, torch_outputs)
return TestResult(
unique_name=unique_name,
compilation_error=None,
Expand Down

0 comments on commit ceae8bd

Please sign in to comment.