Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

人像在b2分支上做SOC #35

Open
buptlihang opened this issue Jun 22, 2021 · 0 comments
Open

人像在b2分支上做SOC #35

buptlihang opened this issue Jun 22, 2021 · 0 comments

Comments

@buptlihang
Copy link
Contributor

buptlihang commented Jun 22, 2021

在新的任务上SOC一般来说需要修改以下几个配置项

  • 修改数据集路径config.sample_path
  • 修改分类数config.cls_num
  • 修改类别权重config.classes_weight
  • 修改mean, std config.mean和config.std

训练时train.py可修改项

···
backup_detail_loss = boundaries * F.cross_entropy(pred_detail, backup_detail.max(1)[1], weight=self.config.classes_weight, reduction='none')
···
backup_fusion_loss = boundaries * F.cross_entropy(pred_fusion, backup_fusion.max(1)[1], weight=self.config.classes_weight, reduction='none')
···
self.config.loss = 5*soc_semantic_loss + backup_detail_loss + backup_fusion_loss

两个loss的weight参数可有可无,也可随机组合。soc_semantic_loss 前的系数可改动

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant