myfile.name will give you the file path.
Note that tempfile does not exist after close() . From the docs:
tempfile.TemporaryFile([mode='w+b'[, bufsize=-1[, suffix=''[, prefix='tmp'[, dir=None]]]]])
Returns a file-like object that can be used as a temporary storage area. The file is created using mkstemp (). It will be destroyed as soon as it closes (including implicit closure when the object is garbage collection). On Unix, the directory entry for the file is deleted immediately after the file is created. Other platforms do not support this; Your code should not rely on the temporary file created using this function, with or without a visible name in the file system.
Source: http://docs.python.org/2/library/tempfile.html
source share