-
-
Notifications
You must be signed in to change notification settings - Fork 71
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
[BUG] graph.ToSvg() not working. (rise4fun is down) #48
Comments
Hello @samvanlier, Ah, sad news. I always though that replacing this call to a web service by a proper implementation of svg conversion would have been better. That was the same case when Graphviz website certificate has expirated some API of the library were broken, but for this case I already fixed that. When reworking the library I already had in mind the fact of doing a web independant version of this conversion for several other reasons BTW. So I guess it quite answers you question about plan about this! Otherwise a possible solution might be to use the graphviz dot executable that if I'm not wrong has a command line to do so. Hope it helped a bit. |
Hello @KeRNeLith , I used the command line tool of graphviz to fix this problem but that is not a solution that is usable for the nuget because it requires the tool being installed on the machine. It is my first time using Graphviz so I cannot recommend any idea to solve this issue without using Graphviz locally. Anyway, thanks for the reply and good luck finding a solution. |
Yeah it requires the tool to be installed indeed, or an alternative would be to create a package that embeds the tool executable. I have to admit that I'm pretty stuck too without having an implementation of what's done in the dot executable. It would be certainly nice to kind of make an equivalent implementation in C#. BTW I don't have the sources of the dot executable. So I'm afraid I don't really have solution for now. Deploying a dot executable may be the best compromise for now. |
I now just call the dot executable from C# giving the Graphviz string as input to convert a graph to a file. I use Mac and accessing command line tools from within C# wasn't easy. So a implementation in C# would seem the most useful solution. |
Hello @KeRNeLith, For simplicity and, kind of, being cross-platform I'd perhaps think of using some wrapper around things like vis.js or d3. Throughout the years I haven't seen any .NET-based visualization libraries for graphs, except, perhaps, MSAGL |
@samvanlier I'm totally agree that a C# implementation will always be better in term of portability, practicality and also resilience. I'm not really aware of those solution @eosfor. Do you have some references on them (vis.js and d3) for the scenario we're facing? |
Hello @KeRNeLith , here is the example in MSAGL repo. I tried it here I wonder what dows QuikGraph.MSAGL do? |
@eosfor the QuikGraph.MSAGL is basically a bridging library. I mean it allows to convert from a QuikGraph representation to an MSAGL one. The main relevant implementation you can have a look around this is here. As a summary QuikGraph provide a customizable convertion by hooking events at some point that gives control to user. Other than that, it's basically almost what your example is showcasing indeed. |
@eosfor The implementation of MSAGL bridge may be improved based on the test implementation you gave earlier. But note that it seems we miss the clustering feature. The best thing would certainly be to get the code that was running behind the rise4fun AGL API, but seems to not be an easy task BTW. |
This might be of help as a temporary work around for people that want to implement their own |
I'm trying to use the
ToSvg()
method to render a graph but it seems that it uses rise4fun.com in the background to do this.After some digging, I found out that this service has been shut down and will probably not recover (source: Z3Prover/z3#5472).
Is there a plan to create a solution for this?
And in the meantime, are there alternatives for rendering a graph to svg?
I would prefer a local solution because I need to render quite a few.
Thanks in advance
The text was updated successfully, but these errors were encountered: