(data, h, w, x_range, y_range, plot_size)
return fig
Helper function to generate a figure

    Arguments:
        data (int): data to plot
        h (int): height
        w (int): width
        x_range (tuple, optional): (start, end) range for x
        y_range (tuple, optional): (start, end) range for y
        plot_size (int): plot size

    Returns:
        bokeh.plotting.figure: Generated figure
Helper function to generate a figure
Helper function to generate a figure
def image_fig(data, h, w, x_range, y_range, plot_size):
    """
    Helper function to generate a figure

    Arguments:
        data (int): data to plot
        h (int): height
        w (int): width
        x_range (tuple, optional): (start, end) range for x
        y_range (tuple, optional): (start, end) range for y
        plot_size (int): plot size

    Returns:
        bokeh.plotting.figure: Generated figure
    """
    fig = figure(x_range=x_range, y_range=y_range,
                 plot_width=plot_size, plot_height=plot_size,
                 toolbar_location=None)
    fig.image_rgba([data], x=[0], y=[0], dw=[w], dh=[h])
    fig.axis.visible = None
    fig.min_border = 0
    return fig
def image_fig ( data , h , w , x_range , y_range , plot_size ) : fig = figure ( x_range = x_range , y_range = y_range , plot_width = plot_size , plot_height = plot_size , toolbar_location = None ) fig . image_rgba ( [ data ] , x = [ 0 ] , y = [ 0 ] , dw = [ w ] , dh = [ h ] ) fig . axis . visible = None fig . min_border = 0 return fig