Ask Your Question
1

trying to install dot2tex

asked 2011-11-22 22:09:49 +0100

this post is marked as community wiki

This post is a wiki. Anyone with karma >750 is welcome to improve it.

In trying to view a crystal graph, I had this sequence of exchanges with SAGE

sage: B=CrystalOfTableaux(['A',2],shape=[2,1])
sage: view(B)
evaluate

dot2tex not available.  Install after running 'sage -sh'
dot2tex not available.  Install after running 'sage -sh'
None

sage: -sh
evaluate


Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "_sage_input_14.py", line 10, in <module>
    exec compile(u'open("___code___.py","w").write("# -*- coding: utf-8 -*-\\n" + _support_.preparse_worksheet_cell(base64.b64decode("LXNo"),globals())+"\\n"); execfile(os.path.abspath("___code___.py"))
  File "", line 1, in <module>

  File "/tmp/tmp_8N1J9/___code___.py", line 2, in <module>
    exec compile(u'-sh
  File "", line 1, in <module>

AttributeError: Sh instance has no attribute '__neg__'

What did I do wrong trying to run the -sh command? And after I get it to run, do I just enter -i dot2tex?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2011-11-22 22:56:50 +0100

kcrisman gravatar image

I'm not sure whether this will work per se, but sage -sh is referring to quitting Sage and then starting it again from the command line with the -sh flag.


Everything after here didn't seem to work the way it should. I'm not sure what's going on. Mabe you really do have to install dot2tex 'manually'.

----------------------------------------------------------------------
| Sage Version 4.7.2, Release Date: 2011-10-29                       |
| Type notebook() for the GUI, and license() for information.        |
----------------------------------------------------------------------
sage: B=CrystalOfTableaux(['A',2],shape=[2,1])
sage: view(B)
dot2tex not available.  Install after running 'sage -sh'
sage: 
Exiting Sage (CPU time 0m0.13s, Wall time 1m20.10s).
new-host-2:$ sage -sh

Starting subshell with Sage environment variables set.
Be sure to exit when you are done and do not do anything
with other copies of Sage!

Bypassing shell configuration files ...

SAGE_ROOT=/Users/.../sage-4.7.2
(sage subshell) new-host-2:$

So presumably then you would install it.

Except, as you point out, this is now an optional package. So I do sage -i dot2tex, restart, and get...

----------------------------------------------------------------------
| Sage Version 4.7.2, Release Date: 2011-10-29                       |
| Type notebook() for the GUI, and license() for information.        |
----------------------------------------------------------------------
sage: B=CrystalOfTableaux(['A',2],shape=[2,1])
ERROR    Could not locate Graphviz binaries
ERROR    Failed to create xdotdata. Is Graphviz installed?
ERROR    Failed to parse the input data. Is it a valid dot file?
Try to input xdot data directly. Example:
    dot -Txdot file.dot | dot2tex > file.tex

If this does not work, check that you have an updated version of PyParsing and
Graphviz. Users have reported problems with old versions. You can also run
dot2tex in debug mode using the --debug option:
    dot2tex --debug file.dot
A file dot2tex.log will be written to the current directory with detailed
information useful for debugging.

Huh. So your problems are probably not at an end at this point. I'm sorry I can't help further!

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2011-11-22 22:09:49 +0100

Seen: 1,069 times

Last updated: Nov 22 '11