[python-dtcwt] 319/497: plotting: update overlay_quiver_DTCWT to use plot directive

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Tue Jul 21 18:06:21 UTC 2015


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to branch debian/sid
in repository python-dtcwt.

commit 5cd9b8d2b65ed29e3c60e917853b428503cc7a87
Author: Rich Wareham <rjw57 at cam.ac.uk>
Date:   Sat Feb 1 12:10:39 2014 +0000

    plotting: update overlay_quiver_DTCWT to use plot directive
---
 dtcwt/plotting.py | 28 ++++++++--------------------
 1 file changed, 8 insertions(+), 20 deletions(-)

diff --git a/dtcwt/plotting.py b/dtcwt/plotting.py
index d7c8c6a..7f332e3 100644
--- a/dtcwt/plotting.py
+++ b/dtcwt/plotting.py
@@ -1,20 +1,6 @@
 """
 Convenience functions for plotting DTCWT-related objects.
 
-The usage examples for functions in this module assume the following boilerplate:
-
-.. ipython::
-
-    In [0]: from pylab import *
-
-    In [0]: import datasets
-
-    In [0]: import dtcwt.plotting as dtcwtplt
-
-    In [1]: import dtcwt.backend.backend_numpy as backend
-
-    In [0]: transform2d = backend.Transform2d()
-
 """
 
 import numpy as np
@@ -43,16 +29,18 @@ def overlay_quiver_DTCWT(image, vectorField, level, offset):
 
     Usage example:
 
-    .. ipython::
+    .. plot::
+        :include-source: true
 
-        In [0]: lena = datasets.lena()
+        import dtcwt.plotting as plotting
+        import dtcwt.backend.backend_numpy as backend
 
-        In [0]: lena_t = transform2d.forward(lena, nlevels=3)
+        lena = datasets.lena()
 
-        In [0]: figure()
+        transform2d = backend.Transform2d()
+        lena_t = transform2d.forward(lena, nlevels=3)
 
-        @savefig gen-overlay_quiver_DTCWT.png
-        In [0]: dtcwtplt.overlay_quiver_DTCWT(lena, lena_t.subbands[-1], 3, 0.5)
+        plotting.overlay_quiver_DTCWT(lena, lena_t.subbands[-1], 3, 0.5)
 
     .. codeauthor:: R. Anderson, 2005 (MATLAB)
     .. codeauthor:: S. C. Forshaw, 2014 (Python)

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/python-dtcwt.git



More information about the debian-science-commits mailing list