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

Implemented losses per event per asset #1564

Merged
merged 14 commits into from Oct 22, 2014
Merged

Implemented losses per event per asset #1564

merged 14 commits into from Oct 22, 2014

Conversation

micheles
Copy link
Contributor

@@ -464,6 +464,16 @@ def job_from_file(cfg_file_path, username, log_level='info', exports=(),
hazard_output_id)

params = vars(oqparam).copy()
Copy link
Member

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] = []

Copy link
Contributor Author

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 ;-)

@ptormene
Copy link
Member

Apart from the Django model and the minor suggestion, LGTM

micheles added a commit that referenced this pull request Oct 22, 2014
Implemented losses per event per asset
@micheles micheles merged commit d2643a6 into master Oct 22, 2014
@micheles micheles deleted the special-assets branch October 22, 2014 08:03
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

Successfully merging this pull request may close these issues.

None yet

2 participants