File: cartopy.rst

package info (click to toggle)
python-cartopy 0.18.0%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 18,204 kB
  • sloc: python: 15,593; makefile: 160; javascript: 65; sh: 6
file content (50 lines) | stat: -rw-r--r-- 2,224 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
The cartopy module
------------------

The top level cartopy module contains the :attr:`~cartopy.config` dictionary which controls various aspects of cartopy's behaviour.

..
    n.b. cartopy.config docstring should be mirrored in lib/cartopy/__init__.py.


.. py:data:: cartopy.config

    The config dictionary stores global configuration values for cartopy.

    In the first instance, the config is defined in ``cartopy/__init__.py``. It
    is possible to provide site wide customisations by including a
    ``siteconfig.py`` file along with the cartopy source code. ``siteconfig.py``
    should contain a function called ``update_config`` which takes the config
    dictionary instance as its first and only argument (from where it is
    possible to update the dictionary howsoever desired).

    For users without write permission to the cartopy source directory, a package
    called ``cartopy_userconfig`` should be made importable (consider putting it
    in ``site.getusersitepackages()``) and should expose a
    function called ``update_config`` which takes the config dictionary as its
    first and only argument.


    Keys in the config dictionary:

    ``pre_existing_data_dir``
        The absolute path to a directory where standard data (such as that from
        NaturalEarth) can be found. If it is not found in this location the
        ``data_dir`` config item will be used.

    ``data_dir``
        The absolute path to a directory where standard data (such as that from
        NaturalEarth) can be found. If it is not found and the item is
        downloadable cartopy will download the appropriate file(s) to a
        subdirectory of this directory, therefore ``data_dir`` should be
        writable by the user.

    ``repo_data_dir``
        The absolute path to the directory where the data delivered with the
        cartopy repository is stored. Typically this will only be set by OS
        packagers and system administrators for site wide deployments.

    ``downloaders``
        A dictionary mapping standard "specifications" to the appropriate
        :class:`~cartopy.io.Downloader`. For further documentation and an
        example see :func:`cartopy.io.Downloader.from_config`.