x3d / configuration_x3d.py
zhong-al
Revert changes
ba918ab
raw
history blame
359 Bytes
from transformers import PretrainedConfig
from .cfg import load_config
class X3DConfig(PretrainedConfig):
model_type = "x3d"
def __init__(self, **kwargs):
super().__init__(**kwargs)
path = kwargs.get("path", None)
gpu_num = kwargs.get("gpu_num", 0)
self.cfg = load_config(path)
self.cfg.NUM_GPUS = gpu_num