Pinpointed the problem with NaNs, working on it..