rompy.swan.components.output.GROUP#

pydantic model rompy.swan.components.output.GROUP[source]#

Output locations on subset of a grid.

GROUP 'sname' SUBGRID [ix1] [ix2] [iy1] [iy2]

With this optional command the user defines a group of output locations on a rectangular or curvilinear grid that is identical with (part of) the computational grid (rectilinear or curvilinear). Such a group may be convenient for the user to obtain output that is not affected by interpolation errors.

The subgrid contains those points (ix,`iy`) of the computational grid for which: ix1 <= ix <= ix2 and iy1 <= iy <= iy2 (The origin of the computational grid is ix=0, iy=0)

Limitations: ix1>=0, ix2<=mxc, iy1>=0, iy2<=myc (mxc and myc as defined in the command CGRID which should always precede this command GROUP)

Note

Cannot be used in 1D-mode or in case of unstructured grids.

Note

Regular and curvilinear grids are supported.

Examples

In [1]: from rompy.swan.components.output import GROUP

In [2]: loc = GROUP(sname="subgrid", ix1=20, iy1=0, ix2=50, iy2=100)

In [3]: print(loc.render())
GROUP sname='subgrid' SUBGRID ix1=20 iy1=0 ix2=50 iy2=100

Show JSON schema
{
   "title": "GROUP",
   "description": "Output locations on subset of a grid.\n\n.. code-block:: text\n\n    GROUP 'sname' SUBGRID [ix1] [ix2] [iy1] [iy2]\n\nWith this optional command the user defines a group of output locations on a\nrectangular or curvilinear grid that is identical with (part of) the computational\ngrid (rectilinear or curvilinear). Such a group may be convenient for the user to\nobtain output that is not affected by interpolation errors.\n\nThe subgrid contains those points (`ix`,`iy`) of the computational grid for which:\n`ix1` <= `ix` <= `ix2` and `iy1` <= `iy` <= `iy2` (The origin of the computational\ngrid is `ix=0`, `iy=0`)\n\nLimitations: `ix1>=0`, `ix2<=mxc`, `iy1>=0`, `iy2<=myc` (`mxc` and `myc` as\ndefined in the command `CGRID` which should always precede this command `GROUP`)\n\nNote\n----\nCannot be used in 1D-mode or in case of unstructured grids.\n\nNote\n----\nRegular and curvilinear grids are supported.\n\nExamples\n--------\n\n.. ipython:: python\n    :okwarning:\n\n    from rompy.swan.components.output import GROUP\n    loc = GROUP(sname=\"subgrid\", ix1=20, iy1=0, ix2=50, iy2=100)\n    print(loc.render())",
   "type": "object",
   "properties": {
      "model_type": {
         "default": "group",
         "description": "Model type discriminator",
         "enum": [
            "group",
            "GROUP"
         ],
         "title": "Model Type",
         "type": "string"
      },
      "sname": {
         "description": "Name of the set of output locations defined by this command",
         "maxLength": 8,
         "title": "Sname",
         "type": "string"
      },
      "ix1": {
         "description": "Lowest index of the computational grid in the ix-direction",
         "minimum": 0,
         "title": "Ix1",
         "type": "integer"
      },
      "iy1": {
         "description": "Lowest index of the computational grid in the iy-direction",
         "minimum": 0,
         "title": "Iy1",
         "type": "integer"
      },
      "ix2": {
         "description": "Highest index of the computational grid in the ix-direction",
         "title": "Ix2",
         "type": "integer"
      },
      "iy2": {
         "description": "Highest index of the computational grid in the ix-direction",
         "title": "Iy2",
         "type": "integer"
      }
   },
   "additionalProperties": false,
   "required": [
      "sname",
      "ix1",
      "iy1",
      "ix2",
      "iy2"
   ]
}

Fields:
Validators:

field ix1: int [Required]#

Lowest index of the computational grid in the ix-direction

Constraints:
  • ge = 0

field ix2: int [Required]#

Highest index of the computational grid in the ix-direction

field iy1: int [Required]#

Lowest index of the computational grid in the iy-direction

Constraints:
  • ge = 0

field iy2: int [Required]#

Highest index of the computational grid in the ix-direction

field model_type: Literal['group', 'GROUP'] = 'group'#

Model type discriminator

cmd() str[source]#

Command file string for this component.