-
Notifications
You must be signed in to change notification settings - Fork 13
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
Instrumental background #670
Open
s-silvestri
wants to merge
51
commits into
main
Choose a base branch
from
instrumental_background
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The build fails because some unit tests were relying on old background templates which are no longer there. Note that even if we redirect the paths of these templates to the new ones, the default template which is just for the residual background, could yield to unexpected results. |
… contains vextors e.g.: STATUS columns
…obssim into instrumental_background
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Changed the workflow for creating a background template and implemented a default background template.
How to create a background:
· Launch instr.py with pha1 files of the background as positional arguments.
· Optionally choose the output file name (default: IXPEOBSSIM_SRCMODEL/ascii/instrumental_bkg_template.txt)
· To generate a background then one needs to create a config file and this is essentially unchanged. The default path for the template file, however, is now IXPEOBSSIM_SRCMODEL/ascii/instrumental_bkg_template.txt, that is the class xTemplateInstrumentalBackground has that as default file_path
New features
· The spline smoothing parameter can be defined as an argument when launching instr.py
· instr.py now plots the input spectra and the average, which is saved by default into the ascii template file. If only one observation is provided, this will be the average of the 3 DUs
· instr.py has a built-in function that tries to mitigate spline oscillations below 1 keV that essentially forces the spline to be monothonic by altering the gradient of the function.
·smcx1 is not special anymore so i deleted its template.
i have not implemented the pha1 files in ixpeobssim/bkg/data as we did for smcx1 since i don't believe that they can be interesting for the user now that we plan to write a documentation for this procedure, but in case they can be implemented in no time.