class_docstr: Writer to save GeoTIFF images.
  
  Basic example from Scene:
  
      >>> scn.save_datasets(writer='geotiff')
  
  By default the writer will use the :class:`~satpy.writers.Enhancer` class to
  linear stretch the data (see :doc:`../enhancements`).
  To get Un-enhanced images ``enhance=False`` can be specified which will
  write a geotiff with the data type of the dataset. The fill value defaults
  to the the datasets ``"_FillValue"`` attribute if not ``None`` and no value is
  passed to ``fill_value`` for integer data. In case of float data if ``fill_value``
  is not passed NaN will be used. If a geotiff with a
  certain datatype is desired for example 32 bit floating point geotiffs:
  
      >>> scn.save_datasets(writer='geotiff', dtype=np.float32, enhance=False)
  
  To add custom metadata use `tags`:
  
      >>> scn.save_dataset(dataset_name, writer='geotiff',
      ...                  tags={'offset': 291.8, 'scale': -0.35})
  
  Images are tiled by default. To create striped TIFF files ``tiled=False`` can be specified:
  
      >>> scn.save_datasets(writer='geotiff', tiled=False)
  
  For performance tips on creating geotiffs quickly and making them smaller
  see the :ref:`faq`.
class_docstr_tok: ["Writer","to","save","GeoTIFF","images",".","Basic","example","from","Scene",":",">",">",">","scn.save_datasets","(","writer='geotiff","'",")","By","default","the","writer","will","use","the",":","class",":","`","~satpy.writers.Enhancer","`","class","to","linear","stretch","the","data","(","see",":","doc",":","`","..","\/enhancements","`",")",".","To","get","Un-enhanced","images","``","enhance=False","``","can","be","specified","which","will","write","a","geotiff","with","the","data","type","of","the","dataset",".","The","fill","value","defaults","to","the","the","datasets","``","``","_FillValue","''","``","attribute","if","not","``","None","``","and","no","value","is","passed","to","``","fill_value","``","for","integer","data",".","In","case","of","float","data","if","``","fill_value","``","is","not","passed","NaN","will","be","used",".","If","a","geotiff","with","a","certain","datatype","is","desired","for","example","32","bit","floating","point","geotiffs",":",">",">",">","scn.save_datasets","(","writer='geotiff","'",",","dtype=np.float32",",","enhance=False",")","To","add","custom","metadata","use","`","tags","`",":",">",">",">","scn.save_dataset","(","dataset_name",",","writer='geotiff","'",",","...","tags=","{","'offset","'",":","291.8",",","'scale","'",":","-0.35","}",")","Images","are","tiled","by","default",".","To","create","striped","TIFF","files","``","tiled=False","``","can","be","specified",":",">",">",">","scn.save_datasets","(","writer='geotiff","'",",","tiled=False",")","For","performance","tips","on","creating","geotiffs","quickly","and","making","them","smaller","see","the",":","ref",":","`","faq","`","."]
code: def _get_gdal_options(self, kwargs):
      # Update global GDAL options with these specific ones
      gdal_options = self.gdal_options.copy()
      for k in kwargs:
          if k in self.GDAL_OPTIONS:
              gdal_options[k] = kwargs[k]
      return gdal_options
  
file_path: satpy/satpy/writers/geotiff.py
imports: from __future__ import annotations
  import logging
  from typing import Any, Optional, Union
  import numpy
  import rasterio
  from trollimage.colormap import Colormap
  from trollimage.xrimage import XRImage
  from satpy._compat import DTypeLike
  from satpy.writers import ImageWriter
label_desc: Use image node_id 4 for calling the GeoTIFFWriter obj's underlying member method code with example usage: obj._get_gdal_options(kwargs) and returns: gdal_options