Pep8 fixes.

This commit is contained in:
Steven Silvester
2012-08-05 23:42:44 -05:00
parent ea850757c8
commit 715271bde9
3 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -26,6 +26,7 @@ import matplotlib.pyplot as plt
import numpy as np
def plot_img_and_hist(img, axes, bins=256):
"""Plot an image along with its histogram and cumulative histogram.
@@ -88,4 +89,3 @@ ax_cdf.set_ylabel('Fraction of total intensity')
# prevent overlap of y-axis labels
plt.subplots_adjust(wspace=0.4)
plt.show()
+1 -1
View File
@@ -218,7 +218,7 @@ def adapthist(image, nx=8, ny=8, clip_limit=0.01, nbins=256, out_range='full'):
-------
out - np.ndarray :
equalized image - may be a different shape than the original
Notes
-----
* The underlying algorithm relies on an image whose rows and columns are even multiples of
+1 -1
View File
@@ -96,7 +96,7 @@ def test_adapthist_float():
adapted = exposure.adapthist(img, nx=10, ny=9, clip_limit=0.01,
nbins=128, out_range='original')
assert_almost_equal = np.testing.assert_almost_equal
assert_almost_equal(adapted.min() , img.min())
assert_almost_equal(adapted.min(), img.min())
assert_almost_equal(adapted.min(), img.min())
assert img.shape == adapted.shape
assert peak_snr(img, adapted) > 136