Did I find the right examples for you? yes no

All Samples(15)  |  Call(14)  |  Derive(0)  |  Import(1)

src/n/i/nipy-0.3.0/nipy/algorithms/tests/test_resample.py   nipy(Download)
                           ArrayCoordMap, compose)
from nipy.core.reference import slices
from nipy.algorithms.resample import resample, resample_img2img
from nipy.io.api import load_image
 
                  [1,0,0],
                  [0,0,1]], np.float)
    ir = resample(i, g2, a, (100, 100))
    assert_array_almost_equal(ir.get_data().T, i.get_data())
 
                  [1,0,0],
                  [0,0,1]], np.float)
    ir = resample(i, g2, a, (80,100))
    assert_array_almost_equal(ir.get_data().T, i.get_data())
 
                                                  [0.7,0,0],
                                                  [0,0,1]]))
    ir = resample(i, g2, a, (80,100))
    assert_array_almost_equal(ir.get_data().T, i.get_data())
 
                  [0,1,0,0],
                  [0,0,0,1.]])
    ir = resample(i, g2, a, (100,80,90))
    assert_array_almost_equal(np.transpose(ir.get_data(), (0,2,1)),
                              i.get_data())