def _to_fixed_ori(forward):
 if ((not forward['surf_ori']) or is_fixed_orient(forward)):
  raise ValueError('Only surface-oriented, free-orientation forward solutions can be converted to fixed orientaton')
 forward['sol']['data'] = forward['sol']['data'][:, 2::3]
 forward['sol']['ncol'] = (forward['sol']['ncol'] / 3)
 forward['source_ori'] = FIFF.FIFFV_MNE_FIXED_ORI
 logger.info('    Converted the forward solution into the fixed-orientation mode.')
 return forward

def _to_fixed_ori ( forward ) : if ( ( not forward [ 'surf_ori' ] ) or is_fixed_orient ( forward ) ) : raise ValueError ( 'Only surface-oriented, free-orientation forward solutions can be converted to fixed orientaton' ) forward [ 'sol' ] [ 'data' ] = forward [ 'sol' ] [ 'data' ] [ : , 2 : : 3 ] forward [ 'sol' ] [ 'ncol' ] = ( forward [ 'sol' ] [ 'ncol' ] / 3 ) forward [ 'source_ori' ] = FIFF . FIFFV_MNE_FIXED_ORI logger . info ( '    Converted the forward solution into the fixed-orientation mode.' ) return forward
convert the forward solution to fixed ori from free .