Closed johndpope closed 3 years ago
you can remove from inplace_abn import InPlaceABN, InPlaceABNSync, because it is not used below
seems intertwined - from inplace_abn import InPlaceABN, InPlaceABNSync BatchNorm2d = functools.partial(InPlaceABNSync, activation='identity')
There's some progress on branches from the original repo - going to try those
https://github.com/speedinghzl/CCNet/tree/pytorch-1.5 https://github.com/speedinghzl/CCNet/tree/pure-python
UPDATE - looks like it's working - just need to set CS_PATH
(torch) ➜ CCNet git:(master) ✗ ./run_local.sh
from networks.ccnet import Res_Deeplab
File "/home/jp/Documents/gitWorkspace/CCNet/networks/ccnet.py", line 15, in
from libs import InPlaceABN, InPlaceABNSync
File "/home/jp/Documents/gitWorkspace/CCNet/libs/init.py", line 1, in
from .bn import ABN, InPlaceABN, InPlaceABNWrappe
r, InPlaceABNSync, InPlaceABNSyncWrapper
File "/home/jp/Documents/gitWorkspace/CCNet/libs/bn.py", line 15, in
from .functions import inplace_abn, inplace_abn_sync
File "/home/jp/Documents/gitWorkspace/CCNet/libs/functions.py", line 5, in
from . import _ext
File "/home/jp/Documents/gitWorkspace/CCNet/libs/_ext/init.py", line 2, in
from torch.utils.ffi import _wrap_function
File "/home/jp/miniconda3/envs/torch/lib/python3.8/site-packages/torch/utils/ffi/init.py", line 1, in
raise ImportError("torch.utils.ffi is deprecated. Please use cpp extensions instead.")
ImportError: torch.utils.ffi is deprecated. Please use cpp extensions instead.
Traceback (most recent call last):
File "evaluate.py", line 14, in
from networks.ccnet import Res_Deeplab
File "/home/jp/Documents/gitWorkspace/CCNet/networks/ccnet.py", line 15, in
from libs import InPlaceABN, InPlaceABNSync
File "/home/jp/Documents/gitWorkspace/CCNet/libs/init.py", line 1, in
from .bn import ABN, InPlaceABN, InPlaceABNWrapper, InPlaceABNSync, InPlaceABNSyncWrapper
File "/home/jp/Documents/gitWorkspace/CCNet/libs/bn.py", line 15, in
from .functions import inplace_abn, inplace_abn_sync
File "/home/jp/Documents/gitWorkspace/CCNet/libs/functions.py", line 5, in
from . import _ext
File "/home/jp/Documents/gitWorkspace/CCNet/libs/_ext/init.py", line 2, in
from torch.utils.ffi import _wrap_function
File "/home/jp/miniconda3/envs/torch/lib/python3.8/site-packages/torch/utils/ffi/init.py", line 1, in
raise ImportError("torch.utils.ffi is deprecated. Please use cpp extensions instead.")
ImportError: torch.utils.ffi is deprecated. Please use cpp extensions instead.
Linux pop-os 5.8.0-7630-generic #32~1609193707~20.10~781bb80-Ubuntu SMP Tue Jan 5 21:29:56 UTC 2 x86_64 x86_64 x86_64 GNU/Linux Fri 05 Feb 2021 21:04:13 AEDT Traceback (most recent call last): File "train.py", line 16, in