Creating a DEM by graph is not a good idea because you should keep track of the outputs of the single steps.
It’s well explained here: