-
Notifications
You must be signed in to change notification settings - Fork 22
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
addable weight view? #276
Comments
I've thought about this a bit before and was already mildly in favor of it. Especially since you define a limit here; all operations a histogram supports should also be supported by accumulator views. |
I think this would actually make things like #261 (the adding different storages) easier. If we make different weight views addable, we can do the addition in Python instead of in C++, and avoid binding every possible combination of pair of histograms and keep the compile time down. |
Adding weight views is supported as of #368. Still are some missing operators, though. |
So we need to be able to support the basic operators (addition, division, etc) between to views and between a view and a scalar/array (in some cases). These can be implemented in the same way as #368. That will enable performing operations on views and will enable a few other features. |
I am not 100 % sure we should really do this, but it would be handy if the view of a histogram with weight storage would allow adding views and in general all the operators that also the histogram itself supports. The record array in numpy does not support addition or other operators, but since we are wrapping it, we could add support for this special record array.
The text was updated successfully, but these errors were encountered: