fix float cost and infra_hash