do not import matplotlib in brother_ql.reader
This commit is contained in:
@@ -7,7 +7,6 @@ import sys
|
||||
|
||||
from PIL import Image
|
||||
import numpy as np
|
||||
from matplotlib import pyplot as plt
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
@@ -280,6 +279,7 @@ class BrotherQLReader(object):
|
||||
array = np.fliplr(array)
|
||||
im = Image.fromarray(array)
|
||||
im = im.point(lambda x: 0 if x == 1 else 255, '1') # -> Monocolor and invert
|
||||
#from matplotlib import pyplot as plt
|
||||
#plt.imshow(im)
|
||||
#plt.show()
|
||||
img_name = 'page{:04d}.png'.format(self.page)
|
||||
|
||||
Reference in New Issue
Block a user