[go: up one dir, main page]

Gas_benchmarks: launch benchmark for `Ticket_costs.Constants.cost_compare_key_contract`

The MR !4491 (merged) adds a new benchmark COMPARE_CONTRACT_alpha, defined in Ticket_benchmarks. This issue is to launch that benchmark and if necessary correct the value of Ticket_costs.Constants.cost_compare_key_contract.

For example, the script

BENCHMARK="COMPARE_CONTRACT_alpha"
MODEL="compare"

BENCH_NUM=1000
NSAMPLES=500
SEED=1234

WORKLOAD_FILE="${BENCHMARK}.workload"
CSV_FILE="${BENCHMARK}.csv"

# Run benchmark
./tezos-snoop benchmark \
  "${BENCHMARK}" \
  and save to "${BENCHMARK}.workload" \
  --bench-num "${BENCH_NUM}" \
  --nsamples "${NSAMPLES}" \
  --seed "${SEED}"

# Infer parameters
./tezos-snoop \
  infer parameters for model "${MODEL}" \
  on data "${WORKLOAD_FILE}" using lasso \
  --lasso-positive \
  --dump-csv "${CSV_FILE}"

will run the benchmark. I don't know what values of BENCH_NUM and NSAMPLES we typically use so those may need to be changed.

Edited by Thomas Athorne