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

Pass options to save_photon_hdf5() #1

Open
tritemio opened this issue Nov 11, 2015 · 0 comments
Open

Pass options to save_photon_hdf5() #1

tritemio opened this issue Nov 11, 2015 · 0 comments

Comments

@tritemio
Copy link
Contributor

Currently is not possible to pass options to phconvert save_photon_hdf5().

We could add a 4th optional positional argument to the phforge script to pass a options.yaml which can contain any keyword arguments.

The advantages of using a YAML file for the these options instead of command line flags are:

  1. Automatically accept all keyword arguments (i.e. if a new argument is added to save_photon_hdf5() phforge does not need to be modified to use it.
  2. Easier to write for humans & computers
  3. Possible to pass arguments containing a dictionary using same YAML syntax (instead of writing/generating python-syntax dictionary)
  4. Easier to implement: the YAML file is loaded directly into a dictionary which is passed to save_photon_hdf5 with ** unpacking.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant