Geneformer / geneformer /mtl /__init__.py
ctheodoris's picture
Refactored token dictionary loading and encapsulated dictionary (#398)
beb62a4 verified
raw
history blame
254 Bytes
# ruff: noqa: F401
from .. import TOKEN_DICTIONARY_FILE
import pickle
def load_token_dictionary():
with open(TOKEN_DICTIONARY_FILE, 'rb') as f:
return pickle.load(f)
TOKEN_DICTIONARY = load_token_dictionary()
__all__ = ["TOKEN_DICTIONARY"]