From 535f6198829bbaee79a872f9235cb1b343f1f3da Mon Sep 17 00:00:00 2001 From: Michele Simionato Date: Fri, 15 Sep 2023 11:22:53 +0200 Subject: [PATCH] Renamed max_gmvs_per_task --- openquake/calculators/event_based_risk.py | 2 +- openquake/commonlib/oqvalidation.py | 8 ++++---- openquake/qa_tests_data/event_based_risk/case_5/job.ini | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/openquake/calculators/event_based_risk.py b/openquake/calculators/event_based_risk.py index 6de7646b6e12..24cc9acae37e 100644 --- a/openquake/calculators/event_based_risk.py +++ b/openquake/calculators/event_based_risk.py @@ -180,7 +180,7 @@ def ebr_from_gmfs(sbe, oqparam, dstore, monitor): df = pandas.DataFrame(dic) del dic slices = performance.split_slices( - df.eid.to_numpy(), oqparam.max_gmvs_per_task) + df.eid.to_numpy(), oqparam.max_gmvs_per_chunk) for s0, s1 in slices: yield event_based_risk(df[s0:s1], oqparam, monitor) diff --git a/openquake/commonlib/oqvalidation.py b/openquake/commonlib/oqvalidation.py index 6b3ee0b7ba3b..5608e2c1397e 100644 --- a/openquake/commonlib/oqvalidation.py +++ b/openquake/commonlib/oqvalidation.py @@ -450,10 +450,10 @@ max_data_transfer: INTERNAL. Restrict the maximum data transfer in disaggregation calculations. -max_gmvs_per_task: +max_gmvs_per_chunk: Maximum number of rows of the gmf_data table per task. - Example: *max_gmvs_per_task = 200_000* - Default: 100_0000 + Example: *max_gmvs_per_chunk = 200_000* + Default: 50_0000 max_potential_gmfs: Restrict the product *num_sites * num_events*. @@ -979,7 +979,7 @@ class OqParam(valid.ParamSet): max = valid.Param(valid.boolean, False) max_aggregations = valid.Param(valid.positivefloat, 100_000) max_data_transfer = valid.Param(valid.positivefloat, 2E11) - max_gmvs_per_task = valid.Param(valid.positiveint, 100_000) + max_gmvs_per_chunk = valid.Param(valid.positiveint, 50_000) # for 2GB limit max_potential_gmfs = valid.Param(valid.positiveint, 1E12) max_potential_paths = valid.Param(valid.positiveint, 15_000) max_sites_disagg = valid.Param(valid.positiveint, 10) diff --git a/openquake/qa_tests_data/event_based_risk/case_5/job.ini b/openquake/qa_tests_data/event_based_risk/case_5/job.ini index ac9547c73bc1..86964e181bca 100644 --- a/openquake/qa_tests_data/event_based_risk/case_5/job.ini +++ b/openquake/qa_tests_data/event_based_risk/case_5/job.ini @@ -40,7 +40,7 @@ exposure_file = exposure_model.xml [risk_calculation] asset_hazard_distance = 20 minimum_asset_loss = {'structural': 1000, 'contents': 1000} -max_gmvs_per_task = 500 +max_gmvs_per_chunk = 500 [outputs] quantiles = 0.15 0.85