Skip to content

Instantly share code, notes, and snippets.

MaxxVit(
(stem): Stem(
(conv1): Conv2d(3, 64, kernel_size=(3, 3), stride=(2, 2), padding=(1, 1), bias=False)
(norm1): BatchNormAct2d(
64, eps=1e-05, momentum=0.1, affine=True, track_running_stats=True
(drop): Identity()
(act): GELU()
)
(conv2): Conv2d(64, 64, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1), bias=False)
)
@rowhanm
rowhanm / verify_state.py
Last active September 27, 2022 00:05
Reproduce fsdp optimizer state save bug
'''
python==3.7.5
pytorch==1.12.0
fairscale==0.4.6 (can't upgrade due to being restricted to python3.7)
'''
import os
import torch
import torch.distributed as dist
import torch.multiprocessing as mp