aws / sagemaker-experiments

Experiment tracking and metric logging for Amazon SageMaker notebooks and model training.
Apache License 2.0
125 stars 36 forks source link

Fix to parameter validation of `tracker.log_table` #125

Closed jmahlik closed 3 years ago

jmahlik commented 3 years ago

…ssed

Issue #, if available: NA

Description of changes: Changed parameter validation for dataframe to if dataframe is not None:. Current if dataframe: causes the index of an array is ambiguous...etc error which was preventing using it to log dfs.

Testing done: Added a simple dataframe test. Let me know if more are needed. The .to_dict() method in the conversion should catch most things that aren't dataframes. Maybe consider isinstanceing and raising as well? Happy to add it.

Merge Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your pull request.

General

Tests

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.