Skip to main content

Who influences whom in social network - an application for finding key nodes

Project description

Influ

pipeline status Finding influencers in social network

An application created as part of the project

Kto na kogo wpływa w sieci społecznej - aplikacja do wyszukiwania kluczowych węzłów

Who influences whom in social network - an application for finding key nodes

Author: Grzegorz Chilczuk

Supervisor: dr inż. Radosław Michalski

Installation

It should be as simple as

pip install influ

Dependencies

All dependencies will be installed automatically. However one of most important dependencies is cool python library called igraph which core is written in C. Sometimes it may cause some problem, igraph documentation should help.

Debian / Ubuntu and derivatives

If you encounter

Could not download and compile the C core of igraph

then installing those dependencies should help:

 sudo apt install build-essential python-dev libxml2 libxml2-dev zlib1g-dev

Konect Reader

In order to test your concepts quickly there is a KonectReader which simplifies downloading and extracting datasets and loading them into Graph object.

from influ import KonectReader

kr = KonectReader()
kr.list  # list available datasets
graph = kr.load('manufacturing_emails')  # load dataset

Currently there is only few datasets available but you can provide your own config file with other datasets specified. Currently only datasets from Konect are supported.

Your own config file

# Content of my_custom_config.yaml
example_dataset:  # name that will be used to access dataset
  name: Example Dataset 1
  url: http://konect.uni-koblenz.de/networks/dataset_examle  # url where dataset is described [optional]
  download: http://konect.uni-koblenz.de/downloads/tsv/dataset_examle.tar.bz2  # url where dataset can be downloaded directly
  file: out.dataset_example_example  # name of file with 
  directed: False  # does graph should be considered as directed?
  edge_attributes:  # list of names attributes
    - distance      # if this list will be empty or there will be more attributes
    - another_attr  # it will be named `attrX` where X is index counted from 0
  vertex_attributes:                # list of vertex attributes with files where they are stored
    - name: alias                   # name of attribute
      file: ent.vertex_alias_name   # file with attribute

Loading your custom config extends (does not override) those previously loaded.

kr = KonectReader('./my_custom_config.yaml')  # loading at creation time
kr.add_config('./my_custom_config.yaml')      # adding config after creation

Working example

from influ import KonectReader, SeedFinder

kr = KonectReader()
graph = kr.load('train_bombing')
finder = SeedFinder(graph)
result = finder.CELFpp()

——————

Change log

[0.1.0] - 2018-12-01

Added

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

influ-0.1.0.tar.gz (11.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

influ-0.1.0-py3-none-any.whl (11.7 kB view details)

Uploaded Python 3

File details

Details for the file influ-0.1.0.tar.gz.

File metadata

  • Download URL: influ-0.1.0.tar.gz
  • Upload date:
  • Size: 11.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.0

File hashes

Hashes for influ-0.1.0.tar.gz
Algorithm Hash digest
SHA256 383118d5e10d6b1910648efa9ce6b4e7ea90e0625fc157d28cd18fdc23e2334b
MD5 78442df3f22949bd9dbc12cc0d4660e0
BLAKE2b-256 900a141163945c1bbf817bb9afbe0b67dfed8b3b047653ae4c3605634fd9e4a1

See more details on using hashes here.

File details

Details for the file influ-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: influ-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 11.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.0

File hashes

Hashes for influ-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c58639874a900efd79f5e2479feaf4e69efa5a7441c20ee578ee708cef6dc0cc
MD5 628de7983ade32533dc76edadba42409
BLAKE2b-256 6a6ac3ee36c31355ee044e9870499b34b544dab2b4be80d2a6369d8f9adbbe0f

See more details on using hashes here.

Supported by

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