You can use os.path.abspath() to get an absolute path from a relative one.
vinko@parrot:~/p/f$ more a.py
import os
print os.path.abspath('../g/a')
vinko@parrot:~/p/f$ python a.py
/home/vinko/p/g/a
The dir structure:
vinko@parrot:~/p$ tree
.
|-- f
| `-- a.py
`-- g
`-- a
2 directories, 2 files