I think you have it backwards. os.path is system-independent (with a few edge cases I imagine), but this rsplit('/') is tied to POSIX systems only. Look at the second "Note:" here: http://docs.python.org/2/library/os.path.html

You can play with compatibility for other systems like this:

```
>>> import ntpath
>>> ntpath.basename('\\a\b\c\d')
'd'
```

So basename is the way to go for portability.