Did I find the right examples for you? yes no

All Samples(3)  |  Call(2)  |  Derive(0)  |  Import(1)

src/n/i/nipy-0.3.0/nipy/labs/spatial_models/tests/test_parcel_io.py   nipy(Download)
from numpy.testing import assert_equal
from ...utils.simul_multisubject_fmri_dataset import surrogate_3d_dataset
from ..parcel_io import (mask_parcellation, fixed_parcellation,
                         parcellation_based_analysis)
from ..hierarchical_parcellation import hparcel
    shape = (10, 10, 10)
    mask_image = Nifti1Image(np.ones(shape), np.eye(4))
    wim = mask_parcellation(mask_image, n_parcels)
    assert_equal(np.unique(wim.get_data()), np.arange(n_parcels))
 
            mask_images.append(path)
 
        wim = mask_parcellation(mask_images, n_parcels)
        assert_equal(np.unique(wim.get_data()), np.arange(n_parcels))