Open
Conversation
Owner
|
@jessicapilling - Damn I'm sorry I completely missed this way back when. Was this fully working when you did the PR? |
DavidT3
requested changes
Sep 10, 2025
Owner
DavidT3
left a comment
There was a problem hiding this comment.
I'm sorry this took so long, I kept forgetting it!
| # dont exist, it returns a default value. We use this here, so that when we format the config | ||
| # file with this defaultdict, if there is a telescope that isn't in the user's archive, but is | ||
| # in the config, it will fill those strings with a default value: 'this/is/optional' | ||
| strs_for_cfg_inc_defaults = defaultdict(lambda: '/this/is/optional/', strings_for_config) |
Owner
There was a problem hiding this comment.
You taught me some new Python - I didn't know about defaultdicts
| xga.sources.base.OUTPUT = new_out | ||
| xga.sas.phot.OUTPUT = new_out | ||
| xga.sas.misc.OUTPUT = new_out | ||
| xga.generate.sas.phot.OUTPUT = new_out |
Owner
There was a problem hiding this comment.
Trouble with this is that xga.generate.sas doesn't exist for non-multi-mission XGA.
| # And we make sure to save! | ||
| self.save() | ||
|
|
||
| def write_xga_config(self, xga_version: str = 'latest', |
Owner
There was a problem hiding this comment.
Reading through this function, does it actually point the new XGA config file to any event lists or images?
The templates for the config files also assume which energies of image/expmap are going to be generated, which will have to change
This file contains hidden or 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
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.
This is the first draft for a function that takes an archive object and writes an xga config file with the paths all formatted for the data in the archive.
I still need to test that xga is happy with the output config file, but I have just submitted a pull request so you can comment on anything you want included/ changed!