nyukat / GMIC

An interpretable classifier for high-resolution breast cancer screening images utilizing weakly supervised localization
https://doi.org/10.1016/j.media.2020.101908
GNU Affero General Public License v3.0
163 stars 48 forks source link

Missing parameter? #29

Closed DrJohnCa closed 1 year ago

DrJohnCa commented 1 year ago

When loading models I get:

_IncompatibleKeys(missing_keys=[], unexpected_keys=['shared_rep_filter.weight'])

It looks like a 256x256x4x4 (4x4 conv?) weight but not implemented in the repo. Any chance this can be added?

seyiqi commented 1 year ago

Hi @DrJohnCa ,

Indeed, shared_rep_filter is a parameter that is not used in the GMIC. Some weight files might contain it. However, when loading the weight, if you set strict=False in the module.load_state_dict function as exemplified in this line in the run_mode.py script, the problem should be resolved.

Let me know if you have any other questions.

Best, Artie