Qiskit / rustworkx

A high performance Python graph library implemented in Rust.
https://www.rustworkx.org
Apache License 2.0
1.08k stars 148 forks source link

Expose vf2_mapping like interface to rustworkx-core #741

Open mtreinish opened 1 year ago

mtreinish commented 1 year ago

What is the expected enhancement?

Right now we have the vf2_mapping() function which iteratively returns the isomorphic mappings found by the vf2 algorithm to python space. It would be great to expose this functionality from rustworkx-core too for rust users so given any two generic graph objects we can get an iterator of mappings of node indices between them which are isomorphic. We should look into how we can port the https://github.com/Qiskit/rustworkx/blob/main/src/isomorphism/vf2.rs module into rustworkx-core so we can expose all the vf2 and vf2++ heuristic functionality to rust users too.

vlvrd commented 1 year ago

+1 :slightly_smiling_face:

ElePT commented 3 months ago

Interested

mtreinish commented 3 months ago

I've been thinking more about this and to get a rustworkx-core interface to start it will be easier to just copy the implementation and leave the rustworkx crate alone. We can worry about de-dpulicating the interface in a followup since there are unknowns about we would interface a rust space iterator with the python side.