zyxu1996

Results 25 comments of zyxu1996

Thank you for your sharing.

Sorry, this code is the basic version and there are many errors. This error may be because the 'model' folder was not created in advance.

Thank you for your praise of our work. All results in Table 11 were evaluated in the test set according to official recommendations. The results of Unet, FPN, etc. are...

During the model inference phase, the `fvcore` package in `tools` folder is used to calculate parameters. Of course, you can take them as trainable parameters. They are usually the same....

This code will only evaluate the model in the last three epochs. See here `test_epoch = args2.end_epoch - 3`

1, If you just run a single picture, the dataloader is not necessary. You can read the image via using cv2.imread, and then transform it to tensor with the shape...

如果cpu用对了,不应该会掉点的。你看看是不是读进来的tensor img没有做normalization ---Original--- From: ***@***.***> Date: Thu, Aug 11, 2022 22:08 PM To: ***@***.***>; Cc: ***@***.******@***.***>; Subject: Re: [zyxu1996/Efficient-Transformer] How can i predict single picturewith trained models (Issue #3) I...

还有,确保best_weight.pkl能正常读进来,这个权重前面有很多model.module这样的前缀,可以删除或增加,保持和model需要的权重的key一致 ------------------ 原始邮件 ------------------ 发件人: "徐志勇" ***@***.***>; 发送时间: 2022年8月11日(星期四) 晚上10:20 ***@***.***>; 主题: Re: [zyxu1996/Efficient-Transformer] How can i predict single picturewith trained models (Issue #3) 如果cpu用对了,不应该会掉点的。你看看是不是读进来的tensor img没有做normalization ---Original--- From: ***@***.***> Date: Thu, Aug 11, 2022...

权重其实就是键值对,你可以按下面这样改一下读进来的key。根据你实际的key和模型需要的key,对model,module这些前缀进行修改。 checkpoint = {k.replace('model.', 'module.'): v for k, v in checkpoint.items()}

看起来你需要的是module.backbone.xx,但是读进来是module.module.backbone.xx。 是不是原本这句话,checkpoint = {k.replace('model.', 'module.'): v for k, v in checkpoint.items()},把model变成module了,试试换成checkpoint = {k.replace('model.', ''): v for k, v in checkpoint.items()}