numpy.DataSource.exists — NumPy v1.15 Manual (original) (raw)

DataSource. exists(path)[source]

Test if path exists.

Test if path exists as (and in this order):

Parameters: path : str Can be a local file or a remote URL.
Returns: out : bool True if path exists.

Notes

When path is an URL, exists will return True if it’s either stored locally in the DataSource directory, or is a valid remote URL. DataSource does not discriminate between the two, the file is accessible if it exists in either location.