What's exactly happening in this part? Can you 'please' explain?
Sayantan17 opened this issue · comments
Sayantan17 commented
nn.Sequential(
block(in_channels , out_channels, *args, **kwargs, downsampling=downsampling),
*[block(out_channels * block.expansion,
out_channels, downsampling=1, *args, **kwargs) for _ in range(n - 1)]
)
Francesco Saverio Zuppichini commented
Hi, "please" is the magic word. This is a python inline for loop where I create one block after the other. Just google "inline for loop in python"