def import_fmi_pgm(filename, gzipped=False, **kwargs):
    """
    Import a 8-bit PGM radar reflectivity composite from the FMI archive.

    Parameters
    ----------
    filename: str
        Name of the file to import.
    gzipped: bool
        If True, the input file is treated as a compressed gzip file.

    {extra_kwargs_doc}

    Returns
    -------
    out: tuple
        A three-element tuple containing the reflectivity composite in dBZ
        and the associated quality field and metadata. The quality field is
        currently set to None.

    Notes
    -----
    Reading georeferencing metadata is supported only for stereographic
    projection. For other projections, the keys related to georeferencing are
    not set.
    """
    if not PYPROJ_IMPORTED:
        raise MissingOptionalDependency(
            "pyproj package is required to import "
            "FMI's radar reflectivity composite "
            "but it is not installed"
        )

    if gzipped is False:
        precip = imread(filename)
    else:
        precip = imread(gzip.open(filename, "r"))
    pgm_metadata = _import_fmi_pgm_metadata(filename, gzipped=gzipped)
    geodata = _import_fmi_pgm_geodata(pgm_metadata)

    mask = precip == pgm_metadata["missingval"]
    precip = precip.astype(float)
    precip[mask] = np.nan
    precip = (precip - 64.0) / 2.0

    metadata = geodata
    metadata["institution"] = "Finnish Meteorological Institute"
    metadata["accutime"] = 5.0
    metadata["unit"] = "dBZ"
    metadata["transform"] = "dB"
    metadata["zerovalue"] = np.nanmin(precip)
    metadata["threshold"] = _get_threshold_value(precip)
    metadata["zr_a"] = 223.0
    metadata["zr_b"] = 1.53

    return precip, None, metadata
Import a 8-bit PGM radar reflectivity composite from the FMI archive.

Parameters
----------
filename: str
Name of the file to import.
gzipped: bool
If True, the input file is treated as a compressed gzip file.

{extra_kwargs_doc}

Returns
-------
out: tuple
A three-element tuple containing the reflectivity composite in dBZ
and the associated quality field and metadata. The quality field is
currently set to None.

Notes
-----
Reading georeferencing metadata is supported only for stereographic
projection. For other projections, the keys related to georeferencing are
not set.
pysteps/io/importers.py