File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change 19
19
setup (
20
20
name = "stylecloud" ,
21
21
packages = ["stylecloud" ], # this must be the same as the name above
22
- version = "0.5.1 " ,
22
+ version = "0.5.2 " ,
23
23
description = "Python package + CLI to generate stylistic wordclouds, "
24
24
"including gradients and icon shapes!" ,
25
25
long_description = long_description ,
33
33
entry_points = {
34
34
"console_scripts" : ["stylecloud=stylecloud.stylecloud:stylecloud_cli" ],
35
35
},
36
- python_requires = ">=3.5 " ,
36
+ python_requires = ">=3.6 " ,
37
37
include_package_data = True ,
38
38
install_requires = [
39
39
"wordcloud" ,
Original file line number Diff line number Diff line change 3
3
import csv
4
4
import os
5
5
from PIL import Image
6
- from matplotlib .colors import makeMappingArray , to_rgb
6
+ from matplotlib .colors import to_rgb
7
7
import numpy as np
8
8
import fire
9
9
from shutil import rmtree
@@ -132,7 +132,7 @@ def gen_gradient_mask(
132
132
mask_array = np .float32 (mask_array )
133
133
134
134
palette_func = gen_palette (palette )
135
- gradient = np .array ( makeMappingArray ( size , palette_func . mpl_colormap ))
135
+ gradient = palette_func . mpl_colormap ( np .linspace ( 0.0 , 1.0 , size ))
136
136
137
137
# matplotlib color maps are from range of (0, 1). Convert to RGB.
138
138
gradient *= 255.0
You can’t perform that action at this time.
0 commit comments