mod, params = relax.frontend.detach_params(mod)

mod = relax.get_pipeline("zero")(mod)

db = ms.tir_integration.tune_tir(
    mod=mod,
    target=target,
    work_dir="./tuning_spr_logs",
    max_trials_global=8000,        # SPR은 코어 많아서 더 돌려야 최고 기록 나옴
    max_trials_per_task=100,
    num_trials_per_iter=64,        # 한 번에 더 많은 후보 테스트
    builder=ms.builder.LocalBuilder(),
    
runner=ms.runner.LocalRunner(evaluator_config=ms.runner.EvaluatorConfig(number=3,
 repeat=10)),
    database=ms.database.JSONDatabase(work_dir="./tuning_spr_logs"),
)

print("튜닝 완료! 최고 성능 기록이 database에 저장됨")
print(db.get_all_tuning_records()[0])
print(len(db.get_all_tuning_records()))
print(db.has_workload(mod=mod))

Result

...

meta_schedule.TuningRecord(0x7c552c0aaa30)
2345
Fasle
None

With the above code, tuning seems to be recorded well, but 
print(db.has_workload(mod=mod)) returns false and 
print(db.query(mod=mod,target=target)) returns none.

The db is saved correctly, but is this because of incorrect code, or is there a 
problem with the version (0.22)?





---
[Visit Topic](https://discuss.tvm.apache.org/t/error-with-tune-tir/18801/1) to 
respond.

You are receiving this because you enabled mailing list mode.

To unsubscribe from these emails, [click 
here](https://discuss.tvm.apache.org/email/unsubscribe/e6a144f486fa511a62663e3e3bc3d491eb9c7abf5ef19c0ed0e26142051e105f).

Reply via email to