'Test image in-painting.'

def test_inpainting(self):

    import numpy as np
    np.random.seed(1)
    (rows, cols) = (100, 100)
    Uorig = np.random.randint(0, 255, size=(rows, cols))
    (rows, cols) = Uorig.shape
    Known = np.zeros((rows, cols))
    for i in range(rows):
        for j in range(cols):
            if (np.random.random() > 0.7):
                Known[(i, j)] = 1
    Ucorr = (Known * Uorig)
    U = Variable(rows, cols)
    obj = Minimize(tv(U))
    constraints = [(mul_elemwise(Known, U) == mul_elemwise(Known, Ucorr))]
    prob = Problem(obj, constraints)
    prob.solve(solver=SCS)
