def replace_zeros(self, val, zero_thresh=0.0):
        """ Replaces all zeros in the image with a specified value

        Returns
        -------
        image dtype
             value to replace zeros with
        """
        new_data = self.data.copy()
        new_data[new_data <= zero_thresh] = val
        return type(self)(new_data.astype(self.data.dtype), frame=self._frame)