Git Product home page Git Product logo

Comments (4)

sfzhang15 avatar sfzhang15 commented on July 21, 2024

@HansolEom
You can refer to this. If you have any questions, please feel free to contact us.

from atss.

HansolEom avatar HansolEom commented on July 21, 2024

@HansolEom
You can refer to this. If you have any questions, please feel free to contact us.

Thank you for your reply.

from atss.

HansolEom avatar HansolEom commented on July 21, 2024

@HansolEom
You can refer to this. If you have any questions, please feel free to contact us.

Thank you for your reply.

Traceback (most recent call last):
File "tools/train_net.py", line 183, in
main()
File "tools/train_net.py", line 179, in main
model = train(cfg, args.local_rank, args.distributed)
File "tools/train_net.py", line 59, in train
extra_checkpoint_data = checkpointer.load(cfg.MODEL.WEIGHT)
File "/workspace/ATSS/atss_core/utils/checkpoint.py", line 63, in load
self._load_model(checkpoint)
File "/workspace/ATSS/atss_core/utils/checkpoint.py", line 99, in _load_model
load_state_dict(self.model, checkpoint.pop("model"))
File "/workspace/ATSS/atss_core/utils/model_serialization.py", line 82, in load_state_dict
model.load_state_dict(model_state_dict)
File "/opt/conda/envs/ATSS/lib/python3.7/site-packages/torch/nn/modules/module.py", line 777, in load_state_dict
self.class.name, "\n\t".join(error_msgs)))
RuntimeError: Error(s) in loading state_dict for DistributedDataParallel:
size mismatch for module.rpn.head.cls_logits.weight: copying a param with shape torch.Size([80, 256, 3, 3]) from checkpoint, the shape in current model is torch.Size([23, 256, 3, 3]).
size mismatch for module.rpn.head.cls_logits.bias: copying a param with shape torch.Size([80]) from checkpoint, the shape in current model is torch.Size([23]).

I haven't solved this problem.
I want to learn about 23 classes. But I think I got an error loading 80 models already learned. I want to use pretraine resnet. Is there a way?

from atss.

sfzhang15 avatar sfzhang15 commented on July 21, 2024

@HansolEom
If your 23 classes is the subset of COCO 80 classes, you can chose the 23 channels from the 80 channels of the classification prediction layer and save this model to use. If not, you can drop the weights of the classification prediction layer and save it to use as pretrain.

from atss.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.