-
Notifications
You must be signed in to change notification settings - Fork 28
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
different result compared to numpy #61
Comments
Is this repo still maintained? |
For numpy 1d histogram function, if you set bins as 10, the returned hist would be length of 9. But for fast histogram 1d function, if you set bins as 10, the returned hist would be length of 10 which is inconsistent.
I realized that fast histogram set the upper range as excluded which is inconsistent with numpy. Correct me if I am wrong. I have tried many ways. The result_2 is the closest one but with a length of 10. I really want to replace numpy histogram with a fast histogram. But I need the same result. |
Yes this is still maintained - will respond soon! |
@d5423197 if you are trying to bin integers, I highly recommend using |
Hello there,
I am trying to use this repo to replace numpy but get different result.
I put range as the minimum of the input and the maximum of the input. But I found out that the result is missing some maximum value.
For example,
test_case = np.array([1, 1, 2, 2, 3, 3, 10, 10]) freq, bins = np.histogram(test_case, range(np.min(test_case), np.max(test_case + 1))) result = histogram1d(test_case, bins=9, range=(np.min(test_case), np.max(test_case)))
The text was updated successfully, but these errors were encountered: