This BigtableTable class is the Python representation of the Cloud Bigtable
table within TensorFlow. Methods on this class allow data to be read from and
written to the Cloud Bigtable service in flexible and high performance
manners.
Retrieves row (including values) from the Bigtable service at high speed.
Rows with row-key prefixed by prefix will be retrieved. This method is
similar to scan_prefix, but by contrast performs multiple sub-scans in
parallel in order to achieve higher performance.
Specifying the columns to retrieve for each row is done by either using
kwargs or in the columns parameter. To retrieve values of the columns "c1",
and "c2" from the column family "cfa", and the value of the column "c3"
from column family "cfb", the following datasets (ds1, and ds2) are
equivalent:
The prefix all row keys must match to be retrieved for prefix-
based scans.
num_parallel_scans
(Optional.) The number of concurrent scans against the
Cloud Bigtable instance.
probability
(Optional.) A float between 0 (exclusive) and 1 (inclusive).
A non-1 value indicates to probabilistically sample rows with the
provided probability.
columns
The columns to read. Note: most commonly, they are expressed as
kwargs. Use the columns value if you are using column families that are
reserved. The value of columns and kwargs are merged. Columns is a list
of tuples of strings ("column_family", "column_qualifier").
**kwargs
The column families and columns to read. Keys are treated as
column_families, and values can be either lists of strings, or strings
that are treated as the column qualifier (column name).
Returns
A tf.data.Dataset returning the row keys and the cell contents.
Retrieves rows (including values) from the Bigtable service.
Rows with row-keys between start and end will be retrieved. This method
is similar to scan_range, but by contrast performs multiple sub-scans in
parallel in order to achieve higher performance.
Specifying the columns to retrieve for each row is done by either using
kwargs or in the columns parameter. To retrieve values of the columns "c1",
and "c2" from the column family "cfa", and the value of the column "c3"
from column family "cfb", the following datasets (ds1, and ds2) are
equivalent:
(Optional.) The end of the range when scanning by range.
num_parallel_scans
(Optional.) The number of concurrent scans against the
Cloud Bigtable instance.
probability
(Optional.) A float between 0 (exclusive) and 1 (inclusive).
A non-1 value indicates to probabilistically sample rows with the
provided probability.
columns
The columns to read. Note: most commonly, they are expressed as
kwargs. Use the columns value if you are using column families that are
reserved. The value of columns and kwargs are merged. Columns is a list
of tuples of strings ("column_family", "column_qualifier").
**kwargs
The column families and columns to read. Keys are treated as
column_families, and values can be either lists of strings, or strings
that are treated as the column qualifier (column name).
Returns
A tf.data.Dataset returning the row keys and the cell contents.
Retrieves row (including values) from the Bigtable service.
Rows with row-key prefixed by prefix will be retrieved.
Specifying the columns to retrieve for each row is done by either using
kwargs or in the columns parameter. To retrieve values of the columns "c1",
and "c2" from the column family "cfa", and the value of the column "c3"
from column family "cfb", the following datasets (ds1, and ds2) are
equivalent:
The prefix all row keys must match to be retrieved for prefix-
based scans.
probability
(Optional.) A float between 0 (exclusive) and 1 (inclusive).
A non-1 value indicates to probabilistically sample rows with the
provided probability.
columns
The columns to read. Note: most commonly, they are expressed as
kwargs. Use the columns value if you are using column families that are
reserved. The value of columns and kwargs are merged. Columns is a list
of tuples of strings ("column_family", "column_qualifier").
**kwargs
The column families and columns to read. Keys are treated as
column_families, and values can be either lists of strings, or strings
that are treated as the column qualifier (column name).
Returns
A tf.data.Dataset returning the row keys and the cell contents.
Retrieves rows (including values) from the Bigtable service.
Rows with row-keys between start and end will be retrieved.
Specifying the columns to retrieve for each row is done by either using
kwargs or in the columns parameter. To retrieve values of the columns "c1",
and "c2" from the column family "cfa", and the value of the column "c3"
from column family "cfb", the following datasets (ds1, and ds2) are
equivalent:
(Optional.) The end of the range when scanning by range.
probability
(Optional.) A float between 0 (exclusive) and 1 (inclusive).
A non-1 value indicates to probabilistically sample rows with the
provided probability.
columns
The columns to read. Note: most commonly, they are expressed as
kwargs. Use the columns value if you are using column families that are
reserved. The value of columns and kwargs are merged. Columns is a list
of tuples of strings ("column_family", "column_qualifier").
**kwargs
The column families and columns to read. Keys are treated as
column_families, and values can be either lists of strings, or strings
that are treated as the column qualifier (column name).
Returns
A tf.data.Dataset returning the row keys and the cell contents.
A tf.data.Dataset to be written to this table. It must produce
a list of number-of-columns+1 elements, all of which must be strings.
The first value will be used as the row key, and subsequent values will
be used as cell values for the corresponding columns from the
corresponding column_families and columns entries.
column_families
A tf.Tensor of tf.strings corresponding to the
column names to store the dataset's elements into.
columns
A tf.Tensor of tf.strings corresponding to the column names
to store the dataset's elements into.
timestamp
(Optional.) An int64 timestamp to write all the values at.
Leave as None to use server-provided timestamps.
Returns
A tf.Operation that can be run to perform the write.
Raises
ValueError
If there are unexpected or incompatible types, or if the
number of columns and column_families does not match the output of
dataset.