_physio.py 文件源码

python
阅读 35 收藏 0 点赞 0 评论 0

项目:brainpipe 作者: EtienneCmb 项目源码 文件源码
def loadatlas(r=5):
    """Load the atlas from the brainpipe module
    """
    B3Dpath = dirname(
        abspath(join(getfile(currentframe()), '..', '..', '..', 'atlas')))

    # Load talairach atlas :
    with open(B3Dpath + '/atlas/labels/talairach_atlas.pickle', "rb") as f:
        TAL = pickle.load(f)
    label = TAL['label']
    strGM = ['No Gray Matter found within +/-'+str(r)+'mm']
    label = concat([label, DataFrame({'hemisphere': [strGM], 'lobe':[
                   strGM], 'gyrus':[strGM], 'matter':[strGM], 'brodmann':[
        0]})])
    label = label.set_index([list(n.arange(label.shape[0]))])
    return TAL['hdr'], TAL['mask'], TAL['gray'], label
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号