def write_bem_surfaces(fname, surfs):
 if isinstance(surfs, dict):
  surfs = [surfs]
 with start_file(fname) as fid:
  start_block(fid, FIFF.FIFFB_BEM)
  write_int(fid, FIFF.FIFF_BEM_COORD_FRAME, surfs[0]['coord_frame'])
  _write_bem_surfaces_block(fid, surfs)
  end_block(fid, FIFF.FIFFB_BEM)
  end_file(fid)

def write_bem_surfaces ( fname , surfs ) : if isinstance ( surfs , dict ) : surfs = [ surfs ] with start_file ( fname ) as fid : start_block ( fid , FIFF . FIFFB_BEM ) write_int ( fid , FIFF . FIFF_BEM_COORD_FRAME , surfs [ 0 ] [ 'coord_frame' ] ) _write_bem_surfaces_block ( fid , surfs ) end_block ( fid , FIFF . FIFFB_BEM ) end_file ( fid )
write bem surfaces to a fiff file .