本文整理匯總了Python中KNNClassifierRegion.KNNClassifierRegion.getSpec方法的典型用法代碼示例。如果您正苦於以下問題:Python KNNClassifierRegion.getSpec方法的具體用法?Python KNNClassifierRegion.getSpec怎麽用?Python KNNClassifierRegion.getSpec使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類KNNClassifierRegion.KNNClassifierRegion
的用法示例。
在下文中一共展示了KNNClassifierRegion.getSpec方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: getSpec
# 需要導入模塊: from KNNClassifierRegion import KNNClassifierRegion [as 別名]
# 或者: from KNNClassifierRegion.KNNClassifierRegion import getSpec [as 別名]
def getSpec(cls):
ns = dict(
description=KNNAnomalyClassifierRegion.__doc__,
singleNodeOnly=True,
inputs=dict(
spBottomUpOut=dict(
description="""The output signal generated from the bottom-up inputs
from lower levels.""",
dataType='Real32',
count=0,
required=True,
regionLevel=False,
isDefaultInput=True,
requireSplitterMap=False),
tpTopDownOut=dict(
description="""The top-down inputsignal, generated from
feedback from upper levels""",
dataType='Real32',
count=0,
required=True,
regionLevel=False,
isDefaultInput=True,
requireSplitterMap=False),
tpLrnActiveStateT=dict(
description="""Active cells in the learn state at time T from TP.
This is used to classify on.""",
dataType='Real32',
count=0,
required=True,
regionLevel=False,
isDefaultInput=True,
requireSplitterMap=False)
),
outputs=dict(
),
parameters=dict(
trainRecords=dict(
description='Number of records to wait for training',
dataType='UInt32',
count=1,
constraints='',
defaultValue=0,
accessMode='Create'),
anomalyThreshold=dict(
description='Threshold used to classify anomalies.',
dataType='Real32',
count=1,
constraints='',
defaultValue=0,
accessMode='Create'),
cacheSize=dict(
description='Number of records to store in cache.',
dataType='UInt32',
count=1,
constraints='',
defaultValue=0,
accessMode='Create'),
classificationVectorType=dict(
description="""Vector type to use when classifying.
1 - Vector Column with Difference (TP and SP)
""",
dataType='UInt32',
count=1,
constraints='',
defaultValue=1,
accessMode='ReadWrite'),
activeColumnCount=dict(
description="""Number of active columns in a given step. Typically
equivalent to SP.numActivePerInhArea""",
dataType='UInt32',
count=1,
constraints='',
defaultValue=40,
accessMode='ReadWrite'),
classificationMaxDist=dict(
description="""Maximum distance a sample can be from an anomaly
in the classifier to be labeled as an anomaly.
Ex: With rawOverlap distance, a value of 0.65 means that the points
must be at most a distance 0.65 apart from each other. This
translates to they must be at least 35% similar.""",
dataType='Real32',
count=1,
constraints='',
defaultValue=0.65,
accessMode='Create'
)
),
commands=dict(
getLabels=dict(description=
"Returns a list of label dicts with properties ROWID and labels."
#.........這裏部分代碼省略.........