def _load_assembly_mapping_data(filename):
        """ Load assembly mapping data.

        Parameters
        ----------
        filename : str
            path to compressed archive with assembly mapping data

        Returns
        -------
        assembly_mapping_data : dict
            dict of assembly maps if loading was successful, else None

        Notes
        -----
        Keys of returned dict are chromosomes and values are the corresponding assembly map.
        """
        try:
            assembly_mapping_data = {}

            with tarfile.open(filename, "r") as tar:
                # http://stackoverflow.com/a/2018576
                for member in tar.getmembers():
                    if ".json" in member.name:
                        with tar.extractfile(member) as tar_file:
                            tar_bytes = tar_file.read()
                        # https://stackoverflow.com/a/42683509/4727627
                        assembly_mapping_data[member.name.split(".")[0]] = json.loads(
                            tar_bytes.decode("utf-8")
                        )

            return assembly_mapping_data
        except Exception as err:
            print(err)
            return None
Load assembly mapping data.

        Parameters
        ----------
        filename : str
            path to compressed archive with assembly mapping data

        Returns
        -------
        assembly_mapping_data : dict
            dict of assembly maps if loading was successful, else None

        Notes
        -----
        Keys of returned dict are chromosomes and values are the corresponding assembly map.