<s> import os <EOL> import inspect <EOL> def module_relative_path ( path ) : <EOL> """<STR_LIT>""" <EOL> if os . path . isabs ( path ) : <EOL> return path <EOL> calling_file = inspect . stack ( ) [ <NUM_LIT:1> ] [ <NUM_LIT:1> ] <EOL> calling_dir = os . path . abspath ( os . path . dirname ( calling_file ) ) <EOL> return os . path . join ( calling_dir , path ) </s>
