fix bugs
1. move count_minimum_peak in profile_memory
2. use nodes_mem in fct