fix: Fixed to add_to_canvas() returns ax instead of plots#989
Open
i-aki-y wants to merge 2 commits intoSheffieldML:develfrom
Open
fix: Fixed to add_to_canvas() returns ax instead of plots#989i-aki-y wants to merge 2 commits intoSheffieldML:develfrom
i-aki-y wants to merge 2 commits intoSheffieldML:develfrom
Conversation
Codecov Report
@@ Coverage Diff @@
## devel #989 +/- ##
==========================================
+ Coverage 54.49% 54.51% +0.01%
==========================================
Files 210 210
Lines 21560 21560
Branches 3169 3169
==========================================
+ Hits 11750 11753 +3
+ Misses 9255 9252 -3
Partials 555 555 |
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
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I want to fix the error which is discussed in #920.
The
plotting.show()function is a alias of theshow_canvas()method and it expect for anaxobject in matplotlib, while theGP.plot()(==add_to_canvas()) function returnsplotsdict.See also:
GPy/GPy/plotting/matplot_dep/plot_definitions.py
Lines 95 to 97 in f63ed48
To fix this, I just replace the return value of
add_to_canvas()fromplotstoax.Note:
The return value of the
add_to_canvas()function was changed at the commit 4f3047e fromaxtoplots.Unfortunately, I could not find the reason why this fix was needed.
I would appreciate it if you reviewed this.