Skip to content
This repository was archived by the owner on Jul 19, 2021. It is now read-only.

Commit

Permalink
Removes test for summary in gen data in order for report step to work…
Browse files Browse the repository at this point in the history
… for other than 0
  • Loading branch information
ManInFez committed Jan 30, 2019
1 parent adb1b28 commit 62869d7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 23 deletions.
24 changes: 1 addition & 23 deletions lib/enkf/ensemble_config.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -814,30 +814,8 @@ bool ensemble_config_has_impl_type(const ensemble_config_type * config, const e
return ret;
}


bool ensemble_config_GEN_DATA_require_summary(const ensemble_config_type * config) {
bool ret = false;
hash_iter_type * iter = hash_iter_alloc(config->config_nodes);
while (!hash_iter_is_complete( iter )) {
const char * key = hash_iter_get_next_key(iter);
const enkf_config_node_type * config_node = (const enkf_config_node_type *)hash_get(config->config_nodes , key);
if ((enkf_config_node_get_impl_type(config_node) == GEN_DATA) && (enkf_config_node_get_var_type( config_node ) != PARAMETER)) {
const gen_data_config_type * gen_data_config_node = (const gen_data_config_type *)enkf_config_node_get_ref( config_node );
int report_step = gen_data_config_get_max_report_step( gen_data_config_node );
if (report_step > 0) {
ret = true;
break;
}
}
}
hash_iter_free(iter);
return ret;
}


bool ensemble_config_require_summary(const ensemble_config_type * ens_config) {
return (ensemble_config_has_impl_type(ens_config, SUMMARY) ||
ensemble_config_GEN_DATA_require_summary(ens_config));
return ensemble_config_has_impl_type(ens_config, SUMMARY);
}


Expand Down
2 changes: 2 additions & 0 deletions test-data/local/snake_oil_no_data/snake_oil_GEN_DATA.ert
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,5 @@ GEN_DATA SNAKE_OIL_GPR_DIFF INPUT_FORMAT:ASCII RESULT_FILE:snake_oil_gpr_diff_%d
LOG_LEVEL INFO
LOG_FILE log/log.txt
UPDATE_LOG_PATH log/update

SUMMARY FOPT -- SUMMARY keyword needed to force time map load from summary file

0 comments on commit 62869d7

Please sign in to comment.