webviz-subsurface 0.2.34__py3-none-any.whl → 0.2.35__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. webviz_subsurface/_providers/ensemble_grid_provider/_xtgeo_to_vtk_explicit_structured_grid.py +1 -1
  2. webviz_subsurface/_providers/ensemble_grid_provider/grid_viz_service.py +3 -3
  3. webviz_subsurface/_providers/ensemble_summary_provider/_provider_impl_arrow_lazy.py +2 -2
  4. webviz_subsurface/_providers/ensemble_summary_provider/_provider_impl_arrow_presampled.py +1 -1
  5. webviz_subsurface/_providers/ensemble_summary_provider/_resampling.py +30 -22
  6. webviz_subsurface/_providers/ensemble_surface_provider/_provider_impl_file.py +1 -17
  7. webviz_subsurface/_providers/ensemble_surface_provider/_surface_to_float32_array.py +1 -1
  8. webviz_subsurface/plugins/_bhp_qc/views/_view_functions.py +1 -1
  9. webviz_subsurface/plugins/_co2_leakage/_utilities/plume_extent.py +1 -1
  10. webviz_subsurface/plugins/_co2_leakage/views/mainview/mainview.py +2 -2
  11. webviz_subsurface/plugins/_grid_viewer_fmu/views/view_3d/view_elements/_vtk_view_3d_element.py +2 -2
  12. webviz_subsurface/plugins/_history_match.py +1 -1
  13. webviz_subsurface/plugins/_map_viewer_fmu/layout.py +2 -2
  14. webviz_subsurface/plugins/_rft_plotter/_plugin.py +5 -0
  15. webviz_subsurface/plugins/_rft_plotter/_utils/_rft_plotter_data_model.py +5 -2
  16. webviz_subsurface/plugins/_running_time_analysis_fmu.py +3 -3
  17. webviz_subsurface/plugins/_well_log_viewer/well_log_viewer.py +1 -1
  18. {webviz_subsurface-0.2.34.dist-info → webviz_subsurface-0.2.35.dist-info}/METADATA +3 -4
  19. {webviz_subsurface-0.2.34.dist-info → webviz_subsurface-0.2.35.dist-info}/RECORD +24 -51
  20. tests/integration_tests/plugin_tests/__init__.py +0 -0
  21. tests/integration_tests/plugin_tests/test_bhp_qc.py +0 -12
  22. tests/integration_tests/plugin_tests/test_history_match.py +0 -18
  23. tests/integration_tests/plugin_tests/test_line_plotter_fmu.py +0 -29
  24. tests/integration_tests/plugin_tests/test_parameter_analysis.py +0 -26
  25. tests/integration_tests/plugin_tests/test_parameter_correlation.py +0 -25
  26. tests/integration_tests/plugin_tests/test_parameter_distribution.py +0 -13
  27. tests/integration_tests/plugin_tests/test_parameter_parallel_coordinates.py +0 -13
  28. tests/integration_tests/plugin_tests/test_parameter_response_correlation.py +0 -15
  29. tests/integration_tests/plugin_tests/test_property_statistics.py +0 -22
  30. tests/integration_tests/plugin_tests/test_pvt_plot.py +0 -15
  31. tests/integration_tests/plugin_tests/test_relative_permeability.py +0 -14
  32. tests/integration_tests/plugin_tests/test_reservoir_simulation_timeseries.py +0 -30
  33. tests/integration_tests/plugin_tests/test_reservoir_simulation_timeseries_onebyone.py +0 -16
  34. tests/integration_tests/plugin_tests/test_reservoir_simulation_timeseries_regional.py +0 -23
  35. tests/integration_tests/plugin_tests/test_rft_plotter.py +0 -43
  36. tests/integration_tests/plugin_tests/test_segy_viewer.py +0 -22
  37. tests/integration_tests/plugin_tests/test_simulation_timeseries_onebyone.py +0 -23
  38. tests/integration_tests/plugin_tests/test_structural_uncertainty.py +0 -244
  39. tests/integration_tests/plugin_tests/test_surface_viewer_fmu.py +0 -21
  40. tests/integration_tests/plugin_tests/test_surface_with_grid_crossection.py +0 -45
  41. tests/integration_tests/plugin_tests/test_surface_with_seismic_crossection.py +0 -35
  42. tests/integration_tests/plugin_tests/test_tornado_plotter_fmu.py +0 -14
  43. tests/integration_tests/plugin_tests/test_vfp_analysis.py +0 -13
  44. tests/integration_tests/plugin_tests/test_volumetric_analysis.py +0 -38
  45. tests/integration_tests/plugin_tests/test_well_log_viewer.py +0 -16
  46. webviz_subsurface/_providers/ensemble_summary_provider/dev_resampling_perf_testing.py +0 -112
  47. {webviz_subsurface-0.2.34.dist-info → webviz_subsurface-0.2.35.dist-info}/LICENSE +0 -0
  48. {webviz_subsurface-0.2.34.dist-info → webviz_subsurface-0.2.35.dist-info}/LICENSE.chromedriver +0 -0
  49. {webviz_subsurface-0.2.34.dist-info → webviz_subsurface-0.2.35.dist-info}/WHEEL +0 -0
  50. {webviz_subsurface-0.2.34.dist-info → webviz_subsurface-0.2.35.dist-info}/entry_points.txt +0 -0
  51. {webviz_subsurface-0.2.34.dist-info → webviz_subsurface-0.2.35.dist-info}/top_level.txt +0 -0
@@ -1,35 +0,0 @@
1
- # pylint: disable=no-name-in-module
2
- from webviz_config.plugins import SurfaceWithSeismicCrossSection
3
-
4
-
5
- def test_surface_with_seismic_crosssection(
6
- dash_duo, app, shared_settings, testdata_folder
7
- ) -> None:
8
- plugin = SurfaceWithSeismicCrossSection(
9
- app,
10
- shared_settings["HM_SETTINGS"],
11
- segyfiles=[
12
- testdata_folder
13
- / "01_drogon_ahm"
14
- / "realization-0"
15
- / "iter-0"
16
- / "share"
17
- / "results"
18
- / "seismic"
19
- / "seismic--amplitude_depth--20180701_20180101.segy"
20
- ],
21
- surfacefiles=[
22
- testdata_folder
23
- / "01_drogon_ahm"
24
- / "realization-0"
25
- / "iter-0"
26
- / "share"
27
- / "results"
28
- / "maps"
29
- / "topvolon--ds_extract_geogrid.gri"
30
- ],
31
- surfacenames=["Top Volon"],
32
- )
33
- app.layout = plugin.layout
34
- dash_duo.start_server(app)
35
- assert not dash_duo.get_logs()
@@ -1,14 +0,0 @@
1
- # pylint: disable=no-name-in-module
2
- from webviz_config.plugins import TornadoPlotterFMU
3
-
4
-
5
- def test_tornado_plotter_fmu(dash_duo, app, shared_settings) -> None:
6
- plugin = TornadoPlotterFMU(
7
- shared_settings["SENS_SETTINGS"],
8
- ensemble=shared_settings["SENS_ENSEMBLES"][0],
9
- csvfile="share/results/volumes/geogrid--vol.csv",
10
- multi_value_selectors=["REGION", "ZONE"],
11
- )
12
- app.layout = plugin.layout
13
- dash_duo.start_server(app)
14
- assert not dash_duo.get_logs()
@@ -1,13 +0,0 @@
1
- # pylint: disable=no-name-in-module
2
- from webviz_config.plugins import VfpAnalysis
3
- from webviz_config.testing import WebvizComposite
4
-
5
-
6
- def test_vfp_analysis(_webviz_duo: WebvizComposite, shared_settings: dict) -> None:
7
- plugin = VfpAnalysis(
8
- shared_settings["HM_SETTINGS"], vfp_file_pattern="tests/data/vfp.arrow"
9
- )
10
-
11
- _webviz_duo.start_server(plugin)
12
-
13
- assert not _webviz_duo.get_logs()
@@ -1,38 +0,0 @@
1
- import warnings
2
-
3
- # pylint: disable=no-name-in-module
4
- from webviz_config.plugins import VolumetricAnalysis
5
-
6
-
7
- def test_volumetrics_no_sens(dash_duo, app, shared_settings) -> None:
8
- plugin = VolumetricAnalysis(
9
- shared_settings["HM_SETTINGS"],
10
- ensembles=shared_settings["HM_ENSEMBLES"],
11
- volfiles={"geogrid": "geogrid--vol.csv", "simgrid": "simgrid--vol.csv"},
12
- )
13
- app.layout = plugin.layout
14
- dash_duo.start_server(app)
15
- logs = []
16
- for log in dash_duo.get_logs() or []:
17
- if "dash_renderer" in log.get("message"):
18
- warnings.warn(log.get("message"))
19
- else:
20
- logs.append(log)
21
- assert not logs
22
-
23
-
24
- def test_volumetrics_sens(dash_duo, app, shared_settings) -> None:
25
- plugin = VolumetricAnalysis(
26
- shared_settings["SENS_SETTINGS"],
27
- ensembles=shared_settings["SENS_ENSEMBLES"],
28
- volfiles={"geogrid": "geogrid--vol.csv", "simgrid": "simgrid--vol.csv"},
29
- )
30
- app.layout = plugin.layout
31
- dash_duo.start_server(app)
32
- logs = []
33
- for log in dash_duo.get_logs() or []:
34
- if "dash_renderer" in log.get("message"):
35
- warnings.warn(log.get("message"))
36
- else:
37
- logs.append(log)
38
- assert not logs
@@ -1,16 +0,0 @@
1
- # pylint: disable=no-name-in-module
2
- from webviz_config.plugins import WellLogViewer
3
-
4
-
5
- def test_well_log_viewer(dash_duo, app, testdata_folder) -> None:
6
- wellfolder = testdata_folder / "observed_data" / "wells/"
7
- plugin = WellLogViewer(
8
- app,
9
- wellfolder=wellfolder,
10
- wellsuffix=".rmswell",
11
- mdlog="MDepth",
12
- logtemplates=[f"{testdata_folder}/webviz_examples/all_logs_template.yml"],
13
- )
14
- app.layout = plugin.layout
15
- dash_duo.start_server(app)
16
- assert not dash_duo.get_logs()
@@ -1,112 +0,0 @@
1
- import logging
2
- import time
3
-
4
- import numpy as np
5
- import pyarrow as pa
6
-
7
- from webviz_subsurface._providers.ensemble_summary_provider._resampling import (
8
- sample_segmented_multi_real_table_at_date,
9
- )
10
-
11
-
12
- def _create_table(
13
- num_reals: int, start_date: np.datetime64, end_date: np.datetime64, num_columns: int
14
- ) -> pa.Table:
15
- date_arr_np = np.empty(0, np.datetime64)
16
- real_arr_np = np.empty(0, np.int32)
17
-
18
- for real in range(0, num_reals):
19
- dates_for_this_real = np.arange(start_date, end_date + 1)
20
- dates_for_this_real = dates_for_this_real.astype("datetime64[ms]")
21
- real_arr_np = np.concatenate(
22
- (real_arr_np, np.full(len(dates_for_this_real), real))
23
- )
24
- date_arr_np = np.concatenate((date_arr_np, dates_for_this_real))
25
-
26
- print(
27
- f"real_arr_np (num unique={len(np.unique(real_arr_np))} len={len(real_arr_np)}):"
28
- )
29
- print(real_arr_np)
30
- print(
31
- f"date_arr_np (num unique={len(np.unique(date_arr_np))} len={len(date_arr_np)}):"
32
- )
33
- print(date_arr_np)
34
-
35
- field_list = []
36
- columndata_list = []
37
- field_list.append(pa.field("DATE", pa.timestamp("ms")))
38
- field_list.append(pa.field("REAL", pa.int64()))
39
- columndata_list.append(pa.array(date_arr_np))
40
- columndata_list.append(pa.array(real_arr_np))
41
-
42
- num_rows = len(real_arr_np)
43
-
44
- for colnum in range(0, num_columns):
45
- if (colnum % 2) == 0:
46
- metadata = {b"is_rate": b'{"is_rate": False}'}
47
- else:
48
- metadata = {b"is_rate": b'{"is_rate": True}'}
49
-
50
- field_list.append(pa.field(f"c_{colnum}", pa.float32(), metadata=metadata))
51
-
52
- valarr = np.linspace(colnum, colnum + num_rows, num_rows)
53
- columndata_list.append(pa.array(valarr))
54
-
55
- schema = pa.schema(field_list)
56
- return pa.table(columndata_list, schema=schema)
57
-
58
-
59
- def main() -> None:
60
- print()
61
- print("## Running resampling performance tests")
62
- print("## =================================================")
63
-
64
- logging.basicConfig(
65
- level=logging.WARNING,
66
- format="%(asctime)s %(levelname)-3s [%(name)s]: %(message)s",
67
- )
68
- logging.getLogger("webviz_subsurface").setLevel(level=logging.INFO)
69
- logging.getLogger("webviz_subsurface").setLevel(level=logging.DEBUG)
70
-
71
- # table = _create_table(
72
- # num_reals=3,
73
- # start_date=np.datetime64("2020-12-30"),
74
- # end_date=np.datetime64("2021-01-05"),
75
- # num_columns=4,
76
- # )
77
-
78
- table = _create_table(
79
- num_reals=100,
80
- start_date=np.datetime64("2000-01-01", "M"),
81
- end_date=np.datetime64("2099-12-31", "M"),
82
- num_columns=10000,
83
- )
84
-
85
- print("## table shape (rows,columns):", table.shape)
86
- # print(table.to_pandas())
87
-
88
- start_tim = time.perf_counter()
89
-
90
- res = sample_segmented_multi_real_table_at_date(
91
- table, np.datetime64("2098-01-03", "ms")
92
- )
93
-
94
- # res = sample_segmented_multi_real_table_at_date(
95
- # table, np.datetime64("2098-01-01", "ms")
96
- # )
97
-
98
- elapsed_time_ms = int(1000 * (time.perf_counter() - start_tim))
99
-
100
- # print(res)
101
- # print(res.to_pandas())
102
-
103
- print("## res shape:", res.shape)
104
-
105
- print(f"## sample at date took: {elapsed_time_ms}ms")
106
-
107
-
108
- # Running:
109
- # python -m webviz_subsurface._providers.ensemble_summary_provider.dev_resampling_perf_testing
110
- # -------------------------------------------------------------------------
111
- if __name__ == "__main__":
112
- main()