read cost from config file