Skip to content

Commit

Permalink
Fix benchmark arg
Browse files Browse the repository at this point in the history
Signed-off-by: aviator19941 <avinash.sharma@amd.com>
  • Loading branch information
aviator19941 committed Nov 2, 2024
1 parent cef7e2b commit 70940f9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions sharktank/sharktank/utils/export_artifacts.py
Original file line number Diff line number Diff line change
Expand Up @@ -251,13 +251,13 @@ def iree_benchmark_vmfb(
f"--module={vmfb_name}",
]
if self.tensor_parallelism_size > 1:
base_irpa_path, _ = os.path.splitext(path)
base_irpa_path, _ = os.path.splitext(irpa_path)
params = [
f"--parameters=model={base_irpa_path}.rank{i}.irpa"
for i in range(self.tensor_parallelism_size)
]
else:
params = f"--parameters=model={irpa_path}"
params = [f"--parameters=model={irpa_path}"]
benchmark_args += params
benchmark_args += args
cmd = subprocess.list2cmdline(benchmark_args)
Expand Down
10 changes: 5 additions & 5 deletions sharktank/tests/models/llama/benchmark_amdgpu_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,10 @@ class BenchmarkLlama3_1_8B(BaseBenchmarkTest):
def setUp(self):
super().setUp()
# TODO: add numpy files to Azure and download from it
self.artifacts_dir = Path("/data/llama-3.1/weights/8b")
self.gguf_path = self.artifacts_dir / "fp16/llama3.1_8b_fp16.gguf"
self.irpa_path = self.artifacts_dir / "fp16/llama3.1_8b_fp16.irpa"
self.irpa_path_fp8 = self.artifacts_dir / "f8/llama8b_fp8.irpa"
self.artifacts_dir = Path("/data/extra/models/llama3.1_8B")
self.gguf_path = self.artifacts_dir / "llama8b_f16.gguf"
self.irpa_path = self.artifacts_dir / "llama8b_f16.irpa"
self.irpa_path_fp8 = self.artifacts_dir / "llama8b_fp8.irpa"
self.tensor_parallelism_size = 1
self.dir_path_8b = self.dir_path / "llama-8b"
self.temp_dir_8b = Path(self.dir_path_8b)
Expand Down Expand Up @@ -711,7 +711,7 @@ def setUp(self):
strict=True,
raises=IreeCompileException,
)
def testBenchmark405B_f16_Decomposed(self):
def testBenchmark405B_f16_TP8_Decomposed(self):
output_file_name = self.dir_path_405b / "f16_decomposed"
output_mlir = self.llama405b_f16_decomposed_artifacts.create_file(
suffix=".mlir", prefix=output_file_name
Expand Down

0 comments on commit 70940f9

Please sign in to comment.