本文整理汇总了Python中bigml.api.BigML.create_cluster方法的典型用法代码示例。如果您正苦于以下问题:Python BigML.create_cluster方法的具体用法?Python BigML.create_cluster怎么用?Python BigML.create_cluster使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类bigml.api.BigML
的用法示例。
在下文中一共展示了BigML.create_cluster方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: BigML
# 需要导入模块: from bigml.api import BigML [as 别名]
# 或者: from bigml.api.BigML import create_cluster [as 别名]
from bigml.api import BigML
api = BigML()
source1 = api.create_source("iris.csv")
api.ok(source1)
dataset1 = api.create_dataset(source1)
api.ok(dataset1)
cluster1 = api.create_cluster(dataset1)
api.ok(cluster1)
batchcentroid1 = api.create_batch_centroid(cluster1, dataset1, {"name": u"my_batch_centroid_name"})
api.ok(batchcentroid1)
示例2: BigML
# 需要导入模块: from bigml.api import BigML [as 别名]
# 或者: from bigml.api.BigML import create_cluster [as 别名]
from bigml.api import BigML
api = BigML()
source1 = api.create_source("iris.csv")
api.ok(source1)
dataset1 = api.create_dataset(source1)
api.ok(dataset1)
cluster1 = api.create_cluster(dataset1, \
{'name': u'my_cluster_name'})
api.ok(cluster1)
示例3: BigML
# 需要导入模块: from bigml.api import BigML [as 别名]
# 或者: from bigml.api.BigML import create_cluster [as 别名]
from bigml.api import BigML
api = BigML()
source1 = api.create_source("iris.csv")
api.ok(source1)
dataset1 = api.create_dataset(source1, \
{'name': u'iris dataset'})
api.ok(dataset1)
cluster1 = api.create_cluster(dataset1, \
{'name': u"iris dataset's cluster"})
api.ok(cluster1)
centroid1 = api.create_centroid(cluster1, \
{u'petal length': 0.5,
u'petal width': 0.5,
u'sepal length': 1,
u'sepal width': 1,
u'species': u'Iris-setosa'}, \
{'name': u'my_centroid_name'})
api.ok(centroid1)
示例4: BigML
# 需要导入模块: from bigml.api import BigML [as 别名]
# 或者: from bigml.api.BigML import create_cluster [as 别名]
from bigml.api import BigML
api = BigML()
source1 = api.create_source("iris.csv")
api.ok(source1)
dataset1 = api.create_dataset(source1, \
{'name': 'iris'})
api.ok(dataset1)
cluster1 = api.create_cluster(dataset1, \
{'name': 'iris'})
api.ok(cluster1)
batchcentroid1 = api.create_batch_centroid(cluster1, dataset1, \
{'name': 'iris dataset with iris', 'output_dataset': True})
api.ok(batchcentroid1)
dataset2 = api.get_dataset(batchcentroid1['object']['output_dataset_resource'])
api.ok(dataset2)
dataset2 = api.update_dataset(dataset2, \
{'name': 'iris dataset with iris'})
api.ok(dataset2)
dataset3 = api.create_dataset(dataset2, \
{'name': 'my_dataset_from_dataset_from_batch_centroid_name',
'new_fields': [{'field': '( integer ( replace ( field "cluster" ) '
'"Cluster " "" ) )',
'name': 'Cluster'}],
'objective_field': {'id': '100000'}})
示例5: BigML
# 需要导入模块: from bigml.api import BigML [as 别名]
# 或者: from bigml.api.BigML import create_cluster [as 别名]
from bigml.api import BigML
api = BigML()
source1 = api.create_source("iris.csv")
api.ok(source1)
dataset1 = api.create_dataset(source1, {"name": u"iris dataset"})
api.ok(dataset1)
cluster1 = api.create_cluster(dataset1, {"name": u"my_cluster_name"})
api.ok(cluster1)