Pipes from Lines

Hello, so i managed to make this work, but now im looking deepet into it.

Is there any way to tweak the node so that instead of using levels as the input for location on the file to be a topography, or mesh, or polysurface.

I have tried getting here

And then editing the python script, for of course it doesnt work,