Network input/output

Warning

Do not manually instantiate this class using the class constructor. Instantiate the class using the method noesis.Noesis.create_network_reader().

Network input and output

class noesis.io.NetworkReader(reader, *args)

This class implements the interface for networks readers. These readers can load a network from a file following the specified file format.

Parameters:
  • reader (string) – File format of the network reader. Currently supported formats are ‘ASCII’, ‘GDF’, ‘GML’, ‘GraphML’, ‘Pajek’, ‘SNAP’, and ‘SNAPGZ’.
  • args (parameters) – Parameters for the network reader. These parameters are specific for each file format and more details are provided in NOESIS documentation.
read(filepath)

Read a network from a specific file path.

Parameters:filepath (string) – Path of the file to read.
Returns:network – The network that has been read from the file.
Return type:Network