Skip to content

Callable date formatter #2707

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jan 14, 2014
Merged

Conversation

pelson
Copy link
Member

@pelson pelson commented Jan 7, 2014

Replaces #2507.

This allows custom functions to be used for formatting in the style of
FuncFormatter.
@pelson
Copy link
Member Author

pelson commented Jan 14, 2014

Anyone interested in moving this forwards? I think it is good to go...

@tacaswell
Copy link
Member

I am not seeing why the test image should have changed.

@pelson
Copy link
Member Author

pelson commented Jan 14, 2014

I am not seeing why the test image should have changed.

Fair comment. This is the result I get when running the tests with anything since the released v1.3.1. Do you get the original image? I notice that our default tolerance is 13 - that is the RMS pixel difference is 13. It is feasible that the two images are different to within this rms value.

@tacaswell
Copy link
Member

On master I get the new image, have not tried to track it back to where it changed.

I am not sure if I think it is worth figuring out what changed (no one has complained), but it does point out a weakness in the image comparison. Maybe we should also add a check on the number of pixel different by greater than a threshold ie assert sum(np.abs(im1 - im2) > threshold) < N.

@pelson
Copy link
Member Author

pelson commented Jan 14, 2014

Maybe we should also add a check on the number of pixel different by greater than a threshold

I've been thinking exactly the same thing in the last couple of days. I think that would be a sensible complimentary approach. Perhaps not in this PR though 😉

@tacaswell
Copy link
Member

No, not in this PR. I'll push the big green button and then get a PR for the new checks going (and I now see why getting the compare.py pep8 in was a good thing).

tacaswell added a commit that referenced this pull request Jan 14, 2014
@tacaswell tacaswell merged commit f3d407d into matplotlib:master Jan 14, 2014
@pelson pelson deleted the callable_date_formatter branch February 12, 2014 13:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants