Made some changes to find_local_max.m