'Adjust subplot parameters to give specified padding.
Parameters:
pad : float
padding between the figure edge and the edges of subplots, as a fraction of the font-size.
h_pad, w_pad : float
padding (height/width) between edges of adjacent subplots.
Defaults to `pad_inches`.
rect : if rect is given, it is interpreted as a rectangle
(left, bottom, right, top) in the normalized figure
coordinate that the whole subplots area (including
labels) will fit into. Default is (0, 0, 1, 1).'

def tight_layout(self, fig, renderer=None, pad=1.08, h_pad=None, w_pad=None, rect=None):

    from .tight_layout import get_subplotspec_list, get_tight_layout_figure, get_renderer
    subplotspec_list = get_subplotspec_list(fig.axes, grid_spec=self)
    if (None in subplotspec_list):
        warnings.warn(u'This    figure    includes    Axes    that    are    not    compatible    with    tight_layout,    so    its    results    might    be    incorrect.')
    if (renderer is None):
        renderer = get_renderer(fig)
    kwargs = get_tight_layout_figure(fig, fig.axes, subplotspec_list, renderer, pad=pad, h_pad=h_pad, w_pad=w_pad, rect=rect)
    self.update(**kwargs)
