Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 5425315

Browse files
committed
FIX
1 parent 47145d1 commit 5425315

File tree

2 files changed

+27
-2
lines changed

2 files changed

+27
-2
lines changed

doc/sphinxext/redirect_from.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,5 @@ def _generate_redirects(app, exception):
8383
else:
8484
p.parent.mkdir(parents=True, exist_ok=True)
8585
with p.open("x") as file:
86-
logger.info('making refresh html file: ' + k +
87-
' redirect to ' + v)
86+
logger.info(f'making refresh html file: {k} redirect to {v}')
8887
file.write(HTML_TEMPLATE.format(v=v))
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
"""
2+
===============
3+
Subplot Toolbar
4+
===============
5+
6+
Matplotlib has a toolbar available for adjusting subplot spacing.
7+
"""
8+
import matplotlib.pyplot as plt
9+
import numpy as np
10+
11+
12+
# Fixing random state for reproducibility
13+
np.random.seed(19680801)
14+
15+
fig, axs = plt.subplots(2, 2)
16+
17+
axs[0, 0].imshow(np.random.random((100, 100)))
18+
19+
axs[0, 1].imshow(np.random.random((100, 100)))
20+
21+
axs[1, 0].imshow(np.random.random((100, 100)))
22+
23+
axs[1, 1].imshow(np.random.random((100, 100)))
24+
25+
plt.subplot_tool()
26+
plt.show()

0 commit comments

Comments
 (0)