Update davit.py

pull/1630/head
Fredo Guan 3 years ago
parent 128d9729c3
commit 792564543c

@ -37,7 +37,7 @@ __all__ = ['DaViT']
class MySequential(nn.Sequential): class MySequential(nn.Sequential):
def forward(self, inputs : Tuple[Tensor, Tuple[int, int]]): def forward(self, inputs : Tuple[Tensor, Tuple[int, int]]):
for module in self._modules.values(): for module in self:
#if type(inputs) == tuple: #if type(inputs) == tuple:
inputs = module(*inputs) inputs = module(*inputs)
#else: #else:

Loading…
Cancel
Save