def __init__(self, base):
<EOL>if not os.path.isdir(base):<EOL><INDENT>os.makedirs(base)<EOL><DEDENT>if (os.stat(base).st_mode & <NUM_LIT>) != <NUM_LIT:0>:<EOL><INDENT>logger.warning('<STR_LIT>', base)<EOL><DEDENT>self.base = os.path.abspath(os.path.normpath(base))<EOL>
Initialise an instance.

:param base: The base directory where the cache should be located.