Skip to content

Commit

Permalink
getStorageLevel -> storageLevel
Browse files Browse the repository at this point in the history
  • Loading branch information
yanboliang committed Sep 13, 2017
1 parent e22ff7f commit 1b7b1d5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python/pyspark/ml/classification.py
Original file line number Diff line number Diff line change
Expand Up @@ -1659,7 +1659,7 @@ def _fit(self, dataset):
multiclassLabeled = dataset.select(labelCol, featuresCol)

# persist if underlying dataset is not persistent.
handlePersistence = dataset.getStorageLevel() == StorageLevel(False, False, False, False)
handlePersistence = dataset.storageLevel == StorageLevel(False, False, False, False)
if handlePersistence:
multiclassLabeled.persist(StorageLevel.MEMORY_AND_DISK)

Expand Down Expand Up @@ -1813,7 +1813,7 @@ def _transform(self, dataset):
newDataset = dataset.withColumn(accColName, initUDF(dataset[origCols[0]]))

# persist if underlying dataset is not persistent.
handlePersistence = dataset.getStorageLevel() == StorageLevel(False, False, False, False)
handlePersistence = dataset.storageLevel == StorageLevel(False, False, False, False)
if handlePersistence:
newDataset.persist(StorageLevel.MEMORY_AND_DISK)

Expand Down

0 comments on commit 1b7b1d5

Please sign in to comment.