Data Directory

pyproj.datadir.get_data_dir

pyproj.datadir.get_data_dir() → str[source]

The order of preference for the data directory is:

  1. The one set by pyproj.datadir.set_data_dir (if exists & valid)

  2. The internal proj directory (if exists & valid)

  3. The directory in PROJ_LIB (if exists & valid)

  4. The directory on sys.prefix (if exists & valid)

  5. The directory on the PATH (if exists & valid)

Returns

The valid data directory.

Return type

str

pyproj.datadir.set_data_dir

pyproj.datadir.set_data_dir(proj_data_dir: str) → None[source]

Set the data directory for PROJ to use.

Parameters

proj_data_dir (str) – The path to the PROJ data directory.

pyproj.datadir.append_data_dir

pyproj.datadir.append_data_dir(proj_data_dir: str) → None[source]

Add an additional data directory for PROJ to use.

Parameters

proj_data_dir (str) – The path to the PROJ data directory.