e7530933e0b00fedb830464aa95a4f5bf6042378,pyemma/plots/plots2d.py,,_get_cmap,#Any#,27

Before Change


def _get_cmap(cmap):
    // matplotlib 2.0 deprecated "spectral" colormap, renamed to nipy_spectral.
    from matplotlib import __version__
    version = tuple(map(int, __version__.split(".")))
    if cmap == "spectral" and version >= (2, ):
        cmap = "nipy_spectral"
    return cmap

After Change


    if _matplotlib_version is None:
        from matplotlib import __version__
        from distutils.version import LooseVersion
        _matplotlib_version = LooseVersion(__version__).version
    if cmap == "spectral" and _matplotlib_version >= (2, ):
        cmap = "nipy_spectral"
    return cmap
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: markovmodel/PyEMMA
Commit Name: e7530933e0b00fedb830464aa95a4f5bf6042378
Time: 2019-05-23
Author: m.scherer@fu-berlin.de
File Name: pyemma/plots/plots2d.py
Class Name:
Method Name: _get_cmap


Project Name: nipy/dipy
Commit Name: 3d8011f9ce1dba31df7c83f07dcf481a65926aa4
Time: 2014-11-21
Author: garyfallidis@gmail.com
File Name: dipy/core/optimize.py
Class Name:
Method Name:


Project Name: nipy/dipy
Commit Name: 419b97c0e7c1c013c6b5bef52ae2e81a2753547c
Time: 2014-11-14
Author: garyfallidis@gmail.com
File Name: dipy/core/optimize.py
Class Name:
Method Name: