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

Enable serialization in daal4py algorithm classes #2067

Merged

Conversation

david-cortes-intel
Copy link
Contributor

Description

fixes #425

This PR adds support for serialization of the algorithm classes in daal4py.

Since they do not store data nor results, the logic is simply to store the init parameters that were passed, and call the initializer again with those same parameters.

I wasn't sure where to add a unit test for this so I created a new test file.


Checklist to comply with before moving PR from draft:

PR completeness and readability

  • I have reviewed my changes thoroughly before submitting this pull request.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have updated the documentation to reflect the changes or created a separate PR with update and provided its number in the description, if necessary.
  • Git commit message contains an appropriate signed-off-by string (see CONTRIBUTING.md for details).
  • I have added a respective label(s) to PR if I have a permission for that.
  • I have resolved any merge conflicts that might occur with the base branch.

Testing

  • The unit tests pass successfully.
  • I have run it locally and tested the changes extensively.

Performance

  • I have measured performance for affected algorithms using scikit-learn_bench and provided at least summary table with measured data, if performance change is expected.
  • I have provided justification why performance has changed or why changes are not expected.

@samir-nasibli
Copy link
Contributor

@david-cortes-intel please address fails. Moving to draft for now

@samir-nasibli samir-nasibli marked this pull request as draft September 25, 2024 13:16
@david-cortes-intel david-cortes-intel marked this pull request as ready for review September 26, 2024 05:51
@david-cortes-intel
Copy link
Contributor Author

/intelci: run

Copy link
Contributor

@icfaust icfaust left a comment

Choose a reason for hiding this comment

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

If you could add another algo to the test, I would be happy. Still good to merge as is. Honestly impressive work.

@david-cortes-intel
Copy link
Contributor Author

Added a test with KMeans also.

@david-cortes-intel
Copy link
Contributor Author

The failing CI jobs appear to be happening elsewhere too and are unrelated to the changes here.

@david-cortes-intel david-cortes-intel merged commit 3208718 into uxlfoundation:main Oct 1, 2024
9 of 24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Algorithms cannot be pickle'd
3 participants