code: def _finalize(self, fill_value=None, dtype=np.uint8, keep_palette=False, cmap=None):
          
          import warnings
          warnings.warn("'_finalize' is deprecated, use 'finalize' instead.",
                        DeprecationWarning)
          return self.finalize(fill_value, dtype, keep_palette, cmap)
docs: Wrapper around 'finalize' method for backwards compatibility.