Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
N
NeuroM
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Model registry
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
BlueBrain
NeuroM
Commits
a44ecc4c
Unverified
Commit
a44ecc4c
authored
Apr 30, 2024
by
Eleftherios Zisis
Committed by
GitHub
Apr 30, 2024
Browse files
Options
Downloads
Patches
Plain Diff
Fix mpl.cm.get_cmap deprecation (#1122)
parent
65a3e2e2
Branches
Branches containing commit
Tags
v3.2.11
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
examples/density_plot.py
+1
-1
1 addition, 1 deletion
examples/density_plot.py
with
1 addition
and
1 deletion
examples/density_plot.py
+
1
−
1
View file @
a44ecc4c
...
@@ -70,7 +70,7 @@ def plot_density(population, # pylint: disable=too-many-arguments, too-many-loc
...
@@ -70,7 +70,7 @@ def plot_density(population, # pylint: disable=too-many-arguments, too-many-loc
mask
=
H1
<
threshold
# mask = H1==0
mask
=
H1
<
threshold
# mask = H1==0
H2
=
np
.
ma
.
masked_array
(
H1
,
mask
)
H2
=
np
.
ma
.
masked_array
(
H1
,
mask
)
colormap
=
m
pl
.
cm
.
get_cmap
(
color_map
).
copy
()
colormap
=
pl
t
.
get_cmap
(
color_map
).
copy
()
colormap
.
set_bad
(
color
=
'
white
'
,
alpha
=
None
)
colormap
.
set_bad
(
color
=
'
white
'
,
alpha
=
None
)
plots
=
ax
.
contourf
((
xedges1
[:
-
1
]
+
xedges1
[
1
:])
/
2
,
plots
=
ax
.
contourf
((
xedges1
[:
-
1
]
+
xedges1
[
1
:])
/
2
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
sign in
to comment