'Subclass the save method, to hash ndarray subclass, rather
than pickling them. Off course, this is a total abuse of
the Pickler class.'

def save(self, obj):

    if (isinstance(obj, self.np.ndarray) and (not obj.dtype.hasobject)):
        if (obj.shape == ()):
            obj_c_contiguous = obj.flatten()
        elif obj.flags.c_contiguous:
            obj_c_contiguous = obj
        elif obj.flags.f_contiguous:
            obj_c_contiguous = obj.T
        else:
            obj_c_contiguous = obj.flatten()
        self._hash.update(self._getbuffer(obj_c_contiguous.view(self.np.uint8)))
        if (self.coerce_mmap and isinstance(obj, self.np.memmap)):
            klass = self.np.ndarray
        else:
            klass = obj.__class__
        obj = (klass, ('HASHED', obj.dtype, obj.shape, obj.strides))
    elif isinstance(obj, self.np.dtype):
        klass = obj.__class__
        obj = (klass, ('HASHED', obj.descr))
    Hasher.save(self, obj)
