Skip to content

Commit

Permalink
use getter instead of creating local var and update version
Browse files Browse the repository at this point in the history
  • Loading branch information
danielenricocahall committed Jan 31, 2021
1 parent d19a929 commit 6ef749a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions elephas/ml_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,6 @@ def _transform(self, df):
"""
output_col = self.getOutputCol()
label_col = self.getLabelCol()
features_col = self.getFeaturesCol()
new_schema = copy.deepcopy(df.schema)
new_schema.add(StructField(output_col, StringType(), True))
rdd = df.rdd
Expand All @@ -199,7 +198,7 @@ def extract_features_and_predict(model_yaml: str,
partial(extract_features_and_predict,
self.get_keras_model_config(),
self.get_custom_objects(),
features_col,
self.getFeaturesCol(),
self.model_type))
if self.model_type == ModelType.CLASSIFICATION:
predictions = predictions.map(lambda x: tuple(str(x)))
Expand Down
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
from setuptools import find_packages

setup(name='elephas',
version='1.2.1',
version='1.3.1',
description='Deep learning on Spark with Keras',
url='http://github.com/maxpumperla/elephas',
download_url='https://github.com/maxpumperla/elephas/tarball/1.2.1',
download_url='https://github.com/maxpumperla/elephas/tarball/1.3.1',
author='Daniel Cahall',
author_email='[email protected]',
install_requires=['cython',
Expand Down

0 comments on commit 6ef749a

Please sign in to comment.