FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Making sure to keep over/under/bad in cmap resample/reverse. by greglucas · Pull Request #16937 · matplotlib/matplotlib · GitHub

Repository navigation

Making sure to keep over/under/bad in cmap resample/reverse. - #16937

Merged
anntzer merged 1 commit into
matplotlib:masterfrom
greglucas:colormap_reverse_extend
Mar 28, 2020
Merged

anntzer merged 1 commit into
matplotlib:masterfrom
greglucas:colormap_reverse_extend

Conversation

Copy link
Copy Markdown
Contributor

PR Summary

Setting the over/under/bad when calling _resample or reverse on the colormaps.

Fixes part of #16296
Addresses bullet 3 of this comment: #16296 (comment)

Could possibly be made a little more elegant using #14645
However, when I was working through this it isn't quite so simple as calling set_over() on the new_cmap object because you're calling it with None which can't be converted to a color on the other side. You also can't update thenew_cmap. _lut directly because when generating the cmap_d the _lut of all colormaps is not populated initially and it is still calling reverse().

PR Checklist

  • Has Pytest style unit tests
  • Code is Flake 8 compliant
  • New features are documented, with examples if plot related
  • Documentation is sphinx and numpydoc compliant
  • Added an entry to doc/users/next_whats_new/ if major new feature (follow instructions in README.rst there)
  • Documented in doc/api/api_changes.rst if API changed in a backward-incompatible way

anntzer left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

lgtm (postci)

tacaswell left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

restarted the failed CI job (know to be flaky on CI).

anntzer merged commit c292827 into matplotlib:master Mar 28, 2020
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL