pyrdf2vec.walkers.anonymous module

class pyrdf2vec.walkers.anonymous.AnonymousWalker(max_depth, max_walks=None, sampler=NOTHING, n_jobs=None, *, with_reverse=False, random_state=None, md5_bytes=8)

Bases: pyrdf2vec.walkers.random.RandomWalker

Anonymous walking strategy which transforms each vertex name other than the root node, into positional information, in order to anonymize the randomly extracted walks.

_is_support_remote

True if the walking strategy can be used with a remote Knowledge Graph, False Otherwise Defaults to True.

kg

The global KG used later on for the worker process. Defaults to None.

max_depth

The maximum depth of one walk.

max_walks

The maximum number of walks per entity. Defaults to None.

random_state

The random state to use to keep random determinism with the walking strategy. Defaults to None.

sampler

The sampling strategy. Defaults to UniformSampler.

with_reverse

True to extracts parents and children hops from an entity, creating (max_walks * max_walks) more walks of 2 * depth, allowing also to centralize this entity in the walks. False otherwise. Defaults to False.