Hi family, in new using fastai and i have some troubles coding. Here is my code:
In the last lane of code i got this error
TypeError: list is not a Module subclass
What’s im doing wrong?
Hi family, in new using fastai and i have some troubles coding. Here is my code:
In the last lane of code i got this error
TypeError: list is not a Module subclass
What’s im doing wrong?
bn_drop_lin
returns a list of layers and nn.Sequential needs layers seperated by ,
. You can use:
model = nn.Sequential(
# layers
*bn_drop_lin(512, 3, True, 0.5)
)
Just add a *
.
But for instance conv_layer also return a list. Why its working without *?
conv_layer returns nn.Sequential layer which has layers inside it but bn_drop_lin returns a list. Check the source code on github.