py3plex.core.HINMINE package¶
Submodules¶
py3plex.core.HINMINE.IO module¶
-
py3plex.core.HINMINE.IO.
load_hinmine_object
(infile, label_delimiter='---', weight_tag=False, targets=True)¶
py3plex.core.HINMINE.dataStructures module¶
-
class
py3plex.core.HINMINE.dataStructures.
Class
(lab_id, name, members)¶ Bases:
object
-
class
py3plex.core.HINMINE.dataStructures.
HeterogeneousInformationNetwork
(network, label_delimiter, weight_tag=False, target_tag=True)¶ Bases:
object
-
add_label
(node, label_id, label_name=None)¶
-
calculate_decomposition_candidates
(max_decomposition_length=10)¶
-
calculate_schema
()¶
-
create_label_matrix
(weights=None)¶
-
decompose_from_iterator
(name, weighing, summing, generator=None, degrees=None, parallel=False, pool=None)¶
-
midpoint_generator
(node_sequence, edge_sequence)¶
-
process_network
(label_delimiter)¶
-
split_to_indices
(train_indices=(), validate_indices=(), test_indices=())¶
-
split_to_parts
(lst, n)¶
-
py3plex.core.HINMINE.decomposition module¶
-
py3plex.core.HINMINE.decomposition.
aggregate_sum
(input_thing, classes, universal_set)¶
-
py3plex.core.HINMINE.decomposition.
aggregate_weighted_sum
(input_thing, classes, universal_set)¶
-
py3plex.core.HINMINE.decomposition.
calculate_importance_chi
(classes, universal_set, linked_nodes, n, **kwargs)¶ Calculates importance of a single midpoint using chi-squared weighing. :param classes: List of all classes :param universal_set: Set of all indices to consider :param linked_nodes: Set of all nodes linked by the midpoint :param n: Number of elements of universal set :return: List of weights of the midpoint for each label in class
-
py3plex.core.HINMINE.decomposition.
calculate_importance_delta
(classes, universal_set, linked_nodes, n, **kwargs)¶ Calculates importance of a single midpoint using delta-idf weighing :param classes: List of all classes :param universal_set: Set of all indices to consider :param linked_nodes: Set of all nodes linked by the midpoint :param n: Number of elements of universal set :return: List of weights of the midpoint for each label in class
-
py3plex.core.HINMINE.decomposition.
calculate_importance_gr
(classes, universal_set, linked_nodes, n, **kwargs)¶ Calculates importance of a single midpoint using the GR (gain ratio) :param classes: List of all classes :param universal_set: Set of all indices to consider :param linked_nodes: Set of all nodes linked by the midpoint :param n: Number of elements of universal set :return: List of weights of the midpoint for each label in class
-
py3plex.core.HINMINE.decomposition.
calculate_importance_idf
(classes, universal_set, linked_nodes, n, **kwargs)¶ Calculates importance of a single midpoint using idf weighing :param classes: List of all classes :param universal_set: Set of all indices to consider :param linked_nodes: Set of all nodes linked by the midpoint :param n: Number of elements of universal set :return: List of weights of the midpoint for each label in class
-
py3plex.core.HINMINE.decomposition.
calculate_importance_ig
(classes, universal_set, linked_nodes, n, **kwargs)¶ Calculates importance of a single midpoint using IG (information gain) weighing :param classes: List of all classes :param universal_set: Set of all indices to consider :param linked_nodes: Set of all nodes linked by the midpoint :param n: Number of elements of universal set :return: List of weights of the midpoint for each label in class
-
py3plex.core.HINMINE.decomposition.
calculate_importance_okapi
(classes, universal_set, linked_nodes, n, degrees=None, avgdegree=None)¶
-
py3plex.core.HINMINE.decomposition.
calculate_importance_rf
(classes, universal_set, linked_nodes, n, **kwargs)¶ Calculates importance of a single midpoint using rf weighing :param classes: List of all classes :param universal_set: Set of all indices to consider :param linked_nodes: Set of all nodes linked by the midpoint :param n: Number of elements of universal set :return: List of weights of the midpoint for each label in class
-
py3plex.core.HINMINE.decomposition.
calculate_importance_tf
(classes, universal_set, linked_nodes, n, **kwargs)¶ Calculates importance of a single midpoint using term frequency weighing. :param classes: List of all classes :param universal_set: Set of all indices to consider :param linked_nodes: Set of all nodes linked by the midpoint :param n: Number of elements of universal set :return: List of weights of the midpoint for each label in class
-
py3plex.core.HINMINE.decomposition.
calculate_importance_w2w
(classes, universal_set, linked_nodes, n, **kwargs)¶
-
py3plex.core.HINMINE.decomposition.
calculate_importances
(midpoints, classes, universal_set, method, degrees=None, avgdegree=None)¶
-
py3plex.core.HINMINE.decomposition.
chi_value
(actual_pos_num, predicted_pos_num, tp, n)¶
-
py3plex.core.HINMINE.decomposition.
get_aggregation_method
(method_name)¶
-
py3plex.core.HINMINE.decomposition.
get_calculation_method
(method_name)¶
-
py3plex.core.HINMINE.decomposition.
gr_value
(actual_pos_num, predicted_pos_num, tp, n)¶
-
py3plex.core.HINMINE.decomposition.
hinmine_decompose
(network, heuristic, cycle=None, parallel=False)¶
-
py3plex.core.HINMINE.decomposition.
hinmine_get_cycles
(network, cycle=None)¶
-
py3plex.core.HINMINE.decomposition.
ig_value
(actual_pos_num, predicted_pos_num, tp, n)¶
-
py3plex.core.HINMINE.decomposition.
np_calculate_importance_chi
(predicted, label_matrix, actual_pos_nums)¶
-
py3plex.core.HINMINE.decomposition.
np_calculate_importance_tf
(predicted, label_matrix)¶
-
py3plex.core.HINMINE.decomposition.
rf_value
(predicted_pos_num, tp)¶