fixed bug with ridge traversal method not working
compute memory usage and print warning if above memory size