Adding code for estimating memory usage by graphchi engine