示例#1
0
def test_fetch_haxby_simple():
    local_url = "file://" + os.path.join(datadir, "pymvpa-exampledata.tar.bz2")
    haxby = func.fetch_haxby_simple(data_dir=tmpdir, url=local_url, verbose=0)
    datasetdir = os.path.join(tmpdir, 'haxby2001_simple', 'pymvpa-exampledata')
    for key, file in [('session_target', 'attributes.txt'),
                      ('func', 'bold.nii.gz'), ('mask', 'mask.nii.gz'),
                      ('conditions_target', 'attributes_literal.txt')]:
        assert_equal(haxby[key], os.path.join(datasetdir, file))
        assert_true(os.path.exists(os.path.join(datasetdir, file)))
示例#2
0
def test_fetch_haxby_simple():
    local_url = "file://" + os.path.join(datadir, "pymvpa-exampledata.tar.bz2")
    haxby = func.fetch_haxby_simple(data_dir=tmpdir, url=local_url,
                                    verbose=0)
    datasetdir = os.path.join(tmpdir, 'haxby2001_simple', 'pymvpa-exampledata')
    for key, file in [
            ('session_target', 'attributes.txt'),
            ('func', 'bold.nii.gz'),
            ('mask', 'mask.nii.gz'),
            ('conditions_target', 'attributes_literal.txt')]:
        assert_equal(haxby[key], os.path.join(datasetdir, file))
        assert_true(os.path.exists(os.path.join(datasetdir, file)))
示例#3
0
def test_fetch_haxby_simple():
    local_url = "file://" + os.path.join(datadir, "pymvpa-exampledata.tar.bz2")
    haxby = func.fetch_haxby_simple(data_dir=tmpdir, url=local_url, verbose=0)
    datasetdir = os.path.join(tmpdir, "haxby2001_simple", "pymvpa-exampledata")
    for key, file in [
        ("session_target", "attributes.txt"),
        ("func", "bold.nii.gz"),
        ("mask", "mask.nii.gz"),
        ("conditions_target", "attributes_literal.txt"),
    ]:
        assert_equal(haxby[key], os.path.join(datasetdir, file))
        assert_true(os.path.exists(os.path.join(datasetdir, file)))