Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Tiago Peixoto
graph-tool
Commits
971de369
Commit
971de369
authored
Jan 04, 2013
by
Tiago Peixoto
Browse files
Safeguard for empty graphs in subgraph_isomorphism()
parent
b0d238d2
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/graph_tool/topology/__init__.py
View file @
971de369
...
...
@@ -265,6 +265,8 @@ def subgraph_isomorphism(sub, g, max_n=0, random=False):
.. [subgraph-isormophism-wikipedia] http://en.wikipedia.org/wiki/Subgraph_isomorphism_problem
"""
if
sub
.
num_vertices
()
==
0
:
raise
ValueError
(
"Cannot search for an empty subgraph."
)
# vertex and edge labels disabled for the time being, until GCC is capable
# of compiling all the variants using reasonable amounts of memory
vlabels
=
(
None
,
None
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment