class_docstr: Mixin providing methods for calculations related
  to transforming between rows and columns of the raster
  array and the coordinates.
  
  These methods are wrappers for the functionality in
  `rasterio.transform` module.
  
  A subclass with this mixin MUST provide a `transform`
  property.
docstr: Get the coordinates x, y of a pixel at row, col.
  
  The pixel's center is returned by default, but a corner can be returned
  by setting `offset` to one of `ul, ur, ll, lr`.
  
  Parameters
  ----------
  row : int
      Pixel row.
  col : int
      Pixel column.
  z : float, optional
      Height associated with coordinates. Primarily used for RPC based
      coordinate transformations. Ignored for affine based
      transformations. Default: 0.
  offset : str, optional
      Determines if the returned coordinates are for the center of the
      pixel or for a corner.
  transform_method: TransformMethod, optional
      The coordinate transformation method. Default: `TransformMethod.affine`.
  rpc_options: dict, optional
      Additional arguments passed to GDALCreateRPCTransformer
  
  Returns
  -------
  tuple
      x, y
docstr_tok: ["Get","the","coordinates","x",",","y","of","a","pixel","at","row",",","col",".","The","pixel","'s","center","is","returned","by","default",",","but","a","corner","can","be","returned","by","setting","`","offset","`","to","one","of","`","ul",",","ur",",","ll",",","lr","`",".","Parameters","--","--","--","--","--","row",":","int","Pixel","row",".","col",":","int","Pixel","column",".","z",":","float",",","optional","Height","associated","with","coordinates",".","Primarily","used","for","RPC","based","coordinate","transformations",".","Ignored","for","affine","based","transformations",".","Default",":","0.","offset",":","str",",","optional","Determines","if","the","returned","coordinates","are","for","the","center","of","the","pixel","or","for","a","corner",".","transform_method",":","TransformMethod",",","optional","The","coordinate","transformation","method",".","Default",":","`","TransformMethod.affine","`",".","rpc_options",":","dict",",","optional","Additional","arguments","passed","to","GDALCreateRPCTransformer","Returns","--","--","--","-","tuple","x",",","y"]
code: def xy(
      self,
      row,
      col,
      z=None,
      offset="center",
      transform_method=TransformMethod.affine,
      **rpc_options,
  ):
      """Get the coordinates x, y of a pixel at row, col.
  
      The pixel's center is returned by default, but a corner can be returned
      by setting `offset` to one of `ul, ur, ll, lr`.
  
      Parameters
      ----------
      row : int
          Pixel row.
      col : int
          Pixel column.
      z : float, optional
          Height associated with coordinates. Primarily used for RPC based
          coordinate transformations. Ignored for affine based
          transformations. Default: 0.
      offset : str, optional
          Determines if the returned coordinates are for the center of the
          pixel or for a corner.
      transform_method: TransformMethod, optional
          The coordinate transformation method. Default: `TransformMethod.affine`.
      rpc_options: dict, optional
          Additional arguments passed to GDALCreateRPCTransformer
  
      Returns
      -------
      tuple
          x, y
  
      """
      transform = getattr(self, transform_method.value)
      if transform_method is TransformMethod.gcps:
          transform = transform[0]
      if not transform:
          raise AttributeError(
              "Dataset has no {}".format(transform_method)
          )
      return xy(transform, row, col, zs=z, offset=offset, **rpc_options)
  
imports: from contextlib import ExitStack
  from functools import partial
  import math
  import numpy
  import warnings
  from affine import Affine
  from rasterio.env import env_ctx_if_needed
  from rasterio._transform import _transform_from_gcps, RPCTransformerBase, GCPTransformerBase
  from rasterio.enums import TransformDirection, TransformMethod
  from rasterio.control import GroundControlPoint
  from rasterio.rpc import RPC
  from rasterio.errors import TransformError, RasterioDeprecationWarning
label_desc: Use image node_id 1 for calling the TransformMethodsMixin obj's underlying member method code with example usage: obj.xy(row, col, z, offset, transform_method) and returns: xy