Skip to main content

Draws graphs.

Project description

app-graphs

Original repository (github). PyPI.

app-graphs uses ogdf-python which in turn uses OGDF. app-graphs draws a graph from data given in .xlsx format. Nodes are generated from given aplications and components as well as from interfaces, where interface represents node and two edges conected to it and source/target node. Edges are generated between aplication and its components and from directed edges provided.

Installation

First we need to install OGDF. This is done by downloading OGDF, unziping it and calling following commands in bash:

foo@bar:~ogdf$ mkdir ogdf-debug ogdf-release
foo@bar:~ogdf$ cd ogdf-debug
foo@bar:~ogdf/ogdf-debug$ cmake ..
foo@bar:~ogdf/ogdf-debug$ ccmake ..

Configure BUILD_SHARED_LIB=ON and CMAKE_BUILD_TYPE=Debug when calling last line.

foo@bar:~ogdf/ogdf-debug$ make

Repeat above for release (debug <-> release). And as a last step add ogdf to path.

foo@bar:~ogdf$ export OGDF_BUILD_DIR=~/ogdf/ogdf-debug

As a last step install app-graphs.

pip install app-graphs

Usage

from app_graphs import graph

# Define graph instance
my_graph = graph()

# Read data from filename_aplikacije and vmesniki_sheet_name
my_graph.read(filename_apps = r'example.xlsx',              # name of file containing information about apps and components
            apps_sheet_name = 'Aplication list',            # name of sheet in above file
            filename_interfaces = r'example.xlsx',          # name of file containing information about interfaces
            interfaces_sheet_name = 'Integration list',     # name of sheet in above file
            apps = 'Aplications',                           # name of apps names column
            components = 'Components',                      # name of components names column
            source = 'Source',                              # name of interface's source app/component column
            target = 'Target',                              # name of interface's target app/component column
            interface_direction = 'Direction',              # name of interface direction column
            technologies = 'Technology',                    # name of technologies names column
            colors = 'Colors'                               # name of colors column
            )

# Uses ogdf-python to generate graph
my_graph.draw()

# Saves genereted graph in desired format
my_graph.save_svg('test-graph')

example

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

app-graphs-0.0.2.tar.gz (16.9 kB view details)

Uploaded Source

Built Distribution

app_graphs-0.0.2-py3-none-any.whl (16.6 kB view details)

Uploaded Python 3

File details

Details for the file app-graphs-0.0.2.tar.gz.

File metadata

  • Download URL: app-graphs-0.0.2.tar.gz
  • Upload date:
  • Size: 16.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.1 pkginfo/1.8.2 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.10

File hashes

Hashes for app-graphs-0.0.2.tar.gz
Algorithm Hash digest
SHA256 5cfd191dceda3a2d127df7189b7b957c6a844dc882a40c1ba08928b51cdd58d7
MD5 6dbadc02f7197a63cf83bef6a48ddc43
BLAKE2b-256 e569576d2daf50b09d85cbc4f6fc236f7543a3f9071e25b1be8760ad05225b0b

See more details on using hashes here.

File details

Details for the file app_graphs-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: app_graphs-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 16.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.1 pkginfo/1.8.2 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.10

File hashes

Hashes for app_graphs-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 ab31ac12049914288a80d6aae267b89deaa1ed7fd483968cec2effb7ba75410f
MD5 346c49dd454dd96a562fc9fe20bf5d7c
BLAKE2b-256 df1d899eeb785fe943a575bfae7894b277bf201d7392ec3f8cc737c698d6153d

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page