Hi,
I've quickly written an extension to metamath-knife which
generates a GraphML file with all theorem dependencies. You can
find the PR here:
https://github.com/david-a-wheeler/metamath-knife/pull/112
It adds an option "export-graphml-deps", so that the tool can be called using:
metamath-knife set.mm --time
--export-graphml-deps deps.xml
which generates a "deps.xml" GraphML file.
The file generated using the current version of set.mm is around 60Mb, includes 43922 nodes and 1324402 edges.
BR,
_
Thierry
--
You received this message because you are subscribed to the Google Groups "Metamath" group.
To unsubscribe from this group and stop receiving emails from it, send an email to metamath+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/metamath/acaf60be-aad3-4e11-9eb4-ecd92479f304n%40googlegroups.com.
error: Found argument '--export-graphml-deps' which wasn't expected, or isn't valid in this context
Did you mean --export?
USAGE:
metamath-knife <DATABASE> --export <LABEL>... --time
For more information try --help
git clone https://github.com/tirix/metamath-knife.git export_graphml_deps
Cloning into 'export_graphml_deps'...
remote: Enumerating objects: 2377, done.
remote: Counting objects: 100% (645/645), done.
remote: Compressing objects: 100% (175/175), done.
remote: Total 2377 (delta 523), reused 526 (delta 466), pack-reused 1732
Receiving objects: 100% (2377/2377), 20.79 MiB | 6.67 MiB/s, done.
Resolving deltas: 100% (1704/1704), done.
Users-MacBook-Pro-5:checkouts user$ cd /Users/user/.cargo/git/checkouts/export_graphml_deps
Users-MacBook-Pro-5:export_graphml_deps user$ cargo build --release
On a separate but relevant note, Thierry, sorry to inform that I seem to have a problem with the current GraphML output. Pls see the attached output which is exactly what I got when I ran the commands in:
#113 (comment)
On Gephi, I have a Invalid GML Parsing error.
On GraPhP with PHP (https://github.com/graphp/graph), I am having the following error:
Fatal error: Uncaught Exception: String could not be parsed as XML in /Users/user/Documents/graph/vendor/graphp/graphml/src/Loader.php:13
Stack trace:
#0 /Users/user/Documents/graph/vendor/graphp/graphml/src/Loader.php(13): SimpleXMLElement->__construct('/Users/user/Doc...')
#1 /Users/user/Documents/graph/index.php(26): Graphp\GraphML\Loader->loadContents('/Users/user/Doc...')
#2 {main}
thrown in /Users/user/Documents/graph/vendor/graphp/graphml/src/Loader.php on line 13
It appears that the GraphML output is not well-formed, but I dun have enough knowledge now to check manually what is the exact problem.
Hopefully, you can fix this problem while you add the feature for the definitions dependency graph..
Yes, the PR has not been merged in yet, so until then you will
need check my branch out.
This feature required an "XML" library and I've kept it optional, so you will only be able to access it if the program is compiled with the "xml" feature, like so:
cargo run --features xml -- ../set.mm/set.mm --time --export-graphml-deps deps.graphml
Or
cargo build --features xml
Sorry, I should have mentioned that.
_
Thierry
--
You received this message because you are subscribed to the Google Groups "Metamath" group.
To unsubscribe from this group and stop receiving emails from it, send an email to metamath+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/metamath/5d59c6af-a1e8-4a32-bfb1-85077310a17bn%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Metamath" group.
To unsubscribe from this group and stop receiving emails from it, send an email to metamath+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/metamath/03E6D2BE-FC76-4663-A563-9BE08D9DF2A1%40dwheeler.com.
Yes this feature is quite far away from a core functionality.
The `metamath-knife` crate is actually both the library and a
command-line tool.
What do you have in mind here?
- still keeping both library and command-line together, but
moving some functionality (like graph exports) to another
command-line crate,
- or splitting library and command-line tool, with the graph
export functionality moving to the command-line tool part?
_
Thierry
To view this discussion on the web visit https://groups.google.com/d/msgid/metamath/CAFXXJSu4TttF50YBYg%3D1x5vwKde6vUcTm1BFLDb%3D_RUU0pxshA%40mail.gmail.com.