GSCNN icon indicating copy to clipboard operation
GSCNN copied to clipboard

ModuleNotFoundError: No module named 'encoding'

Open xjtu19 opened this issue 2 years ago • 2 comments

When I run 'python train.py --evaluate --snapshot checkpoints/best_cityscapes_checkpoint.pth', the bug occurs as:

Traceback (most recent call last): File "train.py", line 381, in main() File "train.py", line 128, in main assert_and_infer_cfg(args) File "E:\Program Files\Anaconda3\envs\newName\E20220227\GSCNN\config.py", line 86, in assert_and_infer_cfg import encoding ModuleNotFoundError: No module named 'encoding'

Then I try to install 'encoding' or search the module 'encoding' in google, but I found nothing. Why does this bug occur? And, how can I settle this problem?

xjtu19 avatar Jun 02 '22 03:06 xjtu19

May help you # import encoding __C.MODEL.BN = 'syncnorm' __C.MODEL.BNFUNC = torch.nn.BatchNorm2d # __C.MODEL.BNFUNC = encoding.nn.BatchNorm2d I know this in a website: https://zhuanlan.zhihu.com/p/428556534

John-cjj avatar Nov 04 '22 03:11 John-cjj

Mabe you can try install "torch-encoding". I use that saving.

eeex-diouf avatar Jan 20 '24 07:01 eeex-diouf