examples/plot_alignment_simulated_2D_data.py
def _plot2D_samples_mat(xs, xt, R, thr=1e-8, **kwargs):
    """ Plot matrix R in 2D with lines for coefficients above threshold thr.
    REPRODUCED FROM POT PACKAGE
    """
    if ('color' not in kwargs) and ('c' not in kwargs):
        kwargs['color'] = 'k'
    mx = R.max()
    for i in range(xs.shape[0]):
        for j in range(xt.shape[0]):
            if R[i, j] / mx > thr:
                plt.plot([xs[i, 0], xt[j, 0]], [xs[i, 1], xt[j, 1]],
                         alpha=R[i, j] / mx, **kwargs)
 Plot matrix R in 2D with lines for coefficients above threshold thr.
    REPRODUCED FROM POT PACKAGE
    
Plot matrix R in 2D with lines for coefficients above threshold thr.
REPRODUCED FROM POT PACKAGE
Plot matrix R in 2D with lines for coefficients above threshold thr . REPRODUCED FROM POT PACKAGE
def _plot2D_samples_mat(xs, xt, R, thr=1e-8, **kwargs):
    if ('color' not in kwargs) and ('c' not in kwargs):
        kwargs['color'] = 'k'
    mx = R.max()
    for i in range(xs.shape[0]):
        for j in range(xt.shape[0]):
            if R[i, j] / mx > thr:
                plt.plot([xs[i, 0], xt[j, 0]], [xs[i, 1], xt[j, 1]],
                         alpha=R[i, j] / mx, **kwargs)
def _plot2D_samples_mat ( xs , xt , R , thr = 1e-8 , ** kwargs ) : if ( 'color' not in kwargs ) and ( 'c' not in kwargs ) : kwargs [ 'color' ] = 'k' mx = R . max ( ) for i in range ( xs . shape [ 0 ] ) : for j in range ( xt . shape [ 0 ] ) : if R [ i , j ] / mx > thr : plt . plot ( [ xs [ i , 0 ] , xt [ j , 0 ] ] , [ xs [ i , 1 ] , xt [ j , 1 ] ] , alpha = R [ i , j ] / mx , ** kwargs )
Plot matrix R in 2D with lines for coefficients above threshold thr.
Plot matrix R in 2D with lines for coefficients above threshold thr .
""" Plot matrix R in 2D with lines for coefficients above threshold thr.
    REPRODUCED FROM POT PACKAGE
    """
xs
xt
R
thr