how to get os basename with file extension in python code example
Example: file base name and extension python
from pathlib import Path
Path('/root/dir/sub/file.ext').stem
from pathlib import Path
Path('/root/dir/sub/file.ext').stem