actually, I just cross checked with previous projects, and it is happening with them as well. I doubt it is the code, but something else. I did look in previous post about  assigning different variables, not using list, and as such, but it seems it is a different problem.
All the research projects over the last year use the same dataloader, and it is the first time I am having memory issue even with the weak old projects.