diff --git a/src/ert/gui/tools/manage_experiments/manage_experiments_panel.py b/src/ert/gui/tools/manage_experiments/manage_experiments_panel.py index 17fb8acf994..b9bfd4a6080 100644 --- a/src/ert/gui/tools/manage_experiments/manage_experiments_panel.py +++ b/src/ert/gui/tools/manage_experiments/manage_experiments_panel.py @@ -116,6 +116,7 @@ def initialize_from_scratch(_: Any) -> None: ensemble=ensemble_selector.currentData(), active_realizations=[int(i) for i in members_model.getSelectedItems()], parameters=parameters, + random_seed=self.ert_config.random_seed, ) def update_button_state() -> None: diff --git a/tests/unit_tests/gui/tools/test_manage_experiments_tool.py b/tests/unit_tests/gui/tools/test_manage_experiments_tool.py index eedcc40b16d..f18b1d78b92 100644 --- a/tests/unit_tests/gui/tools/test_manage_experiments_tool.py +++ b/tests/unit_tests/gui/tools/test_manage_experiments_tool.py @@ -19,6 +19,7 @@ @pytest.mark.usefixtures("copy_poly_case") def test_init_prior(qtbot, storage): config = ErtConfig.from_file("poly.ert") + config.random_seed = 1234 notifier = ErtNotifier(config.config_path) notifier.set_storage(storage) ensemble = storage.create_experiment( @@ -46,6 +47,9 @@ def test_init_prior(qtbot, storage): ensemble.get_ensemble_state() == [RealizationStorageState.INITIALIZED] * config.model_config.num_realizations ) + assert ensemble.load_parameters("COEFFS")[ + "transformed_values" + ].mean() == pytest.approx(1.41487404) @pytest.mark.usefixtures("copy_poly_case")