我希望能够以 PNG 格式保存输出并安装了 Graphviz。它仍然提示说 Graphviz 没有安装:
The output format 'output.png' is currently not available. Please install 'Graphviz' to have other output formats than 'dot' or 'vcg'.
最佳答案
正如@KanwarG 在评论中提到的,解决方案是将 Graphvis 作为一个合适的包进行安装,而不是使用使用 pip 找到的 python 包。
如果使用 mac,那么一个解决方案是使用 Homebrew。如果您没有 Homebrew,请关注 these instructions安装它。然后使用以下命令很容易安装 Graphviz。
brew 安装 graphviz
如果您使用的是 ubuntu Debian,则以下命令可能会起作用。
apt-get install graphviz
希望这可以帮助其他试图找到解决方案的人。
关于python - 即使在拥有 Graphviz 之后,Pyreverse 也会提示,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35205430/