def unpack_model_tar(model_ckpt_path: pathlib.Path) -> pathlib.Path:
    """
    Untar a tar.gz object

    Parameters
    ----------
    model_ckpt_path: pathlib.Path
        A local file system path that points to the `tar.gz` archive containing the model ckpts.
    Returns
    -------
    pathlib.Path
        The directory that contains the uncompress model checkpoint files
    """
    model_dir = model_ckpt_path.parent
    # untar the model
    tar = tarfile.open(str(model_ckpt_path))
    tar.extractall(model_dir)
    tar.close()
    return model_dir

    Untar a tar.gz object

    Parameters
    ----------
    model_ckpt_path: pathlib.Path
        A local file system path that points to the `tar.gz` archive containing the model ckpts.
    Returns
    -------
    pathlib.Path
        The directory that contains the uncompress model checkpoint files
    
benchmarks/transformers/masked_language_modeling.py