Ver código fonte

mean and std computations overs denoised images

Jérôme BUISINE 4 anos atrás
pai
commit
ae4b2f9c6a
1 arquivos alterados com 9 adições e 9 exclusões
  1. 9 9
      data_attributes.py

+ 9 - 9
data_attributes.py

@@ -38,15 +38,15 @@ def get_image_features(data_type, block):
         # compute all filters statistics
         def get_stats(arr, I_filter):
 
-            e1       = np.abs(arr - I_filter)
-            L        = np.array(e1)
-            mu0      = np.mean(L)
-            A        = L - mu0
-            H        = A * A
-            E        = np.sum(H) / (img_width * img_height)
-            P        = np.sqrt(E)
-
-            return mu0, P
+            # e1       = np.abs(arr - I_filter)
+            # L        = np.array(e1)
+            # mu0      = np.mean(L)
+            # A        = L - mu0
+            # H        = A * A
+            # E        = np.sum(H) / (img_width * img_height)
+            # P        = np.sqrt(E)
+
+            return np.mean(I_filter), np.std(I_filter)
 
         stats = []