Skip to content

Commit

Permalink
Merge pull request #949 from ioam/nan_warning
Browse files Browse the repository at this point in the history
Ignore empty slice warning when plotting Layout containing Empty
  • Loading branch information
jbednar authored Oct 24, 2016
2 parents dc7d795 + d95907d commit 267dbd6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions holoviews/plotting/mpl/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,11 @@ def normalize_ratios(ratios):

def compute_ratios(ratios, normalized=True):
unpacked = unpack_adjoints(ratios)
if normalized:
unpacked = normalize_ratios(unpacked)
sorted_ratios = sorted(unpacked.items())
with warnings.catch_warnings():
warnings.filterwarnings('ignore', r'All-NaN (slice|axis) encountered')
if normalized:
unpacked = normalize_ratios(unpacked)
sorted_ratios = sorted(unpacked.items())
return np.nanmax(np.vstack([v for _, v in sorted_ratios]), axis=0)


Expand Down

0 comments on commit 267dbd6

Please sign in to comment.