Particle Statistics

Heat maps

Heatmaps built on the fly with no particle tracks recorded. Options for both time and aged based gridded heatmaps

  • class: particle_statistics.gridded_statistics.GriddedStats2D_timeBased

  • class: particle_statistics.gridded_statistics.GriddedStats2D_agedBased

along with counts of particles inside polygons

  • class: particle_statistics.polygon_statistics.PolygonStats2D_timeBased

  • class: particle_statistics.polygon_statistics.PolygonStats2D_ageBased

json parameters
../../../demos/demo_param_files/demo03_heatmaps.json
{
    "output_file_base": "demo03_heatmaps",
    "add_date_to_run_output_dir": false,
    "time_step": 900,
    "debug": true,
    "reader": {
        "class_name": "oceantracker.reader.generic_unstructured_reader.GenericUnstructuredReader",
        "input_dir": "E:\\H_Local_drive\\ParticleTracking\\oceantracker\\demos\\demo_hindcast",
        "file_mask": "demoHindcast2D*.nc",
        "search_sub_dirs": true,
        "dimension_map": {
            "time": "time",
            "node": "nodes"
        },
        "grid_variables": {
            "time": "time_sec",
            "x": [
                "east",
                "north"
            ],
            "triangles": "tri"
        },
        "field_variables": {
            "water_velocity": [
                "east_vel",
                "north_vel"
            ],
            "water_depth": "depth",
            "tide": "tide"
        },
        "time_buffer_size": 15,
        "isodate_of_hindcast_time_zero": "2020-06-01"
    },
    "user_note": "test of notes",
    "dispersion_miss-spelt": {
        "A_H": 0.1
    },
    "dispersion": {
        "A_H": 0.1
    },
    "tracks_writer": {
        "turn_on_write_particle_properties_list": [
            "n_cell"
        ],
        "write_dry_cell_index": true
    },
    "release_groups": {
        "myP1": {
            "points": [
                [
                    1596000,
                    5486000
                ]
            ],
            "pulse_size": 2000,
            "release_interval": 7200,
            "release_radius": 100.0
        },
        "myP2": {
            "points": [
                [
                    1596000,
                    5490000
                ]
            ],
            "pulse_size": 2000,
            "release_interval": 7200
        }
    },
    "particle_properties ": {
        "Oxygen": {
            "class_name": "oceantracker.particle_properties.age_decay.AgeDecay",
            "decay_time_scale": 86400.0,
            "initial_value": 20.0
        },
        "distance_travelled": {
            "class_name": "oceantracker.particle_properties.distance_travelled.DistanceTravelled"
        }
    },
    "particle_statistics": {
        "gridstats1": {
            "class_name": "oceantracker.particle_statistics.gridded_statistics.GriddedStats2D_timeBased",
            "update_interval": 1800,
            "particle_property_list": [
                "water_depth"
            ],
            "count_start_date": "2020-06-01 21:16:07",
            "grid_size": [
                220,
                221
            ]
        },
        "polystats1": {
            "class_name": "oceantracker.particle_statistics.polygon_statistics.PolygonStats2D_timeBased",
            "update_interval": 1800,
            "particle_property_list": [
                "water_depth"
            ],
            "polygon_list": [
                {
                    "points": [
                        [
                            1597682.1237,
                            5489972.7479
                        ],
                        [
                            1598604.1667,
                            5490275.5488
                        ],
                        [
                            1598886.4247,
                            5489464.0424
                        ],
                        [
                            1597917.3387,
                            5489000
                        ],
                        [
                            1597300,
                            5489000
                        ],
                        [
                            1597682.1237,
                            5489972.7479
                        ]
                    ]
                }
            ]
        }
    },
    "particle_group_manager": {
        "particle_buffer_chunk_size": 20000
    },
    "write_tracks": false,
    "max_run_duration": 259200,
    "root_output_dir": "output"
}
yaml parameters
../../../demos/demo_param_files/demo03_heatmaps.yaml
add_date_to_run_output_dir: false
debug: true
dispersion:
  A_H: 0.1
dispersion_miss-spelt:
  A_H: 0.1
max_run_duration: 259200
output_file_base: demo03_heatmaps
particle_group_manager:
  particle_buffer_chunk_size: 20000
'particle_properties ':
  Oxygen:
    class_name: oceantracker.particle_properties.age_decay.AgeDecay
    decay_time_scale: 86400.0
    initial_value: 20.0
  distance_travelled:
    class_name: oceantracker.particle_properties.distance_travelled.DistanceTravelled
particle_statistics:
  gridstats1:
    class_name: oceantracker.particle_statistics.gridded_statistics.GriddedStats2D_timeBased
    count_start_date: '2020-06-01 21:16:07'
    grid_size:
    - 220
    - 221
    particle_property_list:
    - water_depth
    update_interval: 1800
  polystats1:
    class_name: oceantracker.particle_statistics.polygon_statistics.PolygonStats2D_timeBased
    particle_property_list:
    - water_depth
    polygon_list:
    - points:
      - - 1597682.1237
        - 5489972.7479
      - - 1598604.1667
        - 5490275.5488
      - - 1598886.4247
        - 5489464.0424
      - - 1597917.3387
        - 5489000
      - - 1597300
        - 5489000
      - - 1597682.1237
        - 5489972.7479
    update_interval: 1800
reader:
  class_name: oceantracker.reader.generic_unstructured_reader.GenericUnstructuredReader
  dimension_map:
    node: nodes
    time: time
  field_variables:
    tide: tide
    water_depth: depth
    water_velocity:
    - east_vel
    - north_vel
  file_mask: demoHindcast2D*.nc
  grid_variables:
    time: time_sec
    triangles: tri
    x:
    - east
    - north
  input_dir: E:\H_Local_drive\ParticleTracking\oceantracker\demos\demo_hindcast
  isodate_of_hindcast_time_zero: '2020-06-01'
  search_sub_dirs: true
  time_buffer_size: 15
release_groups:
  myP1:
    points:
    - - 1596000
      - 5486000
    pulse_size: 2000
    release_interval: 7200
    release_radius: 100.0
  myP2:
    points:
    - - 1596000
      - 5490000
    pulse_size: 2000
    release_interval: 7200
root_output_dir: output
time_step: 900
tracks_writer:
  turn_on_write_particle_properties_list:
  - n_cell
  write_dry_cell_index: true
user_note: test of notes
write_tracks: false