he-y/filter-pruning-geometric-median

Pruning filters and channels

zzqiuzz opened this issue · 2 comments

Hi! I have a puzzle that if you prune some filters in a specific layer, consequently you also need to prune channels in the next layer accordingly.But your codes just zerorize filters for each layer instead of considering the ordered relationship between two layers i.e. remove both filters in the ith layer and channels in the i+1th layer. Especially when the pruning process ends, if all targeted filters are pruned in the whole network, Error will be occured in the inference process, cause the reason overhead.

he-y commented

Please refer to the issue of my other repo: link.
The issue is about to delete zeros.
I will update the code in this repo shortly.

oh got it. Filters pruned in the previous layer generate zero featuremaps in the next layer,thus there's no impact pruning the relative channels in the filters of next layer. 3ks