Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Animation module errors out when using Python3 #1891

Copy link
Copy link
Closed
@aignas

Description

@aignas
Issue body actions

I used the double pendulum example and it did not work with the latest version of Matplotlib and Py3k on Arch Linux. However, it worked with Python2.7. I was using

#! /usr/bin/env python3

as my shebang in the script.

The exact script which I used is here: https://gist.github.com/gns-ank/5347084#file-double_pendulum-py

The error log:

Traceback (most recent call last):
  File "./double_pendulum_animated.py", line 88, in <module>
    ani.save('double_pendulum.mp4', fps=15)
  File "/usr/lib/python3.3/site-packages/matplotlib/animation.py", line 616, in save
    writer.grab_frame()
  File "/usr/lib/python3.3/site-packages/matplotlib/animation.py", line 200, in grab_frame
    dpi=self.dpi)
  File "/usr/lib/python3.3/site-packages/matplotlib/figure.py", line 1371, in savefig
    self.canvas.print_figure(*args, **kwargs)
  File "/usr/lib/python3.3/site-packages/matplotlib/backend_bases.py", line 2101, in print_figure
    self.figure.dpi = origDPI
  File "/usr/lib/python3.3/site-packages/matplotlib/figure.py", line 375, in _set_dpi
    self.dpi_scale_trans.clear().scale(dpi, dpi)
  File "/usr/lib/python3.3/site-packages/matplotlib/transforms.py", line 1751, in clear
    self._mtx = np.identity(3)
  File "/usr/lib/python3.3/site-packages/numpy/core/numeric.py", line 1913, in identity
    from numpy import eye
  File "<frozen importlib._bootstrap>", line 1609, in _handle_fromlist
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xff in position 0: invalid start byte

Press ENTER or type command to continue

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.