class_docstr: A base class for the CLAVRx File Handlers.
class_docstr_tok: ["A","base","class","for","the","CLAVRx","File","Handlers","."]
docstr: Read a fixed grid.
  
  CLAVR-x does not transcribe fixed grid parameters to its output
  We have to recover that information from the original input file,
  which is partially named as L1B attribute
  
  example attributes found in L2 CLAVR-x files:
  sensor = "AHI" ;
  platform = "HIM8" ;
  FILENAME = "clavrx_H08_20180719_1300.level2.hdf" ;
  L1B = "clavrx_H08_20180719_1300" ;
docstr_tok: ["Read","a","fixed","grid",".","CLAVR-x","does","not","transcribe","fixed","grid","parameters","to","its","output","We","have","to","recover","that","information","from","the","original","input","file",",","which","is","partially","named","as","L1B","attribute","example","attributes","found","in","L2","CLAVR-x","files",":","sensor","=","``","AHI","''",";","platform","=","``","HIM8","''",";","FILENAME","=","``","clavrx_H08_20180719_1300.level2.hdf","''",";","L1B","=","``","clavrx_H08_20180719_1300","''",";"]
code: def _read_axi_fixed_grid(
      filename: str, l1b_attr
  ) -> geometry.AreaDefinition:
      """Read a fixed grid.
  
      CLAVR-x does not transcribe fixed grid parameters to its output
      We have to recover that information from the original input file,
      which is partially named as L1B attribute
  
      example attributes found in L2 CLAVR-x files:
      sensor = "AHI" ;
      platform = "HIM8" ;
      FILENAME = "clavrx_H08_20180719_1300.level2.hdf" ;
      L1B = "clavrx_H08_20180719_1300" ;
      """
      LOG.debug(
          f"looking for corresponding input file for {l1b_attr}"
          " to act as fixed grid navigation donor"
      )
      l1b_path = _CLAVRxHelper._find_input_nc(filename, l1b_attr)
      LOG.info(
          f"CLAVR-x does not include fixed-grid parameters, use input file {l1b_path} as donor"
      )
      l1b = netCDF4.Dataset(l1b_path)
      proj = None
      proj_var = l1b.variables.get("Projection", None)
      if proj_var is not None:
          # hsd2nc input typically used by CLAVR-x uses old-form km for axes/height
          LOG.debug(
              "found hsd2nc-style draft PUG fixed grid specification"
          )
          proj = _CLAVRxHelper._read_pug_fixed_grid(proj_var, 1000.0)
      if proj is None:  # most likely to come into play for ABI cases
          proj_var = l1b.variables.get("goes_imager_projection", None)
          if proj_var is not None:
              LOG.debug(
                  "found cmip-style final PUG fixed grid specification"
              )
              proj = _CLAVRxHelper._read_pug_fixed_grid(proj_var)
      if not proj:
          raise ValueError(
              f"Unable to recover projection information for {filename}"
          )
  
      h = float(proj["h"])
      x, y = l1b["x"], l1b["y"]
      area_extent, ncols, nlines = _CLAVRxHelper._area_extent(x, y, h)
  
      area = geometry.AreaDefinition(
          "ahi_geos",
          "AHI L2 file area",
          "ahi_geos",
          proj,
          ncols,
          nlines,
          np.asarray(area_extent),
      )
  
      return area
  
imports: import logging
  import os
  from glob import glob
  from typing import Optional, Union
  import netCDF4
  import numpy
  import xarray
  from pyresample import geometry
  from satpy.readers.file_handlers import BaseFileHandler
  from satpy.readers.hdf4_utils import SDS, HDF4FileHandler
  from satpy.utils import get_legacy_chunk_size
label_desc: Use image node_id 7 for calling the _CLAVRxHelper obj's underlying member method code with example usage: obj._read_axi_fixed_grid(filename, l1b_attr) and returns: area