Use bin edges internally for frequency-dependent specific energy - #268
Conversation
|
@dnarayanan - just FYI. Is the slight API change an issue for you? (you'd need to use |
it would be fine for me! |
|
Just to double check, do you rely on the behavior of the end bins being catch-all in the sense they extend to +/- infinity? Or would it also work for you to specify only edges and have those always be finite? (Just to know if we can simplify some code) |
|
finite would actually work just fine! |
…ing temporary model files to tmpdir and making parametrized test collection deterministic
…ectrum deposit guards never read an undefined value when the spectrum is not being computed
d65d40e to
ae50b0a
Compare
|
@dnarayanan - ok thanks! So just to confirm, after the cleanup here which does simplify a bunch of things, the API is e.g.: m.conf.output.output_specific_energy_spectrum = 'last' # (or 'all')
m.set_specific_energy_spectrum_bins(np.logspace(11., 16., 101))where the second method is given the bin edges (so n+1 values for n bins). Can you confirm this is ok for you? (before I merge this and make a new release of Hyperion soon) |
|
yep confirmed - this will be fine for me thank you! |
This implements the suggestion in #267 to use bin edges instead of centers as the canonical way to represent the bins to use for the frequency-dependent specific energy.