Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[#903] Replace custom conversion function with ndarray.tolist #922

Merged

Conversation

tomasatdatabricks
Copy link
Contributor

@tomasatdatabricks tomasatdatabricks commented Feb 25, 2019

Fixes #903

from mlflow.utils import get_jsonable_obj
from mlflow.utils.rest_utils import NumpyEncoder
py_ary = [["a", "b", "c"],["e", "f", "g"]]
np_ary = get_jsonable_obj(np.array(py_ary))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing numpy import here

Copy link
Collaborator

@dbczumar dbczumar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@tomasatdatabricks tomasatdatabricks merged commit 8a62883 into mlflow:master Mar 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants