コード例 #1
0
ファイル: afni_niml_dset.py プロジェクト: neurosbh/PyMVPA
def write(fnout, dset, form='binary'):
    fn = os.path.split(fnout)[1]

    if not type(fn) is str:
        if not isinstance(fnout, basestring):
            raise ValueError("Filename %s should be string" % str)
        fn = str(fn)  # ensure that unicode is converted to string

    dset['filename'] = fn
    niml.write(fnout, dset, form, dset2rawniml)
コード例 #2
0
ファイル: afni_niml_dset.py プロジェクト: Arthurkorn/PyMVPA
def write(fnout, dset, form='binary'):
    fn = os.path.split(fnout)[1]

    if not type(fn) is str:
        if not isinstance(fnout, basestring):
            raise ValueError("Filename %s should be string" % str)
        fn = str(fn) # ensure that unicode is converted to string

    dset['filename'] = fn
    niml.write(fnout, dset, form, dset2rawniml)
コード例 #3
0
def write(fnout, niml_annot):
    fn = os.path.split(fnout)[1]

    if not type(fn) is str:
        if not isinstance(fnout, basestring):
            raise ValueError("Filename %s should be string" % str)
        fn = str(fn)  # ensure that unicode is converted to string

    niml_annot['filename'] = fn
    form = 'text'
    niml.write(fnout, niml_annot, form, annot2rawniml)
コード例 #4
0
ファイル: afni_niml_annot.py プロジェクト: Anhmike/PyMVPA
def write(fnout, niml_annot):
    fn = os.path.split(fnout)[1]

    if not type(fn) is str:
        if not isinstance(fnout, basestring):
            raise ValueError("Filename %s should be string" % str)
        fn = str(fn) # ensure that unicode is converted to string

    niml_annot['filename'] = fn
    form = 'text'
    niml.write(fnout, niml_annot, form, annot2rawniml)