Feature top hat window selection #83
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Following discussion #81 , this PR proposes to extend the ability to get window for
(Log)TopHatWindowthe same asBandpowerWindow.When filling data via
add_ell_clfunction, the(Log)TopHatWindowobject is associated to awindow_indtag which indexes its position related to data index.When retrieving the windows via
get_bandpower_windows(it may be worth renaming this function intoget_windowssince it is not anymore dedicated to onlyBandpowerWindow), then the full binning array is computed given the selected indices (here again, in the same way asBandpowerWindow).The important thing to think about is that
(Log)TopHatWindowobject is now storing the whole bin edges and not a pair of min/max value. Nevertheless, it should be backward compatible since min/max scalar values can also be represented by one entry array.We may understand this feature is not required or desired and that it exists other way to extract the windows (using
get_tagfunctions for instance, see #81 discussion) but the important point is that it allows to treatBandpowerWindowand(Log)TopHatWindowobjects the same way without assuming or accessing the type of window.This will close #81