A New Method and Format for Describing Canopen System Topology

Total Page:16

File Type:pdf, Size:1020Kb

A New Method and Format for Describing Canopen System Topology iCC 2012 CAN in Automation A New Method and Format for Describing CANopen System Topology Matti Helminen, Jaakko Salonen, Heikki Saha*, Ossi Nykänen, Kari T. Koskinen, Pekka Ranta, Seppo Pohjolainen, Tampere University of Technology, *Sandvik Mining and Construction In this article, we present a new method for describing CANopen network topology. A new format using GraphML, an XML-based graph format, is introduced. By using a subset of GraphML along with CANopen-specific new elements and attributes, topology of single as well as multiple CANopen networks can be captured in a well established graph format with existing tool support. The new format is specified in a manner that allows CANopen design applications to adopt it while providing a mechanism for fallback in unsupported software. Methods for extending the format to contain other CAN- and CANopen-specific data as well as transforming the GraphML- based network structure to other formats are described. Finally, the implications of the introduced method and format are discussed. 1. Introduction and Background connection between the nodes as edges in a graph. However since the specific When designing mobile machines in structure within and between nodes is not practice, multiple CANopen networks may defined in actual design data, some need to be used. What may then become structure needs to be generated for the problematic is that the current CANopen purposes of visualization. This is design programs and specification support problematic since the visualized structure only description of individual CANopen may or may not correspond to the actual networks. Specificially, formats and structure of the network. For accurately applications for specifying topology representing CANopen network structures, between and within networks. we would require to have network From stricly practical point of view, this topologies defined in design materials, in may not be problematic. If one wishes, some common format. however, to re-use information from In a more broader level, an important use CANopen designs, becomes integration of case for network topology information re- topology information with other CANopen use is CANopen network monitoring and data cumbersome: we not only need to troubleshooting. By enriching for instance know in which format the topology onboard device monitors with this information is encoded in, but also need to structural information, more informative create adapters that (programmatically) system monitoring tools can be combine topology information with other implemented. CANopen data. In addition, well-defined From the current formats, the most points for schema extensions are missing. promising candidate for a point of Our motivation for enriching CANopen enrichment is nodelist.cpj. As defined by designs with network topology information CiA-306-3 [7], nodelist.cpj has the main stems from Semogen project. In Semogen purpose of providing either network or research project, we have attempt to system level structural information and link (semi-)automatically generate virtual to appropriate DCF- [16] or XDC-files[17]. prototypes, i.e. virtual machine What is limiting is that the current format laboratories (VMLs), directly from design only allows description of individual data [11, 12, 13, 14]. Within a VML, it is CANopen networks. DCF-files can be useful to represent CANopen network in linked to nodes and further to the network, visual, graph-like format, where nodes are but only locally within a given network. The represented as graph nodes and format also doesn't enable us to describe 06-11 iCC 2012 CAN in Automation in which order nodes are physically additional features like Namespaces [3] or connected. XLink [4] inside a GraphML document. In A current effort towards enriching this way, a format can be extended with CANopen designs with topology features required by custom applications. information exist. CiA-302-7 Draft specifies Structural layer of GraphML describes the signal routing in gateway nodes, enabling fundamental graph model, which is mixed us to track signals between multiple multigraph and may, but is not required to, CANopen networks [10]. However, even include nodes, ports, edges, hyperedges with CiA-302-7 we still do not have and nested graphs [1, p-4]. In figure 2.1.1. information about topology of the we have simple GraphML example file. It underlying CANopen networks; the way in has one graph, but GraphML-format may which the nodes are connected within also include multiple graph elements. specific CANopen networks still remain Graph-element has mandatory attribute unspecified. edgedefault, which specifies whether edges are directed or undirected by 2. Nodelist representation with GraphML default. Graphs may contain any number of nodes, edges and hyperedges in any In this chapter we introduce GraphML and order. In the example we have four nodes define a GraphML-based format for and three edges, but no ports or representing nodelists with topology hyperedges. information.This Nodelist.graphml format[9] has also been proposed to <?xml version="1.0" encoding="UTF-8"?> CiA.The proposal will add to the future CiA-311 system structure information, <graphml which has been integral part of the CiA- xmlns="http://graphml.graphdrawing.org/xmlns" xmlns:xsi= 306 defining the old design files. "http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation= 2.1. GraphML "http://graphml.graphdrawing.org/xmlns http://graphml.graphdrawing.org/xmlns/1.0/graphml.xs GraphML (Graph Markup Language) is an d"> XML (eXtensible Markup Language) <!-- System description graph (single network) --> format for graph structures and has a <graph id="RootNetwork" edgedefault="undirected"> <node id="Device_A"/> mechanism that allows to define extension <node id="Device_B"/> modules for additional data [2]. GraphML <node id="Device_C"/> is well suited for data interchange, <node id="Device_D"/> because its extension modules allow <!-- Network connections --> application specific-data to be added that <edge source="Device_D" target="Device_A"/> can be combined or stripped without <edge source="Device_D" target="Device_B"/> <edge source="Device_D" target="Device_C"/> affecting the graph structure. [1, p.1] This </graph> way additional data can be ignored by </graphml> programs not supporting it without Figure 2.1.1. Simple GraphML example file, affecting the graph data itself. which includes graph, nodes and edges. GraphML was designed with simplicity, generality, extensibility and robustness in Port is part of a node to which edges may mind. Because of this, the format is easy attach. Ports appear as nested to parse and interpret and has no subelements of node. Ports may also limitations with respect to the graph model. include other ports. GraphML-based formats can be extended Edges connect ports or nodes together. with well-defined way to represent Edge has source and target node, additional data and application not capable regardless of whether it is directed or not. of supporting this added data can ignore it Edges may also have sourceport and or extract the subset they can handle [1, targetport if it is used to connect ports. p.3]. Edges optional attribute directed can Format in GraphML is based on XML [2] overwrite graphs edgedefault value for so there are readily available parsers and current edge. tools for it. Also XML enables us to use Hyperedge is a special case of an edge 06-12 iCC 2012 CAN in Automation which can have multiple endpoints. Each defined for graphs and has to be in string endpoints' direction can be defined as in, format. out or neither. Endpoints refer to nodes and may also refer to ports. 2.3. Nodelist.graphml format The existing format, nodelist.cpj (figure 2.2 GraphML extensions 2.3.1), represents only nodes within one Extensions provide a method for defining CANopen network and contains no additional data and can also provide typing topology information. The format only information for it. This additional data in allows listing the existing nodes, their GraphML is defined with the help of key DCF-files [16] and names. Yet, having and data elements [1, p8]. A key element topology information and an overview to is used for typing and naming the data and the whole CANopen system would be the data element is for containing actual useful for maintenance and data value. Every data element has to be troubleshooting and can be used for linked to ca orresponding key element with creating different views of the network or id attributes in key and data elements. create semantic models of it. Therefore we Multiple data elements should refer to a specified new format, Nodelist.graphml [9], common key element's id, if they all which has also been proposed to CiA as a contain same type of data. draft. So data typing is done in key element. These elements can be defined in the [Topology] EDSBaseName=EDS #optional beginning of a GraphML file. In figure 2.3.2 NetName=DefaultNet #optional we see an example of key element Nodes=0x02 definitions in use. Key element has id Node2Present=0x01 Node2DCFName=demo_plc.dcf attribute, which has to be unique and is Node2Name=DemoNode_A #optional used to link data element to this key Node3Present=0x01 Node3DCFName=demodeva.dcf element. Further, for attribute defines what Node3Name=DemoNode_B #optional elements (graph, node, edge, port, etc.) can contain this type of data. Purpose of the attr.name attribute is to identify the Figure 2.3.1. Two node network description in meaning of the key attribute and it has to nodelist.cpj format. be unique, but it is not used inside the GraphML provided existing solution for document to refer to key attribute [8]. The describing graphs in XML based format. It attr.type attribute defines the type of the was designed as a data interchange data and can be either boolean, int, long, format for graphs and associated data. It float, double or string. These types are also allows defining of extension modules defined like corresponding types in the for additional data, in this case node and Java programming language [8].
Recommended publications
  • Networkx: Network Analysis with Python
    NetworkX: Network Analysis with Python Salvatore Scellato Full tutorial presented at the XXX SunBelt Conference “NetworkX introduction: Hacking social networks using the Python programming language” by Aric Hagberg & Drew Conway Outline 1. Introduction to NetworkX 2. Getting started with Python and NetworkX 3. Basic network analysis 4. Writing your own code 5. You are ready for your project! 1. Introduction to NetworkX. Introduction to NetworkX - network analysis Vast amounts of network data are being generated and collected • Sociology: web pages, mobile phones, social networks • Technology: Internet routers, vehicular flows, power grids How can we analyze this networks? Introduction to NetworkX - Python awesomeness Introduction to NetworkX “Python package for the creation, manipulation and study of the structure, dynamics and functions of complex networks.” • Data structures for representing many types of networks, or graphs • Nodes can be any (hashable) Python object, edges can contain arbitrary data • Flexibility ideal for representing networks found in many different fields • Easy to install on multiple platforms • Online up-to-date documentation • First public release in April 2005 Introduction to NetworkX - design requirements • Tool to study the structure and dynamics of social, biological, and infrastructure networks • Ease-of-use and rapid development in a collaborative, multidisciplinary environment • Easy to learn, easy to teach • Open-source tool base that can easily grow in a multidisciplinary environment with non-expert users
    [Show full text]
  • The Hitchhiker's Guide to Graph Exchange Formats
    The Hitchhiker’s Guide to Graph Exchange Formats Prof. Matthew Roughan [email protected] http://www.maths.adelaide.edu.au/matthew.roughan/ Work with Jono Tuke UoA June 4, 2015 M.Roughan (UoA) Hitch Hikers Guide June 4, 2015 1 / 31 Graphs Graph: G(N; E) I N = set of nodes (vertices) I E = set of edges (links) Often we have additional information, e.g., I link distance I node type I graph name M.Roughan (UoA) Hitch Hikers Guide June 4, 2015 2 / 31 Why? To represent data where “connections” are 1st class objects in their own right I storing the data in the right format improves access, processing, ... I it’s natural, elegant, efficient, ... Many, many datasets M.Roughan (UoA) Hitch Hikers Guide June 4, 2015 3 / 31 ISPs: Internode: layer 3 http: //www.internode.on.net/pdf/network/internode-domestic-ip-network.pdf M.Roughan (UoA) Hitch Hikers Guide June 4, 2015 4 / 31 ISPs: Level 3 (NA) http://www.fiberco.org/images/Level3-Metro-Fiber-Map4.jpg M.Roughan (UoA) Hitch Hikers Guide June 4, 2015 5 / 31 Telegraph submarine cables http://en.wikipedia.org/wiki/File:1901_Eastern_Telegraph_cables.png M.Roughan (UoA) Hitch Hikers Guide June 4, 2015 6 / 31 Electricity grid M.Roughan (UoA) Hitch Hikers Guide June 4, 2015 7 / 31 Bus network (Adelaide CBD) M.Roughan (UoA) Hitch Hikers Guide June 4, 2015 8 / 31 French Rail http://www.alleuroperail.com/europe-map-railways.htm M.Roughan (UoA) Hitch Hikers Guide June 4, 2015 9 / 31 Protocol relationships M.Roughan (UoA) Hitch Hikers Guide June 4, 2015 10 / 31 Food web M.Roughan (UoA) Hitch Hikers
    [Show full text]
  • Comm 645 Handout – Nodexl Basics
    COMM 645 HANDOUT – NODEXL BASICS NodeXL: Network Overview, Discovery and Exploration for Excel. Download from nodexl.codeplex.com Plugin for social media/Facebook import: socialnetimporter.codeplex.com Plugin for Microsoft Exchange import: exchangespigot.codeplex.com Plugin for Voson hyperlink network import: voson.anu.edu.au/node/13#VOSON-NodeXL Note that NodeXL requires MS Office 2007 or 2010. If your system does not support those (or you do not have them installed), try using one of the computers in the PhD office. Major sections within NodeXL: • Edges Tab: Edge list (Vertex 1 = source, Vertex 2 = destination) and attributes (Fig.1→1a) • Vertices Tab: Nodes and attribute (nodes can be imported from the edge list) (Fig.1→1b) • Groups Tab: Groups of nodes defined by attribute, clusters, or components (Fig.1→1c) • Groups Vertices Tab: Nodes belonging to each group (Fig.1→1d) • Overall Metrics Tab: Network and node measures & graphs (Fig.1→1e) Figure 1: The NodeXL Interface 3 6 8 2 7 9 13 14 5 12 4 10 11 1 1a 1b 1c 1d 1e Download more network handouts at www.kateto.net / www.ognyanova.net 1 After you install the NodeXL template, a new NodeXL tab will appear in your Excel interface. The following features will be available in it: Fig.1 → 1: Switch between different data tabs. The most important two tabs are "Edges" and "Vertices". Fig.1 → 2: Import data into NodeXL. The formats you can use include GraphML, UCINET DL files, and Pajek .net files, among others. You can also import data from social media: Flickr, YouTube, Twitter, Facebook (requires a plugin), or a hyperlink networks (requires a plugin).
    [Show full text]
  • A Model-Driven Approach for Graph Visualization
    A Model-Driven Approach for Graph Visualization Celal Çı ğır, Alptu ğ Dilek, Akif Burak Tosun Department of Computer Engineering, Bilkent University 06800, Bilkent, Ankara {cigir, alptug, tosun}@cs.bilkent.edu.tr Abstract part of the geometrical information and they should be adjusted either manually or automatically in order to produce an understandable and clear graph. This Graphs are data models, which are used in many areas operation is called “graph layout ”. Many complex graphs from networking to biology to computer science. There can be laid out in seconds using automatic graph layouts. are many commercial and non-commercial graph visualization tools. Creating a graph metamodel with Many different graph visualization tools are available graph visualization capability should provide either commercially or freely and they present a variety of interoperability between different graph visualization features. Among one of these, CHISIO [1] is general tools; moreover it should be the core to visualize graphs purpose graph visualization and editing tool for proper from different domains. A detailed and comprehensive creation, layout and modification of graphs. CHISIO research study is required to construct a fully model includes compound graph visualization support among with different styles of layouts that can also work on driven graph visualization software. However according compound graphs. Another example for graph to the study explained in this paper, MDSD steps are visualization software is Graphviz which consists of a successfully applied and interoperability is achieved graph description language named the DOT language and between CHISIO and Graphviz visualization tools. a set of tool that can generate and process DOT files [2] .
    [Show full text]
  • Characterizing the Hypergraph-Of-Entity and the Structural Impact of Its Extensions
    Devezas and Nunes Appl Netw Sci (2020) 5:79 https://doi.org/10.1007/s41109‑020‑00320‑z Applied Network Science RESEARCH Open Access Characterizing the hypergraph‑of‑entity and the structural impact of its extensions José Devezas* and Sérgio Nunes *Correspondence: [email protected] Abstract INESC TEC and Faculty The hypergraph-of-entity is a joint representation model for terms, entities and their of Engineering, University of Porto, Rua Dr. Roberto relations, used as an indexing approach in entity-oriented search. In this work, we Frias, s/n, 4200-465 Porto, PT, characterize the structure of the hypergraph, from a microscopic and macroscopic Portugal scale, as well as over time with an increasing number of documents. We use a random walk based approach to estimate shortest distances and node sampling to estimate clustering coefcients. We also propose the calculation of a general mixed hypergraph density measure based on the corresponding bipartite mixed graph. We analyze these statistics for the hypergraph-of-entity, fnding that hyperedge-based node degrees are distributed as a power law, while node-based node degrees and hyperedge cardinali- ties are log-normally distributed. We also fnd that most statistics tend to converge after an initial period of accentuated growth in the number of documents. We then repeat the analysis over three extensions—materialized through synonym, context, and tf_bin hyperedges—in order to assess their structural impact in the hypergraph. Finally, we focus on the application-specifc aspects of the hypergraph-of-entity, in the domain of information retrieval. We analyze the correlation between the retrieval efectiveness and the structural features of the representation model, proposing ranking and anom- aly indicators, as useful guides for modifying or extending the hypergraph-of-entity.
    [Show full text]
  • A Hypergraph Data Model for Building Multilingual Dictionary Applications Louis Lecailliez, Mathieu Mangeot
    A Hypergraph Data Model for Building Multilingual Dictionary Applications Louis Lecailliez, Mathieu Mangeot To cite this version: Louis Lecailliez, Mathieu Mangeot. A Hypergraph Data Model for Building Multilingual Dictionary Applications. ASIALEX 2018, Jun 2018, Krabi, Thailand. hal-01992846 HAL Id: hal-01992846 https://hal.archives-ouvertes.fr/hal-01992846 Submitted on 24 Jan 2019 HAL is a multi-disciplinary open access L’archive ouverte pluridisciplinaire HAL, est archive for the deposit and dissemination of sci- destinée au dépôt et à la diffusion de documents entific research documents, whether they are pub- scientifiques de niveau recherche, publiés ou non, lished or not. The documents may come from émanant des établissements d’enseignement et de teaching and research institutions in France or recherche français ou étrangers, des laboratoires abroad, or from public or private research centers. publics ou privés. A Hypergraph Data Model for Building Multilingual Dictionary Applications Louis Lecailliez1, Mathieu Mangeot2 1 NLP Centre, Masaryk University, 602 00 Brno, Czech Republic 2 IG, Université Savoie Mont Blanc, 38400 Saint Martin d’Hères, France E-mail: [email protected], [email protected] Abstract A non-negligible part of learners of an East Asian language have an interest for another tongue from East Asia that may share some common areal features such as the use of Chinese Characters and limited word morphology. It makes sense to build for this niche a dictionary application that provides multiple languages in one bundle and allow easy navigation between them and in the lexicon. This paper describes a data model, a generic dictionary application architecture and a prototype that fit this use case.
    [Show full text]
  • Guide to Tools for Social Media & Web Analytics and Insights
    This is a repository copy of Guide to tools for social media & web analytics and insights. White Rose Research Online URL for this paper: http://eprints.whiterose.ac.uk/114759/ Article: Kennedy, H., Moss, G., Birchall, C. et al. (1 more author) (2013) Guide to tools for social media & web analytics and insights. Working Papers of the Communities & Culture Network+, 2. ISSN 2052-7268 Reuse Unless indicated otherwise, fulltext items are protected by copyright with all rights reserved. The copyright exception in section 29 of the Copyright, Designs and Patents Act 1988 allows the making of a single copy solely for the purpose of non-commercial research or private study within the limits of fair dealing. The publisher or other rights-holder may allow further reproduction and re-use of this version - refer to the White Rose Research Online record for this item. Where records identify the publisher as the copyright holder, users can verify any specific terms of use on the publisher’s website. Takedown If you consider content in White Rose Research Online to be in breach of UK law, please notify us by emailing [email protected] including the URL of the record and the reason for the withdrawal request. [email protected] https://eprints.whiterose.ac.uk/ Digital Data Analysis: Guide to tools for social media & web analytics and insights July 2013 From the research project Digital Data Analysis, Public Engagement and the Social Life of Methods Helen Kennedy, Giles Moss, Chris Birchall, Stylianos Moshonas, Institute of Communications Studies, University of Leeds Funded by the EPSRC/Digital Economy Communities & Culture Network + (http://www.communitiesandculture.org/) Contents Digital Data Analysis: ..............................................................................................
    [Show full text]
  • Igraph – a Package for Network Analysis
    igraph { a package for network analysis G´abor Cs´ardi [email protected] Department of Medical Genetics, University of Lausanne, Lausanne, Switzerland Outline 1. Why another graph package? 2. igraph architecture, data model and data representation 3. Manipulating graphs 4. Features and their time complexity igraph { a package for network analysis 2 Why another graph package? • graph is slow. RBGL is slow, too. 1 > ba2 # graph & RBGL 2 A graphNEL graph with undirected edges 3 Number of Nodes = 100000 4 Number of Edges = 199801 ? Why another graph package? • graph is slow. RBGL is slow, too. 1 > ba2 # graph & RBGL 2 A graphNEL graph with undirected edges 3 Number of Nodes = 100000 4 Number of Edges = 199801 5 > system.time(RBGL::transitivity(ba2)) ? 6 user system elapsed 7 7.517 0.000 7.567 Why another graph package? • graph is slow. RBGL is slow, too. 1 > ba2 # graph & RBGL 2 A graphNEL graph with undirected edges 3 Number of Nodes = 100000 4 Number of Edges = 199801 5 > system.time(RBGL::transitivity(ba2)) ? 6 user system elapsed 7 7.517 0.000 7.567 8 > summary(ba) # igraph 9 Vertices: 1e+05 10 Edges: 199801 11 Directed: FALSE 12 No graph attributes. 13 No vertex attributes. 14 No edge attributes. Why another graph package? • graph is slow. RBGL is slow, too. 1 > ba2 # graph & RBGL 2 A graphNEL graph with undirected edges 3 Number of Nodes = 100000 4 Number of Edges = 199801 5 > system.time(RBGL::transitivity(ba2)) ? 6 user system elapsed 7 7.517 0.000 7.567 8 > summary(ba) # igraph 9 Vertices: 1e+05 10 Edges: 199801 11 Directed: FALSE 12 No graph attributes.
    [Show full text]
  • Graphml Progress Report*
    GraphML Progress Report Structural Layer Proposal Ulrik Brandes1, Markus Eiglsperger2, Ivan Herman3, Michael Himsolt4, and M. Scott Marshall3 1 Department of Computer & Information Science, University of Konstanz. [email protected] 2 Wilhelm Schickard Institute for Computer Science, University of T¨ubingen. [email protected] 3 Centrum voor Wiskunde en Informatica. {ivan|scott}@cwi.nl 4 DaimlerChrysler Research. [email protected] Abstract. Following a workshop on graph data formats held with the 8th Symposium on Graph Drawing (GD 2000), a task group was formed to propose a format for graphs and graph drawings that meets current and projected requirements. On behalf of this task group, we here present GraphML (Graph Markup Language), an XML format for graph structures, as an initial step to- wards this goal. Its main characteristic is a unique mechanism that allows to define extension modules for additional data, such as graph drawing information or data specific to a particular application. These modules can freely be combined or stripped without affecting the graph structure, so that information can be added (or omitted) in a well-defined way. 1 Introduction Graph drawing tools, like all other tools dealing with relational data, need to store and exchange graphs and associated data. Despite several earlier attempts to define a standard, no agreed-upon format is widely accepted and, indeed, many tools support only a limited number of custom formats which are typically restricted in their expressibility and specific to an area of application. Motivated by the goals of tool interoperability, access to benchmark data sets, and data exchange over the Web, the Steering Committee of the Graph Drawing Symposium started a new initiative with an informal workshop held in conjunction with the 8th Symposium on Graph Drawing (GD 2000) [1].
    [Show full text]
  • Graphi Documentation Release 0.3.0
    graphi Documentation Release 0.3.0 Max Fischer Nov 16, 2018 Documentation Topics Overview: 1 Quick Usage Reference 3 2 Common Graph Operations 5 3 Graph Syntax 9 4 Glossary 11 5 graphi Changelog 13 6 graphi 15 7 Frequently Asked Questions 33 8 Indices and tables 35 Python Module Index 37 i ii graphi Documentation, Release 0.3.0 Documentation Topics Overview: 1 graphi Documentation, Release 0.3.0 2 Documentation Topics Overview: CHAPTER 1 Quick Usage Reference GraphI is primarily meant for working directly on graph data. The primitives you need to familiarise yourself with are 1. graphs, which are extended containers, 2. nodes, which are arbitrary objects in a graph, 3. edges, which are connections between objects in a graph, and 4. edge values, which are values assigned to connections in a graph. edge z }| { flighttime[Berlin : London] = 3900 | {z } | {z } | {z } | {z } graph node node value This documentation page gives an overview of the most important aspects. The complete interface of GraphI is defined and documented by Graph. 1.1 Creating Graphs and adding Nodes You can create graphs empty, via cloning, from nodes or with nodes, edges and values. For many use-cases, it is simplest to start with a set of nodes: from graphi import graph planets= graph("Earth","Jupiter","Mars","Pluto") Once you have a graph, it works similar to a set for nodes. You can simply add() and discard() nodes: planets.add("Venus") planets.add("Mercury") planets.discard("Pluto") 3 graphi Documentation, Release 0.3.0 1.2 Working with Edges and Values To really make use of a graph, you will want to add edges and give them values.
    [Show full text]
  • Advanced Topics in Visualization Today’S Menu
    DATA11001 INTRODUCTION TO DATA SCIENCE EPISODE 4: ADVANCED TOPICS IN VISUALIZATION TODAY’S MENU 1. NETWORKS 2. SPATIO- TEMPORAL DATA 3. INTERACTIVE VISUALIZATION NETWORKS/GRAPHS • Topological structures, such as orderings, hierarchies (trees), and networks require visualization techniques different from those for metric data (1D or 2D plots, most notably) • Plotting graphs can suggest more information than there is: = NETWORKS/GRAPHS • Topological structures, such as orderings, hierarchies (trees), and networks require visualization techniques different from those for metric data (1D or 2D plots, most notably) • Plotting graphs can suggest more information than there is: = NETWORKS/GRAPHS • Topological structures, such as orderings, hierarchies (trees), and networks require visualization techniques different from those for metric data (1D or 2D plots, most notably) • Plotting graphs can suggest more information than there is: = NETWORKS/GRAPHS • Data formats: – jsongraph { "graph": { "nodes": [ { "id": "A", }, { "id": "B", } ], "edges": [ { "source": "A", "target": "B" } ] } } NETWORKS/GRAPHS • Data formats: – jsongraph – DOT (GraphViz) digraph G { A -> B; } NETWORKS/GRAPHS • Data formats: – jsongraph – DOT (GraphViz) – GraphML (XML-based) <?xml version="1.0" encoding="UTF-8"?> <graphml xmlns="http://graphml.graphdrawing.org/xmlns" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://graphml.graphdrawing.org/xmlns http://graphml.graphdrawing.org/xmlns/1.0/graphml.xsd"> <graph id="G" edgedefault="directed"> <node
    [Show full text]
  • Tutorial 2: Networkx & Graphviz
    CMSC5733 Social Computing Tutorial 2: NetworkX & Graphviz Baichuan Li The Chinese University of Hong Kong [email protected] Outline • NetworkX • Creating A Graph • Adding Attributes • Directed Graphs • Graph Generators • Analyzing Graphs • Drawing Graphs • Graphviz • Dot Language • Sample Graphs NETWORKX Introduction • A Python language software package for the creation, manipulation, and study of the structure, dynamics, and functions of complex networks • What can it do? • Load and store networks • Generate random and classic networks • Analyze network structure • Build network models • Draw networks • ... Installing • Quick install • Python Egg: http://pypi.python.org/pypi/networkx • easy_install networkx or pip install networkx • Current version: 1.8 • Requirement: Python version 2.6 or later • Optional packages • NumPy, SciPy, Matplotlib, Pyparsing, etc. Creating A Graph • Create an empty graph with no nodes and no edges • In NetworkX, nodes can be any hashable object e.g. a text string, an image, an XML object, another Graph, a customized node object, etc. Nodes • Add one node at a time • Add a list of nodes • Add nbunch of nodes • An nbunch is any iterable container of nodes that is not itself a node in the graph • E.g., a list, set, graph, file, etc. • Add a graph as a node Demolishing A Graph • Functions • remove_node() • remove_nodes_from() • remove_edge() • remove_edges_from() • clear() Graph Properties • Functions • nodes() • number_of_nodes() • edges() • number_of_edges() • neighbors() • degree() • … Adding Attributes •
    [Show full text]