Skip to content

Conversation

@gohil-jay
Copy link
Collaborator

No description provided.

@github-actions github-actions bot added the needs changelog Might need a changelog entry label Jun 27, 2022
@gohil-jay gohil-jay changed the title Updated numpy.testing asserts to pytest.approx Added histograms' comparison (and updated numpy.testing asserts to pytest.approx) Jun 28, 2022
)

import numpy as np
from pytest import approx
Copy link
Member

Choose a reason for hiding this comment

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

We can't use pytest inside the library itself. There are tools for this like np.allclose. Also compare should return True/False, not errors / asserts. Let's move the changes to hist.py into a different PR, as that's not related to using approx in the tests. :)

@gohil-jay
Copy link
Collaborator Author

Alright, the first approx PR is here:
#760

I'll send another updated one (without pytest and true/false return) for the comparison once #760 is merged!

@gohil-jay gohil-jay closed this Jun 29, 2022
@gohil-jay
Copy link
Collaborator Author

The separate PR for the comparison is ready here in this branch (without pytest and true/false return):
https://github.com/gohil-jay/boost-histogram/tree/issue157-1

@henryiii henryiii removed the needs changelog Might need a changelog entry label Jun 30, 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.

2 participants