def getSPClass(spatialImp):
 if (spatialImp == 'py'):
  return PYSpatialPooler
 elif (spatialImp == 'cpp'):
  return CPPSpatialPooler
 else:
  raise RuntimeError(("Invalid spatialImp '%s'. Legal values are: 'py', 'cpp'" % spatialImp))

def getSPClass ( spatialImp ) : if ( spatialImp == 'py' ) : return PYSpatialPooler elif ( spatialImp == 'cpp' ) : return CPPSpatialPooler else : raise RuntimeError ( ( "Invalid spatialImp '%s'. Legal values are: 'py', 'cpp'" % spatialImp ) )
return the class corresponding to the given spatialimp string .