U2PL icon indicating copy to clipboard operation
U2PL copied to clipboard

error in running u2pl wth AEL

Open prantikhowlader opened this issue 3 years ago • 1 comments

HI When running U2PL with AEL. I am getting this error: Traceback (most recent call last): File "../../train.py", line 967, in main() File "../../train.py", line 74, in main model = ModelBuilder(cfg["net"]) File "/mnt/data10/shared/ironman/final_aaai23/aaai22/U2PL/u2pl/models/model_helper.py", line 15, in init self.encoder = self._build_encoder(net_cfg["encoder"]) File "/mnt/data10/shared/ironman/final_aaai23/aaai22/U2PL/u2pl/models/model_helper.py", line 29, in _build_encoder encoder = self._build_module(enc_cfg["type"], enc_cfg["kwargs"]) File "/mnt/data10/shared/ironman/final_aaai23/aaai22/U2PL/u2pl/models/model_helper.py", line 47, in _build_module return cls(**kwargs) File "/mnt/data10/shared/ironman/final_aaai23/aaai22/U2PL/u2pl/models/resnet.py", line 370, in resnet101 state_dict = torch.load(model_url) File "/home/phowlader/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/serialization.py", line 608, in load return _legacy_load(opened_file, map_location, pickle_module, **pickle_load_args) File "/home/phowlader/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/serialization.py", line 777, in _legacy_load magic_number = pickle_module.load(f, **pickle_load_args) _pickle.UnpicklingError: could not find MARK /home/phowlader/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/distributed/launch.py:186: FutureWarning: The module torch.distributed.launch is deprecated

I am using the same resnet 101 weights that you have provided as pickle file

prantikhowlader avatar Aug 12 '22 00:08 prantikhowlader

Can you please tell me what is the issue so I can run it.

prantikhowlader avatar Aug 12 '22 00:08 prantikhowlader

Did you change the model_url for ResNet-101? https://github.com/Haochen-Wang409/U2PL/blob/main/u2pl/models/resnet.py#L20

Haochen-Wang409 avatar Aug 16 '22 05:08 Haochen-Wang409

Yes I have changed the model url. But I still get this error. Can you please help

prantikhowlader avatar Aug 22 '22 01:08 prantikhowlader

It seems that something went wrong with the pre-trained ResNet-101. Please re-download the checkpoint and try again.

Haochen-Wang409 avatar Aug 22 '22 05:08 Haochen-Wang409