def __init__(self, filename=None):
        self.filename = None
        if filename:
            self.load(filename)
def local_rank(self) -> int:
        return 0 if self._local_rank is None else self._local_rank