Compare

Comparing two oil drift simulation runs, with and without wind

from datetime import timedelta
from opendrift.readers import reader_netCDF_CF_generic
from opendrift.models.openoil import OpenOil

o = OpenOil(loglevel=20)  # Set loglevel to 0 for debug information

# Arome atmospheric model
reader_arome = reader_netCDF_CF_generic.Reader(o.test_data_folder() +
    '16Nov2015_NorKyst_z_surface/arome_subset_16Nov2015.nc')
# Norkyst ocean model
reader_norkyst = reader_netCDF_CF_generic.Reader(o.test_data_folder() +
    '16Nov2015_NorKyst_z_surface/norkyst800_subset_16Nov2015.nc')

o.add_reader([reader_norkyst, reader_arome])

# Seeding some particles
lon = 4.5; lat = 60.0; # Outside Bergen
time = [reader_arome.start_time,
        reader_arome.start_time + timedelta(hours=30)]
o.seed_elements(lon, lat, radius=50, number=5000, time=time,
                oil_type='GENERIC HEAVY CRUDE',
                wind_drift_factor=0.03) # 3% wind drift

# Running model
o.run(steps=66, time_step=1800, time_step_output=3600)

# Second run, for comparison
o2 = OpenOil(loglevel=20)  # Set loglevel to 0 for debug information
o2.add_reader([reader_norkyst, reader_arome])
o2.seed_elements(lon, lat, radius=50, number=5000, time=time,
                 oil_type='GENERIC HEAVY CRUDE',
                 wind_drift_factor=0.0) # No wind drift
o2.run(steps=66, time_step=1800, time_step_output=3600)
20:15:12 INFO    opendrift.models.basemodel:515: OpenDriftSimulation initialised (version 1.12.0 / v1.12.0-26-g390e945)
20:15:12 INFO    opendrift.readers:58: Opening file with xr.open_dataset
20:15:12 INFO    opendrift.readers.reader_netCDF_CF_generic:337: Detected dimensions: {'time': 'time', 'x': 'x', 'y': 'y'}
20:15:12 INFO    opendrift.readers:58: Opening file with xr.open_dataset
20:15:12 INFO    opendrift.readers.reader_netCDF_CF_generic:337: Detected dimensions: {'x': 'X', 'y': 'Y', 'z': 'depth', 'time': 'time'}
20:15:12 INFO    opendrift.models.openoil.adios.dirjs:86: Querying ADIOS database for oil: GENERIC HEAVY CRUDE
20:15:12 INFO    opendrift.models.openoil.openoil:1715: Using density 963.50937 and viscosity 0.007984481780964631 of oiltype GENERIC HEAVY CRUDE
20:15:12 INFO    opendrift.models.basemodel.environment:218: Adding a dynamical landmask with max. priority based on assumed maximum speed of 1.3 m/s. Adding a customised landmask may be faster...
20:15:16 INFO    opendrift.models.basemodel.environment:245: Fallback values will be used for the following variables which have no readers:
20:15:16 INFO    opendrift.models.basemodel.environment:248:    sea_surface_height: 0.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    upward_sea_water_velocity: 0.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    sea_surface_wave_significant_height: 0.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    sea_surface_wave_stokes_drift_x_velocity: 0.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    sea_surface_wave_stokes_drift_y_velocity: 0.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    sea_surface_wave_period_at_variance_spectral_density_maximum: 0.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    sea_surface_wave_mean_period_from_variance_spectral_density_second_frequency_moment: 0.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    sea_ice_area_fraction: 0.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    sea_ice_x_velocity: 0.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    sea_ice_y_velocity: 0.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    sea_water_temperature: 10.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    sea_water_salinity: 34.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    sea_floor_depth_below_sea_level: 10000.000000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    ocean_vertical_diffusivity: 0.020000
20:15:16 INFO    opendrift.models.basemodel.environment:248:    ocean_mixed_layer_thickness: 50.000000
20:15:17 INFO    opendrift.models.basemodel:935: Using existing reader for land_binary_mask
20:15:17 INFO    opendrift.models.basemodel:946: All points are in ocean
20:15:17 INFO    opendrift.models.openoil.openoil:684: Oil-water surface tension is 0.035048 Nm
20:15:17 INFO    opendrift.models.openoil.openoil:697: Max water fraction not available for GENERIC HEAVY CRUDE, using default
20:15:17 INFO    opendrift.models.basemodel:2035: 2015-11-16 00:00:00 - step 1 of 66 - 84 active elements (0 deactivated)
20:15:18 INFO    opendrift.models.basemodel:2035: 2015-11-16 00:30:00 - step 2 of 66 - 167 active elements (0 deactivated)
20:15:18 INFO    opendrift.models.basemodel:2035: 2015-11-16 01:00:00 - step 3 of 66 - 250 active elements (0 deactivated)
20:15:18 INFO    opendrift.models.basemodel:2035: 2015-11-16 01:30:00 - step 4 of 66 - 334 active elements (0 deactivated)
20:15:18 INFO    opendrift.models.basemodel:2035: 2015-11-16 02:00:00 - step 5 of 66 - 417 active elements (0 deactivated)
20:15:18 INFO    opendrift.models.basemodel:2035: 2015-11-16 02:30:00 - step 6 of 66 - 500 active elements (0 deactivated)
20:15:19 INFO    opendrift.models.basemodel:2035: 2015-11-16 03:00:00 - step 7 of 66 - 584 active elements (0 deactivated)
20:15:19 INFO    opendrift.models.basemodel:2035: 2015-11-16 03:30:00 - step 8 of 66 - 667 active elements (0 deactivated)
20:15:19 INFO    opendrift.models.basemodel:2035: 2015-11-16 04:00:00 - step 9 of 66 - 750 active elements (0 deactivated)
20:15:19 INFO    opendrift.models.basemodel:2035: 2015-11-16 04:30:00 - step 10 of 66 - 834 active elements (0 deactivated)
20:15:19 INFO    opendrift.models.basemodel:2035: 2015-11-16 05:00:00 - step 11 of 66 - 917 active elements (0 deactivated)
20:15:20 INFO    opendrift.models.basemodel:2035: 2015-11-16 05:30:00 - step 12 of 66 - 1000 active elements (0 deactivated)
20:15:20 INFO    opendrift.models.basemodel:2035: 2015-11-16 06:00:00 - step 13 of 66 - 1084 active elements (0 deactivated)
20:15:20 INFO    opendrift.models.basemodel:2035: 2015-11-16 06:30:00 - step 14 of 66 - 1167 active elements (0 deactivated)
20:15:20 INFO    opendrift.models.basemodel:2035: 2015-11-16 07:00:00 - step 15 of 66 - 1250 active elements (0 deactivated)
20:15:21 INFO    opendrift.models.basemodel:2035: 2015-11-16 07:30:00 - step 16 of 66 - 1334 active elements (0 deactivated)
20:15:21 INFO    opendrift.models.basemodel:2035: 2015-11-16 08:00:00 - step 17 of 66 - 1417 active elements (0 deactivated)
20:15:22 INFO    opendrift.models.basemodel:2035: 2015-11-16 08:30:00 - step 18 of 66 - 1500 active elements (0 deactivated)
20:15:23 INFO    opendrift.models.basemodel:2035: 2015-11-16 09:00:00 - step 19 of 66 - 1584 active elements (0 deactivated)
20:15:23 INFO    opendrift.models.basemodel:2035: 2015-11-16 09:30:00 - step 20 of 66 - 1667 active elements (0 deactivated)
20:15:23 INFO    opendrift.models.basemodel:2035: 2015-11-16 10:00:00 - step 21 of 66 - 1750 active elements (0 deactivated)
20:15:23 INFO    opendrift.models.basemodel:2035: 2015-11-16 10:30:00 - step 22 of 66 - 1833 active elements (0 deactivated)
20:15:23 INFO    opendrift.models.basemodel:2035: 2015-11-16 11:00:00 - step 23 of 66 - 1917 active elements (0 deactivated)
20:15:24 INFO    opendrift.models.basemodel:2035: 2015-11-16 11:30:00 - step 24 of 66 - 2000 active elements (0 deactivated)
20:15:24 INFO    opendrift.models.basemodel:2035: 2015-11-16 12:00:00 - step 25 of 66 - 2083 active elements (0 deactivated)
20:15:24 INFO    opendrift.models.basemodel:2035: 2015-11-16 12:30:00 - step 26 of 66 - 2167 active elements (0 deactivated)
20:15:24 INFO    opendrift.models.basemodel:2035: 2015-11-16 13:00:00 - step 27 of 66 - 2250 active elements (0 deactivated)
20:15:25 INFO    opendrift.models.basemodel:2035: 2015-11-16 13:30:00 - step 28 of 66 - 2333 active elements (0 deactivated)
20:15:25 INFO    opendrift.models.basemodel:2035: 2015-11-16 14:00:00 - step 29 of 66 - 2417 active elements (0 deactivated)
20:15:25 INFO    opendrift.models.basemodel:2035: 2015-11-16 14:30:00 - step 30 of 66 - 2500 active elements (0 deactivated)
20:15:25 INFO    opendrift.models.basemodel:2035: 2015-11-16 15:00:00 - step 31 of 66 - 2583 active elements (0 deactivated)
20:15:26 INFO    opendrift.models.basemodel:2035: 2015-11-16 15:30:00 - step 32 of 66 - 2667 active elements (0 deactivated)
20:15:26 INFO    opendrift.models.basemodel:2035: 2015-11-16 16:00:00 - step 33 of 66 - 2750 active elements (0 deactivated)
20:15:26 INFO    opendrift.models.basemodel:2035: 2015-11-16 16:30:00 - step 34 of 66 - 2833 active elements (0 deactivated)
20:15:27 INFO    opendrift.models.basemodel:2035: 2015-11-16 17:00:00 - step 35 of 66 - 2917 active elements (0 deactivated)
20:15:27 INFO    opendrift.models.basemodel:2035: 2015-11-16 17:30:00 - step 36 of 66 - 3000 active elements (0 deactivated)
20:15:27 INFO    opendrift.models.basemodel:2035: 2015-11-16 18:00:00 - step 37 of 66 - 3083 active elements (0 deactivated)
20:15:28 INFO    opendrift.models.basemodel:2035: 2015-11-16 18:30:00 - step 38 of 66 - 3167 active elements (0 deactivated)
20:15:28 INFO    opendrift.models.basemodel:2035: 2015-11-16 19:00:00 - step 39 of 66 - 3250 active elements (0 deactivated)
20:15:28 INFO    opendrift.models.basemodel:2035: 2015-11-16 19:30:00 - step 40 of 66 - 3333 active elements (0 deactivated)
20:15:29 INFO    opendrift.models.basemodel:2035: 2015-11-16 20:00:00 - step 41 of 66 - 3416 active elements (0 deactivated)
20:15:29 INFO    opendrift.models.basemodel:2035: 2015-11-16 20:30:00 - step 42 of 66 - 3500 active elements (0 deactivated)
20:15:30 INFO    opendrift.models.basemodel:2035: 2015-11-16 21:00:00 - step 43 of 66 - 3583 active elements (0 deactivated)
20:15:30 INFO    opendrift.models.basemodel:2035: 2015-11-16 21:30:00 - step 44 of 66 - 3666 active elements (0 deactivated)
20:15:30 INFO    opendrift.models.basemodel:2035: 2015-11-16 22:00:00 - step 45 of 66 - 3750 active elements (0 deactivated)
20:15:31 INFO    opendrift.models.basemodel:2035: 2015-11-16 22:30:00 - step 46 of 66 - 3833 active elements (0 deactivated)
20:15:34 INFO    opendrift.models.basemodel:2035: 2015-11-16 23:00:00 - step 47 of 66 - 3915 active elements (1 deactivated)
20:15:35 INFO    opendrift.models.basemodel:2035: 2015-11-16 23:30:00 - step 48 of 66 - 3996 active elements (4 deactivated)
20:15:35 INFO    opendrift.models.basemodel:2035: 2015-11-17 00:00:00 - step 49 of 66 - 4073 active elements (10 deactivated)
20:15:35 INFO    opendrift.models.basemodel:2035: 2015-11-17 00:30:00 - step 50 of 66 - 4147 active elements (19 deactivated)
20:15:36 INFO    opendrift.models.basemodel:2035: 2015-11-17 01:00:00 - step 51 of 66 - 4184 active elements (66 deactivated)
20:15:36 INFO    opendrift.models.basemodel:2035: 2015-11-17 01:30:00 - step 52 of 66 - 4171 active elements (162 deactivated)
20:15:36 INFO    opendrift.models.basemodel:2035: 2015-11-17 02:00:00 - step 53 of 66 - 4116 active elements (300 deactivated)
20:15:37 INFO    opendrift.models.basemodel:2035: 2015-11-17 02:30:00 - step 54 of 66 - 4024 active elements (476 deactivated)
20:15:37 INFO    opendrift.models.basemodel:2035: 2015-11-17 03:00:00 - step 55 of 66 - 3887 active elements (696 deactivated)
20:15:38 INFO    opendrift.models.basemodel:2035: 2015-11-17 03:30:00 - step 56 of 66 - 3792 active elements (874 deactivated)
20:15:38 INFO    opendrift.models.basemodel:2035: 2015-11-17 04:00:00 - step 57 of 66 - 3692 active elements (1058 deactivated)
20:15:39 INFO    opendrift.models.basemodel:2035: 2015-11-17 04:30:00 - step 58 of 66 - 3596 active elements (1237 deactivated)
20:15:39 INFO    opendrift.models.basemodel:2035: 2015-11-17 05:00:00 - step 59 of 66 - 3563 active elements (1353 deactivated)
20:15:39 INFO    opendrift.models.basemodel:2035: 2015-11-17 05:30:00 - step 60 of 66 - 3563 active elements (1436 deactivated)
20:15:40 INFO    opendrift.models.basemodel:2035: 2015-11-17 06:00:00 - step 61 of 66 - 3478 active elements (1522 deactivated)
20:15:40 INFO    opendrift.models.basemodel:2035: 2015-11-17 06:30:00 - step 62 of 66 - 3392 active elements (1608 deactivated)
20:15:40 INFO    opendrift.models.basemodel:2035: 2015-11-17 07:00:00 - step 63 of 66 - 3302 active elements (1698 deactivated)
20:15:41 INFO    opendrift.models.basemodel:2035: 2015-11-17 07:30:00 - step 64 of 66 - 3173 active elements (1827 deactivated)
20:15:41 INFO    opendrift.models.basemodel:2035: 2015-11-17 08:00:00 - step 65 of 66 - 2933 active elements (2067 deactivated)
20:15:42 INFO    opendrift.models.basemodel:2035: 2015-11-17 08:30:00 - step 66 of 66 - 2713 active elements (2287 deactivated)
20:15:42 INFO    opendrift.models.basemodel:515: OpenDriftSimulation initialised (version 1.12.0 / v1.12.0-26-g390e945)
20:15:42 INFO    opendrift.models.openoil.adios.dirjs:86: Querying ADIOS database for oil: GENERIC HEAVY CRUDE
20:15:42 INFO    opendrift.models.openoil.openoil:1715: Using density 963.50937 and viscosity 0.007984481780964631 of oiltype GENERIC HEAVY CRUDE
20:15:42 INFO    opendrift.models.basemodel.environment:218: Adding a dynamical landmask with max. priority based on assumed maximum speed of 1.3 m/s. Adding a customised landmask may be faster...
20:15:42 INFO    opendrift.models.basemodel.environment:245: Fallback values will be used for the following variables which have no readers:
20:15:42 INFO    opendrift.models.basemodel.environment:248:    sea_surface_height: 0.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    upward_sea_water_velocity: 0.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    sea_surface_wave_significant_height: 0.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    sea_surface_wave_stokes_drift_x_velocity: 0.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    sea_surface_wave_stokes_drift_y_velocity: 0.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    sea_surface_wave_period_at_variance_spectral_density_maximum: 0.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    sea_surface_wave_mean_period_from_variance_spectral_density_second_frequency_moment: 0.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    sea_ice_area_fraction: 0.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    sea_ice_x_velocity: 0.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    sea_ice_y_velocity: 0.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    sea_water_temperature: 10.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    sea_water_salinity: 34.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    sea_floor_depth_below_sea_level: 10000.000000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    ocean_vertical_diffusivity: 0.020000
20:15:42 INFO    opendrift.models.basemodel.environment:248:    ocean_mixed_layer_thickness: 50.000000
20:15:43 INFO    opendrift.models.basemodel:935: Using existing reader for land_binary_mask
20:15:43 INFO    opendrift.models.basemodel:946: All points are in ocean
20:15:43 INFO    opendrift.models.openoil.openoil:684: Oil-water surface tension is 0.035048 Nm
20:15:43 INFO    opendrift.models.openoil.openoil:697: Max water fraction not available for GENERIC HEAVY CRUDE, using default
20:15:43 INFO    opendrift.models.basemodel:2035: 2015-11-16 00:00:00 - step 1 of 66 - 84 active elements (0 deactivated)
20:15:43 INFO    opendrift.models.basemodel:2035: 2015-11-16 00:30:00 - step 2 of 66 - 167 active elements (0 deactivated)
20:15:43 INFO    opendrift.models.basemodel:2035: 2015-11-16 01:00:00 - step 3 of 66 - 250 active elements (0 deactivated)
20:15:43 INFO    opendrift.models.basemodel:2035: 2015-11-16 01:30:00 - step 4 of 66 - 334 active elements (0 deactivated)
20:15:43 INFO    opendrift.models.basemodel:2035: 2015-11-16 02:00:00 - step 5 of 66 - 417 active elements (0 deactivated)
20:15:43 INFO    opendrift.models.basemodel:2035: 2015-11-16 02:30:00 - step 6 of 66 - 500 active elements (0 deactivated)
20:15:43 INFO    opendrift.models.basemodel:2035: 2015-11-16 03:00:00 - step 7 of 66 - 584 active elements (0 deactivated)
20:15:43 INFO    opendrift.models.basemodel:2035: 2015-11-16 03:30:00 - step 8 of 66 - 667 active elements (0 deactivated)
20:15:44 INFO    opendrift.models.basemodel:2035: 2015-11-16 04:00:00 - step 9 of 66 - 750 active elements (0 deactivated)
20:15:44 INFO    opendrift.models.basemodel:2035: 2015-11-16 04:30:00 - step 10 of 66 - 834 active elements (0 deactivated)
20:15:44 INFO    opendrift.models.basemodel:2035: 2015-11-16 05:00:00 - step 11 of 66 - 917 active elements (0 deactivated)
20:15:44 INFO    opendrift.models.basemodel:2035: 2015-11-16 05:30:00 - step 12 of 66 - 1000 active elements (0 deactivated)
20:15:44 INFO    opendrift.models.basemodel:2035: 2015-11-16 06:00:00 - step 13 of 66 - 1084 active elements (0 deactivated)
20:15:44 INFO    opendrift.models.basemodel:2035: 2015-11-16 06:30:00 - step 14 of 66 - 1167 active elements (0 deactivated)
20:15:44 INFO    opendrift.models.basemodel:2035: 2015-11-16 07:00:00 - step 15 of 66 - 1250 active elements (0 deactivated)
20:15:44 INFO    opendrift.models.basemodel:2035: 2015-11-16 07:30:00 - step 16 of 66 - 1334 active elements (0 deactivated)
20:15:45 INFO    opendrift.models.basemodel:2035: 2015-11-16 08:00:00 - step 17 of 66 - 1417 active elements (0 deactivated)
20:15:45 INFO    opendrift.models.basemodel:2035: 2015-11-16 08:30:00 - step 18 of 66 - 1500 active elements (0 deactivated)
20:15:45 INFO    opendrift.models.basemodel:2035: 2015-11-16 09:00:00 - step 19 of 66 - 1584 active elements (0 deactivated)
20:15:45 INFO    opendrift.models.basemodel:2035: 2015-11-16 09:30:00 - step 20 of 66 - 1667 active elements (0 deactivated)
20:15:45 INFO    opendrift.models.basemodel:2035: 2015-11-16 10:00:00 - step 21 of 66 - 1750 active elements (0 deactivated)
20:15:45 INFO    opendrift.models.basemodel:2035: 2015-11-16 10:30:00 - step 22 of 66 - 1833 active elements (0 deactivated)
20:15:46 INFO    opendrift.models.basemodel:2035: 2015-11-16 11:00:00 - step 23 of 66 - 1917 active elements (0 deactivated)
20:15:46 INFO    opendrift.models.basemodel:2035: 2015-11-16 11:30:00 - step 24 of 66 - 2000 active elements (0 deactivated)
20:15:46 INFO    opendrift.models.basemodel:2035: 2015-11-16 12:00:00 - step 25 of 66 - 2083 active elements (0 deactivated)
20:15:46 INFO    opendrift.models.basemodel:2035: 2015-11-16 12:30:00 - step 26 of 66 - 2167 active elements (0 deactivated)
20:15:46 INFO    opendrift.models.basemodel:2035: 2015-11-16 13:00:00 - step 27 of 66 - 2250 active elements (0 deactivated)
20:15:46 INFO    opendrift.models.basemodel:2035: 2015-11-16 13:30:00 - step 28 of 66 - 2333 active elements (0 deactivated)
20:15:47 INFO    opendrift.models.basemodel:2035: 2015-11-16 14:00:00 - step 29 of 66 - 2417 active elements (0 deactivated)
20:15:47 INFO    opendrift.models.basemodel:2035: 2015-11-16 14:30:00 - step 30 of 66 - 2500 active elements (0 deactivated)
20:15:47 INFO    opendrift.models.basemodel:2035: 2015-11-16 15:00:00 - step 31 of 66 - 2583 active elements (0 deactivated)
20:15:47 INFO    opendrift.models.basemodel:2035: 2015-11-16 15:30:00 - step 32 of 66 - 2667 active elements (0 deactivated)
20:15:47 INFO    opendrift.models.basemodel:2035: 2015-11-16 16:00:00 - step 33 of 66 - 2750 active elements (0 deactivated)
20:15:48 INFO    opendrift.models.basemodel:2035: 2015-11-16 16:30:00 - step 34 of 66 - 2833 active elements (0 deactivated)
20:15:48 INFO    opendrift.models.basemodel:2035: 2015-11-16 17:00:00 - step 35 of 66 - 2917 active elements (0 deactivated)
20:15:48 INFO    opendrift.models.basemodel:2035: 2015-11-16 17:30:00 - step 36 of 66 - 3000 active elements (0 deactivated)
20:15:48 INFO    opendrift.models.basemodel:2035: 2015-11-16 18:00:00 - step 37 of 66 - 3083 active elements (0 deactivated)
20:15:49 INFO    opendrift.models.basemodel:2035: 2015-11-16 18:30:00 - step 38 of 66 - 3167 active elements (0 deactivated)
20:15:49 INFO    opendrift.models.basemodel:2035: 2015-11-16 19:00:00 - step 39 of 66 - 3250 active elements (0 deactivated)
20:15:49 INFO    opendrift.models.basemodel:2035: 2015-11-16 19:30:00 - step 40 of 66 - 3333 active elements (0 deactivated)
20:15:49 INFO    opendrift.models.basemodel:2035: 2015-11-16 20:00:00 - step 41 of 66 - 3416 active elements (0 deactivated)
20:15:49 INFO    opendrift.models.basemodel:2035: 2015-11-16 20:30:00 - step 42 of 66 - 3500 active elements (0 deactivated)
20:15:50 INFO    opendrift.models.basemodel:2035: 2015-11-16 21:00:00 - step 43 of 66 - 3583 active elements (0 deactivated)
20:15:50 INFO    opendrift.models.basemodel:2035: 2015-11-16 21:30:00 - step 44 of 66 - 3666 active elements (0 deactivated)
20:15:50 INFO    opendrift.models.basemodel:2035: 2015-11-16 22:00:00 - step 45 of 66 - 3750 active elements (0 deactivated)
20:15:51 INFO    opendrift.models.basemodel:2035: 2015-11-16 22:30:00 - step 46 of 66 - 3833 active elements (0 deactivated)
20:15:51 INFO    opendrift.models.basemodel:2035: 2015-11-16 23:00:00 - step 47 of 66 - 3916 active elements (0 deactivated)
20:15:51 INFO    opendrift.models.basemodel:2035: 2015-11-16 23:30:00 - step 48 of 66 - 4000 active elements (0 deactivated)
20:15:51 INFO    opendrift.models.basemodel:2035: 2015-11-17 00:00:00 - step 49 of 66 - 4083 active elements (0 deactivated)
20:15:52 INFO    opendrift.models.basemodel:2035: 2015-11-17 00:30:00 - step 50 of 66 - 4166 active elements (0 deactivated)
20:15:52 INFO    opendrift.models.basemodel:2035: 2015-11-17 01:00:00 - step 51 of 66 - 4250 active elements (0 deactivated)
20:15:52 INFO    opendrift.models.basemodel:2035: 2015-11-17 01:30:00 - step 52 of 66 - 4333 active elements (0 deactivated)
20:15:53 INFO    opendrift.models.basemodel:2035: 2015-11-17 02:00:00 - step 53 of 66 - 4416 active elements (0 deactivated)
20:15:53 INFO    opendrift.models.basemodel:2035: 2015-11-17 02:30:00 - step 54 of 66 - 4500 active elements (0 deactivated)
20:15:53 INFO    opendrift.models.basemodel:2035: 2015-11-17 03:00:00 - step 55 of 66 - 4583 active elements (0 deactivated)
20:15:54 INFO    opendrift.models.basemodel:2035: 2015-11-17 03:30:00 - step 56 of 66 - 4666 active elements (0 deactivated)
20:15:54 INFO    opendrift.models.basemodel:2035: 2015-11-17 04:00:00 - step 57 of 66 - 4750 active elements (0 deactivated)
20:15:54 INFO    opendrift.models.basemodel:2035: 2015-11-17 04:30:00 - step 58 of 66 - 4833 active elements (0 deactivated)
20:15:54 INFO    opendrift.models.basemodel:2035: 2015-11-17 05:00:00 - step 59 of 66 - 4916 active elements (0 deactivated)
20:15:55 INFO    opendrift.models.basemodel:2035: 2015-11-17 05:30:00 - step 60 of 66 - 4999 active elements (0 deactivated)
20:15:55 INFO    opendrift.models.basemodel:2035: 2015-11-17 06:00:00 - step 61 of 66 - 5000 active elements (0 deactivated)
20:15:55 INFO    opendrift.models.basemodel:2035: 2015-11-17 06:30:00 - step 62 of 66 - 5000 active elements (0 deactivated)
20:15:56 INFO    opendrift.models.basemodel:2035: 2015-11-17 07:00:00 - step 63 of 66 - 5000 active elements (0 deactivated)
20:15:56 INFO    opendrift.models.basemodel:2035: 2015-11-17 07:30:00 - step 64 of 66 - 5000 active elements (0 deactivated)
20:15:56 INFO    opendrift.models.basemodel:2035: 2015-11-17 08:00:00 - step 65 of 66 - 5000 active elements (0 deactivated)
20:15:57 INFO    opendrift.models.basemodel:2035: 2015-11-17 08:30:00 - step 66 of 66 - 5000 active elements (0 deactivated)

Animate and compare the two runs. We see that there is much more stranding of oil when wind is considered.

o.animation(fast=True, compare=o2,
            legend=['Current + 3 % wind drift', 'Current only'])
20:15:57 WARNING opendrift.models.basemodel:2410: Plotting fast. This will make your plots less accurate.
/opt/conda/envs/opendrift/lib/python3.11/site-packages/cartopy/mpl/geoaxes.py:1692: UserWarning: No data for colormapping provided via 'c'. Parameters 'cmap' will be ignored
  result = super().scatter(*args, **kwargs)
20:16:01 INFO    opendrift.models.basemodel:4613: Saving animation to /root/project/docs/source/gallery/animations/example_compare_0.gif...
20:16:34 INFO    opendrift.models.basemodel:3037: Time to make animation: 0:00:36.905837
../_images/example_compare_0.gif
o.plot(fast=True, compare=o2,
       legend=['Current + 3 % wind drift', 'Current only'])
OpenDrift - OpenOil (GENERIC HEAVY CRUDE) 2015-11-16 00:00 to 2015-11-17 09:00 UTC (34 steps)
20:16:34 WARNING opendrift.models.basemodel:2410: Plotting fast. This will make your plots less accurate.

(<GeoAxes: title={'center': 'OpenDrift - OpenOil (GENERIC HEAVY CRUDE)\n2015-11-16 00:00 to 2015-11-17 09:00 UTC (34 steps)'}>, <Figure size 623.045x1100 with 1 Axes>)

Total running time of the script: (2 minutes 3.588 seconds)

Gallery generated by Sphinx-Gallery