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
Implemented losses per event per asset #1564
Conversation
@@ -464,6 +464,16 @@ def job_from_file(cfg_file_path, username, log_level='info', exports=(), | |||
hazard_output_id) | |||
|
|||
params = vars(oqparam).copy() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a suggestion to remove some redundancy:
par_list = ['quantile_loss_curves', 'poes_disagg', 'poes_disagg', 'sites_disagg', 'sites_disagg', 'specific_assets', 'conditional_loss_poes']
for par in par_list:
if par not in params:
params[par] = []
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I prefer the keep the ugliness as it is, because the plan is to move the checks here from the engine into commonlib. Having a ugly series of ifs
increases the likeness of cleaning this sooner ;-)
Apart from the Django model and the minor suggestion, LGTM |
Implemented losses per event per asset
See https://bugs.launchpad.net/oq-engine/+bug/1383291 and the companion PR https://github.com/gem/oq-commonlib/pull/45. The tests are running here: https://ci.openquake.org/job/zdevel_oq-engine/766