class_docstr: File handler for TROPOMI L2 netCDF files.
class_docstr_tok: ["File","handler","for","TROPOMI","L2","netCDF","files","."]
docstr: Get dataset.
docstr_tok: ["Get","dataset","."]
code: def get_dataset(self, ds_id, ds_info):
      """Get dataset."""
      logger.debug("Getting data for: %s", ds_id["name"])
      file_key = ds_info.get("file_key", ds_id["name"])
      data = self[file_key]
      data.attrs = self.get_metadata(data, ds_info)
      fill_value = data.attrs.get("_FillValue", np.float32(np.nan))
      data = data.squeeze()
  
      # preserve integer data types if possible
      if np.issubdtype(data.dtype, np.integer):
          new_fill = fill_value
      else:
          new_fill = np.float32(np.nan)
          data.attrs.pop("_FillValue", None)
      good_mask = data != fill_value
  
      scale_factor = data.attrs.get("scale_factor")
      add_offset = data.attrs.get("add_offset")
      if scale_factor is not None:
          data = data * scale_factor + add_offset
  
      data = data.where(good_mask, new_fill)
      data = self._rename_dims(data)
  
      # drop coords whose units are not meters
      drop_list = ["y", "x", "layer", "vertices"]
      coords_exist = [
          coord for coord in drop_list if coord in data.coords
      ]
      if coords_exist:
          data = data.drop_vars(coords_exist)
  
      if ds_id["name"] in [
          "assembled_lat_bounds",
          "assembled_lon_bounds",
      ]:
          data = self.prepare_geo(data)
      return data
  
imports: import logging
  from datetime import datetime
  import dask.array
  import numpy
  import xarray
  from satpy.readers.netcdf_utils import NetCDF4FileHandler, netCDF4
  from satpy.utils import get_legacy_chunk_size
label_desc: Use image node_id 13 for calling the TROPOMIL2FileHandler obj's underlying member method code with example usage: obj.get_dataset(ds_id, ds_info) and returns: data