pyphi.provenance.unique_path#

pyphi.provenance.unique_path(directory, stem, suffix)[source]#

Return a non-clobbering path: stem+suffix, else stem_v2+suffix, …

Creates directory (with parents) if it does not exist. Never returns a path that already exists, so earlier outputs are never overwritten.

Parameters:
Return type:

Path