Extensão de queda de Python

>>> print(os.path.splitext(os.path.basename("/path/to/file/hemanth.txt"))[0])
hemanth
Splendid Sandpiper