MCPcopy Index your code
hub / github.com/matplotlib/matplotlib / test_figimage

Function test_figimage

lib/matplotlib/tests/test_image.py:72–83  ·  view source on GitHub ↗
(suppressComposite)

Source from the content-addressed store, hash-verified

70@pytest.mark.parametrize('suppressComposite', [False, True])
71@image_comparison(['figimage'], extensions=['png', 'pdf'], style='_classic_test')
72def test_figimage(suppressComposite):
73 fig = plt.figure(figsize=(2, 2), dpi=100)
74 fig.suppressComposite = suppressComposite
75 x, y = np.ix_(np.arange(100) / 100.0, np.arange(100) / 100)
76 z = np.sin(x**2 + y**2 - x*y)
77 c = np.sin(20*x**2 + 50*y**2)
78 img = z + c/5
79
80 fig.figimage(img, xo=0, yo=0, origin='lower')
81 fig.figimage(img[::-1, :], xo=0, yo=100, origin='lower')
82 fig.figimage(img[:, ::-1], xo=100, yo=0, origin='lower')
83 fig.figimage(img[::-1, ::-1], xo=100, yo=100, origin='lower')
84
85
86def test_image_python_io():

Callers

nothing calls this directly

Calls 2

figureMethod · 0.80
figimageMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…