Commit 37c8f217 authored by Alexander Alekhin's avatar Alexander Alekhin

Merge pull request #9076 from mshabunin:fix-doc-from-mail

parents c8783f3e 2a33f452
...@@ -35,7 +35,7 @@ img = cv2.imread('wiki.jpg',0) ...@@ -35,7 +35,7 @@ img = cv2.imread('wiki.jpg',0)
hist,bins = np.histogram(img.flatten(),256,[0,256]) hist,bins = np.histogram(img.flatten(),256,[0,256])
cdf = hist.cumsum() cdf = hist.cumsum()
cdf_normalized = cdf * hist.max()/ cdf.max() cdf_normalized = cdf * float(hist.max()) / cdf.max()
plt.plot(cdf_normalized, color = 'b') plt.plot(cdf_normalized, color = 'b')
plt.hist(img.flatten(),256,[0,256], color = 'r') plt.hist(img.flatten(),256,[0,256], color = 'r')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment