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

[Enhancement]: Add default parameters in Meta class rather than throughout the code #594

Open
1 task done
taylorbell57 opened this issue Dec 18, 2023 · 0 comments · May be fixed by #632
Open
1 task done

[Enhancement]: Add default parameters in Meta class rather than throughout the code #594

taylorbell57 opened this issue Dec 18, 2023 · 0 comments · May be fixed by #632
Assignees
Labels
enhancement New feature or request

Comments

@taylorbell57
Copy link
Collaborator

Instrument

Other (any stage)

What is your suggestion?

At present, all original ECF parameters need to be specified in the files, and any recently added parameters have hardcoded defaults scattered throughout the code to maintain backwards compatibility. This is becoming increasingly painful to maintain since the defaults aren't anywhere in particular, but rather just before the parameters are first used. The clean way of doing this is having a Meta class that's unique to each stage and has all of the default ECF parameters specified; this makes it easy for folks to understand what the defaults are if they don't set a parameter, and makes maintenance much easier. This will also allow us to set defaults for many/all parameters so that users can have more sparse ECF files by removing the parameters they never intend to change from their defaults (there's definitely some of these). This will require some instrument-specific switching since the defaults for some parameters do change with instrument.

Related to this though, I think it'd be best to output all of the utilized defaults to the ECF file that gets copied to the output directory. That way the end user has all of the exact settings they used which will make it easier for folks to ensure reproducibility if they switch between different versions of Eureka! that might have different defaults.

Error traceback output

No response

What operating system are you using?

No response

What version of Python are you running?

No response

What Python packages do you have installed?

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@taylorbell57 taylorbell57 added the enhancement New feature or request label Dec 18, 2023
@taylorbell57 taylorbell57 self-assigned this Dec 18, 2023
@taylorbell57 taylorbell57 added this to To do in Road to v1.0 via automation Dec 18, 2023
@taylorbell57 taylorbell57 moved this from To do to In progress in Road to v1.0 Mar 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Road to v1.0
In progress
Development

Successfully merging a pull request may close this issue.

1 participant