Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0c6a533 commit 0005ab4Copy full SHA for 0005ab4
1 file changed
examples/pylab_examples/agg_buffer_to_array.py
@@ -12,7 +12,7 @@
12
# grab the pixel buffer and dump it into a numpy array
13
buf = fig.canvas.buffer_rgba()
14
l, b, w, h = fig.bbox.bounds
15
-X = np.frombuffer(buf, np.uint8)
+X = np.fromstring(buf, np.uint8)
16
X.shape = h,w,4
17
18
# now display the array X as an Axes in a new figure
0 commit comments