I seem to feel like this already exists...
I'm trying to determine the path of a source without baked in frame numbers. When users use shell expansion, frame numbers are explicitly baked it; and I imagine there's many other ways of specifying frames that will result in various formats.
So before I try to cover them all on my own, is there any sort of mu/python command that can extract the name of a path sans explicit frame numbers for use in accompanying scripts?