Skip to content

Fix np.__round__ does not exist#259

Merged
eddiebergman merged 9 commits intomasterfrom
fix_rounding
Jun 27, 2022
Merged

Fix np.__round__ does not exist#259
eddiebergman merged 9 commits intomasterfrom
fix_rounding

Conversation

@eddiebergman
Copy link
Copy Markdown
Contributor

@eddiebergman eddiebergman commented Jun 23, 2022

Seems there was some issue with AssertAlmostEqual will call round(np.ndarray), causing the issue that Type: np.ndarray has no __round__ method. Solution was just to unpack the single element arrays

Also fixes an issue where ConfigSpace.util::generate_grid was converting log uniforms from float to int with vec.astype(int) instead of np.round(vec), which cause occasional failures due to something like 99.9999999 being converted to 99 instead of 100.

@codecov
Copy link
Copy Markdown

codecov bot commented Jun 23, 2022

Codecov Report

Merging #259 (088aebd) into master (3036164) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #259   +/-   ##
=======================================
  Coverage   66.72%   66.72%           
=======================================
  Files          17       17           
  Lines        1665     1665           
=======================================
  Hits         1111     1111           
  Misses        554      554           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3036164...088aebd. Read the comment docs.

@eddiebergman eddiebergman mentioned this pull request Jun 27, 2022
@eddiebergman eddiebergman requested a review from mfeurer June 27, 2022 09:34
@eddiebergman eddiebergman merged commit 328fc5d into master Jun 27, 2022
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.

1 participant