def cell_sides(self):
        """Side lengths of all 'inner' cells of a uniform partition.

        Only defined if ``self.grid`` is uniform.

        Examples
        --------
        We create a partition of the rectangle [0, 1] x [-1, 2] into
        3 x 3 cells, where the grid points lie on the boundary. This
        means that the grid points are [0, 0.5, 1] x [-1, 0.5, 2],
        i.e. the inner cell has side lengths 0.5 x 1.5:

        >>> rect = odl.IntervalProd([0, -1], [1, 2])
        >>> grid = odl.uniform_grid([0, -1], [1, 2], (3, 3))
        >>> part = odl.RectPartition(rect, grid)
        >>> part.cell_sides
        array([ 0.5,  1.5])
        """
        sides = self.grid.stride
        sides[sides == 0] = self.extent[sides == 0]
        return sides