API Reference#
Python bindings for Universal Key Value store library.#
Supports:#
Collection-level CRUD operations, like dict.
Batch operations & ACID transactions.
Graph collections, mimicking networkx.
Tabular views, mimicking pandas.
Apache Arrow exports for inter-process communication.
- class ustore.rocksdb.Collection#
- broadcast(self: ustore.rocksdb.Collection, arg0: object, arg1: object) None #
- clear(self: ustore.rocksdb.Collection) None #
- property docs#
- get(self: ustore.rocksdb.Collection, arg0: object) object #
- get_matrix(self: ustore.rocksdb.Collection, arg0: object, arg1: int, arg2: str) int #
- property graph#
- has_key(self: ustore.rocksdb.Collection, arg0: object) object #
- property items#
- property keys#
- property media#
- pop(self: ustore.rocksdb.Collection, arg0: object) None #
- remove(self: ustore.rocksdb.Collection) None #
- sample_keys(self: ustore.rocksdb.Collection, arg0: int) object #
- scan(self: ustore.rocksdb.Collection, arg0: int, arg1: int) numpy.ndarray[numpy.int64] #
- set(self: ustore.rocksdb.Collection, arg0: object, arg1: object) None #
- set_matrix(self: ustore.rocksdb.Collection, arg0: object, arg1: object) int #
- property table#
- update(self: ustore.rocksdb.Collection, arg0: object) None #
- class ustore.rocksdb.DataBase#
- clear(self: ustore.rocksdb.DataBase) None #
- close(self: ustore.rocksdb.DataBase) None #
- collection_names(self: ustore.rocksdb.DataBase) List[str] #
- property main#
- class ustore.rocksdb.DataFrame#
- astype(self: ustore.rocksdb.DataFrame, arg0: handle) ustore.rocksdb.DataFrame #
- drop(self: ustore.rocksdb.DataFrame, arg0: object) None #
- property empty#
- head(self: ustore.rocksdb.DataFrame, arg0: int) ustore.rocksdb.DataFrame #
- insert(*args, **kwargs)#
Overloaded function.
insert(self: ustore.rocksdb.DataFrame, arg0: str, arg1: object) -> None
insert(self: ustore.rocksdb.DataFrame, arg0: object) -> None
- loc(self: ustore.rocksdb.DataFrame, arg0: handle) ustore.rocksdb.DataFrame #
- merge(self: ustore.rocksdb.DataFrame, arg0: ustore.rocksdb.DataFrame) None #
- rename(self: ustore.rocksdb.DataFrame, arg0: object) None #
- sample(self: ustore.rocksdb.DataFrame, arg0: int) ustore.rocksdb.DataFrame #
- property shape#
- property size#
- tail(self: ustore.rocksdb.DataFrame, arg0: int) ustore.rocksdb.DataFrame #
- to_arrow(self: ustore.rocksdb.DataFrame) object #
- to_csv(self: ustore.rocksdb.DataFrame, arg0: str) None #
- to_json(self: ustore.rocksdb.DataFrame, path: str = '') object #
- to_parquet(self: ustore.rocksdb.DataFrame, arg0: str) None #
- update(self: ustore.rocksdb.DataFrame, arg0: object) None #
- class ustore.rocksdb.DegreeView#
- class ustore.rocksdb.DegreesStream#
- class ustore.rocksdb.DocsCollection#
- broadcast(self: ustore.rocksdb.DocsCollection, arg0: object, arg1: object) None #
- clear(self: ustore.rocksdb.DocsCollection) None #
- get(self: ustore.rocksdb.DocsCollection, arg0: object) object #
- has_key(self: ustore.rocksdb.DocsCollection, arg0: object) object #
- property items#
- property keys#
- merge(self: ustore.rocksdb.DocsCollection, arg0: object, arg1: object) None #
- patch(self: ustore.rocksdb.DocsCollection, arg0: object, arg1: object) None #
- remove(self: ustore.rocksdb.DocsCollection, arg0: object) None #
- scan(self: ustore.rocksdb.DocsCollection, arg0: int, arg1: int) object #
- set(self: ustore.rocksdb.DocsCollection, arg0: object, arg1: object) None #
- class ustore.rocksdb.DocsKVRange#
- since(self: ustore.rocksdb.DocsKVRange, arg0: int) ustore.rocksdb.DocsKVRange #
- until(self: ustore.rocksdb.DocsKVRange, arg0: int) ustore.rocksdb.DocsKVRange #
- class ustore.rocksdb.DocsKVStream#
- class ustore.rocksdb.EdgesIter#
- class ustore.rocksdb.EdgesRange#
- class ustore.rocksdb.EdgesStream#
- class ustore.rocksdb.ItemsRange#
- since(self: ustore.rocksdb.ItemsRange, arg0: int) ustore.rocksdb.ItemsRange #
- until(self: ustore.rocksdb.ItemsRange, arg0: int) ustore.rocksdb.ItemsRange #
- class ustore.rocksdb.ItemsStream#
- class ustore.rocksdb.KeysRange#
- since(self: ustore.rocksdb.KeysRange, arg0: int) ustore.rocksdb.KeysRange #
- until(self: ustore.rocksdb.KeysRange, arg0: int) ustore.rocksdb.KeysRange #
- class ustore.rocksdb.KeysStream#
- class ustore.rocksdb.Network#
- add_edge(*args, **kwargs)#
Overloaded function.
add_edge(self: ustore.rocksdb.Network, u_for_edge: int, v_for_edge: int) -> None
add_edge(self: ustore.rocksdb.Network, u_for_edge: int, v_for_edge: int, id: int, **kwargs) -> None
- add_edges_from(*args, **kwargs)#
Overloaded function.
add_edges_from(self: ustore.rocksdb.Network, ebunch_to_add: object) -> None
Adds an adjacency list (in a form of 2 or 3 columnar matrix) to the graph.
add_edges_from(self: ustore.rocksdb.Network, us: object, vs: object, keys: object = None, **kwargs) -> None
Adds edges from members of the first array to members of the second array.
- add_node(self: ustore.rocksdb.Network, v_to_upsert: int, **kwargs) None #
- add_nodes_from(self: ustore.rocksdb.Network, arg0: object, **kwargs) None #
- property allows_loops#
- clear(self: ustore.rocksdb.Network) None #
Removes both vertices and edges from the graph.
- clear_edges(self: ustore.rocksdb.Network) None #
Removes edges from the graph.
- community_louvain(self: ustore.rocksdb.Network) object #
Community Louvain.
- copy(self: ustore.rocksdb.Network) None #
- property degree#
A DegreeView for the graph.
- edge_subgraph(self: ustore.rocksdb.Network) None #
- property edges#
- get_edge_attributes(self: ustore.rocksdb.Network, name: str) object #
- get_edge_data(self: ustore.rocksdb.Network, u: int, v: int, default: object = None) object #
- get_node_attributes(self: ustore.rocksdb.Network, name: str) object #
- has_edge(*args, **kwargs)#
Overloaded function.
has_edge(self: ustore.rocksdb.Network, u: int, v: int) -> bool
has_edge(self: ustore.rocksdb.Network, u: int, v: int, key: int) -> bool
- has_node(self: ustore.rocksdb.Network, n: int) bool #
Returns True if the graph contains the node n.
- property in_degree#
A DegreeView with the number incoming edges for each Vertex.
- is_directed(self: ustore.rocksdb.Network) bool #
- is_multigraph(self: ustore.rocksdb.Network) bool #
- nbunch_iter(self: ustore.rocksdb.Network, arg0: _object) numpy.ndarray[numpy.int64] #
Filters given nodes which are also in the graph and returns an iterator over them.
- neighbors(self: ustore.rocksdb.Network, n: int) object #
Returns an iterable of incoming and outgoing nodes of n. Potentially with duplicates.
- property nodes#
A NodeView of the graph.
- number_of_edges(*args, **kwargs)#
Overloaded function.
number_of_edges(self: ustore.rocksdb.Network, arg0: int, arg1: int) -> int
Returns the number of edges between two nodes.
number_of_edges(self: ustore.rocksdb.Network) -> int
Returns edges count
- number_of_nodes(self: ustore.rocksdb.Network) int #
Returns the number of nodes in the graph.
- order(self: ustore.rocksdb.Network) int #
Returns the number of nodes in the graph.
- property out_degree#
A DegreeView with the number outgoing edges for each Vertex.
- predecessors(self: ustore.rocksdb.Network, n: int) object #
Returns an iterable of follower nodes of n.
- remove_edge(*args, **kwargs)#
Overloaded function.
remove_edge(self: ustore.rocksdb.Network, u_for_edge: int, v_for_edge: int) -> None
remove_edge(self: ustore.rocksdb.Network, u_for_edge: int, v_for_edge: int, key: int) -> None
- remove_edges_from(*args, **kwargs)#
Overloaded function.
remove_edges_from(self: ustore.rocksdb.Network, ebunch: object) -> None
Removes all edges in supplied adjacency list (in a form of 2 or 3 columnar matrix) from the graph.
remove_edges_from(self: ustore.rocksdb.Network, us: object, vs: object, keys: object = None) -> None
Removes edges from members of the first array to members of the second array.
- remove_node(self: ustore.rocksdb.Network, v_to_remove: int) None #
- remove_nodes_from(self: ustore.rocksdb.Network, arg0: object) None #
- reverse(self: ustore.rocksdb.Network) None #
- set_edge_attributes(self: ustore.rocksdb.Network, values: object, name: str | None = None) None #
- set_node_attributes(self: ustore.rocksdb.Network, values: object, name: str | None = None) None #
- size(self: ustore.rocksdb.Network, weight: str = '') int #
Returns the number of attributed edges.
- subgraph(*args, **kwargs)#
Overloaded function.
subgraph(self: ustore.rocksdb.Network) -> None
subgraph(self: ustore.rocksdb.Network, arg0: object) -> None
Returns a subgraph in a form of an adjacency list with 3 columns, where every edge (row) contains at least one vertex from the supplied list. Some edges may be duplicated.
subgraph(self: ustore.rocksdb.Network, arg0: int, arg1: int) -> None
Returns a subgraph in a form of an adjacency list with 3 columns, where every edge (row) contains at least one vertex from the supplied list at a distance withing a given number hops from the supplied n.
- successors(self: ustore.rocksdb.Network, n: int) object #
Returns an iterable of successor nodes of n.
- to_directed(self: ustore.rocksdb.Network) None #
- to_undirected(self: ustore.rocksdb.Network) None #
- class ustore.rocksdb.NodesRange#
- class ustore.rocksdb.NodesStream#
- class ustore.rocksdb.Transaction#
- commit(self: ustore.rocksdb.Transaction) None #
- property main#
- ustore.rocksdb.allows_loops(arg0: ustore.rocksdb.Network) bool #
- ustore.rocksdb.density(arg0: ustore.rocksdb.Network) float #
- ustore.rocksdb.from_dict(arg0: ustore.rocksdb.Collection, arg1: object) ustore.rocksdb.DataFrame #
- ustore.rocksdb.from_records(arg0: ustore.rocksdb.Collection, arg1: object) ustore.rocksdb.DataFrame #
- ustore.rocksdb.is_directed(arg0: ustore.rocksdb.Network) bool #
- ustore.rocksdb.is_multi(arg0: ustore.rocksdb.Network) bool #
- ustore.rocksdb.write_adjlist(G: ustore.rocksdb.Network, path: str, comments: str = '#', delimiter: str = ' ', encoding: str = 'utf-8') None #