From e71e01bb90a831b8c540dbf841bdbc502359a3ff Mon Sep 17 00:00:00 2001
From: wanggh <wangguohua_key@163.com>
Date: Mon, 27 Dec 2021 11:51:52 +0800
Subject: [PATCH] fix bugs

---
 ...er_rcnn_r152_fpn_1x_distill_faster_rcnn_r50_fpn_1x_coco.py | 4 ++--
 tools/gen_checkpoint.py                                       | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/configs/distillers/mimic_backbone/mb_faster_rcnn_r152_fpn_1x_distill_faster_rcnn_r50_fpn_1x_coco.py b/configs/distillers/mimic_backbone/mb_faster_rcnn_r152_fpn_1x_distill_faster_rcnn_r50_fpn_1x_coco.py
index 2676c376..302da9cf 100644
--- a/configs/distillers/mimic_backbone/mb_faster_rcnn_r152_fpn_1x_distill_faster_rcnn_r50_fpn_1x_coco.py
+++ b/configs/distillers/mimic_backbone/mb_faster_rcnn_r152_fpn_1x_distill_faster_rcnn_r50_fpn_1x_coco.py
@@ -51,5 +51,5 @@ distiller = dict(
                    ]
     )
 
-student_cfg = 'configs/faster_rcnn/faster_rcnn_r152_fpn_1x_coco.py'
-teacher_cfg = 'configs/faster_rcnn/faster_rcnn_r50_fpn_1x_coco.py'
+student_cfg = 'configs/faster_rcnn/faster_rcnn_r50_fpn_1x_coco.py'
+teacher_cfg = 'configs/faster_rcnn/faster_rcnn_r152_fpn_1x_coco.py'
diff --git a/tools/gen_checkpoint.py b/tools/gen_checkpoint.py
index b3ba6d64..86572ea9 100644
--- a/tools/gen_checkpoint.py
+++ b/tools/gen_checkpoint.py
@@ -28,7 +28,7 @@ def merge(backbone, neck, head):
     target['state_dict'] = dict()
     tsd = target['state_dict']
     bsd = backbone['state_dict']
-    nsd = backbone['state_dict']
+    nsd = neck['state_dict']
     hsd = head['state_dict']
     for key in bsd.keys():
         if 'backbone' in key:
-- 
GitLab