fixed bug about cwd in link_bilm.py