grakel.VertexHistogram

class grakel.VertexHistogram(n_jobs=None, normalize=False, verbose=False, sparse='auto')[source][source]

Vertex Histogram kernel as found in [SB15].

Parameters
sparsebool, or ‘auto’, default=’auto’

Defines if the data will be stored in a sparse format. Sparse format is slower, but less memory consuming and in some cases the only solution. If ‘auto’, uses a sparse matrix when the number of zeros is more than the half of the matrix size. In all cases if the dense matrix doesn’t fit system memory, I sparse approach will be tried.

Attributes
None.

Methods

diagonal()

Calculate the kernel matrix diagonal of the fitted data.

fit(X[, y])

Fit a dataset, for a transformer.

fit_transform(X)

Fit and transform, on the same dataset.

get_params([deep])

Get parameters for this estimator.

initialize()

Initialize all transformer arguments, needing initialisation.

pairwise_operation(x, y)

Calculate a pairwise kernel between two elements.

parse_input(X)

Parse and check the given input for VH kernel.

set_params(**params)

Call the parent method.

transform(X)

Calculate the kernel matrix, between given and fitted dataset.

Initialise a vertex histogram kernel.

Attributes
X

Methods

diagonal()

Calculate the kernel matrix diagonal of the fitted data.

fit(X[, y])

Fit a dataset, for a transformer.

fit_transform(X)

Fit and transform, on the same dataset.

get_params([deep])

Get parameters for this estimator.

initialize()

Initialize all transformer arguments, needing initialisation.

pairwise_operation(x, y)

Calculate a pairwise kernel between two elements.

parse_input(X)

Parse and check the given input for VH kernel.

set_params(**params)

Call the parent method.

transform(X)

Calculate the kernel matrix, between given and fitted dataset.

__init__(n_jobs=None, normalize=False, verbose=False, sparse='auto')[source][source]

Initialise a vertex histogram kernel.

Bibliography

SB15

Mahito Sugiyama and Karsten M. Borgwardt. Halting in Random Walk Kernels. In Advances in Neural Information Processing Systems, 1639–1647. 2015.