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

FIX: Fix error in report when sklearnex has more parameters than sklearn #171

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

david-cortes-intel
Copy link
Contributor

@david-cortes-intel david-cortes-intel commented Mar 6, 2025

Description

Currently, when creating a report comparing sklearn vs. sklearnex, if some algorithm has more parameters in sklearnex than in sklearn (such as tree-based algorithms like ExtraTreesClassifier), an error will occur when trying to generate the excel report from the JSONs, due to being unable to find those sklearnex-specific columns in the data from sklearn.

This PR fixes the issue by dropping all parameter columns that are not present in data from all the compared libraries, but I am not sure that this wouldn't break some other use-case, so please give it a thorough review.


PR should start as a draft, then move to ready for review state after CI is passed and all applicable checkboxes are closed.
This approach ensures that reviewers don't spend extra time asking for regular requirements.

You can remove a checkbox as not applicable only if it doesn't relate to this PR in any way.

Checklist to comply with before moving PR from draft:

PR completeness and readability

  • I have reviewed my changes thoroughly before submitting this pull request.
  • 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

  • I have run it locally and tested the changes extensively.
  • All CI jobs are green or I have provided justification why they aren't.

@david-cortes-intel david-cortes-intel added the bug Something isn't working label Mar 6, 2025
@david-cortes-intel david-cortes-intel marked this pull request as ready for review March 6, 2025 11:32
@david-cortes-intel david-cortes-intel marked this pull request as draft March 10, 2025 08:55
@david-cortes-intel
Copy link
Contributor Author

Looks like this PR doesn't work in all cases. Sometimes it leaves rows where there are times for both sklearn and sklearnex but no comparison metrics (e.g. time improvement) calculated for them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant