@@ -4454,9 +4454,6 @@ def scatter(self, x, y, s=None, c=None, marker=None, cmap=None, norm=None,
44544454 collection .update (kwargs )
44554455
44564456 if colors is None :
4457- if norm is not None and not isinstance (norm , mcolors .Normalize ):
4458- raise ValueError (
4459- "'norm' must be an instance of 'mcolors.Normalize'" )
44604457 collection .set_array (c )
44614458 collection .set_cmap (cmap )
44624459 collection .set_norm (norm )
@@ -4770,11 +4767,6 @@ def hexbin(self, x, y, C=None, gridsize=100, bins=None,
47704767 offset_position = "data"
47714768 )
47724769
4773- # Check for valid norm
4774- if norm is not None and not isinstance (norm , mcolors .Normalize ):
4775- msg = "'norm' must be an instance of 'mcolors.Normalize'"
4776- raise ValueError (msg )
4777-
47784770 # Set normalizer if bins is 'log'
47794771 if bins == 'log' :
47804772 if norm is not None :
@@ -5593,9 +5585,6 @@ def imshow(self, X, cmap=None, norm=None, aspect=None,
55935585 `~matplotlib.pyplot.imshow` expects RGB images adopting the straight
55945586 (unassociated) alpha representation.
55955587 """
5596- if norm is not None and not isinstance (norm , mcolors .Normalize ):
5597- raise ValueError (
5598- "'norm' must be an instance of 'mcolors.Normalize'" )
55995588 if aspect is None :
56005589 aspect = rcParams ['image.aspect' ]
56015590 self .set_aspect (aspect )
@@ -5885,9 +5874,6 @@ def pcolor(self, *args, alpha=None, norm=None, cmap=None, vmin=None,
58855874
58865875 collection .set_alpha (alpha )
58875876 collection .set_array (C )
5888- if norm is not None and not isinstance (norm , mcolors .Normalize ):
5889- raise ValueError (
5890- "'norm' must be an instance of 'mcolors.Normalize'" )
58915877 collection .set_cmap (cmap )
58925878 collection .set_norm (norm )
58935879 collection .set_clim (vmin , vmax )
@@ -6102,9 +6088,6 @@ def pcolormesh(self, *args, alpha=None, norm=None, cmap=None, vmin=None,
61026088 ** kwargs )
61036089 collection .set_alpha (alpha )
61046090 collection .set_array (C )
6105- if norm is not None and not isinstance (norm , mcolors .Normalize ):
6106- raise ValueError (
6107- "'norm' must be an instance of 'mcolors.Normalize'" )
61086091 collection .set_cmap (cmap )
61096092 collection .set_norm (norm )
61106093 collection .set_clim (vmin , vmax )
@@ -6241,11 +6224,7 @@ def pcolorfast(self, *args, alpha=None, norm=None, cmap=None, vmin=None,
62416224 Notes
62426225 -----
62436226 .. [notes section required to get data note injection right]
6244-
62456227 """
6246- if norm is not None and not isinstance (norm , mcolors .Normalize ):
6247- raise ValueError (
6248- "'norm' must be an instance of 'mcolors.Normalize'" )
62496228
62506229 C = args [- 1 ]
62516230 nr , nc = np .shape (C )[:2 ]
0 commit comments