Giter Club home page Giter Club logo

ccnetviz's People

Contributors

amanmdave avatar anadroid avatar arraxx avatar brickmaker avatar canerakdas avatar davidtichy avatar dependabot[bot] avatar fitappstore avatar gauravgrover95 avatar helikarlabpersonal avatar himanshuc3 avatar hjhimanshu01 avatar rmoore14 avatar saskaale avatar statebait avatar ttm avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ccnetviz's Issues

Not able to display nodes and arrows by running "basic example" from /README.md file

OS: MacOS High Sierra 10.13.1
Browser: Firefox Quantum 58.0.2 (64-bit)

Following I have attached the screenshot of the result I obtained by running the "basic example" mentioned in the /README.md documentation file of the project.

Please note that no nodes and arrows are visible. As a result, there is no distinction between the source and the target nodes.

In addition to it, I tried zooming to the very large level. The exclamation mark (!) was just being visible as a single straight vertical line.


ccnetviz screenshot


Downloaded image is not visible clearly

When you download a .png file of the graph, downloaded image gets blurred.It would be a great idea if we can download a .jpg file of it with better quality and resolution.
2020-02-04

Did not get 404 error here for the non-existent gibbrish file paths supplied in styles.nodes.texture and styles.edges.arrow

For the following code, I am not getting any error for the gibberish 'file paths' supplied into the styling options of the ccNetViz object.

var graph = new ccNetViz(document.getElementById('container'), {
      styles: {
        node: { texture: "ccnetviz/ cabbsd sjdbds kjvsjkjssadb images/node.png", label: { hideSize: 16 } }, // <-- This is just gibberish file path
        edge: { arrow: { texture: "ccnetviz/imagescsnk /arrow.png" } } // <-- Here again a gibberish file path is supplied.
      }});

You can observe in the following screenshot that we are not receiving any error in console for any gibberish file path supplied to those arguments. Simply no nodes and arrows are drawn in the graph.

ccnetviz screenshot

Performance testing

  1. Performance benchmark
    -- rendering time, layout computation time for various networks of increasing sizes
    -- see https://github.com/HelikarLab/ccNetViz/tree/master/src/layout for all implemented layouts
    -- see https://github.com/HelikarLab/ccNetViz/tree/master/examples/data for graphs ~( you can even add / create new ones )
  2. Feature comparison table that would illustrate how ccNetViz fits in with other network visualization tools (layouts, node/edge coloring etc. )

The performance benchmark would be done for the same net visualization tools that would be compared in the feature comparison table.

Software to compare ccNetViz against:
slim D3 plot of the implemented layouts. (I can implement this)
Cytoscape.JS
SigmaJS
JSNetworkX
other possible softwares

Adding prettier

I think to generalize the code standard and white spacing we could add prettier. I could do that if needed. Open to suggestions!

Implement color animation

Implement color animation and speed control.

Doing benchmark for performance with animation and without animation.

Implement BVH-Tree if needed.

Dark Mode example

We can add a dark mode option as in it the images would be displayed nicely.

Better support for multi level graphs

Openning this ticket as a feature request for the refractor of the multilevel graph nodes.

DESIRED BEHAVIOR

  • The changing of the levels would be based on the zoom level instead of the click on the node.

POSSIBLE IMPLEMENTATIONS

  1. SHOWING/HIDING nodes according to their levels (PREFERED)

    • the nodes would have the integer variable associated to their "level"
      • show only nodes with one level according to the zoom

    CHALLENGES
    - maintain graph layout in the nested levels

  2. REDRAWING THE GRAPH (through set() method) according to the zoom level
    CHALLENGES
    - maintaining continuous zoom while REDRAWING (calling set()) the graph with the big subgraph

Graphs not rendering properly

The graphs on the ccNetViz website, along with cell collective are not being rendered properly on the browser. The issue is with hardware acceleration when rendering such graphs. Sometimes the operating systems have low compatibility with certain hardware.

Current Operating System: Linux Mint 19 Tara
GPU: Nvidia GTX 1050

Screenshot from 2019-06-13 10-18-59

Screenshot from 2019-06-13 10-19-18

Refactor client-side SDF spritesheet generation for text rendering

Current implementations of client-side generation of SDF coded character sprite-sheets has some references to old libraries and function that are not required anymore. They were not deleted but simply ignored at run-time. There is a scope for improvement of the code.

Examples:

  • PBFs and shelf-pack libraries are not requried anymore.
  • Code which utilizes unused libraries can be removed e.g. glyphs.js file
  • Naming conventions can be further improved to make process seem less complex and more intuitive

References:

Refactor background layout computation code

Code written in #22 is good enough to make things work. But to make it crisp, easy to understand and more DRY. We can

  • use a single worker file (can be named wrapper.worker.js file)
  • import every layout computation file in it
  • Transfer the switch case statement from layout.js file to wrapper worker file to decide which layout to use

Although this is not the super best technique to do this because there will be two entry files into the layout computation. One will be layout.js and the other will be wrapper.worker.js.

A much more advanced version of doing this would be to even merge those two files into one if it does not make the code super-complicated.

Random user inputs against config option of layout name is not handled

Description

User is supposed to provide the layout name to the library manually like:

graph.set(nodes, edges, "force"); .

Leaving responsibility to the user to provide the correct layout name against in the configuration file could be a bad practice. If the layout name is not correct, library throws an error as below:

error

Possible fixes:

  1. stop the execution of library by throwing a proper error that will guide user to fix the name
  2. choose render a chosen default layout
  3. We can do both

Corresponding code files: Code file 1 and Code File 2

Interactivity hover example

For the current "styles" configuration of interactivity_hover.html , i.e.

styles: {
        node: { texture: "images/node_bw.png", label: { hideSize: 16 } },
        edge: { arrow: { texture: "images/arrow.png" } },
        edgeHover: {
          color: "rgb(0, 0, 255)"
        },

On hovering over the edges once , all the label disappears , subsequently on moving to a node changes label of two nodes with same text and third node as empty, on changing font module to sdf type ,

styles: {
        node: { texture: "images/node_bw.png", label: { hideSize: 16, font:{ type: "sdf" } } },
        edge: { arrow: { texture: "images/arrow.png" } },
        edgeHover: {
          color: "rgb(0, 0, 255)"
        }, 

it doesn't work.
Screenshot (37)
Screenshot (40)
Screenshot (42)

create CI deploy

Create automated script which would make sure that the builded library would be always up the date.

Advanced testing for sdf text rendering

The current code is already verified against a lot of test cases which includes consideration of

  • Scale of graph
  • Font-families
  • Characters
  • Font-sizes
  • Font-weight
  • Font-style
  • Alignment

But considering the number of test cases possible, I believe there is still a scope for bugs. If any potential bug is found or even it is under suspicion, Please feel free to give me a mention or even better generate a pull request.

disable nodes on command or view clearly

download
In the above example, most of the labels are not clearer or merge into one another, apart from zooming , magnifying the node label on hover to see it clearly that could be disabled or enabled using the ccNetViz API would be a good feature I guess.

Unresolved bug in client-side SDF character spritesheet generation

Unless the font-size supplied to the algorithm is a multiple of 4, the rendering algorithm is showing weird elongation of labels with multiple horizontal straight line artifacts as shown in the image below.

screen shot 2018-08-11 at 4 44 33 pm

where the expected behavior was as follows:

screen shot 2018-08-11 at 4 45 23 pm

A quick fix was applied in the spriteGenrator.js [Link] by rounding off the font-size supplied to the nearest multiple of 4, but the case requires more investigation and a proper fix.

Add >>npm start<< command for better user-friendliness

This command would internally

  1. run the simple web server ( for example https://www.npmjs.com/package/http-server ) and
  2. Open browser window with examples directory ( parameter -o in the http-server package )

additional work required:

  • add simple index page into the examples directory whichs allows users to redirect to each example
  • document these steps needed for showing in the Readme.md page
    a) download with git clone
    b) yarn install
    c) yarn build
    d) yarn start

Errors while importing to ReactJS

Getting the following errors while importing ccNetViz (latest version from the github repo) in ReactJS (Using eslint, create-react-app configuration):

ccNetViz-errors

Zooming is defocussed

Unlike the graphs produced using cytoscape.js when we try to zoom on a particular element by hovering the mouse over it and using mousewheel to zoom on it. The element pans away and we have to find it by manually panning to it.

This will create problems when we will try to find tiny elements in large graphs. Also, since our library is unique in supporting large graphs really well. This will be an important issue.

For Example (Steps for Reproduction) :

Step 1: Please go to this Official Example of ccNetViz library.

Step 2: Place your mouse pointer over the node number 8 and try zooming to a large extent. You will find that the focus shift aways from the node 8 and we got zoomed to some irrelevant space.

Screenshots:

Before zooming

ccnet zoom - 1

After zooming

ccnet zoom - 2

For comparision:

Refer this Cytoscape Example. and place mouse pointer on some node and try zooming. You won't find the viewport loosing its focus on mouse pointer.

Rendering fails of text and nodes without disabling cache in latest Firefox

screen shot 2018-07-31 at 4 53 59 pm

Firefox version: 61.0.1 (64-bit)

Error Message: "Error: WebGL warning: drawElements: Active texture 0 for target 0x0de1 is 'incomplete', and will be rendered as RGBA(0,0,0,1), as per the GLES 2.0.24 $3.8.2: The dimensions of level_base are not all positive."

OS: MacOS

Setup: local php server from cli. Example = sdf.html

Notes: This does not happen if cache is disabled from developer-tools. Not sure about the behavior in production.

Display of nodes in the webpage

Nodes written is hidden
Screenshot from 2020-01-13 22-59-13
code :
Screenshot from 2020-01-13 22-58-33
Expected Behavior
It should be not hidden and displayed either on the top or on the bottom.

Context menu support

Write example for support context menu.

Basic iIde how to make is style div element to look like browser context menu.
Once user would right-click on the graph there would be call for the find() method. for nearby area (let's say 10px) If the area contains the node, look if the node has property for context menu, if yes then show the context menu with specified context.

At the beginning I'd start with the raw html ( string / element ) as parameter to the context menu context.

e.g.:

nodes = [{
label: "node_1
},
{
label: "node_with_context,
contextMenu: HTML_STRING_or_HTML_ELEMENT
},
]

Texture edge animation

Create a plugin which allow the user to do animate the image on top of the edge.

THE GENERAL IDEA:

CODING CHALLENGES

POSSIBLE IMPLEMENTATION
for the discussion

No "ccNetViz.min.js" available in /dist directory as illustrated in 'basic example' section of /README.md

In the documentation file /README.md. Maybe there is a simple spelling error or in the latest build, we have missed the minified compilation of the source code.

Please refer the code below:

README.md

<!-- Basic Example -->

...
... 
<style type="text/css">
    #container {
      width: 500px;
      height: 500px;
    }
  </style>
  <script src="dist/ccNetViz.min.js" ></script>     <!-- ERROR -->
</head>
<body>
  <canvas id="container"/>
...
...

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.