resmlp_12.py 365 Bytes
Newer Older
yuguo960516's avatar
bloom  
yuguo960516 committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
from omegaconf import DictConfig
from libai.config import LazyCall
from libai.models import ResMLP


cfg = dict(
    img_size=224,
    patch_size=16,
    in_chans=3,
    embed_dim=384,
    depth=12,
    drop_rate=0.0,
    drop_path_rate=0.05,
    init_scale=0.1,
    num_classes=1000,
    loss_func=None,
)

cfg = DictConfig(cfg)

model = LazyCall(ResMLP)(cfg=cfg)