dipy/data/fetcher.py
def fetch_stanford_hardi():
    """ Download a HARDI dataset with 160 gradient directions
    """
    url = 'https://stacks.stanford.edu/file/druid:yx282xq2090/'
    uraw = url + 'dwi.nii.gz'
    ubval = url + 'dwi.bvals'
    ubvec = url + 'dwi.bvecs'
    folder = pjoin(dipy_home, 'stanford_hardi')

    md5_list = ['0b18513b46132b4d1051ed3364f2acbc',  # data
                '4e08ee9e2b1d2ec3fddb68c70ae23c36',  # bval
                '4c63a586f29afc6a48a5809524a76cb4']  # bvec

    url_list = [uraw, ubval, ubvec]
    fname_list = ['HARDI150.nii.gz', 'HARDI150.bval', 'HARDI150.bvec']

    if not os.path.exists(folder):
        print('Creating new directory %s' % folder)
        os.makedirs(folder)
        print('Downloading raw HARDI data (87MB)...')

        for i in range(len(md5_list)):
            _get_file_data(pjoin(folder, fname_list[i]), url_list[i])
            check_md5(pjoin(folder, fname_list[i]), md5_list[i])

        print('Done.')
        print('Files copied in folder %s' % folder)
    else:
        _already_there_msg(folder)
 Download a HARDI dataset with 160 gradient directions
    
Download a HARDI dataset with 160 gradient directions
Download a HARDI dataset with 160 gradient directions
def fetch_stanford_hardi():
    url = 'https://stacks.stanford.edu/file/druid:yx282xq2090/'
    uraw = url + 'dwi.nii.gz'
    ubval = url + 'dwi.bvals'
    ubvec = url + 'dwi.bvecs'
    folder = pjoin(dipy_home, 'stanford_hardi')
    md5_list = ['0b18513b46132b4d1051ed3364f2acbc',  
                '4e08ee9e2b1d2ec3fddb68c70ae23c36',  
                '4c63a586f29afc6a48a5809524a76cb4']  
    url_list = [uraw, ubval, ubvec]
    fname_list = ['HARDI150.nii.gz', 'HARDI150.bval', 'HARDI150.bvec']
    if not os.path.exists(folder):
        print('Creating new directory %s' % folder)
        os.makedirs(folder)
        print('Downloading raw HARDI data (87MB)...')
        for i in range(len(md5_list)):
            _get_file_data(pjoin(folder, fname_list[i]), url_list[i])
            check_md5(pjoin(folder, fname_list[i]), md5_list[i])
        print('Done.')
        print('Files copied in folder %s' % folder)
    else:
        _already_there_msg(folder)
def fetch_stanford_hardi ( ) : url = 'https://stacks.stanford.edu/file/druid:yx282xq2090/' uraw = url + 'dwi.nii.gz' ubval = url + 'dwi.bvals' ubvec = url + 'dwi.bvecs' folder = pjoin ( dipy_home , 'stanford_hardi' ) md5_list = [ '0b18513b46132b4d1051ed3364f2acbc' , '4e08ee9e2b1d2ec3fddb68c70ae23c36' , '4c63a586f29afc6a48a5809524a76cb4' ] url_list = [ uraw , ubval , ubvec ] fname_list = [ 'HARDI150.nii.gz' , 'HARDI150.bval' , 'HARDI150.bvec' ] if not os . path . exists ( folder ) : print ( 'Creating new directory %s' % folder ) os . makedirs ( folder ) print ( 'Downloading raw HARDI data (87MB)...' ) for i in range ( len ( md5_list ) ) : _get_file_data ( pjoin ( folder , fname_list [ i ] ) , url_list [ i ] ) check_md5 ( pjoin ( folder , fname_list [ i ] ) , md5_list [ i ] ) print ( 'Done.' ) print ( 'Files copied in folder %s' % folder ) else : _already_there_msg ( folder )
Download a HARDI dataset with 160 gradient directions
Download a HARDI dataset with 160 gradient directions
""" Download a HARDI dataset with 160 gradient directions
    """ # data # bval # bvec