From a51f5873437427cad29dabe1839035dbebe17077 Mon Sep 17 00:00:00 2001 From: deeppomf Date: Sun, 21 Oct 2018 04:27:16 -0400 Subject: [PATCH] remove unnecessary initializations --- decensor.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/decensor.py b/decensor.py index e6b78f0..20ff19c 100644 --- a/decensor.py +++ b/decensor.py @@ -79,7 +79,6 @@ class Decensor(): width, height = ori.size #save the alpha channel if the image has an alpha channel has_alpha = False - alpha_channel = None if (ori.mode == "RGBA"): has_alpha = True alpha_channel = np.asarray(ori)[:,:,3] @@ -90,7 +89,6 @@ class Decensor(): ori_array = np.array(ori_array / 255.0) ori_array = np.expand_dims(ori_array, axis = 0) - mask = None if self.is_mosaic: #if mosaic decensor, mask is empty mask = np.ones(ori_array.shape, np.uint8)