Skip to content

Commit

Permalink
DOC: fix for typo
Browse files Browse the repository at this point in the history
DOC: fix for typo

DOC: turn to a 2x2 presentation

DOC: add tight layout

DOC: fix typo + remove extra spaces
  • Loading branch information
François Boulogne committed Jan 31, 2016
1 parent 0230375 commit 096bf3c
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 13 deletions.
30 changes: 18 additions & 12 deletions doc/examples/filters/plot_inpaint.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Inpainting
===========
Inpainting [1]_ is the process of reconstructing lost or deteriorated
parts of images and videos.
parts of images and videos.
The reconstruction is supposed to be performed in fully automatic way by
exploiting the information presented in non-damaged regions.
Expand All @@ -15,7 +15,7 @@
https://en.wikipedia.org/wiki/Inpainting
.. [2] Wikipedia. Biharmonic equation
https://en.wikipedia.org/wiki/Biharmonic_equation
.. [3] N.S.Hoang, S.B.Damelin, "On surface completion and image
.. [3] N.S.Hoang, S.B.Damelin, "On surface completion and image
inpainting by biharmonic functions: numerical aspects",
http://www.ima.umn.edu/~damelin/biharmonic
"""
Expand All @@ -41,18 +41,24 @@

image_result = inpaint.inpaint_biharmonic(image_defect, mask, multichannel=True)

fig, axes = plt.subplots(ncols=3, nrows=1)
fig, axes = plt.subplots(ncols=2, nrows=2)
ax0, ax1, ax2, ax3 = axes.ravel()

axes[0].set_title('Defected image')
axes[0].imshow(image_orig)
axes[0].set_xticks([]), axes[0].set_yticks([])
ax0.set_title('Original image')
ax0.imshow(image_orig)
ax0.set_xticks([]), ax0.set_yticks([])

axes[1].set_title('Defect mask')
axes[1].imshow(mask, cmap=plt.cm.gray)
axes[1].set_xticks([]), axes[1].set_yticks([])
ax1.set_title('Mask')
ax1.imshow(mask, cmap=plt.cm.gray)
ax1.set_xticks([]), ax1.set_yticks([])

axes[2].set_title('Inpainted image')
axes[2].imshow(image_result)
axes[2].set_xticks([]), axes[2].set_yticks([])
ax2.set_title('Defected image')
ax2.imshow(image_defect)
ax2.set_xticks([]), ax2.set_yticks([])

ax3.set_title('Inpainted image')
ax3.imshow(image_result)
ax3.set_xticks([]), ax3.set_yticks([])

plt.tight_layout()
plt.show()
2 changes: 1 addition & 1 deletion doc/examples/filters/plot_restoration.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
This algorithm has a self-tuned regularisation parameters based on
data learning. This is not common and based on the following
publication. The algorithm is based on a iterative Gibbs sampler that
draw alternatively samples of posterior conditionnal law of the image,
draw alternatively samples of posterior conditional law of the image,
the noise power and the image frequency power.
.. [1] François Orieux, Jean-François Giovannelli, and Thomas
Expand Down

0 comments on commit 096bf3c

Please sign in to comment.