Skip to content

Commit

Permalink
Added temporary fix to ensure tests pass by enabling RasterGridPlot
Browse files Browse the repository at this point in the history
  • Loading branch information
jlstevens committed Jun 13, 2015
1 parent 67ab735 commit 52908c1
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion holoviews/ipython/display_hooks.py
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,15 @@ def grid_display(grid, size, max_frames, max_branches, widget_mode):
if not isinstance(grid, GridSpace): return None
info = process_object(grid)
if info: return info
plot_class = Store.registry[OutputMagic.backend()][GridSpace]

raster_fn = lambda x: True if isinstance(x, Raster) else False
all_raster = all(grid.traverse(raster_fn, [Element]))
if all_raster:
from ..plotting.mpl import RasterGridPlot
plot_class = RasterGridPlot
else:
plot_class = Store.registry[OutputMagic.backend()][GridSpace]

gridplot = plot_class(grid, **OutputMagic.renderer().plot_options(grid, size))

if len(gridplot) > max_frames:
Expand Down

0 comments on commit 52908c1

Please sign in to comment.