Skip to content

COMPAT: mpl 2.0.0 #13333

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

Closed
jreback opened this issue May 31, 2016 · 17 comments · Fixed by #13662
Closed

COMPAT: mpl 2.0.0 #13333

jreback opened this issue May 31, 2016 · 17 comments · Fixed by #13662
Labels
Compat pandas objects compatability with Numpy or Python functions Visualization plotting
Milestone

Comments

@jreback
Copy link
Contributor

jreback commented May 31, 2016

seems @tacaswell / @mdboom have been busy

https://github.com/matplotlib/matplotlib/releases/tag/v2.0.0b1

we should test with this.

is this going up on a conda-forge dev channel? (is there such a thing)?

@jreback jreback added the Compat pandas objects compatability with Numpy or Python functions label May 31, 2016
@jreback jreback added this to the 0.18.2 milestone May 31, 2016
@jreback jreback added the Visualization plotting label May 31, 2016
@jreback
Copy link
Contributor Author

jreback commented May 31, 2016

@tacaswell
Copy link
Contributor

conda install -c conda-forge/label/rc -c conda-forge matplotlib

@jreback
Copy link
Contributor Author

jreback commented May 31, 2016

on OSX.

[Tue May 31 09:45:42 ~/pandas]$ nosetests  pandas/tests/test_graphics.py pandas/tests/test_graphics_others.py
EE
======================================================================
ERROR: Failure: AttributeError ('Cycler' object has no attribute 'change_key')
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/nose/loader.py", line 418, in loadTestsFromName
    addr.filename, addr.module)
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/nose/importer.py", line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/nose/importer.py", line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/Users/jreback/pandas/pandas/__init__.py", line 39, in <module>
    from pandas.core.api import *
  File "/Users/jreback/pandas/pandas/core/api.py", line 10, in <module>
    from pandas.core.groupby import Grouper
  File "/Users/jreback/pandas/pandas/core/groupby.py", line 19, in <module>
    from pandas.core.frame import DataFrame
  File "/Users/jreback/pandas/pandas/core/frame.py", line 39, in <module>
    from pandas.core.series import Series
  File "/Users/jreback/pandas/pandas/core/series.py", line 2933, in <module>
    import pandas.tools.plotting as _gfx  # noqa
  File "/Users/jreback/pandas/pandas/tools/plotting.py", line 27, in <module>
    import pandas.tseries.converter as conv
  File "/Users/jreback/pandas/pandas/tseries/converter.py", line 7, in <module>
    import matplotlib.units as units
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/matplotlib/__init__.py", line 1162, in <module>
    rcParams = rc_params()
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/matplotlib/__init__.py", line 1005, in rc_params
    return rc_params_from_file(fname, fail_on_error)
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/matplotlib/__init__.py", line 1138, in rc_params_from_file
    if key not in _all_deprecated])
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/matplotlib/__init__.py", line 889, in __init__
    self[k] = v
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/matplotlib/__init__.py", line 906, in __setitem__
    cval = self.validate[key](val)
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/matplotlib/rcsetup.py", line 840, in validate_cycler
    cycler_inst.change_key(prop, norm_prop)
AttributeError: 'Cycler' object has no attribute 'change_key'

======================================================================
ERROR: Failure: ImportError (C extension: hashtable not built. If you want to import pandas from the source directory, you may need to run 'python setup.py build_ext --inplace --force' to build the C extensions first.)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/nose/loader.py", line 418, in loadTestsFromName
    addr.filename, addr.module)
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/nose/importer.py", line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/nose/importer.py", line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/Users/jreback/pandas/pandas/__init__.py", line 31, in <module>
    "the C extensions first.".format(module))
ImportError: C extension: hashtable not built. If you want to import pandas from the source directory, you may need to run 'python setup.py build_ext --inplace --force' to build the C extensions first.

----------------------------------------------------------------------
Ran 2 tests in 0.001s

@jreback
Copy link
Contributor Author

jreback commented May 31, 2016

pandas master

@tacaswell
Copy link
Contributor

You need cycler >= 0.10. Should have pulled that from conda-forge

@jreback
Copy link
Contributor Author

jreback commented May 31, 2016

hmm, maybe needs to be part of your recipe?

@tacaswell
Copy link
Contributor

@sinhrks
Copy link
Member

sinhrks commented Jul 6, 2016

There looks some errors / failures (most of them are caused by figure size check). Will dig in.

Can we add one more SLOW build using mpl2.0 on Travis with allowed failure?

ERROR: test_errorbar_asymmetrical (pandas.tests.test_graphics.TestDataFramePlots)
ERROR: test_errorbar_scatter (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_bar_linewidth (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_boxplot (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_boxplot_colors (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_boxplot_vertical (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_hexbin_basic (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_hist_df (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_kde_df (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_line_colors_and_styles_subplots (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_line_lim (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_plot (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_plot_scatter (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_scatter_colors (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_subplots (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_subplots_layout (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_subplots_multiple_axes (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_subplots_timeseries (pandas.tests.test_graphics.TestDataFramePlots)
FAIL: test_bar_log (pandas.tests.test_graphics.TestSeriesPlots)
FAIL: test_hist_layout_with_by (pandas.tests.test_graphics.TestSeriesPlots)
FAIL: test_plot (pandas.tests.test_graphics.TestSeriesPlots)

@jreback
Copy link
Contributor Author

jreback commented Jul 6, 2016

@sinhrks sure. is 2.0 rc available on a channel somewhere?

@sinhrks
Copy link
Member

sinhrks commented Jul 6, 2016

Not yet. Will try to built from source if it's not available until I need.

@jorisvandenbossche
Copy link
Member

jorisvandenbossche commented Jul 6, 2016

I think it is available on conda-forge: https://anaconda.org/conda-forge/matplotlib/labels (edit: at least the beta, not rc)

@tacaswell
Copy link
Contributor

There is no rc yet, should be one 'soon'

@TomAugspurger
Copy link
Contributor

@sinhrks for the figsize failures, I think the new default in MPL is 6.4 x 4.8. We had the old 8 x 6 as the default for _check_axes_shape. Will just need to make that default None, and determine it based on the MPL version.

@TomAugspurger
Copy link
Contributor

@tacaswell does this make sense to you? Regarding errorbar

import matplotlib.pyplot as plt
fig, ax = plt.subplots()
r = ax.errorbar(range(5), range(5), xerr=.2)
print(ax.lines)

In MPL 1.5.x

[<matplotlib.lines.Line2D object at 0x1193411d0>, <matplotlib.lines.Line2D object at 0x1193414a8>, <matplotlib.lines.Line2D object at 0x119341da0>]

in MPL 2.0 beta

[<matplotlib.lines.Line2D object at 0x117a79128>]

I found matplotlib/matplotlib#5047 (don't draw caps by default) but not sure if that's what's going on here.

@tacaswell
Copy link
Contributor

We changed the default dpi so reduced the figure size (in inches) to keep the same figure size (in pixels).

re errorbar: that does look correct, the caps are not created which does not even add the artists. I would look at the contents of r rather than ax.lines for testing purposes.

@sinhrks sinhrks assigned sinhrks and unassigned sinhrks Jul 12, 2016
@TomAugspurger
Copy link
Contributor

@sinhrks I can work on this if you want.

@sinhrks
Copy link
Member

sinhrks commented Jul 13, 2016

@TomAugspurger It would be very helpful!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Compat pandas objects compatability with Numpy or Python functions Visualization plotting
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants