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

Problem abput inplace_abn setup #261

Open
666shaw opened this issue Mar 26, 2022 · 1 comment
Open

Problem abput inplace_abn setup #261

666shaw opened this issue Mar 26, 2022 · 1 comment

Comments

@666shaw
Copy link

666shaw commented Mar 26, 2022

when I tried to set up the inplace_abn, it warmed me up that 'your setuptools is too old (<12)
,setuptools_scm functionality is degraded'. I do not how to deal with this problem. If you have any ideas, please tell me! Thank you!!!
Here are my settings:
ninja =1.10.2.3
pytorch =1.7.1

@666shaw
Copy link
Author

666shaw commented Mar 26, 2022

I though the author had given the answer in the .py file in models->bn_helpers.py, as follow:
import torch
import functools
  |  
  | if torch.version.startswith('0'):
  | from .sync_bn.inplace_abn.bn import InPlaceABNSync
  | BatchNorm2d = functools.partial(InPlaceABNSync, activation='none')
  | BatchNorm2d_class = InPlaceABNSync
  | relu_inplace = False
  | else:
  | BatchNorm2d_class = BatchNorm2d = torch.nn.SyncBatchNorm
  | relu_inplace = True

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