From 0ff78c76cb74e76c8a6362495f32ab4a4022931c Mon Sep 17 00:00:00 2001
From: Neta Zmora <31280975+nzmora@users.noreply.github.com>
Date: Wed, 27 Mar 2019 00:00:51 +0200
Subject: [PATCH] utils.py - fix issue #203

Line 291 was coded twice (repeated), so removed one instance.
There's no functional effect (maybe a very small performance improvement).
---
 distiller/utils.py | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/distiller/utils.py b/distiller/utils.py
index 510a481..220ba3c 100755
--- a/distiller/utils.py
+++ b/distiller/utils.py
@@ -287,9 +287,6 @@ def sparsity_blocks(tensor, block_shape):
             )
     view1 = tensor.view(*view_dims)
 
-    # Next, compute the sums of each column (block)
-    block_sums = view1.abs().sum(dim=1)
-
     # Next, compute the sums of each column (block)
     block_sums = view1.abs().sum(dim=1)
     nonzero_blocks = len(torch.nonzero(block_sums))
-- 
GitLab