def gettempprefix():
"""Accessor for tempdir.template."""
return template
# now see how fast it is for a little one small=arange(10) st=time() from tempfile import gettempdir, gettempprefix, mkstemp #tmp=gettempdir()+gettempprefix() tmpfd=mkstemp(suffix='.npz')
src/p/r/prdg.util-0.0.7/prdg/util/file.py prdg.util(Download)
from tempfile import gettempdir, gettempprefix
from datetime import datetime
from os.path import join, splitext, dirname
from os import remove, access, F_OK, chdir
def exists(path):
return access(path, F_OK)
def get_temp_filename():
return join(gettempdir(), gettempprefix() + str(datetime.now().microsecond))