Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(7)  |  Call(6)  |  Derive(0)  |  Import(1)

src/s/c/scikits.sparse-0.1/scikits/sparse/test_cholmod.py   scikits.sparse(Download)
import numpy as np
from scipy import sparse
from cholmod import cholesky, cholesky_AAt, analyze, analyze_AAt, CholmodError
 
# At time of writing (scipy 0.7.0), scipy.sparse.csc.csc_matrix explicitly
def test_cholesky_smoke_test():
    f = cholesky(sparse.eye(10, 10) * 1.)
    d = np.arange(20).reshape(10, 2)
    print "dense"
    assert np.allclose(f(d), d)
def test_complex():
    c = complex_matrix()
    fc = cholesky(c)
    r = real_matrix()
    fr = cholesky(r)
            for mode in ["auto", "supernodal", "simplicial"]:
                L = cholesky(matrix, beta=beta).L()
                assert factor_of(cholesky(matrix, beta=beta),
                                 matrix_plus_beta)