BlueBrain / BlueCelluLab

Biologically detailed neural network simulations and analysis API
https://bluecellulab.readthedocs.io/en/latest/
Apache License 2.0
12 stars 14 forks source link

Bug: `matplotlib>=3.9` - module 'matplotlib.cm' has no attribute 'get_cmap' #183

Closed joni-herttuainen closed 4 months ago

joni-herttuainen commented 4 months ago

Matplotlib introduced breaking changes in version 3.9, which also causes bluecellulab to crash:

<Truncated traceback>
...
File ".../venv/lib/python3.11/site-packages/bluecellulab/psegment.py", line 38, in __init__
    self.color_map = cm.get_cmap("hot")
                     ^^^^^^^^^^^
AttributeError: module 'matplotlib.cm' has no attribute 'get_cmap'
ilkilic commented 4 months ago

Thank you @joni-herttuainen for raising this issue. PR #184 addresses it by replacing get_cmap with colormaps

joni-herttuainen commented 4 months ago

Since this issue is fixed, I'll close it. Thanks for a quick response.