-
Notifications
You must be signed in to change notification settings - Fork 7
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
Could not plot phenotypic comparison #17
Labels
bug
Something isn't working
Comments
Yes, I am seeing something similar in Windows. I had initially developed this in Linux and it worked just fine. There is some literature already about these issues with graphviz's dot program. I get a similar error, but not quite the same:
Maybe @hchittanuru3 has some insights on how to go about this one. Ideas? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I tried to plot phenotypic comparison using these lines:
hpo.plot(
patient = patients['ORPHA:104']['cohort'][0]['phenotype'],
disease = {
'name': patients['ORPHA:104']['name'],
'id': patients['ORPHA:104']['id'],
'phenotype': patients['ORPHA:104']['phenotype']})
But it did not work, I got this:
FileNotFoundError Traceback (most recent call last)
~\anaconda3\envs\OIA\lib\site-packages\pydot.py in create(self, prog, format, encoding)
1925 arguments=arguments,
-> 1926 working_dir=tmp_dir,
1927 )
~\anaconda3\envs\OIA\lib\site-packages\pydot.py in call_graphviz(program, arguments, working_dir, **kwargs)
138 stdout=subprocess.PIPE,
--> 139 **kwargs
140 )
~\anaconda3\envs\OIA\lib\subprocess.py in init(self, args, bufsize, executable, stdin, stdout, stderr, preexec_fn, close_fds, shell, cwd, env, universal_newlines, startupinfo, creationflags, restore_signals, start_new_session, pass_fds, encoding, errors, text)
799 errread, errwrite,
--> 800 restore_signals, start_new_session)
801 except:
~\anaconda3\envs\OIA\lib\subprocess.py in _execute_child(self, args, executable, preexec_fn, close_fds, pass_fds, cwd, env, startupinfo, creationflags, shell, p2cread, p2cwrite, c2pread, c2pwrite, errread, errwrite, unused_restore_signals, unused_start_new_session)
1206 os.fspath(cwd) if cwd is not None else None,
-> 1207 startupinfo)
1208 finally:
FileNotFoundError: [WinError 2] The system cannot find the file specified
During handling of the above exception, another exception occurred:
FileNotFoundError Traceback (most recent call last)
in
4 'name': patients['ORPHA:104']['name'],
5 'id': patients['ORPHA:104']['id'],
----> 6 'phenotype': patients['ORPHA:104']['phenotype']})
7
8 #plot does not work
~\AppData\Roaming\Python\Python37\site-packages\rarecrowds\utils\hpo.py in plot(self, patient, disease)
230 G = self.Graph.subgraph(list(hpo_set))
231 ## Prepare the data
--> 232 plt_data = prepare_data(G, patient_set, disease_set)
233
234 edge_trace = go.Scatter(
~\AppData\Roaming\Python\Python37\site-packages\rarecrowds\utils\hpo.py in prepare_data(G, patient_set, disease_set)
173 mapping = {n: n.replace(":", "_") for n in G.nodes}
174 G = nx.relabel_nodes(G, mapping)
--> 175 pos = nx.drawing.nx_pydot.graphviz_layout(G, prog="dot")
176 ## Set positions of each item
177 data = {
~\anaconda3\envs\OIA\lib\site-packages\networkx\drawing\nx_pydot.py in graphviz_layout(G, prog, root)
255 This is a wrapper for pydot_layout.
256 """
--> 257 return pydot_layout(G=G, prog=prog, root=root)
258
259
~\anaconda3\envs\OIA\lib\site-packages\networkx\drawing\nx_pydot.py in pydot_layout(G, prog, root)
304 # List of low-level bytes comprising a string in the dot language converted
305 # from the passed graph with the passed external GraphViz command.
--> 306 D_bytes = P.create_dot(prog=prog)
307
308 # Unique string decoded from these bytes with the preferred locale encoding
~\anaconda3\envs\OIA\lib\site-packages\pydot.py in new_method(f, prog, encoding)
1732 """Refer to docstring of method
create
."""1733 return self.create(
-> 1734 format=f, prog=prog, encoding=encoding)
1735 name = 'create_{fmt}'.format(fmt=frmt)
1736 self.setattr(name, new_method)
~\anaconda3\envs\OIA\lib\site-packages\pydot.py in create(self, prog, format, encoding)
1931 args[1] = '"{prog}" not found in path.'.format(
1932 prog=prog)
-> 1933 raise OSError(*args)
1934 else:
1935 raise
FileNotFoundError: [WinError 2] "dot" not found in path.
The text was updated successfully, but these errors were encountered: