.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "gallery/example_wind_measurements.py" .. LINE NUMBERS ARE GIVEN BELOW. .. only:: html .. note:: :class: sphx-glr-download-link-note :ref:`Go to the end ` to download the full example code. .. rst-class:: sphx-glr-example-title .. _sphx_glr_gallery_example_wind_measurements.py: Using wind measurements ======================= .. GENERATED FROM PYTHON SOURCE LINES 6-32 .. code-block:: Python from datetime import datetime, timedelta, date from opendrift.readers import reader_netCDF_CF_generic from opendrift.models.openoil import OceanDrift from opendrift.readers import reader_timeseries from opendrift.readers.operators import ops import opendrift.models.physics_methods as phy import xarray as xr import trajan as _ import numpy as np import pyproj import matplotlib.pyplot as plt import matplotlib as mpl # Preparation of figsize, dpi, fontsize and font style # Could also be done using mpl style sheet # https://matplotlib.org/stable/users/explain/customizing.html mpl.rcParams['figure.figsize'] = (5, 5) mpl.rcParams['savefig.dpi'] = 300 mpl.rcParams['font.family'] = "sans-serif" mpl.rcParams['font.sans-serif'] = "DejaVu Sans" mpl.rcParams['font.size'] = 22 mpl.rcParams['mathtext.fontset'] = "dejavusans" .. GENERATED FROM PYTHON SOURCE LINES 33-36 This example shows how to use wind or currents measurments combined with an ocean model to improove the drift calculation arround the measurment station. .. GENERATED FROM PYTHON SOURCE LINES 39-42 Fisrt, we import two times the same model, because one will be used for the usual simulation, and one will be used for the measurement combined simulation. .. GENERATED FROM PYTHON SOURCE LINES 42-50 .. code-block:: Python reader_norkyst = reader_netCDF_CF_generic.Reader('https://thredds.met.no/thredds/dodsC/sea/norkyst800m/1h/aggregate_be') reader_norkyst2 = reader_netCDF_CF_generic.Reader('https://thredds.met.no/thredds/dodsC/sea/norkyst800m/1h/aggregate_be') #Verification print(reader_norkyst) .. rst-class:: sphx-glr-script-out .. code-block:: none =========================== Reader: https://thredds.met.no/thredds/dodsC/sea/norkyst800m/1h/aggregate_be Projection: +proj=stere +lat_0=90 +lat_ts=60 +lon_0=70 +x_0=3192800 +y_0=1784000 +a=6378137 +b=6356752.3142 +units=m +no_defs +type=crs Coverage: [degrees] xmin: 0.000000 xmax: 2080800.000000 step: 800 numx: 2602 ymin: 0.000000 ymax: 720800.000000 step: 800 numy: 902 Corners (lon, lat): ( -1.58, 58.50) ( 23.71, 75.32) ( 9.19, 55.91) ( 38.06, 70.03) Vertical levels [m]: [ -0. -3. -10. -15. -25. -50. -75. -100. -150. -200. -250. -300. -500. -1000. -2000. -3000.] Available time range: start: 2017-02-20 00:00:00 end: 2025-03-18 00:00:00 step: 1:00:00 70753 times (3444 missing) Variables: sea_floor_depth_below_sea_level latitude longitude x_wind y_wind sea_water_salinity sea_water_temperature x_sea_water_velocity eastward_sea_water_velocity y_sea_water_velocity northward_sea_water_velocity upward_sea_water_velocity sea_surface_height wind_speed - derived from ['x_wind', 'y_wind'] sea_water_speed - derived from ['x_sea_water_velocity', 'y_sea_water_velocity'] =========================== .. GENERATED FROM PYTHON SOURCE LINES 51-55 We then import wind measurement data, that will be stored in a timeserie reader. Don't forget to give the lon and lat of the measurement station. .. GENERATED FROM PYTHON SOURCE LINES 55-89 .. code-block:: Python time_list = [datetime(2024, 5, 27, 6, 00, 00) + i*timedelta(minutes=10) for i in range(7)] # Manual import for this example wind_speed_array = np.array([1.9, 3.0, 3.5, 3.4, 3.9, 2.8, 2.5]) wind_speed_angle = np.array([22, 25, 24, 19, 17, 30, 16]) # Alternative if data are in a csv file # data_wind_bridge = np.genfromtxt("Simulation_data/data_wind_21_mai_2024.txt", dtype = ',
) .. GENERATED FROM PYTHON SOURCE LINES 130-132 Measurement modified model simulation and comparison .. GENERATED FROM PYTHON SOURCE LINES 132-144 .. code-block:: Python o2 = OceanDrift(loglevel=20) o2.set_config('drift:max_speed', 10) #Necessary for the moment because of a bug to be solved o2.add_reader([c, reader_norkyst]) #o2.set_config('drift:current_uncertainty', .1) #o2.set_config('drift:wind_uncertainty', 1) o2.seed_elements(lon=lon, lat=lat, radius=radius, number=number, time=time_start, wind_drift_factor=wind_drift_factor) o2.run(end_time=time_end, time_step=time_step, time_step_output=time_step_output) o.plot(fast = False, compare=o2, background=['x_sea_water_velocity', 'y_sea_water_velocity'], legend=['Norkyst only', 'Gaussian measurement'], buffer = .023, markersize = 150, linewidth = 3, title = "", xlocs = mpl.ticker.MaxNLocator(5), ylocs = mpl.ticker.MaxNLocator(5), clabel = r"Wind speed $\mathrm{(m.s^{-1})}$", cpad = 0.08, text=text) .. image-sg:: /gallery/images/sphx_glr_example_wind_measurements_002.png :alt: example wind measurements :srcset: /gallery/images/sphx_glr_example_wind_measurements_002.png :class: sphx-glr-single-img .. rst-class:: sphx-glr-script-out .. code-block:: none 14:21:01 INFO opendrift:509: OpenDriftSimulation initialised (version 1.13.0 / v1.13.0-75-gd4c13d2) 14:21:01 INFO opendrift.models.basemodel.environment:206: Adding a dynamical landmask with max. priority based on assumed maximum speed of 10.0 m/s. Adding a customised landmask may be faster... 14:21:01 INFO opendrift.models.basemodel.environment:233: Fallback values will be used for the following variables which have no readers: 14:21:01 INFO opendrift.models.basemodel.environment:236: ocean_vertical_diffusivity: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_significant_height: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_stokes_drift_x_velocity: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_stokes_drift_y_velocity: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_period_at_variance_spectral_density_maximum: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_mean_period_from_variance_spectral_density_second_frequency_moment: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: sea_surface_swell_wave_to_direction: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: sea_surface_swell_wave_peak_period_from_variance_spectral_density: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: sea_surface_swell_wave_significant_height: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: sea_surface_wind_wave_to_direction: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: sea_surface_wind_wave_mean_period: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: sea_surface_wind_wave_significant_height: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: surface_downward_x_stress: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: surface_downward_y_stress: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: turbulent_kinetic_energy: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: turbulent_generic_length_scale: 0.000000 14:21:01 INFO opendrift.models.basemodel.environment:236: ocean_mixed_layer_thickness: 50.000000 14:21:01 INFO opendrift:919: Using existing reader for land_binary_mask 14:21:01 INFO opendrift:930: All points are in ocean 14:21:01 WARNING opendrift:713: Seafloor check not being run because environment is missing. This will happen the first time the function is run but if it happens subsequently there is probably a problem. 14:21:01 INFO opendrift:2056: 2024-05-27 06:00:00 - step 1 of 48 - 1 active elements (0 deactivated) 14:21:02 INFO opendrift:2056: 2024-05-27 06:02:30 - step 2 of 48 - 1 active elements (0 deactivated) 14:21:03 INFO opendrift:2056: 2024-05-27 06:05:00 - step 3 of 48 - 1 active elements (0 deactivated) 14:21:03 INFO opendrift:2056: 2024-05-27 06:07:30 - step 4 of 48 - 1 active elements (0 deactivated) 14:21:03 INFO opendrift:2056: 2024-05-27 06:10:00 - step 5 of 48 - 1 active elements (0 deactivated) 14:21:03 INFO opendrift:2056: 2024-05-27 06:12:30 - step 6 of 48 - 1 active elements (0 deactivated) 14:21:03 INFO opendrift:2056: 2024-05-27 06:15:00 - step 7 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:17:30 - step 8 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:20:00 - step 9 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:22:30 - step 10 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:25:00 - step 11 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:27:30 - step 12 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:30:00 - step 13 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:32:30 - step 14 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:35:00 - step 15 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:37:30 - step 16 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:40:00 - step 17 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:42:30 - step 18 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:45:00 - step 19 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:47:30 - step 20 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:50:00 - step 21 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:52:30 - step 22 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:55:00 - step 23 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 06:57:30 - step 24 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 07:00:00 - step 25 of 48 - 1 active elements (0 deactivated) 14:21:04 INFO opendrift:2056: 2024-05-27 07:02:30 - step 26 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:05:00 - step 27 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:07:30 - step 28 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:10:00 - step 29 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:12:30 - step 30 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:15:00 - step 31 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:17:30 - step 32 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:20:00 - step 33 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:22:30 - step 34 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:25:00 - step 35 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:27:30 - step 36 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:30:00 - step 37 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:32:30 - step 38 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:35:00 - step 39 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:37:30 - step 40 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:40:00 - step 41 of 48 - 1 active elements (0 deactivated) 14:21:07 INFO opendrift:2056: 2024-05-27 07:42:30 - step 42 of 48 - 1 active elements (0 deactivated) 14:21:08 INFO opendrift:2056: 2024-05-27 07:45:00 - step 43 of 48 - 1 active elements (0 deactivated) 14:21:08 INFO opendrift:2056: 2024-05-27 07:47:30 - step 44 of 48 - 1 active elements (0 deactivated) 14:21:08 INFO opendrift:2056: 2024-05-27 07:50:00 - step 45 of 48 - 1 active elements (0 deactivated) 14:21:08 INFO opendrift:2056: 2024-05-27 07:52:30 - step 46 of 48 - 1 active elements (0 deactivated) 14:21:08 INFO opendrift:2056: 2024-05-27 07:55:00 - step 47 of 48 - 1 active elements (0 deactivated) 14:21:08 INFO opendrift:2056: 2024-05-27 07:57:30 - step 48 of 48 - 1 active elements (0 deactivated) (,
) .. GENERATED FROM PYTHON SOURCE LINES 145-148 Here, we generate more particles and look at the skillscore impact of the measurment combined simulation .. GENERATED FROM PYTHON SOURCE LINES 148-165 .. code-block:: Python radius = 100 number = 100 o = OceanDrift(loglevel=20) o.add_reader([reader_norkyst]) o.seed_elements(lon=lon, lat=lat, radius=radius, number=number, time=time_start, wind_drift_factor=wind_drift_factor) o.run(end_time=time_end, time_step=time_step, time_step_output=time_step_output) o2 = OceanDrift(loglevel=20) o2.set_config('drift:max_speed', 10) #Necessary for the moment because of a bug to be solved o2.add_reader([c, reader_norkyst]) o2.seed_elements(lon=lon, lat=lat, radius=radius, number=number, time=time_start, wind_drift_factor=wind_drift_factor) o2.run(end_time=time_end, time_step=time_step, time_step_output=time_step_output) o.plot(fast = False, compare=o2, background=['x_sea_water_velocity', 'y_sea_water_velocity'], legend=['Norkyst only', 'Gaussian measurement'], buffer = .023, markersize = 70, linewidth = 1, title = "", xlocs = mpl.ticker.MaxNLocator(5), ylocs = mpl.ticker.MaxNLocator(5), clabel = r"Wind speed $\mathrm{(m.s^{-1})}$", cpad = 0.08, text=text) .. image-sg:: /gallery/images/sphx_glr_example_wind_measurements_003.png :alt: example wind measurements :srcset: /gallery/images/sphx_glr_example_wind_measurements_003.png :class: sphx-glr-single-img .. rst-class:: sphx-glr-script-out .. code-block:: none 14:21:21 INFO opendrift:509: OpenDriftSimulation initialised (version 1.13.0 / v1.13.0-75-gd4c13d2) 14:21:21 INFO opendrift.models.basemodel.environment:206: Adding a dynamical landmask with max. priority based on assumed maximum speed of 2.0 m/s. Adding a customised landmask may be faster... 14:21:21 INFO opendrift.models.basemodel.environment:233: Fallback values will be used for the following variables which have no readers: 14:21:21 INFO opendrift.models.basemodel.environment:236: ocean_vertical_diffusivity: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_significant_height: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_stokes_drift_x_velocity: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_stokes_drift_y_velocity: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_period_at_variance_spectral_density_maximum: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_mean_period_from_variance_spectral_density_second_frequency_moment: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: sea_surface_swell_wave_to_direction: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: sea_surface_swell_wave_peak_period_from_variance_spectral_density: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: sea_surface_swell_wave_significant_height: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: sea_surface_wind_wave_to_direction: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: sea_surface_wind_wave_mean_period: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: sea_surface_wind_wave_significant_height: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: surface_downward_x_stress: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: surface_downward_y_stress: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: turbulent_kinetic_energy: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: turbulent_generic_length_scale: 0.000000 14:21:21 INFO opendrift.models.basemodel.environment:236: ocean_mixed_layer_thickness: 50.000000 14:21:21 INFO opendrift:919: Using existing reader for land_binary_mask 14:21:23 INFO opendrift:930: All points are in ocean 14:21:23 WARNING opendrift:713: Seafloor check not being run because environment is missing. This will happen the first time the function is run but if it happens subsequently there is probably a problem. 14:21:23 INFO opendrift:2056: 2024-05-27 06:00:00 - step 1 of 48 - 100 active elements (0 deactivated) 14:21:24 INFO opendrift:2056: 2024-05-27 06:02:30 - step 2 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:05:00 - step 3 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:07:30 - step 4 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:10:00 - step 5 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:12:30 - step 6 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:15:00 - step 7 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:17:30 - step 8 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:20:00 - step 9 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:22:30 - step 10 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:25:00 - step 11 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:27:30 - step 12 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:30:00 - step 13 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:32:30 - step 14 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:35:00 - step 15 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:37:30 - step 16 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:40:00 - step 17 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:42:30 - step 18 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:45:00 - step 19 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:47:30 - step 20 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:50:00 - step 21 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:52:30 - step 22 of 48 - 100 active elements (0 deactivated) 14:21:25 INFO opendrift:2056: 2024-05-27 06:55:00 - step 23 of 48 - 100 active elements (0 deactivated) 14:21:26 INFO opendrift:2056: 2024-05-27 06:57:30 - step 24 of 48 - 100 active elements (0 deactivated) 14:21:26 INFO opendrift:2056: 2024-05-27 07:00:00 - step 25 of 48 - 100 active elements (0 deactivated) 14:21:26 INFO opendrift:2056: 2024-05-27 07:02:30 - step 26 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:05:00 - step 27 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:07:30 - step 28 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:10:00 - step 29 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:12:30 - step 30 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:15:00 - step 31 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:17:30 - step 32 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:20:00 - step 33 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:22:30 - step 34 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:25:00 - step 35 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:27:30 - step 36 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:30:00 - step 37 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:32:30 - step 38 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:35:00 - step 39 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:37:30 - step 40 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:40:00 - step 41 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:42:30 - step 42 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:45:00 - step 43 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:47:30 - step 44 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:50:00 - step 45 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:52:30 - step 46 of 48 - 100 active elements (0 deactivated) 14:21:27 INFO opendrift:2056: 2024-05-27 07:55:00 - step 47 of 48 - 100 active elements (0 deactivated) 14:21:28 INFO opendrift:2056: 2024-05-27 07:57:30 - step 48 of 48 - 100 active elements (0 deactivated) 14:21:28 INFO opendrift:509: OpenDriftSimulation initialised (version 1.13.0 / v1.13.0-75-gd4c13d2) 14:21:28 INFO opendrift.models.basemodel.environment:206: Adding a dynamical landmask with max. priority based on assumed maximum speed of 10.0 m/s. Adding a customised landmask may be faster... 14:21:28 INFO opendrift.models.basemodel.environment:233: Fallback values will be used for the following variables which have no readers: 14:21:28 INFO opendrift.models.basemodel.environment:236: ocean_vertical_diffusivity: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_significant_height: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_stokes_drift_x_velocity: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_stokes_drift_y_velocity: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_period_at_variance_spectral_density_maximum: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: sea_surface_wave_mean_period_from_variance_spectral_density_second_frequency_moment: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: sea_surface_swell_wave_to_direction: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: sea_surface_swell_wave_peak_period_from_variance_spectral_density: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: sea_surface_swell_wave_significant_height: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: sea_surface_wind_wave_to_direction: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: sea_surface_wind_wave_mean_period: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: sea_surface_wind_wave_significant_height: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: surface_downward_x_stress: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: surface_downward_y_stress: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: turbulent_kinetic_energy: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: turbulent_generic_length_scale: 0.000000 14:21:28 INFO opendrift.models.basemodel.environment:236: ocean_mixed_layer_thickness: 50.000000 14:21:28 INFO opendrift:919: Using existing reader for land_binary_mask 14:21:28 INFO opendrift:930: All points are in ocean 14:21:28 WARNING opendrift:713: Seafloor check not being run because environment is missing. This will happen the first time the function is run but if it happens subsequently there is probably a problem. 14:21:28 INFO opendrift:2056: 2024-05-27 06:00:00 - step 1 of 48 - 100 active elements (0 deactivated) 14:21:29 INFO opendrift:2056: 2024-05-27 06:02:30 - step 2 of 48 - 100 active elements (0 deactivated) 14:21:30 INFO opendrift:2056: 2024-05-27 06:05:00 - step 3 of 48 - 100 active elements (0 deactivated) 14:21:30 INFO opendrift:2056: 2024-05-27 06:07:30 - step 4 of 48 - 100 active elements (0 deactivated) 14:21:30 INFO opendrift:2056: 2024-05-27 06:10:00 - step 5 of 48 - 100 active elements (0 deactivated) 14:21:30 INFO opendrift:2056: 2024-05-27 06:12:30 - step 6 of 48 - 100 active elements (0 deactivated) 14:21:30 INFO opendrift:2056: 2024-05-27 06:15:00 - step 7 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:17:30 - step 8 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:20:00 - step 9 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:22:30 - step 10 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:25:00 - step 11 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:27:30 - step 12 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:30:00 - step 13 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:32:30 - step 14 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:35:00 - step 15 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:37:30 - step 16 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:40:00 - step 17 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:42:30 - step 18 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:45:00 - step 19 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:47:30 - step 20 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:50:00 - step 21 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:52:30 - step 22 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:55:00 - step 23 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 06:57:30 - step 24 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 07:00:00 - step 25 of 48 - 100 active elements (0 deactivated) 14:21:31 INFO opendrift:2056: 2024-05-27 07:02:30 - step 26 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:05:00 - step 27 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:07:30 - step 28 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:10:00 - step 29 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:12:30 - step 30 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:15:00 - step 31 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:17:30 - step 32 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:20:00 - step 33 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:22:30 - step 34 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:25:00 - step 35 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:27:30 - step 36 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:30:00 - step 37 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:32:30 - step 38 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:35:00 - step 39 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:37:30 - step 40 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:40:00 - step 41 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:42:30 - step 42 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:45:00 - step 43 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:47:30 - step 44 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:50:00 - step 45 of 48 - 100 active elements (0 deactivated) 14:21:34 INFO opendrift:2056: 2024-05-27 07:52:30 - step 46 of 48 - 100 active elements (0 deactivated) 14:21:35 INFO opendrift:2056: 2024-05-27 07:55:00 - step 47 of 48 - 100 active elements (0 deactivated) 14:21:35 INFO opendrift:2056: 2024-05-27 07:57:30 - step 48 of 48 - 100 active elements (0 deactivated) (,
) .. GENERATED FROM PYTHON SOURCE LINES 166-167 Calculating skillscores with TrajAn .. GENERATED FROM PYTHON SOURCE LINES 167-180 .. code-block:: Python skillscores = o.result.traj.skill(o2.result, method='liu-weissberg', tolerance_threshold=1) plt.figure() plt.hist(skillscores, bins = 100, range = (0, 1), facecolor = 'none', edgecolor = 'C0') plt.xlabel("Skillscore") plt.ylabel("Histogram (percentages)") plt.show() plt.figure() plt.hist(skillscores, bins = 100, range = (0.9, 0.95), facecolor = 'none', edgecolor = 'C0') plt.xlabel("Skillscore") plt.ylabel("Histogram (percentages)") plt.show() .. rst-class:: sphx-glr-horizontal * .. image-sg:: /gallery/images/sphx_glr_example_wind_measurements_004.png :alt: example wind measurements :srcset: /gallery/images/sphx_glr_example_wind_measurements_004.png :class: sphx-glr-multi-img * .. image-sg:: /gallery/images/sphx_glr_example_wind_measurements_005.png :alt: example wind measurements :srcset: /gallery/images/sphx_glr_example_wind_measurements_005.png :class: sphx-glr-multi-img .. rst-class:: sphx-glr-timing **Total running time of the script:** (1 minutes 19.163 seconds) .. _sphx_glr_download_gallery_example_wind_measurements.py: .. only:: html .. container:: sphx-glr-footer sphx-glr-footer-example .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: example_wind_measurements.ipynb ` .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: example_wind_measurements.py ` .. container:: sphx-glr-download sphx-glr-download-zip :download:`Download zipped: example_wind_measurements.zip ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_