Skip to content

Commit

Permalink
[SPARK-8765] [MLLIB] [PYTHON] removed flaky python PIC test
Browse files Browse the repository at this point in the history
See failure: [https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/36133/console]

CC yanboliang  mengxr

Author: Joseph K. Bradley <joseph@databricks.com>

Closes #7164 from jkbradley/pic-python-test and squashes the following commits:

156d55b [Joseph K. Bradley] removed flaky python PIC test
  • Loading branch information
jkbradley authored and mengxr committed Jul 1, 2015
1 parent 2012913 commit b8faa32
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions python/pyspark/mllib/clustering.py
Original file line number Diff line number Diff line change
Expand Up @@ -288,16 +288,12 @@ class PowerIterationClusteringModel(JavaModelWrapper, JavaSaveable, JavaLoader):
>>> model = PowerIterationClustering.train(rdd, 2, 100)
>>> model.k
2
>>> sorted(model.assignments().collect())
[Assignment(id=0, cluster=1), Assignment(id=1, cluster=0), ...
>>> import os, tempfile
>>> path = tempfile.mkdtemp()
>>> model.save(sc, path)
>>> sameModel = PowerIterationClusteringModel.load(sc, path)
>>> sameModel.k
2
>>> sorted(sameModel.assignments().collect())
[Assignment(id=0, cluster=1), Assignment(id=1, cluster=0), ...
>>> from shutil import rmtree
>>> try:
... rmtree(path)
Expand Down

0 comments on commit b8faa32

Please sign in to comment.