Skip to content

Commit e4e0926

Browse files
author
Matthias Koeppe
committed
src/sage/plot/complex_plot.pyx: Use block tags
1 parent 322f19a commit e4e0926

File tree

1 file changed

+10
-9
lines changed

1 file changed

+10
-9
lines changed

src/sage/plot/complex_plot.pyx

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -669,12 +669,13 @@ def add_lightness_smoothing_to_rgb(rgb, delta):
669669
670670
We can call this on grids of values::
671671
672-
sage: import numpy as np # needs numpy
673-
sage: from sage.plot.complex_plot import add_lightness_smoothing_to_rgb # needs numpy
674-
sage: add_lightness_smoothing_to_rgb( # abs tol 1e-4 # needs numpy
672+
sage: # needs numpy
673+
sage: import numpy as np
674+
sage: from sage.plot.complex_plot import add_lightness_smoothing_to_rgb
675+
sage: add_lightness_smoothing_to_rgb( # abs tol 1e-4
675676
....: np.array([[[0, 0.25, 0.5]]]), np.array([[0.75]]))
676677
array([[[0.75 , 0.8125, 0.875 ]]])
677-
sage: add_lightness_smoothing_to_rgb( # abs tol 1e-4 # needs numpy
678+
sage: add_lightness_smoothing_to_rgb( # abs tol 1e-4
678679
....: np.array([[[0, 0.25, 0.5]]]), np.array([[0.75]]))
679680
array([[[0.75 , 0.8125, 0.875 ]]])
680681
"""
@@ -734,15 +735,15 @@ def add_contours_to_rgb(rgb, delta, dark_rate=0.5):
734735
EXAMPLES::
735736
736737
sage: # needs numpy
737-
sage: import numpy as np # needs numpy
738-
sage: from sage.plot.complex_plot import add_contours_to_rgb # needs numpy
739-
sage: add_contours_to_rgb(np.array([[[0, 0.25, 0.5]]]), # abs tol 1e-4 # needs numpy
738+
sage: import numpy as np
739+
sage: from sage.plot.complex_plot import add_contours_to_rgb
740+
sage: add_contours_to_rgb(np.array([[[0, 0.25, 0.5]]]), # abs tol 1e-4
740741
....: np.array([[0.75]]))
741742
array([[[0.25 , 0.625, 1. ]]])
742-
sage: add_contours_to_rgb(np.array([[[0, 0, 0]]]), # abs tol 1e-4 # needs numpy
743+
sage: add_contours_to_rgb(np.array([[[0, 0, 0]]]), # abs tol 1e-4
743744
....: np.array([[1]]))
744745
array([[[0.5, 0.5, 0.5]]])
745-
sage: add_contours_to_rgb(np.array([[[1, 1, 1]]]), # abs tol 1e-4 # needs numpy
746+
sage: add_contours_to_rgb(np.array([[[1, 1, 1]]]), # abs tol 1e-4
746747
....: np.array([[-0.5]]))
747748
array([[[0.75, 0.75, 0.75]]])
748749

0 commit comments

Comments
 (0)