Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AttributeError: module 'torch.nn' has no attribute 'Conv64d' -- Can you share your full list of dependencies? #3

Open
blutjens opened this issue Jul 13, 2020 · 0 comments

Comments

@blutjens
Copy link

Do you know how to fix the error AttributeError: module 'torch.nn' has no attribute 'Conv64d' ? Would you be able to print all your dependencies?

Specifically, I assume there's a mismatch in one of the following modules; My setup is:

  • pytorch 0.4.1post2
  • torchvision 0.2.1
  • cudatoolkit 10.1
  • Python 3.6.10
  • unet 0.2.0

Thank you very much!

---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
<ipython-input-1-9dd2f6c8fecf> in <module>
     26                             shuffle=True)
     27 
---> 28 model = UNet(3,3,64).cuda()
     29 """
     30 

/opt/conda/envs/eie-floods-seg-tst2/lib/python3.6/site-packages/unet/unet.py in __init__(self, in_channels, out_classes, dimensions, num_encoding_blocks, out_channels_first_layer, normalization, pooling_type, upsampling_type, preactivation, residual, padding, padding_mode, activation, initial_dilation, dropout)
     48             activation=activation,
     49             initial_dilation=initial_dilation,
---> 50             dropout=dropout,
     51         )
     52 

/opt/conda/envs/eie-floods-seg-tst2/lib/python3.6/site-packages/unet/encoding.py in __init__(self, in_channels, out_channels_first, dimensions, pooling_type, num_encoding_blocks, normalization, preactivation, residual, padding, padding_mode, activation, initial_dilation, dropout)
     40                 activation=activation,
     41                 dilation=self.dilation,
---> 42                 dropout=dropout,
     43             )
     44             is_first_block = False

/opt/conda/envs/eie-floods-seg-tst2/lib/python3.6/site-packages/unet/encoding.py in __init__(self, in_channels, out_channels_first, dimensions, normalization, pooling_type, preactivation, is_first_block, residual, padding, padding_mode, activation, dilation, dropout)
    106             activation=activation,
    107             dilation=dilation,
--> 108             dropout=dropout,
    109         )
    110 

/opt/conda/envs/eie-floods-seg-tst2/lib/python3.6/site-packages/unet/conv.py in __init__(self, dimensions, in_channels, out_channels, normalization, kernel_size, activation, preactivation, padding, padding_mode, dilation, dropout)
     28             padding = total_padding // 2
     29 
---> 30         conv_class = getattr(nn, f'Conv{dimensions}d')
     31         conv_layer = conv_class(
     32             in_channels,

AttributeError: module 'torch.nn' has no attribute 'Conv64d'
@blutjens blutjens changed the title AttributeError: module 'torch.nn' has no attribute 'Conv64d' -- Can you share your full list of dependencies AttributeError: module 'torch.nn' has no attribute 'Conv64d' -- Can you share your full list of dependencies? Jul 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant