Comments (3)
At OuestWare, many people have asked us a solution to share networks online, using sigma v2. Our solution is Retina (source page). Its current functional scope is to allow sharing online a GEXF graph, but with custom filtering, coloring and sizing.
It is still in beta version, but ultimately:
- It reads any graph available online, as long as there is no CORS restriction (and Gist applies)
- The state (sizes, colors, filters...) are stored in the URL
- All Retina versions will coexist so that permalinks are persistent
One solution to provide a solution to share GEXF online using sigma v2 would be to have a wizard in Gephi that uploads the GEXF graph somewhere online (maybe on Gist, if we can allow users to login from the wizard itself), and then give them a URL to use.
We could also make something similar (exporting a .zip that contains Retina code and the graph file), but I'm afraid it will be harder to maintain.
from gephi-plugins.
Here is a list of things that the plugin must do, if we go that way:
1. We must register Gephi (or this plugin) as a GitHub app, to enable saving Gists
The doc is here. This is not the biggest topic, but we must store the registered app ID somewhere.
Also, to prevent having to deal with displaying a web page inside Gephi, the Enable Device Flow option must be checked.
2. The plugin should allow user to log into GitHub Gist
This will allow uploading the GEXF graph file onto Gist, to share it online with Retina.
The process to authenticate a user (ie. retrieving a usable API token) is the following (as described here):
- Gephi will ask for a user verification code to GitHub, and display to the user the code and a URL. The API call contains the app ID and the required scope (
gist
, in our case). More information here. - The user opens the URL in a browser where they log into GitHub, and then they give the code to GitHub.
- During that time, Gephi will poll GitHub API to know when the user has effectively been verified. When it's done, Gephi will have a proper
access_token
. This token must be saved into the plugin
3. A logged in user can share their graph online
To share a graph with Retina, here is the list of things to do:
- The graph is serialized in GEXF
- A new public Gist is created with the GEXF file (doc here), with given file name, such as
shared-graph.gexf
- The API call response should provide the raw GEXF file URL under
response.files["shared-graph.gexf"].raw_url
. This is the URL that will be used to share the graph with Retina.
At this point, Gephi just has to share with the user the URL:
- To open Retina with the editor interface (to allow the user to pick what graph viewers will be able to do):
https://ouestware.gitlab.io/retina/beta/#/graph/?url={ ENCODED_GRAPH_URL }&r=d
- To open Retina as a viewer with the default settings (ie. GEXF nodes and edges colors, no viewer option):
https://ouestware.gitlab.io/retina/beta/#/graph/?url={ ENCODED_GRAPH_URL }
Please note that the graph URL must be properly URL-encoded before being put into the Retina URLs.
from gephi-plugins.
Additional attention spots
- We must properly handle authentication failure:
- Authentication token can be invalid, in which case the process at 2. must be rerun
- During 2., a timeout (a long one, maybe 5 minutes or something) should be set before considering that something went wrong and asking for a new GitHub verification code
- At this point, if Retina is updated from
beta
tov1
for instance, this plugin will have to be updated as well. This is an issue that must be addressed on Retina's side.
from gephi-plugins.
Related Issues (20)
- HTTP Graph Plugin fail to build due to external dependency HOT 10
- Graphiz (dot) not found
- mvn package clean HOT 3
- Update and test Neo4j plugin HOT 4
- Export graph to JSON doesn't write Z position HOT 1
- Make the "Spatial Ranking" plugin great again HOT 1
- GeoLayout plugin update with new map projection(s)
- GeoLayout not working HOT 6
- Delete node does not work if used from a method HOT 3
- Update Semantic Web Import plugin HOT 2
- Gephi 0.9.7: Concentric Layout Plugin Missing HOT 1
- 500 error on Publish HOT 2
- Gephi 0.10.1 | Image Preview plugin
- Layout bug HOT 10
- Twitter Streaming Importer v2 not working HOT 2
- Twitter Streaming Importer v2 not found in Gephi-Plugins HOT 2
- How to adjust the center coordinate position
- Gremlin console not connecting to Gephi
- Run Gephi java code
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gephi-plugins.