Skip to content

Commit dd5dd78

Browse files
committed
Fixup json load
1 parent 158a672 commit dd5dd78

File tree

1 file changed

+3
-5
lines changed
  • models/turbine_models/custom_models/torchbench

1 file changed

+3
-5
lines changed

models/turbine_models/custom_models/torchbench/export.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -420,7 +420,7 @@ def run_main(model_id, args, tb_dir, tb_args):
420420
if args.compile_to in ["torch", "mlir"]:
421421
safe_name = utils.create_safe_name(
422422
model_id,
423-
f"_{static_dim}_{precision}",
423+
f"_{static_dim}_{args.precision}",
424424
)
425425
with open(f"{safe_name}.mlir", "w+") as f:
426426
f.write(mod_str)
@@ -445,11 +445,9 @@ def run_main(model_id, args, tb_dir, tb_args):
445445
from turbine_models.custom_models.torchbench.cmd_opts import args, unknown
446446
import json
447447

448-
torchbench_models_dict = json.load(args.model_list_json)
449448
for list in args.model_lists:
450-
torchbench_models_dict = json.load(list)
451-
with open(args.models_json, "r") as f:
452-
torchbench_models_dict = json.load(file)
449+
with open(list, "r") as f:
450+
torchbench_models_dict = json.load(f)
453451

454452
tb_dir = setup_torchbench_cwd()
455453
if args.model_id.lower() == "all":

0 commit comments

Comments
 (0)