Hello Jordy,
There are multiple factors that contribute to the memory consumption of RDF. (A few paragraphs can be found here under “Memory usage”).
I think in your case it might be the computation graphs that have to be compiled for each DatasetSpec. The compiled products will stay in memory until the process exits.
Another reason for higher memory consumption is the thread-local histograms that have to be filled. The higher the level of parallelism, the more histograms get created. If you used to run your graphs one after the other, those intermediate histograms might already haven been cleared when the next graphs starts running, saving you some RAM. Now that you merged the inputs, it could be that multiple graphs are running in parallel, so there are more histograms “in flight”.
If you want to test, you could “RunGraph” the 25 different graphs after each other. If that uses less, it may be the histograms in flight. If it uses a similar amount or more, it is the compiled computation graphs that fill up the RAM.