BerkeleyAutomation/visualization

Visualization Import Errors

Closed this issue · 1 comments

I get the following errors whenever i try to import anything from visualization module:
I tried reinstalling/upgrading/downgrading , but no luck.
Traceback (most recent call last):
File "render_images.py", line 19, in
from visualization import Visualizer2D as vis
File "/home/ahmad3/anaconda2/envs/gpd/lib/python2.7/site-packages/visualization/init.py", line 3, in
from .visualizer3d import Visualizer3D
File "/home/ahmad3/anaconda2/envs/gpd/lib/python2.7/site-packages/visualization/visualizer3d.py", line 9, in
from pyrender import Scene, Mesh, Viewer, Node, MetallicRoughnessMaterial, TextAlign
File "/home/ahmad3/anaconda2/envs/gpd/lib/python2.7/site-packages/pyrender/init.py", line 12, in
from .viewer import Viewer
File "/home/ahmad3/anaconda2/envs/gpd/lib/python2.7/site-packages/pyrender/viewer.py", line 36, in
class Viewer(pyglet.window.Window):
File "/home/ahmad3/anaconda2/envs/gpd/lib/python2.7/site-packages/pyglet/init.py", line 335, in getattr
import(import_name)
File "/home/ahmad3/anaconda2/envs/gpd/lib/python2.7/site-packages/pyglet/window/init.py", line 131, in
import pyglet.window.event
File "/home/ahmad3/anaconda2/envs/gpd/lib/python2.7/site-packages/pyglet/window/event.py", line 74
key.symbol_string(symbol), key.modifiers_string(modifiers)), file=self.file)

mjd3 commented

Hey @saadehmd, I think the issue here lies with pyglet; as stated here: "Pyglet runs under Python 3.5+." You appear to be running Python 2.7. Your options are to either downgrade your pyrender/pyglet versions so that they are compatible with your version of Python or upgrade to Python 3.5+ (I'd recommend the latter if possible, since support for Python 2.7 officially was ended this January).