Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GraphViz error while running grasp_erdos_renyi() function #2

Open
sybernix opened this issue Jul 31, 2022 · 3 comments
Open

GraphViz error while running grasp_erdos_renyi() function #2

sybernix opened this issue Jul 31, 2022 · 3 comments

Comments

@sybernix
Copy link

I am trying to run the following example code provided at https://github.com/bgirault-ensai/GSP-Intro-GraSP-Code. I have installed GraSP toolbox for matlab.

N = 30;

% Erdos-Renyi: Uniform Random Graph Model (@\index{Graphs!Erd\H{o}s-R'{e}nyi}@)
p = 0.1; % Edge probability
er = grasp_erdos_renyi(N, p, 'directed', false);

% Barabasi-Albert: Preferential Attachment Graph Model (@\index{Graphs!Barabasi-Albert}@)
m0 = 3; % Size of the initial complete graph
ba = grasp_barabasi_albert(N, m0);

% Random Bipartite
M = 20; % Size of the second set of nodes
rb = grasp_random_bipartite(N, M, 'p', p);

% Random Regular
k = 3; % Degree
rr = grasp_random_regular(N, k);

I am getting the following error in the Matlab console

zsh:1: command not found: neato
Warning: File 'output.dot' not found.
In grasp_layout (line 130)
In grasp_erdos_renyi (line 88)
In B_1_2_Random_Graph (line 5)
Error using grasp_layout
Sorry, unknown GraphViz failure, please try another layout

Error in grasp_erdos_renyi (line 88)
graph.layout = grasp_layout(graph);

Error in B_1_2_Random_Graph (line 5)
er = grasp_erdos_renyi(N, p, 'directed', false);

I have tried installing GraphViz using Homebrew and MacPorts. Both of them give the same error. My specs are as follows

Matlab - R2022a Update 3
MacOS - MacOS Monterey 12.4
Processor - M1 Pro

Kindly let me know if there is any resolution

@bgirault-ensai
Copy link
Contributor

zsh:1: command not found: neato

This is the relevant error. neato is a software part of the GraphViz package. The error says that zsh is not able to find it, most likely because the PATH is not set correctly.

You should first check where GraphViz binaires (including neata) are installed, and then look for adding the folder they are in to your PATH.

I'll leave this issue open for a few days, but this does not appear to be an issue with GraSP.

@JinhaoGu
Copy link

JinhaoGu commented Sep 9, 2022

@niruhan Hi Niruhan, I have the same issue, did you manage to solve that? Thanks!

@AO2666
Copy link

AO2666 commented Sep 9, 2022 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants