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

an error in gof.py #18

Closed
ellot opened this issue Feb 7, 2021 · 5 comments
Closed

an error in gof.py #18

ellot opened this issue Feb 7, 2021 · 5 comments

Comments

@ellot
Copy link

ellot commented Feb 7, 2021

I use BXA in pyxspec. In some cases, there are nan values in lowmodel_parts. So the assert error is reported in line 85 of gof.py.
I find some values of kplusones equal 0 (line 78, 79).

@JohannesBuchner
Copy link
Owner

Hmm, doesn't that mean data was <0 somewhere? Are you using binning on non-count data somehow?

@ellot
Copy link
Author

ellot commented Feb 8, 2021

Yes, in few cases, the net counts (subtracting background) is <0.

@JohannesBuchner
Copy link
Owner

That code (binning function) is only supposed to be run on count data, not subtracted data.

@JohannesBuchner
Copy link
Owner

Probably the exception should be raised earlier, in the binning function.

@JohannesBuchner
Copy link
Owner

Please reopen this if you still have the issue, and provide a code example with data.

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

No branches or pull requests

2 participants