Python pyproj.__version__() Examples

The following are 2 code examples of pyproj.__version__(). You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may also want to check out all available functions/classes of the module pyproj , or try the search function .
Example #1
Source File: conf.py    From oggm with BSD 3-Clause "New" or "Revised" License 5 votes vote down vote up
def write_index():
    """This is to write the docs for the index automatically."""

    here = os.path.dirname(__file__)
    filename = os.path.join(here, '_generated', 'version_text.txt')

    try:
        os.makedirs(os.path.dirname(filename))
    except FileExistsError:
        pass

    text = text_version if '+' not in oggm.__version__ else text_dev

    with open(filename, 'w') as f:
        f.write(text) 
Example #2
Source File: __init__.py    From pyresample with GNU Lesser General Public License v3.0 5 votes vote down vote up
def is_pyproj2():
    """Determine whether the current pyproj version is >= 2.0"""
    return pyproj.__version__ >= '2'