mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-09-30 07:02:25 +08:00
Bump mypy-protobuf in sync_tensorflow script and improve generation scripts (#11740)
This commit is contained in:
@@ -35,6 +35,7 @@ echo "Working in $TMP_DIR"
|
||||
wget "$PROTOC_URL"
|
||||
mkdir protoc_install
|
||||
unzip "$PROTOC_FILENAME" -d protoc_install
|
||||
protoc_install/bin/protoc --version
|
||||
|
||||
# Fetch protoc-python (which contains all the .proto files)
|
||||
wget "$PYTHON_PROTOBUF_URL"
|
||||
@@ -67,16 +68,22 @@ PROTO_FILES=$(grep "GenProto.*google" $PYTHON_PROTOBUF_DIR/python/setup.py | \
|
||||
|
||||
# And regenerate!
|
||||
# shellcheck disable=SC2086
|
||||
protoc_install/bin/protoc --proto_path="$PYTHON_PROTOBUF_DIR/src" --mypy_out="relax_strict_optional_primitives:$REPO_ROOT/stubs/protobuf" $PROTO_FILES
|
||||
protoc_install/bin/protoc \
|
||||
--proto_path="$PYTHON_PROTOBUF_DIR/src" \
|
||||
--mypy_out="relax_strict_optional_primitives:$REPO_ROOT/stubs/protobuf" \
|
||||
$PROTO_FILES
|
||||
|
||||
PYTHON_PROTOBUF_VERSION=$(jq -r '.[] | .languages.python' "$PYTHON_PROTOBUF_DIR/version.json")
|
||||
|
||||
# Cleanup after ourselves, this is a temp dir, but it can still grow fast if run multiple times
|
||||
rm -rf "$TMP_DIR"
|
||||
# Must be in a git repository to run pre-commit
|
||||
cd "$REPO_ROOT"
|
||||
|
||||
sed --in-place="" \
|
||||
"s/extra_description = .*$/extra_description = \"Generated using [mypy-protobuf==$MYPY_PROTOBUF_VERSION](https:\/\/github.com\/nipunn1313\/mypy-protobuf\/tree\/v$MYPY_PROTOBUF_VERSION) on [protobuf v$PROTOBUF_VERSION](https:\/\/github.com\/protocolbuffers\/protobuf\/releases\/tag\/v$PROTOBUF_VERSION) (python protobuf==$PYTHON_PROTOBUF_VERSION)\"/" \
|
||||
"$REPO_ROOT/stubs/protobuf/METADATA.toml"
|
||||
stubs/protobuf/METADATA.toml
|
||||
|
||||
# Must be run in a git repository
|
||||
cd "$REPO_ROOT"
|
||||
# use `|| true` so the script still continues even if a pre-commit hook
|
||||
# applies autofixes (which will result in a nonzero exit code)
|
||||
pre-commit run --files $(git ls-files -- "$REPO_ROOT/stubs/protobuf/**_pb2.pyi") || true
|
||||
pre-commit run --files $(git ls-files -- "stubs/protobuf/**_pb2.pyi") || true
|
||||
|
||||
@@ -1,79 +1,97 @@
|
||||
#!/bin/bash
|
||||
set -euxo pipefail
|
||||
|
||||
# Partly based on scripts/generate_proto_stubs.sh.
|
||||
|
||||
# Based on scripts/generate_proto_stubs.sh.
|
||||
# Generates the protobuf stubs for the given tensorflow version using mypy-protobuf.
|
||||
# Generally, new minor versions are a good time to update the stubs.
|
||||
REPO_ROOT="$(realpath "$(dirname "${BASH_SOURCE[0]}")"/..)"
|
||||
|
||||
# This version should be consistent with the version in tensorflow's METADATA.toml.
|
||||
set -euxo pipefail
|
||||
|
||||
# Need protoc >= 3.15 for explicit optional
|
||||
PROTOBUF_VERSION=25.3 # 4.25.3
|
||||
# Whenever you update TENSORFLOW_VERSION here, version should be updated
|
||||
# in stubs/tensorflow/METADATA.toml and vice-versa.
|
||||
TENSORFLOW_VERSION=2.12.1
|
||||
# Latest mypy-protobuf has dependency on protobuf >4, which is incompatible at runtime
|
||||
# with tensorflow. However, the stubs produced do still work with tensorflow. So after
|
||||
# installing mypy-protobuf, before running stubtest on tensorflow you should downgrade
|
||||
# protobuf<4.
|
||||
MYPY_PROTOBUF_VERSION=3.5.0
|
||||
MYPY_PROTOBUF_VERSION=3.6.0
|
||||
|
||||
pip install pre-commit mypy-protobuf=="$MYPY_PROTOBUF_VERSION"
|
||||
if uname -a | grep Darwin; then
|
||||
# brew install coreutils wget
|
||||
PLAT=osx
|
||||
else
|
||||
PLAT=linux
|
||||
fi
|
||||
REPO_ROOT="$(realpath "$(dirname "${BASH_SOURCE[0]}")"/..)"
|
||||
TMP_DIR="$(mktemp -d)"
|
||||
TENSORFLOW_FILENAME="v$TENSORFLOW_VERSION.zip"
|
||||
PROTOC_FILENAME="protoc-$PROTOBUF_VERSION-$PLAT-x86_64.zip"
|
||||
PROTOC_URL="https://github.com/protocolbuffers/protobuf/releases/download/v$PROTOBUF_VERSION/$PROTOC_FILENAME"
|
||||
TENSORFLOW_URL="https://github.com/tensorflow/tensorflow/archive/refs/tags/$TENSORFLOW_FILENAME"
|
||||
|
||||
cd "$(dirname "$0")" > /dev/null
|
||||
cd ../stubs/tensorflow
|
||||
mkdir -p repository
|
||||
pushd repository &> /dev/null
|
||||
# If the script fails halfway, it's nice to be able to re-run it immediately
|
||||
if [ ! -d "tensorflow" ] ; then
|
||||
git clone --depth 1 --branch v"$TENSORFLOW_VERSION" https://github.com/tensorflow/tensorflow.git
|
||||
fi
|
||||
pushd tensorflow &> /dev/null
|
||||
# Folders here cover the more commonly used protobufs externally and
|
||||
# their dependencies. Tensorflow has more protobufs and can be added if requested.
|
||||
protoc --mypy_out "relax_strict_optional_primitives:$REPO_ROOT/stubs/tensorflow" \
|
||||
tensorflow/compiler/xla/*.proto \
|
||||
tensorflow/compiler/xla/service/*.proto \
|
||||
tensorflow/core/example/*.proto \
|
||||
tensorflow/core/framework/*.proto \
|
||||
tensorflow/core/protobuf/*.proto \
|
||||
tensorflow/core/protobuf/tpu/*.proto \
|
||||
tensorflow/core/util/*.proto \
|
||||
tensorflow/python/keras/protobuf/*.proto \
|
||||
tensorflow/tsl/protobuf/*.proto
|
||||
popd &> /dev/null
|
||||
popd &> /dev/null
|
||||
cd "$TMP_DIR"
|
||||
echo "Working in $TMP_DIR"
|
||||
|
||||
# Install protoc
|
||||
wget "$PROTOC_URL"
|
||||
mkdir protoc_install
|
||||
unzip "$PROTOC_FILENAME" -d protoc_install
|
||||
protoc_install/bin/protoc --version
|
||||
|
||||
# Fetch tensorflow (which contains all the .proto files)
|
||||
wget "$TENSORFLOW_URL"
|
||||
unzip "$TENSORFLOW_FILENAME"
|
||||
TENSORFLOW_DIR="tensorflow-$TENSORFLOW_VERSION"
|
||||
|
||||
# Prepare virtualenv
|
||||
python3 -m venv .venv
|
||||
source .venv/bin/activate
|
||||
python3 -m pip install pre-commit mypy-protobuf=="$MYPY_PROTOBUF_VERSION"
|
||||
|
||||
# Remove existing pyi
|
||||
find "$REPO_ROOT/stubs/tensorflow/" -name "*_pb2.pyi" -delete
|
||||
|
||||
# Folders here cover the more commonly used protobufs externally and
|
||||
# their dependencies. Tensorflow has more protobufs and can be added if requested.
|
||||
protoc_install/bin/protoc \
|
||||
--proto_path="$TENSORFLOW_DIR" \
|
||||
--mypy_out "relax_strict_optional_primitives:$REPO_ROOT/stubs/tensorflow" \
|
||||
$TENSORFLOW_DIR/tensorflow/compiler/xla/*.proto \
|
||||
$TENSORFLOW_DIR/tensorflow/compiler/xla/service/*.proto \
|
||||
$TENSORFLOW_DIR/tensorflow/core/example/*.proto \
|
||||
$TENSORFLOW_DIR/tensorflow/core/framework/*.proto \
|
||||
$TENSORFLOW_DIR/tensorflow/core/protobuf/*.proto \
|
||||
$TENSORFLOW_DIR/tensorflow/core/protobuf/tpu/*.proto \
|
||||
$TENSORFLOW_DIR/tensorflow/core/util/*.proto \
|
||||
$TENSORFLOW_DIR/tensorflow/python/keras/protobuf/*.proto \
|
||||
$TENSORFLOW_DIR/tensorflow/tsl/protobuf/*.proto \
|
||||
|
||||
# Cleanup after ourselves, this is a temp dir, but it can still grow fast if run multiple times
|
||||
rm -rf "$TMP_DIR"
|
||||
# Must be in a git repository to run pre-commit
|
||||
cd "$REPO_ROOT"
|
||||
|
||||
# These protos exist in a folder with protos used in python, but are not
|
||||
# included in the python wheel. They are likely only used for other
|
||||
# language builds. stubtest was used to identify them by looking for
|
||||
# ModuleNotFoundError.
|
||||
rm tensorflow/compiler/xla/service/hlo_execution_profile_data_pb2.pyi \
|
||||
tensorflow/compiler/xla/service/hlo_profile_printer_data_pb2.pyi \
|
||||
tensorflow/compiler/xla/service/test_compilation_environment_pb2.pyi \
|
||||
tensorflow/compiler/xla/xla_pb2.pyi \
|
||||
tensorflow/core/protobuf/autotuning_pb2.pyi \
|
||||
tensorflow/core/protobuf/conv_autotuning_pb2.pyi \
|
||||
tensorflow/core/protobuf/critical_section_pb2.pyi \
|
||||
tensorflow/core/protobuf/eager_service_pb2.pyi \
|
||||
tensorflow/core/protobuf/master_pb2.pyi \
|
||||
tensorflow/core/protobuf/master_service_pb2.pyi \
|
||||
tensorflow/core/protobuf/replay_log_pb2.pyi \
|
||||
tensorflow/core/protobuf/tpu/compile_metadata_pb2.pyi \
|
||||
tensorflow/core/protobuf/worker_pb2.pyi \
|
||||
tensorflow/core/protobuf/worker_service_pb2.pyi \
|
||||
tensorflow/core/util/example_proto_fast_parsing_test_pb2.pyi
|
||||
|
||||
rm \
|
||||
stubs/tensorflow/tensorflow/compiler/xla/service/hlo_execution_profile_data_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/compiler/xla/service/hlo_profile_printer_data_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/compiler/xla/service/test_compilation_environment_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/compiler/xla/xla_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/core/protobuf/autotuning_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/core/protobuf/conv_autotuning_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/core/protobuf/critical_section_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/core/protobuf/eager_service_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/core/protobuf/master_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/core/protobuf/master_service_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/core/protobuf/replay_log_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/core/protobuf/tpu/compile_metadata_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/core/protobuf/worker_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/core/protobuf/worker_service_pb2.pyi \
|
||||
stubs/tensorflow/tensorflow/core/util/example_proto_fast_parsing_test_pb2.pyi \
|
||||
|
||||
sed --in-place="" \
|
||||
"s/extra_description = .*$/extra_description = \"Partially generated using [mypy-protobuf==$MYPY_PROTOBUF_VERSION](https:\/\/github.com\/nipunn1313\/mypy-protobuf\/tree\/v$MYPY_PROTOBUF_VERSION) on tensorflow==$TENSORFLOW_VERSION\"/" \
|
||||
"$REPO_ROOT/stubs/tensorflow/METADATA.toml"
|
||||
stubs/tensorflow/METADATA.toml
|
||||
|
||||
# Cleanup last. If the script fails halfway, it's nice to be able to re-run it immediately
|
||||
rm -rf repository/
|
||||
|
||||
# Must be run in a git repository
|
||||
cd $REPO_ROOT
|
||||
# use `|| true` so the script still continues even if a pre-commit hook
|
||||
# applies autofixes (which will result in a nonzero exit code)
|
||||
pre-commit run --files $(git ls-files -- "$REPO_ROOT/stubs/tensorflow/tensorflow") || true
|
||||
# Ruff takes two passes to fix everything, re-running all of pre-commit is *slow*
|
||||
# and we don't need --unsafe-fixes to remove imports
|
||||
ruff check "$REPO_ROOT/stubs/tensorflow/tensorflow" --fix --exit-zero
|
||||
pre-commit run --files $(git ls-files -- "stubs/tensorflow/**_pb2.pyi") || true
|
||||
|
||||
@@ -2,7 +2,7 @@ version = "2.15.*"
|
||||
upstream_repository = "https://github.com/tensorflow/tensorflow"
|
||||
# requires a version of numpy with a `py.typed` file
|
||||
requires = ["numpy>=1.20", "types-protobuf", "types-requests"]
|
||||
extra_description = "Partially generated using [mypy-protobuf==3.5.0](https://github.com/nipunn1313/mypy-protobuf/tree/v3.5.0) on tensorflow==2.12.1"
|
||||
extra_description = "Partially generated using [mypy-protobuf==3.6.0](https://github.com/nipunn1313/mypy-protobuf/tree/v3.6.0) on tensorflow==2.12.1"
|
||||
partial_stub = true
|
||||
|
||||
[tool.stubtest]
|
||||
|
||||
@@ -16,9 +16,10 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
==============================================================================
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -27,7 +28,7 @@ import tensorflow.tsl.protobuf.autotuning_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AutotuneResults(google.protobuf.message.Message):
|
||||
"""A collection of algorithms for particular dot/convs. Usually this is "the
|
||||
best" algorithm for the particular dot/conv, although that's not strictly
|
||||
@@ -43,7 +44,7 @@ class AutotuneResults(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Entry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -60,6 +61,7 @@ class AutotuneResults(google.protobuf.message.Message):
|
||||
algorithms returned by cublasLt. Different version of cublasLt ->
|
||||
different list of algos -> different interpretation of results!
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -67,8 +69,8 @@ class AutotuneResults(google.protobuf.message.Message):
|
||||
hlo: builtins.str | None = ...,
|
||||
result: tensorflow.tsl.protobuf.autotuning_pb2.AutotuneResult | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["result", b"result"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device", b"device", "hlo", b"hlo", "result", b"result"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["result", b"result"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["device", b"device", "hlo", b"hlo", "result", b"result"]) -> None: ...
|
||||
|
||||
VERSION_FIELD_NUMBER: builtins.int
|
||||
DOTS_FIELD_NUMBER: builtins.int
|
||||
@@ -85,6 +87,6 @@ class AutotuneResults(google.protobuf.message.Message):
|
||||
dots: collections.abc.Iterable[global___AutotuneResults.Entry] | None = ...,
|
||||
convs: collections.abc.Iterable[global___AutotuneResults.Entry] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["convs", b"convs", "dots", b"dots", "version", b"version"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["convs", b"convs", "dots", b"dots", "version", b"version"]) -> None: ...
|
||||
|
||||
global___AutotuneResults = AutotuneResults
|
||||
|
||||
@@ -14,6 +14,7 @@ Unlike most protos, you can't safely change the names of fields, even if you
|
||||
keep the numeric ids the same. This is because we sometimes serialize these
|
||||
protos as JSON, which includes the field names in the serialization.
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -214,7 +215,7 @@ MUST_ALIAS: Kind.ValueType # 2
|
||||
"""The buffers must alias at runtime."""
|
||||
global___Kind = Kind
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HloInstructionProto(google.protobuf.message.Message):
|
||||
"""Serialization of HloInstruction.
|
||||
Next ID: 81
|
||||
@@ -222,7 +223,7 @@ class HloInstructionProto(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SliceDimensions(google.protobuf.message.Message):
|
||||
"""Describes the [begin, end) index range and stride for slices."""
|
||||
|
||||
@@ -241,7 +242,7 @@ class HloInstructionProto(google.protobuf.message.Message):
|
||||
limit: builtins.int | None = ...,
|
||||
stride: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["limit", b"limit", "start", b"start", "stride", b"stride"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["limit", b"limit", "start", b"start", "stride", b"stride"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
OPCODE_FIELD_NUMBER: builtins.int
|
||||
@@ -313,51 +314,21 @@ class HloInstructionProto(google.protobuf.message.Message):
|
||||
ASYNC_EXECUTION_THREAD_FIELD_NUMBER: builtins.int
|
||||
name: builtins.str
|
||||
opcode: builtins.str
|
||||
@property
|
||||
def shape(self) -> tensorflow.compiler.xla.xla_data_pb2.ShapeProto: ...
|
||||
@property
|
||||
def metadata(self) -> tensorflow.compiler.xla.xla_data_pb2.OpMetadata: ...
|
||||
@property
|
||||
def literal(self) -> tensorflow.compiler.xla.xla_data_pb2.LiteralProto:
|
||||
"""Literal, only present for kConstant."""
|
||||
parameter_number: builtins.int
|
||||
"""Parameter number is only present for kParameter."""
|
||||
fusion_kind: builtins.str
|
||||
"""Fusion state, only present for kFusion."""
|
||||
tuple_index: builtins.int
|
||||
"""Index for kGetTupleElement."""
|
||||
@property
|
||||
def dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Dimensions present for some operations that require reshaping or
|
||||
broadcasting, including Reshape, Reduce, ReduceWindow, and Reverse.
|
||||
"""
|
||||
@property
|
||||
def window(self) -> tensorflow.compiler.xla.xla_data_pb2.Window:
|
||||
"""Describes the window in a windowed operation such as convolution."""
|
||||
@property
|
||||
def convolution_dimension_numbers(self) -> tensorflow.compiler.xla.xla_data_pb2.ConvolutionDimensionNumbers:
|
||||
"""Describes the dimension numbers used for a convolution."""
|
||||
feature_group_count: builtins.int
|
||||
"""The number of feature groups. Used for a convolution. Must be a divisor of
|
||||
the input feature dimension and output feature dimension. If not specified,
|
||||
it will use a default value of 1.
|
||||
"""
|
||||
batch_group_count: builtins.int
|
||||
@property
|
||||
def slice_dimensions(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___HloInstructionProto.SliceDimensions]: ...
|
||||
exponent_bits: builtins.int
|
||||
"""The bit sizes for a reduce-precision operation."""
|
||||
mantissa_bits: builtins.int
|
||||
@property
|
||||
def dynamic_slice_sizes(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Describes the [start, start + size) range size for a dynamic slice
|
||||
('start' is specified dynamically in the second operand of the operation).
|
||||
"""
|
||||
@property
|
||||
def padding_config(self) -> tensorflow.compiler.xla.xla_data_pb2.PaddingConfig:
|
||||
"""The padding configuration that describes the edge padding and interior
|
||||
padding of this pad instruction. Only set for pad instructions.
|
||||
"""
|
||||
outfeed_config: builtins.bytes
|
||||
"""Outfeed configuration information, only present for kOutfeed."""
|
||||
distribution: tensorflow.compiler.xla.xla_data_pb2.RandomDistribution.ValueType
|
||||
@@ -385,39 +356,14 @@ class HloInstructionProto(google.protobuf.message.Message):
|
||||
"""Name of a external target (eg, global symbol) to call, only present for
|
||||
kCustomCall.
|
||||
"""
|
||||
@property
|
||||
def outfeed_shape(self) -> tensorflow.compiler.xla.xla_data_pb2.ShapeProto:
|
||||
"""Shape of outfeed request."""
|
||||
@property
|
||||
def dot_dimension_numbers(self) -> tensorflow.compiler.xla.xla_data_pb2.DotDimensionNumbers:
|
||||
"""Describes the dimension numbers used for a dot operation"""
|
||||
fft_type: tensorflow.compiler.xla.xla_data_pb2.FftType.ValueType
|
||||
"""FFT type (FFT, IFFT, etc)."""
|
||||
@property
|
||||
def fft_length(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""FFT length."""
|
||||
comparison_direction: builtins.str
|
||||
"""Comparison direction only used for kCompare."""
|
||||
@property
|
||||
def gather_dimension_numbers(self) -> tensorflow.compiler.xla.xla_data_pb2.GatherDimensionNumbers:
|
||||
"""Gather dimension numbers."""
|
||||
@property
|
||||
def gather_slice_sizes(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
id: builtins.int
|
||||
"""The id of this instruction."""
|
||||
@property
|
||||
def operand_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def control_predecessor_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def called_computation_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def sharding(self) -> tensorflow.compiler.xla.xla_data_pb2.OpSharding: ...
|
||||
backend_config: builtins.bytes
|
||||
"""Backend configuration for the instruction. Has backend-specific meaning."""
|
||||
@property
|
||||
def replica_groups(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.compiler.xla.xla_data_pb2.ReplicaGroup]:
|
||||
"""Cross replica op fields."""
|
||||
all_reduce_id: builtins.int
|
||||
"""Deprecated, but keeping it for backward compatibility. Use channel_id.
|
||||
Non-positive all_reduce_id is equivalent to no all_reduce_id.
|
||||
@@ -433,45 +379,16 @@ class HloInstructionProto(google.protobuf.message.Message):
|
||||
"""
|
||||
is_stable: builtins.bool
|
||||
"""Whether this Sort instruction should be stable."""
|
||||
@property
|
||||
def scatter_dimension_numbers(self) -> tensorflow.compiler.xla.xla_data_pb2.ScatterDimensionNumbers: ...
|
||||
@property
|
||||
def precision_config(self) -> tensorflow.compiler.xla.xla_data_pb2.PrecisionConfig:
|
||||
"""Precision configuration for the instruction. Has backend-specific meaning."""
|
||||
@property
|
||||
def source_target_pairs(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.compiler.xla.xla_data_pb2.SourceTarget]:
|
||||
"""Collective permute field."""
|
||||
@property
|
||||
def domain_entry_sharding(self) -> tensorflow.compiler.xla.xla_data_pb2.OpSharding:
|
||||
"""Sharding for kDomain instructions."""
|
||||
@property
|
||||
def domain_exit_sharding(self) -> tensorflow.compiler.xla.xla_data_pb2.OpSharding: ...
|
||||
constrain_layout: builtins.bool
|
||||
"""For custom call this indicates that the layouts are constrained. If
|
||||
constrain_layout is true then the 'shape' field must contain a layout, and
|
||||
'operand_shapes_with_layout' must contain a shape with layout for each
|
||||
operand.
|
||||
"""
|
||||
@property
|
||||
def operand_shapes_with_layout(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.compiler.xla.xla_data_pb2.ShapeProto]: ...
|
||||
@property
|
||||
def triangular_solve_options(self) -> tensorflow.compiler.xla.xla_data_pb2.TriangularSolveOptions:
|
||||
"""Options for TriangularSolve"""
|
||||
@property
|
||||
def cholesky_options(self) -> tensorflow.compiler.xla.xla_data_pb2.CholeskyOptions:
|
||||
"""Options for Cholesky"""
|
||||
@property
|
||||
def parameter_replication(self) -> tensorflow.compiler.xla.xla_data_pb2.ParameterReplication:
|
||||
"""Describes how parameters behave with regards to replicas."""
|
||||
custom_call_has_side_effect: builtins.bool
|
||||
"""Whether the kCustomCall instruction has side-effects, only present for
|
||||
kCustomCall.
|
||||
"""
|
||||
@property
|
||||
def output_operand_aliasing(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.compiler.xla.xla_data_pb2.OutputOperandAliasing]:
|
||||
"""A list of OutputOperandAliasing pairs that specifies aliasing buffers
|
||||
between output and operands for kCustomCall and kFusion.
|
||||
"""
|
||||
custom_call_schedule: global___CustomCallSchedule.ValueType
|
||||
"""Specifies the desired schedule for the custom-call. The field is only
|
||||
present for custom-call.
|
||||
@@ -482,9 +399,6 @@ class HloInstructionProto(google.protobuf.message.Message):
|
||||
"""Specifies if the gather/scatter indices are guaranteed to be sorted by the
|
||||
caller.
|
||||
"""
|
||||
@property
|
||||
def frontend_attributes(self) -> tensorflow.compiler.xla.xla_data_pb2.FrontendAttributes:
|
||||
"""Frontend attributes to pass to the XLA backend."""
|
||||
unique_indices: builtins.bool
|
||||
"""Specifies if all elements updated are guaranteed to be unique by
|
||||
the caller.
|
||||
@@ -516,6 +430,112 @@ class HloInstructionProto(google.protobuf.message.Message):
|
||||
Each HLO module may contain a main thread and one or more parallel threads.
|
||||
Empty async_execution_thread is equivalent to main thread.
|
||||
"""
|
||||
@property
|
||||
def shape(self) -> tensorflow.compiler.xla.xla_data_pb2.ShapeProto: ...
|
||||
@property
|
||||
def metadata(self) -> tensorflow.compiler.xla.xla_data_pb2.OpMetadata: ...
|
||||
@property
|
||||
def literal(self) -> tensorflow.compiler.xla.xla_data_pb2.LiteralProto:
|
||||
"""Literal, only present for kConstant."""
|
||||
|
||||
@property
|
||||
def dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Dimensions present for some operations that require reshaping or
|
||||
broadcasting, including Reshape, Reduce, ReduceWindow, and Reverse.
|
||||
"""
|
||||
|
||||
@property
|
||||
def window(self) -> tensorflow.compiler.xla.xla_data_pb2.Window:
|
||||
"""Describes the window in a windowed operation such as convolution."""
|
||||
|
||||
@property
|
||||
def convolution_dimension_numbers(self) -> tensorflow.compiler.xla.xla_data_pb2.ConvolutionDimensionNumbers:
|
||||
"""Describes the dimension numbers used for a convolution."""
|
||||
|
||||
@property
|
||||
def slice_dimensions(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___HloInstructionProto.SliceDimensions]: ...
|
||||
@property
|
||||
def dynamic_slice_sizes(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Describes the [start, start + size) range size for a dynamic slice
|
||||
('start' is specified dynamically in the second operand of the operation).
|
||||
"""
|
||||
|
||||
@property
|
||||
def padding_config(self) -> tensorflow.compiler.xla.xla_data_pb2.PaddingConfig:
|
||||
"""The padding configuration that describes the edge padding and interior
|
||||
padding of this pad instruction. Only set for pad instructions.
|
||||
"""
|
||||
|
||||
@property
|
||||
def outfeed_shape(self) -> tensorflow.compiler.xla.xla_data_pb2.ShapeProto:
|
||||
"""Shape of outfeed request."""
|
||||
|
||||
@property
|
||||
def dot_dimension_numbers(self) -> tensorflow.compiler.xla.xla_data_pb2.DotDimensionNumbers:
|
||||
"""Describes the dimension numbers used for a dot operation"""
|
||||
|
||||
@property
|
||||
def fft_length(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""FFT length."""
|
||||
|
||||
@property
|
||||
def gather_dimension_numbers(self) -> tensorflow.compiler.xla.xla_data_pb2.GatherDimensionNumbers:
|
||||
"""Gather dimension numbers."""
|
||||
|
||||
@property
|
||||
def gather_slice_sizes(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def operand_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def control_predecessor_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def called_computation_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def sharding(self) -> tensorflow.compiler.xla.xla_data_pb2.OpSharding: ...
|
||||
@property
|
||||
def replica_groups(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.compiler.xla.xla_data_pb2.ReplicaGroup]:
|
||||
"""Cross replica op fields."""
|
||||
|
||||
@property
|
||||
def scatter_dimension_numbers(self) -> tensorflow.compiler.xla.xla_data_pb2.ScatterDimensionNumbers: ...
|
||||
@property
|
||||
def precision_config(self) -> tensorflow.compiler.xla.xla_data_pb2.PrecisionConfig:
|
||||
"""Precision configuration for the instruction. Has backend-specific meaning."""
|
||||
|
||||
@property
|
||||
def source_target_pairs(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.compiler.xla.xla_data_pb2.SourceTarget]:
|
||||
"""Collective permute field."""
|
||||
|
||||
@property
|
||||
def domain_entry_sharding(self) -> tensorflow.compiler.xla.xla_data_pb2.OpSharding:
|
||||
"""Sharding for kDomain instructions."""
|
||||
|
||||
@property
|
||||
def domain_exit_sharding(self) -> tensorflow.compiler.xla.xla_data_pb2.OpSharding: ...
|
||||
@property
|
||||
def operand_shapes_with_layout(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.compiler.xla.xla_data_pb2.ShapeProto]: ...
|
||||
@property
|
||||
def triangular_solve_options(self) -> tensorflow.compiler.xla.xla_data_pb2.TriangularSolveOptions:
|
||||
"""Options for TriangularSolve"""
|
||||
|
||||
@property
|
||||
def cholesky_options(self) -> tensorflow.compiler.xla.xla_data_pb2.CholeskyOptions:
|
||||
"""Options for Cholesky"""
|
||||
|
||||
@property
|
||||
def parameter_replication(self) -> tensorflow.compiler.xla.xla_data_pb2.ParameterReplication:
|
||||
"""Describes how parameters behave with regards to replicas."""
|
||||
|
||||
@property
|
||||
def output_operand_aliasing(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.compiler.xla.xla_data_pb2.OutputOperandAliasing]:
|
||||
"""A list of OutputOperandAliasing pairs that specifies aliasing buffers
|
||||
between output and operands for kCustomCall and kFusion.
|
||||
"""
|
||||
|
||||
@property
|
||||
def frontend_attributes(self) -> tensorflow.compiler.xla.xla_data_pb2.FrontendAttributes:
|
||||
"""Frontend attributes to pass to the XLA backend."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -588,13 +608,13 @@ class HloInstructionProto(google.protobuf.message.Message):
|
||||
async_group_id: builtins.int | None = ...,
|
||||
async_execution_thread: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["cholesky_options", b"cholesky_options", "convolution_dimension_numbers", b"convolution_dimension_numbers", "cross_program_prefetch_index", b"cross_program_prefetch_index", "domain_entry_sharding", b"domain_entry_sharding", "domain_exit_sharding", b"domain_exit_sharding", "dot_dimension_numbers", b"dot_dimension_numbers", "frontend_attributes", b"frontend_attributes", "gather_dimension_numbers", b"gather_dimension_numbers", "literal", b"literal", "metadata", b"metadata", "optional_cross_program_prefetch_index", b"optional_cross_program_prefetch_index", "outfeed_shape", b"outfeed_shape", "padding_config", b"padding_config", "parameter_replication", b"parameter_replication", "precision_config", b"precision_config", "scatter_dimension_numbers", b"scatter_dimension_numbers", "shape", b"shape", "sharding", b"sharding", "triangular_solve_options", b"triangular_solve_options", "window", b"window"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["all_reduce_id", b"all_reduce_id", "async_execution_thread", b"async_execution_thread", "async_group_id", b"async_group_id", "backend_config", b"backend_config", "batch_group_count", b"batch_group_count", "called_computation_ids", b"called_computation_ids", "channel_id", b"channel_id", "cholesky_options", b"cholesky_options", "comparison_direction", b"comparison_direction", "comparison_type", b"comparison_type", "constrain_layout", b"constrain_layout", "control_predecessor_ids", b"control_predecessor_ids", "convolution_dimension_numbers", b"convolution_dimension_numbers", "cross_program_prefetch_index", b"cross_program_prefetch_index", "custom_call_api_version", b"custom_call_api_version", "custom_call_has_side_effect", b"custom_call_has_side_effect", "custom_call_schedule", b"custom_call_schedule", "custom_call_target", b"custom_call_target", "delta", b"delta", "dimensions", b"dimensions", "distribution", b"distribution", "domain_entry_sharding", b"domain_entry_sharding", "domain_exit_sharding", b"domain_exit_sharding", "dot_dimension_numbers", b"dot_dimension_numbers", "dynamic_slice_sizes", b"dynamic_slice_sizes", "epsilon", b"epsilon", "exponent_bits", b"exponent_bits", "feature_group_count", b"feature_group_count", "feature_index", b"feature_index", "fft_length", b"fft_length", "fft_type", b"fft_type", "frontend_attributes", b"frontend_attributes", "fusion_kind", b"fusion_kind", "gather_dimension_numbers", b"gather_dimension_numbers", "gather_slice_sizes", b"gather_slice_sizes", "id", b"id", "indices_are_sorted", b"indices_are_sorted", "infeed_config", b"infeed_config", "is_cross_program_prefetch", b"is_cross_program_prefetch", "is_host_transfer", b"is_host_transfer", "is_stable", b"is_stable", "literal", b"literal", "mantissa_bits", b"mantissa_bits", "metadata", b"metadata", "name", b"name", "opcode", b"opcode", "operand_ids", b"operand_ids", "operand_shapes_with_layout", b"operand_shapes_with_layout", "optional_cross_program_prefetch_index", b"optional_cross_program_prefetch_index", "outfeed_config", b"outfeed_config", "outfeed_shape", b"outfeed_shape", "output_operand_aliasing", b"output_operand_aliasing", "padding_config", b"padding_config", "padding_type", b"padding_type", "parameter_number", b"parameter_number", "parameter_replication", b"parameter_replication", "precision_config", b"precision_config", "replica_groups", b"replica_groups", "rng_algorithm", b"rng_algorithm", "scatter_dimension_numbers", b"scatter_dimension_numbers", "shape", b"shape", "sharding", b"sharding", "slice_dimensions", b"slice_dimensions", "source_target_pairs", b"source_target_pairs", "triangular_solve_options", b"triangular_solve_options", "tuple_index", b"tuple_index", "unique_indices", b"unique_indices", "use_global_device_ids", b"use_global_device_ids", "window", b"window"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_cross_program_prefetch_index", b"optional_cross_program_prefetch_index"]) -> typing_extensions.Literal["cross_program_prefetch_index"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["cholesky_options", b"cholesky_options", "convolution_dimension_numbers", b"convolution_dimension_numbers", "cross_program_prefetch_index", b"cross_program_prefetch_index", "domain_entry_sharding", b"domain_entry_sharding", "domain_exit_sharding", b"domain_exit_sharding", "dot_dimension_numbers", b"dot_dimension_numbers", "frontend_attributes", b"frontend_attributes", "gather_dimension_numbers", b"gather_dimension_numbers", "literal", b"literal", "metadata", b"metadata", "optional_cross_program_prefetch_index", b"optional_cross_program_prefetch_index", "outfeed_shape", b"outfeed_shape", "padding_config", b"padding_config", "parameter_replication", b"parameter_replication", "precision_config", b"precision_config", "scatter_dimension_numbers", b"scatter_dimension_numbers", "shape", b"shape", "sharding", b"sharding", "triangular_solve_options", b"triangular_solve_options", "window", b"window"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["all_reduce_id", b"all_reduce_id", "async_execution_thread", b"async_execution_thread", "async_group_id", b"async_group_id", "backend_config", b"backend_config", "batch_group_count", b"batch_group_count", "called_computation_ids", b"called_computation_ids", "channel_id", b"channel_id", "cholesky_options", b"cholesky_options", "comparison_direction", b"comparison_direction", "comparison_type", b"comparison_type", "constrain_layout", b"constrain_layout", "control_predecessor_ids", b"control_predecessor_ids", "convolution_dimension_numbers", b"convolution_dimension_numbers", "cross_program_prefetch_index", b"cross_program_prefetch_index", "custom_call_api_version", b"custom_call_api_version", "custom_call_has_side_effect", b"custom_call_has_side_effect", "custom_call_schedule", b"custom_call_schedule", "custom_call_target", b"custom_call_target", "delta", b"delta", "dimensions", b"dimensions", "distribution", b"distribution", "domain_entry_sharding", b"domain_entry_sharding", "domain_exit_sharding", b"domain_exit_sharding", "dot_dimension_numbers", b"dot_dimension_numbers", "dynamic_slice_sizes", b"dynamic_slice_sizes", "epsilon", b"epsilon", "exponent_bits", b"exponent_bits", "feature_group_count", b"feature_group_count", "feature_index", b"feature_index", "fft_length", b"fft_length", "fft_type", b"fft_type", "frontend_attributes", b"frontend_attributes", "fusion_kind", b"fusion_kind", "gather_dimension_numbers", b"gather_dimension_numbers", "gather_slice_sizes", b"gather_slice_sizes", "id", b"id", "indices_are_sorted", b"indices_are_sorted", "infeed_config", b"infeed_config", "is_cross_program_prefetch", b"is_cross_program_prefetch", "is_host_transfer", b"is_host_transfer", "is_stable", b"is_stable", "literal", b"literal", "mantissa_bits", b"mantissa_bits", "metadata", b"metadata", "name", b"name", "opcode", b"opcode", "operand_ids", b"operand_ids", "operand_shapes_with_layout", b"operand_shapes_with_layout", "optional_cross_program_prefetch_index", b"optional_cross_program_prefetch_index", "outfeed_config", b"outfeed_config", "outfeed_shape", b"outfeed_shape", "output_operand_aliasing", b"output_operand_aliasing", "padding_config", b"padding_config", "padding_type", b"padding_type", "parameter_number", b"parameter_number", "parameter_replication", b"parameter_replication", "precision_config", b"precision_config", "replica_groups", b"replica_groups", "rng_algorithm", b"rng_algorithm", "scatter_dimension_numbers", b"scatter_dimension_numbers", "shape", b"shape", "sharding", b"sharding", "slice_dimensions", b"slice_dimensions", "source_target_pairs", b"source_target_pairs", "triangular_solve_options", b"triangular_solve_options", "tuple_index", b"tuple_index", "unique_indices", b"unique_indices", "use_global_device_ids", b"use_global_device_ids", "window", b"window"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_cross_program_prefetch_index", b"optional_cross_program_prefetch_index"]) -> typing.Literal["cross_program_prefetch_index"] | None: ...
|
||||
|
||||
global___HloInstructionProto = HloInstructionProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HloComputationProto(google.protobuf.message.Message):
|
||||
"""Serialization of HloComputation."""
|
||||
|
||||
@@ -608,14 +628,6 @@ class HloComputationProto(google.protobuf.message.Message):
|
||||
IS_FUSION_COMPUTATION_FIELD_NUMBER: builtins.int
|
||||
EXECUTION_THREAD_FIELD_NUMBER: builtins.int
|
||||
name: builtins.str
|
||||
@property
|
||||
def instructions(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___HloInstructionProto]:
|
||||
"""The array of instructions is always in a valid dependency order, where
|
||||
operands appear before their users.
|
||||
"""
|
||||
@property
|
||||
def program_shape(self) -> tensorflow.compiler.xla.xla_data_pb2.ProgramShapeProto:
|
||||
"""The program shape (with layout) of this computation."""
|
||||
id: builtins.int
|
||||
"""The id of this computation."""
|
||||
root_id: builtins.int
|
||||
@@ -627,6 +639,16 @@ class HloComputationProto(google.protobuf.message.Message):
|
||||
"""
|
||||
execution_thread: builtins.str
|
||||
"""The name of execution thread this computation belongs to."""
|
||||
@property
|
||||
def instructions(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___HloInstructionProto]:
|
||||
"""The array of instructions is always in a valid dependency order, where
|
||||
operands appear before their users.
|
||||
"""
|
||||
|
||||
@property
|
||||
def program_shape(self) -> tensorflow.compiler.xla.xla_data_pb2.ProgramShapeProto:
|
||||
"""The program shape (with layout) of this computation."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -638,12 +660,12 @@ class HloComputationProto(google.protobuf.message.Message):
|
||||
is_fusion_computation: builtins.bool | None = ...,
|
||||
execution_thread: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["program_shape", b"program_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["execution_thread", b"execution_thread", "id", b"id", "instructions", b"instructions", "is_fusion_computation", b"is_fusion_computation", "name", b"name", "program_shape", b"program_shape", "root_id", b"root_id"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["program_shape", b"program_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["execution_thread", b"execution_thread", "id", b"id", "instructions", b"instructions", "is_fusion_computation", b"is_fusion_computation", "name", b"name", "program_shape", b"program_shape", "root_id", b"root_id"]) -> None: ...
|
||||
|
||||
global___HloComputationProto = HloComputationProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HloScheduleProto(google.protobuf.message.Message):
|
||||
"""Serialization of an HLO schedule. An HLO schedule contains a total order of
|
||||
instructions for each non-fusion computation in the module.
|
||||
@@ -651,7 +673,7 @@ class HloScheduleProto(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class InstructionSequence(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -663,9 +685,9 @@ class HloScheduleProto(google.protobuf.message.Message):
|
||||
*,
|
||||
instruction_ids: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["instruction_ids", b"instruction_ids"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["instruction_ids", b"instruction_ids"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SequencesEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -680,27 +702,28 @@ class HloScheduleProto(google.protobuf.message.Message):
|
||||
key: builtins.int | None = ...,
|
||||
value: global___HloScheduleProto.InstructionSequence | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
SEQUENCES_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def sequences(self) -> google.protobuf.internal.containers.MessageMap[builtins.int, global___HloScheduleProto.InstructionSequence]:
|
||||
"""Map from computation id to sequence."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
sequences: collections.abc.Mapping[builtins.int, global___HloScheduleProto.InstructionSequence] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["sequences", b"sequences"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["sequences", b"sequences"]) -> None: ...
|
||||
|
||||
global___HloScheduleProto = HloScheduleProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HloInputOutputAliasProto(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AliasEntryProto(google.protobuf.message.Message):
|
||||
"""The following proto describes a pair of aliased an input
|
||||
(described by parameter number and a ShapeIndex of the parameter)
|
||||
@@ -723,16 +746,18 @@ class HloInputOutputAliasProto(google.protobuf.message.Message):
|
||||
PARAMETER_NUMBER_FIELD_NUMBER: builtins.int
|
||||
PARAMETER_SHAPE_INDEX_FIELD_NUMBER: builtins.int
|
||||
KIND_FIELD_NUMBER: builtins.int
|
||||
parameter_number: builtins.int
|
||||
"""Number of the parameter in entry computation."""
|
||||
kind: global___Kind.ValueType
|
||||
"""The kind of alias to be setup."""
|
||||
@property
|
||||
def output_shape_index(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""ShapeIndex of the root hlo."""
|
||||
parameter_number: builtins.int
|
||||
"""Number of the parameter in entry computation."""
|
||||
|
||||
@property
|
||||
def parameter_shape_index(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""ShapeIndex of the parameter instruction."""
|
||||
kind: global___Kind.ValueType
|
||||
"""The kind of alias to be setup."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -741,7 +766,7 @@ class HloInputOutputAliasProto(google.protobuf.message.Message):
|
||||
parameter_shape_index: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
kind: global___Kind.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["kind", b"kind", "output_shape_index", b"output_shape_index", "parameter_number", b"parameter_number", "parameter_shape_index", b"parameter_shape_index"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["kind", b"kind", "output_shape_index", b"output_shape_index", "parameter_number", b"parameter_number", "parameter_shape_index", b"parameter_shape_index"]) -> None: ...
|
||||
|
||||
ENTRIES_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
@@ -751,15 +776,15 @@ class HloInputOutputAliasProto(google.protobuf.message.Message):
|
||||
*,
|
||||
entries: collections.abc.Iterable[global___HloInputOutputAliasProto.AliasEntryProto] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["entries", b"entries"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["entries", b"entries"]) -> None: ...
|
||||
|
||||
global___HloInputOutputAliasProto = HloInputOutputAliasProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DynamicParameterBindingProto(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Binding(google.protobuf.message.Message):
|
||||
"""A list of bindings which indicates that the `target_param_dim_num` in
|
||||
the subshape `target_param_index` of parameter `target_param_num`
|
||||
@@ -794,12 +819,12 @@ class DynamicParameterBindingProto(google.protobuf.message.Message):
|
||||
TARGET_PARAM_INDEX_FIELD_NUMBER: builtins.int
|
||||
TARGET_PARAM_DIM_NUM_FIELD_NUMBER: builtins.int
|
||||
dynamic_param_num: builtins.int
|
||||
target_param_num: builtins.int
|
||||
target_param_dim_num: builtins.int
|
||||
@property
|
||||
def dynamic_param_index(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
target_param_num: builtins.int
|
||||
@property
|
||||
def target_param_index(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
target_param_dim_num: builtins.int
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -809,7 +834,7 @@ class DynamicParameterBindingProto(google.protobuf.message.Message):
|
||||
target_param_index: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
target_param_dim_num: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dynamic_param_index", b"dynamic_param_index", "dynamic_param_num", b"dynamic_param_num", "target_param_dim_num", b"target_param_dim_num", "target_param_index", b"target_param_index", "target_param_num", b"target_param_num"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["dynamic_param_index", b"dynamic_param_index", "dynamic_param_num", b"dynamic_param_num", "target_param_dim_num", b"target_param_dim_num", "target_param_index", b"target_param_index", "target_param_num", b"target_param_num"]) -> None: ...
|
||||
|
||||
ENTRIES_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
@@ -819,11 +844,11 @@ class DynamicParameterBindingProto(google.protobuf.message.Message):
|
||||
*,
|
||||
entries: collections.abc.Iterable[global___DynamicParameterBindingProto.Binding] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["entries", b"entries"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["entries", b"entries"]) -> None: ...
|
||||
|
||||
global___DynamicParameterBindingProto = DynamicParameterBindingProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CrossProgramPrefetch(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -831,9 +856,9 @@ class CrossProgramPrefetch(google.protobuf.message.Message):
|
||||
INDEX_FIELD_NUMBER: builtins.int
|
||||
OFFSET_FIELD_NUMBER: builtins.int
|
||||
parameter: builtins.int
|
||||
offset: builtins.int
|
||||
@property
|
||||
def index(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
offset: builtins.int
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -841,11 +866,11 @@ class CrossProgramPrefetch(google.protobuf.message.Message):
|
||||
index: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
offset: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["index", b"index", "offset", b"offset", "parameter", b"parameter"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["index", b"index", "offset", b"offset", "parameter", b"parameter"]) -> None: ...
|
||||
|
||||
global___CrossProgramPrefetch = CrossProgramPrefetch
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HloModuleProto(google.protobuf.message.Message):
|
||||
"""Serialization of HloModule."""
|
||||
|
||||
@@ -872,7 +897,7 @@ class HloModuleProto(google.protobuf.message.Message):
|
||||
LAYOUT: HloModuleProto.ProfileType.ValueType # 3
|
||||
DOT: HloModuleProto.ProfileType.ValueType # 4
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ProfileInfo(google.protobuf.message.Message):
|
||||
"""Information about the optimization profile that this module contains."""
|
||||
|
||||
@@ -898,7 +923,7 @@ class HloModuleProto(google.protobuf.message.Message):
|
||||
profile_source: tensorflow.compiler.xla.xla_data_pb2.ProfileSource.ValueType | None = ...,
|
||||
compilation_event: tensorflow.compiler.xla.xla_data_pb2.CompilationEvent.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["compilation_event", b"compilation_event", "profile_source", b"profile_source", "profile_type", b"profile_type", "relative_speedup", b"relative_speedup"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["compilation_event", b"compilation_event", "profile_source", b"profile_source", "profile_type", b"profile_type", "relative_speedup", b"relative_speedup"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
ENTRY_COMPUTATION_NAME_FIELD_NUMBER: builtins.int
|
||||
@@ -919,40 +944,46 @@ class HloModuleProto(google.protobuf.message.Message):
|
||||
name: builtins.str
|
||||
entry_computation_name: builtins.str
|
||||
entry_computation_id: builtins.int
|
||||
id: builtins.int
|
||||
"""The id of this module."""
|
||||
is_dynamic: builtins.bool
|
||||
"""True if the module contains dynamic computation."""
|
||||
use_auto_spmd_partitioning: builtins.bool
|
||||
"""Uses AutoSharding pass or not."""
|
||||
@property
|
||||
def computations(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___HloComputationProto]:
|
||||
"""The array of computations is always in a valid dependency order, where
|
||||
callees appear before their callers.
|
||||
"""
|
||||
|
||||
@property
|
||||
def host_program_shape(self) -> tensorflow.compiler.xla.xla_data_pb2.ProgramShapeProto:
|
||||
"""The host program shape (with layout) of the entry computation."""
|
||||
id: builtins.int
|
||||
"""The id of this module."""
|
||||
|
||||
@property
|
||||
def schedule(self) -> global___HloScheduleProto:
|
||||
"""The schedule for this module."""
|
||||
|
||||
@property
|
||||
def input_output_alias(self) -> global___HloInputOutputAliasProto:
|
||||
"""Describes alias information between inputs and outputs."""
|
||||
|
||||
@property
|
||||
def dynamic_parameter_binding(self) -> global___DynamicParameterBindingProto: ...
|
||||
@property
|
||||
def cross_program_prefetches(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___CrossProgramPrefetch]: ...
|
||||
is_dynamic: builtins.bool
|
||||
"""True if the module contains dynamic computation."""
|
||||
@property
|
||||
def spmd_output_sharding(self) -> tensorflow.compiler.xla.xla_data_pb2.OpSharding: ...
|
||||
@property
|
||||
def spmd_parameters_shardings(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.compiler.xla.xla_data_pb2.OpSharding]: ...
|
||||
use_auto_spmd_partitioning: builtins.bool
|
||||
"""Uses AutoSharding pass or not."""
|
||||
@property
|
||||
def profile_info(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___HloModuleProto.ProfileInfo]:
|
||||
"""Profile information for the HLO module."""
|
||||
|
||||
@property
|
||||
def device_assignment(self) -> tensorflow.compiler.xla.xla_data_pb2.DeviceAssignmentProto:
|
||||
"""DeviceAssignment object information."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -973,18 +1004,18 @@ class HloModuleProto(google.protobuf.message.Message):
|
||||
profile_info: collections.abc.Iterable[global___HloModuleProto.ProfileInfo] | None = ...,
|
||||
device_assignment: tensorflow.compiler.xla.xla_data_pb2.DeviceAssignmentProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["device_assignment", b"device_assignment", "dynamic_parameter_binding", b"dynamic_parameter_binding", "host_program_shape", b"host_program_shape", "input_output_alias", b"input_output_alias", "schedule", b"schedule", "spmd_output_sharding", b"spmd_output_sharding"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["computations", b"computations", "cross_program_prefetches", b"cross_program_prefetches", "device_assignment", b"device_assignment", "dynamic_parameter_binding", b"dynamic_parameter_binding", "entry_computation_id", b"entry_computation_id", "entry_computation_name", b"entry_computation_name", "host_program_shape", b"host_program_shape", "id", b"id", "input_output_alias", b"input_output_alias", "is_dynamic", b"is_dynamic", "name", b"name", "profile_info", b"profile_info", "schedule", b"schedule", "spmd_output_sharding", b"spmd_output_sharding", "spmd_parameters_shardings", b"spmd_parameters_shardings", "use_auto_spmd_partitioning", b"use_auto_spmd_partitioning"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["device_assignment", b"device_assignment", "dynamic_parameter_binding", b"dynamic_parameter_binding", "host_program_shape", b"host_program_shape", "input_output_alias", b"input_output_alias", "schedule", b"schedule", "spmd_output_sharding", b"spmd_output_sharding"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["computations", b"computations", "cross_program_prefetches", b"cross_program_prefetches", "device_assignment", b"device_assignment", "dynamic_parameter_binding", b"dynamic_parameter_binding", "entry_computation_id", b"entry_computation_id", "entry_computation_name", b"entry_computation_name", "host_program_shape", b"host_program_shape", "id", b"id", "input_output_alias", b"input_output_alias", "is_dynamic", b"is_dynamic", "name", b"name", "profile_info", b"profile_info", "schedule", b"schedule", "spmd_output_sharding", b"spmd_output_sharding", "spmd_parameters_shardings", b"spmd_parameters_shardings", "use_auto_spmd_partitioning", b"use_auto_spmd_partitioning"]) -> None: ...
|
||||
|
||||
global___HloModuleProto = HloModuleProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class LogicalBufferProto(google.protobuf.message.Message):
|
||||
"""Serialization of LogicalBuffer."""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Location(google.protobuf.message.Message):
|
||||
"""Location represents an instruction and its shape index, which uniquely
|
||||
identifies a point where a buffer is needed.
|
||||
@@ -1007,7 +1038,7 @@ class LogicalBufferProto(google.protobuf.message.Message):
|
||||
instruction_id: builtins.int | None = ...,
|
||||
shape_index: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["instruction_id", b"instruction_id", "instruction_name", b"instruction_name", "shape_index", b"shape_index"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["instruction_id", b"instruction_id", "instruction_name", b"instruction_name", "shape_index", b"shape_index"]) -> None: ...
|
||||
|
||||
ID_FIELD_NUMBER: builtins.int
|
||||
SIZE_FIELD_NUMBER: builtins.int
|
||||
@@ -1015,10 +1046,11 @@ class LogicalBufferProto(google.protobuf.message.Message):
|
||||
COLOR_FIELD_NUMBER: builtins.int
|
||||
id: builtins.int
|
||||
size: builtins.int
|
||||
color: builtins.int
|
||||
@property
|
||||
def defined_at(self) -> global___LogicalBufferProto.Location:
|
||||
"""The location where the buffer is defined."""
|
||||
color: builtins.int
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1027,18 +1059,18 @@ class LogicalBufferProto(google.protobuf.message.Message):
|
||||
defined_at: global___LogicalBufferProto.Location | None = ...,
|
||||
color: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["defined_at", b"defined_at"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["color", b"color", "defined_at", b"defined_at", "id", b"id", "size", b"size"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["defined_at", b"defined_at"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["color", b"color", "defined_at", b"defined_at", "id", b"id", "size", b"size"]) -> None: ...
|
||||
|
||||
global___LogicalBufferProto = LogicalBufferProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BufferAllocationProto(google.protobuf.message.Message):
|
||||
"""Serialization of BufferAllocation."""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Assigned(google.protobuf.message.Message):
|
||||
"""Assigned represents a single LogicalBuffer that is assigned to this
|
||||
BufferAllocation.
|
||||
@@ -1059,7 +1091,7 @@ class BufferAllocationProto(google.protobuf.message.Message):
|
||||
offset: builtins.int | None = ...,
|
||||
size: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["logical_buffer_id", b"logical_buffer_id", "offset", b"offset", "size", b"size"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["logical_buffer_id", b"logical_buffer_id", "offset", b"offset", "size", b"size"]) -> None: ...
|
||||
|
||||
INDEX_FIELD_NUMBER: builtins.int
|
||||
SIZE_FIELD_NUMBER: builtins.int
|
||||
@@ -1079,11 +1111,11 @@ class BufferAllocationProto(google.protobuf.message.Message):
|
||||
is_entry_computation_parameter: builtins.bool
|
||||
is_constant: builtins.bool
|
||||
parameter_number: builtins.int
|
||||
@property
|
||||
def parameter_shape_index(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
maybe_live_out: builtins.bool
|
||||
color: builtins.int
|
||||
@property
|
||||
def parameter_shape_index(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def assigned(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___BufferAllocationProto.Assigned]: ...
|
||||
def __init__(
|
||||
self,
|
||||
@@ -1100,17 +1132,17 @@ class BufferAllocationProto(google.protobuf.message.Message):
|
||||
color: builtins.int | None = ...,
|
||||
assigned: collections.abc.Iterable[global___BufferAllocationProto.Assigned] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["assigned", b"assigned", "color", b"color", "index", b"index", "is_constant", b"is_constant", "is_entry_computation_parameter", b"is_entry_computation_parameter", "is_thread_local", b"is_thread_local", "is_tuple", b"is_tuple", "maybe_live_out", b"maybe_live_out", "parameter_number", b"parameter_number", "parameter_shape_index", b"parameter_shape_index", "size", b"size"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["assigned", b"assigned", "color", b"color", "index", b"index", "is_constant", b"is_constant", "is_entry_computation_parameter", b"is_entry_computation_parameter", "is_thread_local", b"is_thread_local", "is_tuple", b"is_tuple", "maybe_live_out", b"maybe_live_out", "parameter_number", b"parameter_number", "parameter_shape_index", b"parameter_shape_index", "size", b"size"]) -> None: ...
|
||||
|
||||
global___BufferAllocationProto = BufferAllocationProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HeapSimulatorTrace(google.protobuf.message.Message):
|
||||
"""A trace of a HeapSimulator run."""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Event(google.protobuf.message.Message):
|
||||
"""The trace includes a list of events, where each event describes one action
|
||||
performed by the heap simulator.
|
||||
@@ -1176,15 +1208,15 @@ class HeapSimulatorTrace(google.protobuf.message.Message):
|
||||
instruction_name: builtins.str | None = ...,
|
||||
share_with_canonical_id: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["buffer_id", b"buffer_id", "computation_name", b"computation_name", "instruction_name", b"instruction_name", "kind", b"kind", "share_with_canonical_id", b"share_with_canonical_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["buffer_id", b"buffer_id", "computation_name", b"computation_name", "instruction_name", b"instruction_name", "kind", b"kind", "share_with_canonical_id", b"share_with_canonical_id"]) -> None: ...
|
||||
|
||||
EVENTS_FIELD_NUMBER: builtins.int
|
||||
WHOLE_MODULE_SIMULATION_FIELD_NUMBER: builtins.int
|
||||
BUFFER_ALLOCATION_INDEX_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def events(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___HeapSimulatorTrace.Event]: ...
|
||||
whole_module_simulation: builtins.bool
|
||||
buffer_allocation_index: builtins.int
|
||||
@property
|
||||
def events(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___HeapSimulatorTrace.Event]: ...
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1192,11 +1224,11 @@ class HeapSimulatorTrace(google.protobuf.message.Message):
|
||||
whole_module_simulation: builtins.bool | None = ...,
|
||||
buffer_allocation_index: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["buffer_allocation_index", b"buffer_allocation_index", "events", b"events", "whole_module_simulation", b"whole_module_simulation"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["buffer_allocation_index", b"buffer_allocation_index", "events", b"events", "whole_module_simulation", b"whole_module_simulation"]) -> None: ...
|
||||
|
||||
global___HeapSimulatorTrace = HeapSimulatorTrace
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HloModuleGroupProto(google.protobuf.message.Message):
|
||||
"""An abstraction representing a set of HLO module built to run concurrently
|
||||
across different devices.
|
||||
@@ -1215,17 +1247,17 @@ class HloModuleGroupProto(google.protobuf.message.Message):
|
||||
name: builtins.str | None = ...,
|
||||
hlo_modules: collections.abc.Iterable[global___HloModuleProto] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["hlo_modules", b"hlo_modules", "name", b"name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["hlo_modules", b"hlo_modules", "name", b"name"]) -> None: ...
|
||||
|
||||
global___HloModuleGroupProto = HloModuleGroupProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BufferAssignmentProto(google.protobuf.message.Message):
|
||||
"""Serialization of BufferAssignment."""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BufferAlias(google.protobuf.message.Message):
|
||||
"""Alias represents a source LogicalBuffer, and the buffer location that
|
||||
aliases it.
|
||||
@@ -1244,8 +1276,8 @@ class BufferAssignmentProto(google.protobuf.message.Message):
|
||||
source_buffer_id: builtins.int | None = ...,
|
||||
location: global___LogicalBufferProto.Location | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["location", b"location"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["location", b"location", "source_buffer_id", b"source_buffer_id"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["location", b"location"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["location", b"location", "source_buffer_id", b"source_buffer_id"]) -> None: ...
|
||||
|
||||
LOGICAL_BUFFERS_FIELD_NUMBER: builtins.int
|
||||
BUFFER_ALIASES_FIELD_NUMBER: builtins.int
|
||||
@@ -1267,11 +1299,11 @@ class BufferAssignmentProto(google.protobuf.message.Message):
|
||||
buffer_allocations: collections.abc.Iterable[global___BufferAllocationProto] | None = ...,
|
||||
heap_simulator_traces: collections.abc.Iterable[global___HeapSimulatorTrace] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["buffer_aliases", b"buffer_aliases", "buffer_allocations", b"buffer_allocations", "heap_simulator_traces", b"heap_simulator_traces", "logical_buffers", b"logical_buffers"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["buffer_aliases", b"buffer_aliases", "buffer_allocations", b"buffer_allocations", "heap_simulator_traces", b"heap_simulator_traces", "logical_buffers", b"logical_buffers"]) -> None: ...
|
||||
|
||||
global___BufferAssignmentProto = BufferAssignmentProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HloProto(google.protobuf.message.Message):
|
||||
"""Grouping message that contains all of the information above."""
|
||||
|
||||
@@ -1289,12 +1321,12 @@ class HloProto(google.protobuf.message.Message):
|
||||
hlo_module: global___HloModuleProto | None = ...,
|
||||
buffer_assignment: global___BufferAssignmentProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["buffer_assignment", b"buffer_assignment", "hlo_module", b"hlo_module"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["buffer_assignment", b"buffer_assignment", "hlo_module", b"hlo_module"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["buffer_assignment", b"buffer_assignment", "hlo_module", b"hlo_module"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["buffer_assignment", b"buffer_assignment", "hlo_module", b"hlo_module"]) -> None: ...
|
||||
|
||||
global___HloProto = HloProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HloSnapshot(google.protobuf.message.Message):
|
||||
"""Encapsulates HloProto together with the arguments, result, and
|
||||
execution_platform. This message is used for purposes such as
|
||||
@@ -1307,17 +1339,20 @@ class HloSnapshot(google.protobuf.message.Message):
|
||||
ARGUMENTS_FIELD_NUMBER: builtins.int
|
||||
RESULT_FIELD_NUMBER: builtins.int
|
||||
EXECUTION_PLATFORM_FIELD_NUMBER: builtins.int
|
||||
execution_platform: builtins.str
|
||||
"""The name of the platform used to run the graph."""
|
||||
@property
|
||||
def hlo(self) -> global___HloProto:
|
||||
"""The hlo graph."""
|
||||
|
||||
@property
|
||||
def arguments(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.compiler.xla.xla_data_pb2.LiteralProto]:
|
||||
"""The arguments passed to the graph."""
|
||||
|
||||
@property
|
||||
def result(self) -> tensorflow.compiler.xla.xla_data_pb2.LiteralProto:
|
||||
"""The result of the graph."""
|
||||
execution_platform: builtins.str
|
||||
"""The name of the platform used to run the graph."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1326,12 +1361,12 @@ class HloSnapshot(google.protobuf.message.Message):
|
||||
result: tensorflow.compiler.xla.xla_data_pb2.LiteralProto | None = ...,
|
||||
execution_platform: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["hlo", b"hlo", "result", b"result"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["arguments", b"arguments", "execution_platform", b"execution_platform", "hlo", b"hlo", "result", b"result"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["hlo", b"hlo", "result", b"result"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["arguments", b"arguments", "execution_platform", b"execution_platform", "hlo", b"hlo", "result", b"result"]) -> None: ...
|
||||
|
||||
global___HloSnapshot = HloSnapshot
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HloModuleMetadataProto(google.protobuf.message.Message):
|
||||
"""Metadata for an HLO module. Dumped after HLO passes and before LLO lowering
|
||||
with filename module_####.metadata.textproto, where #### is
|
||||
@@ -1362,9 +1397,11 @@ class HloModuleMetadataProto(google.protobuf.message.Message):
|
||||
"""The canonical module ids of the modules that this one is partitioned into,
|
||||
if applicable.
|
||||
"""
|
||||
|
||||
@property
|
||||
def pass_metadata(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___HloPassMetadata]:
|
||||
"""Metadata for the HLO passes that are run on the module."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1374,11 +1411,11 @@ class HloModuleMetadataProto(google.protobuf.message.Message):
|
||||
partitioned_module_ids: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
pass_metadata: collections.abc.Iterable[global___HloPassMetadata] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["canonical_module_id", b"canonical_module_id", "module_group_name", b"module_group_name", "original_module_id", b"original_module_id", "partitioned_module_ids", b"partitioned_module_ids", "pass_metadata", b"pass_metadata"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["canonical_module_id", b"canonical_module_id", "module_group_name", b"module_group_name", "original_module_id", b"original_module_id", "partitioned_module_ids", b"partitioned_module_ids", "pass_metadata", b"pass_metadata"]) -> None: ...
|
||||
|
||||
global___HloModuleMetadataProto = HloModuleMetadataProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HloPassMetadata(google.protobuf.message.Message):
|
||||
"""Metadata for one run of an HLO pass on a module. Provides more information
|
||||
when processing debug dumps of HloProtos about the order of HLO passes and
|
||||
@@ -1407,12 +1444,6 @@ class HloPassMetadata(google.protobuf.message.Message):
|
||||
"""
|
||||
pass_name: builtins.str
|
||||
pipeline_name: builtins.str
|
||||
@property
|
||||
def dump_filenames(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Filenames of the dumps of the module after this pass ran. Module may be
|
||||
dumped in multiple formats, and the order of formats in this field will
|
||||
stay consistent across passes.
|
||||
"""
|
||||
module_changed: builtins.bool
|
||||
"""Return value of pass.Run(). True if this pass changed the module, or, in
|
||||
the case where the module was run through this pass as part of a module
|
||||
@@ -1423,14 +1454,22 @@ class HloPassMetadata(google.protobuf.message.Message):
|
||||
the canonical_module_id of the HloModuleMetadata that this HloPassMetadata
|
||||
is inside.
|
||||
"""
|
||||
start_timestamp_usec: builtins.int
|
||||
"""Timestamp before and after the pass is run. Note they may be equal."""
|
||||
end_timestamp_usec: builtins.int
|
||||
@property
|
||||
def dump_filenames(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Filenames of the dumps of the module after this pass ran. Module may be
|
||||
dumped in multiple formats, and the order of formats in this field will
|
||||
stay consistent across passes.
|
||||
"""
|
||||
|
||||
@property
|
||||
def module_group_module_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""If the module went through this pass as part of a module group, this is
|
||||
set as the ids of all the modules in the module group. Empty otherwise.
|
||||
"""
|
||||
start_timestamp_usec: builtins.int
|
||||
"""Timestamp before and after the pass is run. Note they may be equal."""
|
||||
end_timestamp_usec: builtins.int
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1444,17 +1483,17 @@ class HloPassMetadata(google.protobuf.message.Message):
|
||||
start_timestamp_usec: builtins.int | None = ...,
|
||||
end_timestamp_usec: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dump_filenames", b"dump_filenames", "end_timestamp_usec", b"end_timestamp_usec", "module_changed", b"module_changed", "module_group_module_ids", b"module_group_module_ids", "module_id", b"module_id", "pass_id", b"pass_id", "pass_name", b"pass_name", "pipeline_name", b"pipeline_name", "start_timestamp_usec", b"start_timestamp_usec"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["dump_filenames", b"dump_filenames", "end_timestamp_usec", b"end_timestamp_usec", "module_changed", b"module_changed", "module_group_module_ids", b"module_group_module_ids", "module_id", b"module_id", "pass_id", b"pass_id", "pass_name", b"pass_name", "pipeline_name", b"pipeline_name", "start_timestamp_usec", b"start_timestamp_usec"]) -> None: ...
|
||||
|
||||
global___HloPassMetadata = HloPassMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class EntryFunctionAttributes(google.protobuf.message.Message):
|
||||
"""Encodes attributes for an entry function."""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ShapeIndex(google.protobuf.message.Message):
|
||||
"""Acts as the underlying container for an xla::ShapeIndex."""
|
||||
|
||||
@@ -1468,9 +1507,9 @@ class EntryFunctionAttributes(google.protobuf.message.Message):
|
||||
*,
|
||||
indices: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["indices", b"indices"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["indices", b"indices"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BufferParameterAttributes(google.protobuf.message.Message):
|
||||
"""Encodes attributes for a single buffer parameter."""
|
||||
|
||||
@@ -1488,16 +1527,18 @@ class EntryFunctionAttributes(google.protobuf.message.Message):
|
||||
"""TODO(hanbinyoon): Deprecate when optional fields are available in proto3
|
||||
(Protocol Buffers v3.15.0).
|
||||
"""
|
||||
@property
|
||||
def lmhlo_param_shape_index(self) -> global___EntryFunctionAttributes.ShapeIndex:
|
||||
"""Represents an lmhlo.param_shape_index function argument attribute."""
|
||||
lmhlo_constant_name: builtins.str
|
||||
"""Represents an lmhlo.constant_name function argument attribute."""
|
||||
lmhlo_must_alias: builtins.bool
|
||||
"""Represents an lmhlo.must_alias function argument attribute."""
|
||||
@property
|
||||
def lmhlo_param_shape_index(self) -> global___EntryFunctionAttributes.ShapeIndex:
|
||||
"""Represents an lmhlo.param_shape_index function argument attribute."""
|
||||
|
||||
@property
|
||||
def lmhlo_output_index(self) -> global___EntryFunctionAttributes.ShapeIndex:
|
||||
"""Represents an lmhlo.params function argument attribute."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1508,26 +1549,26 @@ class EntryFunctionAttributes(google.protobuf.message.Message):
|
||||
lmhlo_must_alias: builtins.bool | None = ...,
|
||||
lmhlo_output_index: global___EntryFunctionAttributes.ShapeIndex | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["lmhlo_output_index", b"lmhlo_output_index", "lmhlo_param_shape_index", b"lmhlo_param_shape_index"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["lmhlo_constant_name", b"lmhlo_constant_name", "lmhlo_must_alias", b"lmhlo_must_alias", "lmhlo_output_index", b"lmhlo_output_index", "lmhlo_param_shape_index", b"lmhlo_param_shape_index", "lmhlo_params", b"lmhlo_params", "lmhlo_params_present", b"lmhlo_params_present"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["lmhlo_output_index", b"lmhlo_output_index", "lmhlo_param_shape_index", b"lmhlo_param_shape_index"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["lmhlo_constant_name", b"lmhlo_constant_name", "lmhlo_must_alias", b"lmhlo_must_alias", "lmhlo_output_index", b"lmhlo_output_index", "lmhlo_param_shape_index", b"lmhlo_param_shape_index", "lmhlo_params", b"lmhlo_params", "lmhlo_params_present", b"lmhlo_params_present"]) -> None: ...
|
||||
|
||||
BUFFERS_FIELD_NUMBER: builtins.int
|
||||
RESULT_XLA_SHAPE_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def buffers(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___EntryFunctionAttributes.BufferParameterAttributes]: ...
|
||||
result_xla_shape: builtins.str
|
||||
"""xla::Shape in string format."""
|
||||
@property
|
||||
def buffers(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___EntryFunctionAttributes.BufferParameterAttributes]: ...
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
buffers: collections.abc.Iterable[global___EntryFunctionAttributes.BufferParameterAttributes] | None = ...,
|
||||
result_xla_shape: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["buffers", b"buffers", "result_xla_shape", b"result_xla_shape"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["buffers", b"buffers", "result_xla_shape", b"result_xla_shape"]) -> None: ...
|
||||
|
||||
global___EntryFunctionAttributes = EntryFunctionAttributes
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class XlaRuntimeExecutableProto(google.protobuf.message.Message):
|
||||
"""Encodes the underlying Xla runtime executable compiled from the XLA module."""
|
||||
|
||||
@@ -1536,8 +1577,6 @@ class XlaRuntimeExecutableProto(google.protobuf.message.Message):
|
||||
HLO_MODULE_PROTO_FIELD_NUMBER: builtins.int
|
||||
OBJ_FILE_FIELD_NUMBER: builtins.int
|
||||
MLIR_MODULE_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def hlo_module_proto(self) -> global___HloModuleProto: ...
|
||||
obj_file: builtins.bytes
|
||||
"""TODO(b/232263665)): Serialized executable has to know what APIs it has to
|
||||
be linked with, including the version. For example Gpu executable must be
|
||||
@@ -1547,6 +1586,8 @@ class XlaRuntimeExecutableProto(google.protobuf.message.Message):
|
||||
"""
|
||||
mlir_module: builtins.str
|
||||
"""Serialized MLIR module corresponding to compiled object file."""
|
||||
@property
|
||||
def hlo_module_proto(self) -> global___HloModuleProto: ...
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1554,7 +1595,7 @@ class XlaRuntimeExecutableProto(google.protobuf.message.Message):
|
||||
obj_file: builtins.bytes | None = ...,
|
||||
mlir_module: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["hlo_module_proto", b"hlo_module_proto"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["hlo_module_proto", b"hlo_module_proto", "mlir_module", b"mlir_module", "obj_file", b"obj_file"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["hlo_module_proto", b"hlo_module_proto"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["hlo_module_proto", b"hlo_module_proto", "mlir_module", b"mlir_module", "obj_file", b"obj_file"]) -> None: ...
|
||||
|
||||
global___XlaRuntimeExecutableProto = XlaRuntimeExecutableProto
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import sys
|
||||
import typing
|
||||
@@ -19,7 +20,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CompilationLogEntry(google.protobuf.message.Message):
|
||||
"""Defines XLA compilation metrics."""
|
||||
|
||||
@@ -50,16 +51,18 @@ class CompilationLogEntry(google.protobuf.message.Message):
|
||||
STAGE_FIELD_NUMBER: builtins.int
|
||||
DURATION_FIELD_NUMBER: builtins.int
|
||||
TASK_INDEX_FIELD_NUMBER: builtins.int
|
||||
stage: global___CompilationLogEntry.CompilationStage.ValueType
|
||||
"""Compilation stage recorded by this log entry."""
|
||||
task_index: builtins.int
|
||||
"""Task index from which this log entry was recorded."""
|
||||
@property
|
||||
def timestamp(self) -> google.protobuf.timestamp_pb2.Timestamp:
|
||||
"""Time when the event captured by this log entry occurred."""
|
||||
stage: global___CompilationLogEntry.CompilationStage.ValueType
|
||||
"""Compilation stage recorded by this log entry."""
|
||||
|
||||
@property
|
||||
def duration(self) -> google.protobuf.duration_pb2.Duration:
|
||||
"""Duration of the given compilation stage."""
|
||||
task_index: builtins.int
|
||||
"""Task index from which this log entry was recorded."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -68,7 +71,7 @@ class CompilationLogEntry(google.protobuf.message.Message):
|
||||
duration: google.protobuf.duration_pb2.Duration | None = ...,
|
||||
task_index: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["duration", b"duration", "timestamp", b"timestamp"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["duration", b"duration", "stage", b"stage", "task_index", b"task_index", "timestamp", b"timestamp"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["duration", b"duration", "timestamp", b"timestamp"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["duration", b"duration", "stage", b"stage", "task_index", b"task_index", "timestamp", b"timestamp"]) -> None: ...
|
||||
|
||||
global___CompilationLogEntry = CompilationLogEntry
|
||||
|
||||
@@ -16,6 +16,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
==============================================================================
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -377,7 +378,7 @@ RNG_PHILOX: RandomAlgorithm.ValueType # 2
|
||||
"""Next: 2"""
|
||||
global___RandomAlgorithm = RandomAlgorithm
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class PaddingConfig(google.protobuf.message.Message):
|
||||
"""Describes the padding configuration for Pad operation. The padding amount on
|
||||
both edges as well as between the elements are specified for each dimension.
|
||||
@@ -385,7 +386,7 @@ class PaddingConfig(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class PaddingConfigDimension(google.protobuf.message.Message):
|
||||
"""Describes the padding configuration for a dimension."""
|
||||
|
||||
@@ -409,22 +410,23 @@ class PaddingConfig(google.protobuf.message.Message):
|
||||
edge_padding_high: builtins.int | None = ...,
|
||||
interior_padding: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["edge_padding_high", b"edge_padding_high", "edge_padding_low", b"edge_padding_low", "interior_padding", b"interior_padding"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["edge_padding_high", b"edge_padding_high", "edge_padding_low", b"edge_padding_low", "interior_padding", b"interior_padding"]) -> None: ...
|
||||
|
||||
DIMENSIONS_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def dimensions(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___PaddingConfig.PaddingConfigDimension]:
|
||||
"""The padding configuration for all dimensions."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
dimensions: collections.abc.Iterable[global___PaddingConfig.PaddingConfigDimension] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dimensions", b"dimensions"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["dimensions", b"dimensions"]) -> None: ...
|
||||
|
||||
global___PaddingConfig = PaddingConfig
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TileProto(google.protobuf.message.Message):
|
||||
"""Describes a tile used in tiling-based layout. Refer to
|
||||
g3doc/third_party/tensorflow/compiler/xla/g3doc/tiled_layout.md for
|
||||
@@ -441,16 +443,17 @@ class TileProto(google.protobuf.message.Message):
|
||||
The dimensions correspond to a suffix of the dimensions of the shape being
|
||||
tiled.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
dimensions: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dimensions", b"dimensions"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["dimensions", b"dimensions"]) -> None: ...
|
||||
|
||||
global___TileProto = TileProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class LayoutProto(google.protobuf.message.Message):
|
||||
"""A layout describes how the array is placed in (1D) memory space. This
|
||||
includes the minor-to-major ordering of dimensions within a shape.
|
||||
@@ -476,35 +479,6 @@ class LayoutProto(google.protobuf.message.Message):
|
||||
POINTER_PRIMITIVE_TYPE_FIELD_NUMBER: builtins.int
|
||||
PHYSICAL_SHAPE_FIELD_NUMBER: builtins.int
|
||||
DYNAMIC_SHAPE_METADATA_PREFIX_BYTES_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def dim_level_types(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[global___DimLevelType.ValueType]:
|
||||
"""The dimension level type list for this array, specifying the way in which
|
||||
each array dimension is represented in memory. If this list is empty, the
|
||||
array is assumed to be dense.
|
||||
"""
|
||||
@property
|
||||
def dim_unique(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bool]:
|
||||
"""Whether each dimension is unique or ordered. Each of the following lists
|
||||
must be empty, or have one entry for each entry of dim_level_types. If
|
||||
either list is empty, all dimensions are assumed to be unique and ordered,
|
||||
respectively. Entries in this list may not be false for some DimLevelType
|
||||
values (such as DIM_DENSE in particular).
|
||||
"""
|
||||
@property
|
||||
def dim_ordered(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bool]: ...
|
||||
@property
|
||||
def minor_to_major(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Sequence of dimension numbers, from minor (fastest varying index) to major
|
||||
(slowest varying index). This field is required.
|
||||
"""
|
||||
@property
|
||||
def tiles(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___TileProto]:
|
||||
"""A sequence of tiles, starting from the tile that's applied first to the
|
||||
Shape.
|
||||
|
||||
TODO(b/119839262): implement tiling in each backend or add Unimplemented
|
||||
error.
|
||||
"""
|
||||
memory_space: builtins.int
|
||||
"""Memory space where this array resides. The integer field is interpreted in
|
||||
a backend-specific manner.
|
||||
@@ -518,6 +492,44 @@ class LayoutProto(google.protobuf.message.Message):
|
||||
supported devices).
|
||||
"""
|
||||
pointer_primitive_type: global___PrimitiveType.ValueType
|
||||
dynamic_shape_metadata_prefix_bytes: builtins.int
|
||||
"""The dynamic shape metadata size in bytes in front of the shape data. The
|
||||
field may be non-zero for a static shape whose associated buffer is for a
|
||||
dynamic shape, e.g. a result of SliceToDynamic.
|
||||
"""
|
||||
@property
|
||||
def dim_level_types(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[global___DimLevelType.ValueType]:
|
||||
"""The dimension level type list for this array, specifying the way in which
|
||||
each array dimension is represented in memory. If this list is empty, the
|
||||
array is assumed to be dense.
|
||||
"""
|
||||
|
||||
@property
|
||||
def dim_unique(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bool]:
|
||||
"""Whether each dimension is unique or ordered. Each of the following lists
|
||||
must be empty, or have one entry for each entry of dim_level_types. If
|
||||
either list is empty, all dimensions are assumed to be unique and ordered,
|
||||
respectively. Entries in this list may not be false for some DimLevelType
|
||||
values (such as DIM_DENSE in particular).
|
||||
"""
|
||||
|
||||
@property
|
||||
def dim_ordered(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bool]: ...
|
||||
@property
|
||||
def minor_to_major(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Sequence of dimension numbers, from minor (fastest varying index) to major
|
||||
(slowest varying index). This field is required.
|
||||
"""
|
||||
|
||||
@property
|
||||
def tiles(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___TileProto]:
|
||||
"""A sequence of tiles, starting from the tile that's applied first to the
|
||||
Shape.
|
||||
|
||||
TODO(b/119839262): implement tiling in each backend or add Unimplemented
|
||||
error.
|
||||
"""
|
||||
|
||||
@property
|
||||
def physical_shape(self) -> global___ShapeProto:
|
||||
"""The physical, on-device shape used to represent the shape this layout
|
||||
@@ -525,11 +537,7 @@ class LayoutProto(google.protobuf.message.Message):
|
||||
The layout(s) contained within the physical shape should not also contain
|
||||
a physical shape.
|
||||
"""
|
||||
dynamic_shape_metadata_prefix_bytes: builtins.int
|
||||
"""The dynamic shape metadata size in bytes in front of the shape data. The
|
||||
field may be non-zero for a static shape whose associated buffer is for a
|
||||
dynamic shape, e.g. a result of SliceToDynamic.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -544,12 +552,12 @@ class LayoutProto(google.protobuf.message.Message):
|
||||
physical_shape: global___ShapeProto | None = ...,
|
||||
dynamic_shape_metadata_prefix_bytes: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["physical_shape", b"physical_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dim_level_types", b"dim_level_types", "dim_ordered", b"dim_ordered", "dim_unique", b"dim_unique", "dynamic_shape_metadata_prefix_bytes", b"dynamic_shape_metadata_prefix_bytes", "index_primitive_type", b"index_primitive_type", "memory_space", b"memory_space", "minor_to_major", b"minor_to_major", "physical_shape", b"physical_shape", "pointer_primitive_type", b"pointer_primitive_type", "tiles", b"tiles"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["physical_shape", b"physical_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["dim_level_types", b"dim_level_types", "dim_ordered", b"dim_ordered", "dim_unique", b"dim_unique", "dynamic_shape_metadata_prefix_bytes", b"dynamic_shape_metadata_prefix_bytes", "index_primitive_type", b"index_primitive_type", "memory_space", b"memory_space", "minor_to_major", b"minor_to_major", "physical_shape", b"physical_shape", "pointer_primitive_type", b"pointer_primitive_type", "tiles", b"tiles"]) -> None: ...
|
||||
|
||||
global___LayoutProto = LayoutProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ShapeProto(google.protobuf.message.Message):
|
||||
"""A shape describes the number of dimensions in the array, the size of each
|
||||
dimension, and the primitive component type.
|
||||
@@ -582,12 +590,15 @@ class ShapeProto(google.protobuf.message.Message):
|
||||
If the respective element in 'is_dimension_dynamic' is true then the value
|
||||
in this field represents an upper bound on the size of the dimension.
|
||||
"""
|
||||
|
||||
@property
|
||||
def tuple_shapes(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ShapeProto]:
|
||||
"""For tuples only, the shapes of constituent shapes in the tuple sequence."""
|
||||
|
||||
@property
|
||||
def layout(self) -> global___LayoutProto:
|
||||
"""The layout used to back this shape."""
|
||||
|
||||
@property
|
||||
def is_dynamic_dimension(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bool]:
|
||||
"""For arrays, this indicates whether or not each dimension is
|
||||
@@ -595,6 +606,7 @@ class ShapeProto(google.protobuf.message.Message):
|
||||
zero (indicating that no dimensions are dynamic) or equal to the number of
|
||||
elements in the 'dimensions' field.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -604,12 +616,12 @@ class ShapeProto(google.protobuf.message.Message):
|
||||
layout: global___LayoutProto | None = ...,
|
||||
is_dynamic_dimension: collections.abc.Iterable[builtins.bool] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["layout", b"layout"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dimensions", b"dimensions", "element_type", b"element_type", "is_dynamic_dimension", b"is_dynamic_dimension", "layout", b"layout", "tuple_shapes", b"tuple_shapes"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["layout", b"layout"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["dimensions", b"dimensions", "element_type", b"element_type", "is_dynamic_dimension", b"is_dynamic_dimension", "layout", b"layout", "tuple_shapes", b"tuple_shapes"]) -> None: ...
|
||||
|
||||
global___ShapeProto = ShapeProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ProgramShapeProto(google.protobuf.message.Message):
|
||||
"""Shape of the parameters and output of a computation (like a traditional
|
||||
function signature).
|
||||
@@ -633,12 +645,12 @@ class ProgramShapeProto(google.protobuf.message.Message):
|
||||
result: global___ShapeProto | None = ...,
|
||||
parameter_names: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["result", b"result"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["parameter_names", b"parameter_names", "parameters", b"parameters", "result", b"result"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["result", b"result"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["parameter_names", b"parameter_names", "parameters", b"parameters", "result", b"result"]) -> None: ...
|
||||
|
||||
global___ProgramShapeProto = ProgramShapeProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ComputationStats(google.protobuf.message.Message):
|
||||
"""Statistics of a computation."""
|
||||
|
||||
@@ -656,11 +668,11 @@ class ComputationStats(google.protobuf.message.Message):
|
||||
flop_count: builtins.float | None = ...,
|
||||
transcendental_count: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["flop_count", b"flop_count", "transcendental_count", b"transcendental_count"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["flop_count", b"flop_count", "transcendental_count", b"transcendental_count"]) -> None: ...
|
||||
|
||||
global___ComputationStats = ComputationStats
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OpMetadata(google.protobuf.message.Message):
|
||||
"""Symbolization metadata for HLO Instructions.
|
||||
|
||||
@@ -670,7 +682,7 @@ class OpMetadata(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ProfileInfo(google.protobuf.message.Message):
|
||||
"""Information about the optimization profile that this operation contains."""
|
||||
|
||||
@@ -680,9 +692,6 @@ class OpMetadata(google.protobuf.message.Message):
|
||||
RELATIVE_SPEEDUP_FIELD_NUMBER: builtins.int
|
||||
PROFILE_SOURCE_FIELD_NUMBER: builtins.int
|
||||
COMPILATION_EVENT_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def profile_type(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[global___ProfileType.ValueType]:
|
||||
"""The type of optimization profiles that this operation contains."""
|
||||
relative_speedup: builtins.float
|
||||
"""Speedup of tuned config compared to default config.
|
||||
TODO(b/203817882) Set the relative_speedup.
|
||||
@@ -691,6 +700,10 @@ class OpMetadata(google.protobuf.message.Message):
|
||||
"""The source of the optimization profiles that this operation contains."""
|
||||
compilation_event: global___CompilationEvent.ValueType
|
||||
"""The compilation event that triggered the use of the profiles."""
|
||||
@property
|
||||
def profile_type(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[global___ProfileType.ValueType]:
|
||||
"""The type of optimization profiles that this operation contains."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -699,7 +712,7 @@ class OpMetadata(google.protobuf.message.Message):
|
||||
profile_source: global___ProfileSource.ValueType | None = ...,
|
||||
compilation_event: global___CompilationEvent.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["compilation_event", b"compilation_event", "profile_source", b"profile_source", "profile_type", b"profile_type", "relative_speedup", b"relative_speedup"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["compilation_event", b"compilation_event", "profile_source", b"profile_source", "profile_type", b"profile_type", "relative_speedup", b"relative_speedup"]) -> None: ...
|
||||
|
||||
OP_TYPE_FIELD_NUMBER: builtins.int
|
||||
OP_NAME_FIELD_NUMBER: builtins.int
|
||||
@@ -732,9 +745,6 @@ class OpMetadata(google.protobuf.message.Message):
|
||||
e.g. it could be the file and line of user code that generated the op.
|
||||
"""
|
||||
source_line: builtins.int
|
||||
@property
|
||||
def profile_type(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[global___ProfileType.ValueType]:
|
||||
"""Deprecated, use [ProfileInfo][profile_type] instead."""
|
||||
creation_pass_id: builtins.int
|
||||
"""HloPassMetadata.pass_id of the pass that created this HLO instruction
|
||||
object. Should never be copied between HLO instructions. Zero if unset and
|
||||
@@ -752,9 +762,14 @@ class OpMetadata(google.protobuf.message.Message):
|
||||
"""The size of the working set, i.e., the amount of memory, used by the
|
||||
instruction in a compiler-managed fast device memory.
|
||||
"""
|
||||
@property
|
||||
def profile_type(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[global___ProfileType.ValueType]:
|
||||
"""Deprecated, use [ProfileInfo][profile_type] instead."""
|
||||
|
||||
@property
|
||||
def profile_info(self) -> global___OpMetadata.ProfileInfo:
|
||||
"""Profile information for the Op."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -769,12 +784,12 @@ class OpMetadata(google.protobuf.message.Message):
|
||||
size_of_memory_working_set_in_bytes: builtins.int | None = ...,
|
||||
profile_info: global___OpMetadata.ProfileInfo | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["profile_info", b"profile_info"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["creation_pass_id", b"creation_pass_id", "logical_creation_pass_id", b"logical_creation_pass_id", "op_name", b"op_name", "op_type", b"op_type", "profile_info", b"profile_info", "profile_type", b"profile_type", "size_of_generated_code_in_bytes", b"size_of_generated_code_in_bytes", "size_of_memory_working_set_in_bytes", b"size_of_memory_working_set_in_bytes", "source_file", b"source_file", "source_line", b"source_line"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["profile_info", b"profile_info"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["creation_pass_id", b"creation_pass_id", "logical_creation_pass_id", b"logical_creation_pass_id", "op_name", b"op_name", "op_type", b"op_type", "profile_info", b"profile_info", "profile_type", b"profile_type", "size_of_generated_code_in_bytes", b"size_of_generated_code_in_bytes", "size_of_memory_working_set_in_bytes", b"size_of_memory_working_set_in_bytes", "source_file", b"source_file", "source_line", b"source_line"]) -> None: ...
|
||||
|
||||
global___OpMetadata = OpMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ExecutionProfile(google.protobuf.message.Message):
|
||||
"""Profile data from the execution of a computation."""
|
||||
|
||||
@@ -824,11 +839,11 @@ class ExecutionProfile(google.protobuf.message.Message):
|
||||
executable_size_in_bytes: builtins.int | None = ...,
|
||||
profile_cache_hit: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["compilation_cache_hit", b"compilation_cache_hit", "compile_time_ms", b"compile_time_ms", "compute_and_transfer_time_ns", b"compute_and_transfer_time_ns", "compute_cycle_count", b"compute_cycle_count", "compute_time_ns", b"compute_time_ns", "executable_size_in_bytes", b"executable_size_in_bytes", "profile_cache_hit", b"profile_cache_hit"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["compilation_cache_hit", b"compilation_cache_hit", "compile_time_ms", b"compile_time_ms", "compute_and_transfer_time_ns", b"compute_and_transfer_time_ns", "compute_cycle_count", b"compute_cycle_count", "compute_time_ns", b"compute_time_ns", "executable_size_in_bytes", b"executable_size_in_bytes", "profile_cache_hit", b"profile_cache_hit"]) -> None: ...
|
||||
|
||||
global___ExecutionProfile = ExecutionProfile
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ExecutionHandle(google.protobuf.message.Message):
|
||||
"""Handle given to a user that represents an execution that the user launched
|
||||
asynchronously on the device.
|
||||
@@ -843,11 +858,11 @@ class ExecutionHandle(google.protobuf.message.Message):
|
||||
*,
|
||||
handle: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["handle", b"handle"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["handle", b"handle"]) -> None: ...
|
||||
|
||||
global___ExecutionHandle = ExecutionHandle
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GlobalDataHandle(google.protobuf.message.Message):
|
||||
"""Handle given to a user that represents a globally accessible allocation.
|
||||
Contrast this against a ComputationDataHandle, which is not globally
|
||||
@@ -863,11 +878,11 @@ class GlobalDataHandle(google.protobuf.message.Message):
|
||||
*,
|
||||
handle: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["handle", b"handle"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["handle", b"handle"]) -> None: ...
|
||||
|
||||
global___GlobalDataHandle = GlobalDataHandle
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DeviceHandle(google.protobuf.message.Message):
|
||||
"""Handle given to a user that represents a replicated virtual device. Each
|
||||
replicated device represents N physical devices for execution where N is the
|
||||
@@ -889,11 +904,11 @@ class DeviceHandle(google.protobuf.message.Message):
|
||||
handle: builtins.int | None = ...,
|
||||
device_count: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device_count", b"device_count", "handle", b"handle"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["device_count", b"device_count", "handle", b"handle"]) -> None: ...
|
||||
|
||||
global___DeviceHandle = DeviceHandle
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ChannelHandle(google.protobuf.message.Message):
|
||||
"""Handle given to a user to represent a channel between two computations
|
||||
via a Send and Recv instruction pair. Channels are unbuffered, so Send
|
||||
@@ -945,11 +960,11 @@ class ChannelHandle(google.protobuf.message.Message):
|
||||
handle: builtins.int | None = ...,
|
||||
type: global___ChannelHandle.ChannelType.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["handle", b"handle", "type", b"type"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["handle", b"handle", "type", b"type"]) -> None: ...
|
||||
|
||||
global___ChannelHandle = ChannelHandle
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DeviceAssignmentProto(google.protobuf.message.Message):
|
||||
"""DeviceAssignmentProto is a serialized form of DeviceAssignment class, which
|
||||
represents the device ids assigned to a set of replicated computations.
|
||||
@@ -958,7 +973,7 @@ class DeviceAssignmentProto(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ComputationDevice(google.protobuf.message.Message):
|
||||
"""Each logical computation runs on replica_count physical devices.
|
||||
ComputationDevice represents the device ids assinged to the replicas.
|
||||
@@ -974,7 +989,7 @@ class DeviceAssignmentProto(google.protobuf.message.Message):
|
||||
*,
|
||||
replica_device_ids: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["replica_device_ids", b"replica_device_ids"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["replica_device_ids", b"replica_device_ids"]) -> None: ...
|
||||
|
||||
REPLICA_COUNT_FIELD_NUMBER: builtins.int
|
||||
COMPUTATION_COUNT_FIELD_NUMBER: builtins.int
|
||||
@@ -990,11 +1005,11 @@ class DeviceAssignmentProto(google.protobuf.message.Message):
|
||||
computation_count: builtins.int | None = ...,
|
||||
computation_devices: collections.abc.Iterable[global___DeviceAssignmentProto.ComputationDevice] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["computation_count", b"computation_count", "computation_devices", b"computation_devices", "replica_count", b"replica_count"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["computation_count", b"computation_count", "computation_devices", b"computation_devices", "replica_count", b"replica_count"]) -> None: ...
|
||||
|
||||
global___DeviceAssignmentProto = DeviceAssignmentProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class LiteralProto(google.protobuf.message.Message):
|
||||
"""Literals are used when the server and client need to exchange materialized
|
||||
data / results. Literals are also used to describe constants used in
|
||||
@@ -1026,12 +1041,19 @@ class LiteralProto(google.protobuf.message.Message):
|
||||
F8E5M2S_FIELD_NUMBER: builtins.int
|
||||
F8E4M3FNS_FIELD_NUMBER: builtins.int
|
||||
SPARSE_INDICES_FIELD_NUMBER: builtins.int
|
||||
s8s: builtins.bytes
|
||||
u8s: builtins.bytes
|
||||
f16s: builtins.bytes
|
||||
"""The F16s, BF16s, U16s and S16s are encoded in little endian byte order"""
|
||||
bf16s: builtins.bytes
|
||||
u16s: builtins.bytes
|
||||
s16s: builtins.bytes
|
||||
f8e5m2s: builtins.bytes
|
||||
f8e4m3fns: builtins.bytes
|
||||
@property
|
||||
def shape(self) -> global___ShapeProto: ...
|
||||
@property
|
||||
def preds(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bool]: ...
|
||||
s8s: builtins.bytes
|
||||
u8s: builtins.bytes
|
||||
@property
|
||||
def s32s(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
@@ -1047,21 +1069,17 @@ class LiteralProto(google.protobuf.message.Message):
|
||||
@property
|
||||
def c64s(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.float]:
|
||||
"""Stored as interleaved real, imag floats."""
|
||||
|
||||
@property
|
||||
def c128s(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.float]:
|
||||
"""Stored as interleaved real, imag doubles."""
|
||||
|
||||
@property
|
||||
def tuple_literals(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___LiteralProto]: ...
|
||||
f16s: builtins.bytes
|
||||
"""The F16s, BF16s, U16s and S16s are encoded in little endian byte order"""
|
||||
bf16s: builtins.bytes
|
||||
u16s: builtins.bytes
|
||||
s16s: builtins.bytes
|
||||
f8e5m2s: builtins.bytes
|
||||
f8e4m3fns: builtins.bytes
|
||||
@property
|
||||
def sparse_indices(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Next = 21"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1086,12 +1104,12 @@ class LiteralProto(google.protobuf.message.Message):
|
||||
f8e4m3fns: builtins.bytes | None = ...,
|
||||
sparse_indices: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bf16s", b"bf16s", "c128s", b"c128s", "c64s", b"c64s", "f16s", b"f16s", "f32s", b"f32s", "f64s", b"f64s", "f8e4m3fns", b"f8e4m3fns", "f8e5m2s", b"f8e5m2s", "preds", b"preds", "s16s", b"s16s", "s32s", b"s32s", "s64s", b"s64s", "s8s", b"s8s", "shape", b"shape", "sparse_indices", b"sparse_indices", "tuple_literals", b"tuple_literals", "u16s", b"u16s", "u32s", b"u32s", "u64s", b"u64s", "u8s", b"u8s"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["bf16s", b"bf16s", "c128s", b"c128s", "c64s", b"c64s", "f16s", b"f16s", "f32s", b"f32s", "f64s", b"f64s", "f8e4m3fns", b"f8e4m3fns", "f8e5m2s", b"f8e5m2s", "preds", b"preds", "s16s", b"s16s", "s32s", b"s32s", "s64s", b"s64s", "s8s", b"s8s", "shape", b"shape", "sparse_indices", b"sparse_indices", "tuple_literals", b"tuple_literals", "u16s", b"u16s", "u32s", b"u32s", "u64s", b"u64s", "u8s", b"u8s"]) -> None: ...
|
||||
|
||||
global___LiteralProto = LiteralProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class WindowDimension(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -1153,11 +1171,11 @@ class WindowDimension(google.protobuf.message.Message):
|
||||
base_dilation: builtins.int | None = ...,
|
||||
window_reversal: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["base_dilation", b"base_dilation", "padding_high", b"padding_high", "padding_low", b"padding_low", "size", b"size", "stride", b"stride", "window_dilation", b"window_dilation", "window_reversal", b"window_reversal"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["base_dilation", b"base_dilation", "padding_high", b"padding_high", "padding_low", b"padding_low", "size", b"size", "stride", b"stride", "window_dilation", b"window_dilation", "window_reversal", b"window_reversal"]) -> None: ...
|
||||
|
||||
global___WindowDimension = WindowDimension
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Window(google.protobuf.message.Message):
|
||||
"""Describes the windowing in an operation such as convolution.
|
||||
|
||||
@@ -1176,11 +1194,11 @@ class Window(google.protobuf.message.Message):
|
||||
*,
|
||||
dimensions: collections.abc.Iterable[global___WindowDimension] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dimensions", b"dimensions"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["dimensions", b"dimensions"]) -> None: ...
|
||||
|
||||
global___Window = Window
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GatherDimensionNumbers(google.protobuf.message.Message):
|
||||
"""Describes the dimension numbers for a gather operation.
|
||||
|
||||
@@ -1194,6 +1212,10 @@ class GatherDimensionNumbers(google.protobuf.message.Message):
|
||||
COLLAPSED_SLICE_DIMS_FIELD_NUMBER: builtins.int
|
||||
START_INDEX_MAP_FIELD_NUMBER: builtins.int
|
||||
INDEX_VECTOR_DIM_FIELD_NUMBER: builtins.int
|
||||
index_vector_dim: builtins.int
|
||||
"""The dimension in the start_indices input that contains the starting
|
||||
indices.
|
||||
"""
|
||||
@property
|
||||
def offset_dims(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
""""Window indices" is a term for a set of indices that index into the
|
||||
@@ -1210,6 +1232,7 @@ class GatherDimensionNumbers(google.protobuf.message.Message):
|
||||
then 0
|
||||
else Out[offset_dims[i++]]
|
||||
"""
|
||||
|
||||
@property
|
||||
def collapsed_slice_dims(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
@@ -1218,10 +1241,7 @@ class GatherDimensionNumbers(google.protobuf.message.Message):
|
||||
transforms the gather index looked up from the start_indices tensor into
|
||||
the starting index in the input space.
|
||||
"""
|
||||
index_vector_dim: builtins.int
|
||||
"""The dimension in the start_indices input that contains the starting
|
||||
indices.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1230,11 +1250,11 @@ class GatherDimensionNumbers(google.protobuf.message.Message):
|
||||
start_index_map: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
index_vector_dim: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["collapsed_slice_dims", b"collapsed_slice_dims", "index_vector_dim", b"index_vector_dim", "offset_dims", b"offset_dims", "start_index_map", b"start_index_map"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["collapsed_slice_dims", b"collapsed_slice_dims", "index_vector_dim", b"index_vector_dim", "offset_dims", b"offset_dims", "start_index_map", b"start_index_map"]) -> None: ...
|
||||
|
||||
global___GatherDimensionNumbers = GatherDimensionNumbers
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ScatterDimensionNumbers(google.protobuf.message.Message):
|
||||
"""Describes the dimension numbers for a scatter operation.
|
||||
|
||||
@@ -1248,15 +1268,17 @@ class ScatterDimensionNumbers(google.protobuf.message.Message):
|
||||
INSERTED_WINDOW_DIMS_FIELD_NUMBER: builtins.int
|
||||
SCATTER_DIMS_TO_OPERAND_DIMS_FIELD_NUMBER: builtins.int
|
||||
INDEX_VECTOR_DIM_FIELD_NUMBER: builtins.int
|
||||
index_vector_dim: builtins.int
|
||||
@property
|
||||
def update_window_dims(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The set of dimensions in the updates shape that are window dimensions."""
|
||||
|
||||
@property
|
||||
def inserted_window_dims(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The set of window dimensions that must be inserted into the updates shape."""
|
||||
|
||||
@property
|
||||
def scatter_dims_to_operand_dims(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
index_vector_dim: builtins.int
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1265,11 +1287,11 @@ class ScatterDimensionNumbers(google.protobuf.message.Message):
|
||||
scatter_dims_to_operand_dims: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
index_vector_dim: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["index_vector_dim", b"index_vector_dim", "inserted_window_dims", b"inserted_window_dims", "scatter_dims_to_operand_dims", b"scatter_dims_to_operand_dims", "update_window_dims", b"update_window_dims"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["index_vector_dim", b"index_vector_dim", "inserted_window_dims", b"inserted_window_dims", "scatter_dims_to_operand_dims", b"scatter_dims_to_operand_dims", "update_window_dims", b"update_window_dims"]) -> None: ...
|
||||
|
||||
global___ScatterDimensionNumbers = ScatterDimensionNumbers
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ConvolutionDimensionNumbers(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -1286,11 +1308,6 @@ class ConvolutionDimensionNumbers(google.protobuf.message.Message):
|
||||
"""The number of the dimension that represents batch in the input."""
|
||||
input_feature_dimension: builtins.int
|
||||
"""The number of the dimension that represents features in the input."""
|
||||
@property
|
||||
def input_spatial_dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The dimension numbers for the spatial dimensions that the window
|
||||
moves through in the input.
|
||||
"""
|
||||
kernel_input_feature_dimension: builtins.int
|
||||
"""The number of the dimension that represents input features in the
|
||||
convolutional kernel (rhs).
|
||||
@@ -1299,21 +1316,29 @@ class ConvolutionDimensionNumbers(google.protobuf.message.Message):
|
||||
"""The number of the dimension that represents output features in
|
||||
the convolutional kernel (rhs).
|
||||
"""
|
||||
output_batch_dimension: builtins.int
|
||||
"""The number of the dimension that represents batch in the output."""
|
||||
output_feature_dimension: builtins.int
|
||||
"""The number of the dimension that represents features in the output."""
|
||||
@property
|
||||
def input_spatial_dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The dimension numbers for the spatial dimensions that the window
|
||||
moves through in the input.
|
||||
"""
|
||||
|
||||
@property
|
||||
def kernel_spatial_dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The dimension numbers for the spatial dimensions that the window
|
||||
moves through in the kernel (rhs). window.strides(0) is the
|
||||
stride in the kernel_spatial_dimensions(0) dimension.
|
||||
"""
|
||||
output_batch_dimension: builtins.int
|
||||
"""The number of the dimension that represents batch in the output."""
|
||||
output_feature_dimension: builtins.int
|
||||
"""The number of the dimension that represents features in the output."""
|
||||
|
||||
@property
|
||||
def output_spatial_dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The dimension numbers for the spatial dimensions that the window
|
||||
moves through in the output.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1327,11 +1352,11 @@ class ConvolutionDimensionNumbers(google.protobuf.message.Message):
|
||||
output_feature_dimension: builtins.int | None = ...,
|
||||
output_spatial_dimensions: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["input_batch_dimension", b"input_batch_dimension", "input_feature_dimension", b"input_feature_dimension", "input_spatial_dimensions", b"input_spatial_dimensions", "kernel_input_feature_dimension", b"kernel_input_feature_dimension", "kernel_output_feature_dimension", b"kernel_output_feature_dimension", "kernel_spatial_dimensions", b"kernel_spatial_dimensions", "output_batch_dimension", b"output_batch_dimension", "output_feature_dimension", b"output_feature_dimension", "output_spatial_dimensions", b"output_spatial_dimensions"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["input_batch_dimension", b"input_batch_dimension", "input_feature_dimension", b"input_feature_dimension", "input_spatial_dimensions", b"input_spatial_dimensions", "kernel_input_feature_dimension", b"kernel_input_feature_dimension", "kernel_output_feature_dimension", b"kernel_output_feature_dimension", "kernel_spatial_dimensions", b"kernel_spatial_dimensions", "output_batch_dimension", b"output_batch_dimension", "output_feature_dimension", b"output_feature_dimension", "output_spatial_dimensions", b"output_spatial_dimensions"]) -> None: ...
|
||||
|
||||
global___ConvolutionDimensionNumbers = ConvolutionDimensionNumbers
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DotDimensionNumbers(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -1342,15 +1367,19 @@ class DotDimensionNumbers(google.protobuf.message.Message):
|
||||
@property
|
||||
def lhs_contracting_dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The dimension numbers that represent the 'lhs' contracting dimensions."""
|
||||
|
||||
@property
|
||||
def rhs_contracting_dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The dimension numbers that represent the 'rhs' contracting dimensions."""
|
||||
|
||||
@property
|
||||
def lhs_batch_dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The dimension numbers that represent the 'lhs' batch dimensions."""
|
||||
|
||||
@property
|
||||
def rhs_batch_dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The dimension numbers that represent the 'rhs' batch dimensions."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1359,11 +1388,11 @@ class DotDimensionNumbers(google.protobuf.message.Message):
|
||||
lhs_batch_dimensions: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
rhs_batch_dimensions: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["lhs_batch_dimensions", b"lhs_batch_dimensions", "lhs_contracting_dimensions", b"lhs_contracting_dimensions", "rhs_batch_dimensions", b"rhs_batch_dimensions", "rhs_contracting_dimensions", b"rhs_contracting_dimensions"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["lhs_batch_dimensions", b"lhs_batch_dimensions", "lhs_contracting_dimensions", b"lhs_contracting_dimensions", "rhs_batch_dimensions", b"rhs_batch_dimensions", "rhs_contracting_dimensions", b"rhs_contracting_dimensions"]) -> None: ...
|
||||
|
||||
global___DotDimensionNumbers = DotDimensionNumbers
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TriangularSolveOptions(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -1411,11 +1440,11 @@ class TriangularSolveOptions(google.protobuf.message.Message):
|
||||
unit_diagonal: builtins.bool | None = ...,
|
||||
transpose_a: global___TriangularSolveOptions.Transpose.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["left_side", b"left_side", "lower", b"lower", "transpose_a", b"transpose_a", "unit_diagonal", b"unit_diagonal"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["left_side", b"left_side", "lower", b"lower", "transpose_a", b"transpose_a", "unit_diagonal", b"unit_diagonal"]) -> None: ...
|
||||
|
||||
global___TriangularSolveOptions = TriangularSolveOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CholeskyOptions(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -1429,11 +1458,11 @@ class CholeskyOptions(google.protobuf.message.Message):
|
||||
*,
|
||||
lower: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["lower", b"lower"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["lower", b"lower"]) -> None: ...
|
||||
|
||||
global___CholeskyOptions = CholeskyOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FrontendAttributes(google.protobuf.message.Message):
|
||||
"""Generic map of attributes used to pass hints / configuration options from
|
||||
the Python frontend to the XLA backend.
|
||||
@@ -1441,7 +1470,7 @@ class FrontendAttributes(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MapEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -1455,7 +1484,7 @@ class FrontendAttributes(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
MAP_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
@@ -1465,11 +1494,11 @@ class FrontendAttributes(google.protobuf.message.Message):
|
||||
*,
|
||||
map: collections.abc.Mapping[builtins.str, builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["map", b"map"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["map", b"map"]) -> None: ...
|
||||
|
||||
global___FrontendAttributes = FrontendAttributes
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OpSharding(google.protobuf.message.Message):
|
||||
"""LINT.IfChange"""
|
||||
|
||||
@@ -1521,20 +1550,28 @@ class OpSharding(google.protobuf.message.Message):
|
||||
METADATA_FIELD_NUMBER: builtins.int
|
||||
LAST_TILE_DIMS_FIELD_NUMBER: builtins.int
|
||||
type: global___OpSharding.Type.ValueType
|
||||
replicate_on_last_tile_dim: builtins.bool
|
||||
"""Only used for OTHER type. If true, data is sharded according to other
|
||||
dimensions of tile_assignment(), but replicated across devices along the
|
||||
last dimension. (Experimental)
|
||||
"""
|
||||
@property
|
||||
def tile_shape(self) -> global___ShapeProto:
|
||||
"""The shape of the sharded tile."""
|
||||
|
||||
@property
|
||||
def tile_assignment_dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The shape of the tile assignment tensor - this must be the same rank as
|
||||
tile_shape and the product of its dimensions must equal
|
||||
tile_assignment_devices.size().
|
||||
"""
|
||||
|
||||
@property
|
||||
def tile_assignment_devices(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Flattened list of device IDs. The order of flattening is the same as used
|
||||
by IndexUtil::MultiToLinearIndex(tile_assignment_shape).
|
||||
"""
|
||||
|
||||
@property
|
||||
def tuple_shardings(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___OpSharding]:
|
||||
"""If type == TUPLE, the sub-shardings, one per leaf node in the tuple shape,
|
||||
@@ -1544,11 +1581,7 @@ class OpSharding(google.protobuf.message.Message):
|
||||
applied, this is inferred from the instruction this sharding gets attached
|
||||
to.
|
||||
"""
|
||||
replicate_on_last_tile_dim: builtins.bool
|
||||
"""Only used for OTHER type. If true, data is sharded according to other
|
||||
dimensions of tile_assignment(), but replicated across devices along the
|
||||
last dimension. (Experimental)
|
||||
"""
|
||||
|
||||
@property
|
||||
def metadata(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___OpMetadata]:
|
||||
"""This field is used to track the source of this sharding, usually derived
|
||||
@@ -1557,6 +1590,7 @@ class OpSharding(google.protobuf.message.Message):
|
||||
type == TUPLE and instead metadata should be set on individual tuple
|
||||
elements.
|
||||
"""
|
||||
|
||||
@property
|
||||
def last_tile_dims(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[global___OpSharding.Type.ValueType]:
|
||||
"""This field is used to represented the sharding type of each subgroup.
|
||||
@@ -1565,6 +1599,7 @@ class OpSharding(google.protobuf.message.Message):
|
||||
in [2,2,2,2] represents a subgrouping in replicate, manual,
|
||||
unreduced sharding type respectively.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1577,12 +1612,12 @@ class OpSharding(google.protobuf.message.Message):
|
||||
metadata: collections.abc.Iterable[global___OpMetadata] | None = ...,
|
||||
last_tile_dims: collections.abc.Iterable[global___OpSharding.Type.ValueType] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["tile_shape", b"tile_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["last_tile_dims", b"last_tile_dims", "metadata", b"metadata", "replicate_on_last_tile_dim", b"replicate_on_last_tile_dim", "tile_assignment_devices", b"tile_assignment_devices", "tile_assignment_dimensions", b"tile_assignment_dimensions", "tile_shape", b"tile_shape", "tuple_shardings", b"tuple_shardings", "type", b"type"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["tile_shape", b"tile_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["last_tile_dims", b"last_tile_dims", "metadata", b"metadata", "replicate_on_last_tile_dim", b"replicate_on_last_tile_dim", "tile_assignment_devices", b"tile_assignment_devices", "tile_assignment_dimensions", b"tile_assignment_dimensions", "tile_shape", b"tile_shape", "tuple_shardings", b"tuple_shardings", "type", b"type"]) -> None: ...
|
||||
|
||||
global___OpSharding = OpSharding
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ReplicaGroup(google.protobuf.message.Message):
|
||||
"""Describes the replica groups in a cross replica op (e.g., all-reduce and
|
||||
all-to-all).
|
||||
@@ -1596,16 +1631,17 @@ class ReplicaGroup(google.protobuf.message.Message):
|
||||
"""The ids of the replicas that belongs to the same group. The ordering of the
|
||||
ids matters in some ops (e.g., all-to-all).
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
replica_ids: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["replica_ids", b"replica_ids"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["replica_ids", b"replica_ids"]) -> None: ...
|
||||
|
||||
global___ReplicaGroup = ReplicaGroup
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SourceTarget(google.protobuf.message.Message):
|
||||
"""Describes the source target pair in the collective permute op."""
|
||||
|
||||
@@ -1621,11 +1657,11 @@ class SourceTarget(google.protobuf.message.Message):
|
||||
source: builtins.int | None = ...,
|
||||
target: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["source", b"source", "target", b"target"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["source", b"source", "target", b"target"]) -> None: ...
|
||||
|
||||
global___SourceTarget = SourceTarget
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class PrecisionConfig(google.protobuf.message.Message):
|
||||
"""Used to indicate the precision configuration. It has backend specific
|
||||
meaning.
|
||||
@@ -1660,11 +1696,11 @@ class PrecisionConfig(google.protobuf.message.Message):
|
||||
*,
|
||||
operand_precision: collections.abc.Iterable[global___PrecisionConfig.Precision.ValueType] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["operand_precision", b"operand_precision"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["operand_precision", b"operand_precision"]) -> None: ...
|
||||
|
||||
global___PrecisionConfig = PrecisionConfig
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ParameterReplication(google.protobuf.message.Message):
|
||||
"""Describes whether all data-parallelism replicas will receive the same
|
||||
parameter data at each buffer.
|
||||
@@ -1682,16 +1718,17 @@ class ParameterReplication(google.protobuf.message.Message):
|
||||
number of elements in this field must match the number of leaf buffers in
|
||||
the HLO instruction's shape.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
replicated_at_leaf_buffers: collections.abc.Iterable[builtins.bool] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["replicated_at_leaf_buffers", b"replicated_at_leaf_buffers"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["replicated_at_leaf_buffers", b"replicated_at_leaf_buffers"]) -> None: ...
|
||||
|
||||
global___ParameterReplication = ParameterReplication
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class WhileLoopBackendConfig(google.protobuf.message.Message):
|
||||
"""A backend-config for kWhile loops that stores the loop's trip count, if it is
|
||||
known.
|
||||
@@ -1705,7 +1742,7 @@ class WhileLoopBackendConfig(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class KnownTripCount(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -1716,7 +1753,7 @@ class WhileLoopBackendConfig(google.protobuf.message.Message):
|
||||
*,
|
||||
n: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["n", b"n"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["n", b"n"]) -> None: ...
|
||||
|
||||
KNOWN_TRIP_COUNT_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
@@ -1724,17 +1761,18 @@ class WhileLoopBackendConfig(google.protobuf.message.Message):
|
||||
"""This indirection lets us distinguish between known-trip-count == 0 and
|
||||
unknown-trip-count.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
known_trip_count: global___WhileLoopBackendConfig.KnownTripCount | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["known_trip_count", b"known_trip_count"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["known_trip_count", b"known_trip_count"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["known_trip_count", b"known_trip_count"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["known_trip_count", b"known_trip_count"]) -> None: ...
|
||||
|
||||
global___WhileLoopBackendConfig = WhileLoopBackendConfig
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OutputOperandAliasing(google.protobuf.message.Message):
|
||||
"""Specifies a pair of output/operand buffers that alias each other for
|
||||
kCustomCall and kFusion
|
||||
@@ -1745,9 +1783,9 @@ class OutputOperandAliasing(google.protobuf.message.Message):
|
||||
OUTPUT_SHAPE_INDEX_FIELD_NUMBER: builtins.int
|
||||
OPERAND_INDEX_FIELD_NUMBER: builtins.int
|
||||
OPERAND_SHAPE_INDEX_FIELD_NUMBER: builtins.int
|
||||
operand_index: builtins.int
|
||||
@property
|
||||
def output_shape_index(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
operand_index: builtins.int
|
||||
@property
|
||||
def operand_shape_index(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
def __init__(
|
||||
@@ -1757,6 +1795,6 @@ class OutputOperandAliasing(google.protobuf.message.Message):
|
||||
operand_index: builtins.int | None = ...,
|
||||
operand_shape_index: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["operand_index", b"operand_index", "operand_shape_index", b"operand_shape_index", "output_shape_index", b"output_shape_index"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["operand_index", b"operand_index", "operand_shape_index", b"operand_shape_index", "output_shape_index", b"output_shape_index"]) -> None: ...
|
||||
|
||||
global___OutputOperandAliasing = OutputOperandAliasing
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
Protocol messages for describing the configuration of the ExampleParserOp."""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -15,7 +16,7 @@ import tensorflow.core.framework.types_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class VarLenFeatureProto(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -35,11 +36,11 @@ class VarLenFeatureProto(google.protobuf.message.Message):
|
||||
indices_output_tensor_name: builtins.str | None = ...,
|
||||
shapes_output_tensor_name: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dtype", b"dtype", "indices_output_tensor_name", b"indices_output_tensor_name", "shapes_output_tensor_name", b"shapes_output_tensor_name", "values_output_tensor_name", b"values_output_tensor_name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["dtype", b"dtype", "indices_output_tensor_name", b"indices_output_tensor_name", "shapes_output_tensor_name", b"shapes_output_tensor_name", "values_output_tensor_name", b"values_output_tensor_name"]) -> None: ...
|
||||
|
||||
global___VarLenFeatureProto = VarLenFeatureProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FixedLenFeatureProto(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -48,11 +49,11 @@ class FixedLenFeatureProto(google.protobuf.message.Message):
|
||||
DEFAULT_VALUE_FIELD_NUMBER: builtins.int
|
||||
VALUES_OUTPUT_TENSOR_NAME_FIELD_NUMBER: builtins.int
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
values_output_tensor_name: builtins.str
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto: ...
|
||||
@property
|
||||
def default_value(self) -> tensorflow.core.framework.tensor_pb2.TensorProto: ...
|
||||
values_output_tensor_name: builtins.str
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -61,12 +62,12 @@ class FixedLenFeatureProto(google.protobuf.message.Message):
|
||||
default_value: tensorflow.core.framework.tensor_pb2.TensorProto | None = ...,
|
||||
values_output_tensor_name: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["default_value", b"default_value", "shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["default_value", b"default_value", "dtype", b"dtype", "shape", b"shape", "values_output_tensor_name", b"values_output_tensor_name"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["default_value", b"default_value", "shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["default_value", b"default_value", "dtype", b"dtype", "shape", b"shape", "values_output_tensor_name", b"values_output_tensor_name"]) -> None: ...
|
||||
|
||||
global___FixedLenFeatureProto = FixedLenFeatureProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FeatureConfiguration(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -82,17 +83,17 @@ class FeatureConfiguration(google.protobuf.message.Message):
|
||||
fixed_len_feature: global___FixedLenFeatureProto | None = ...,
|
||||
var_len_feature: global___VarLenFeatureProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["config", b"config", "fixed_len_feature", b"fixed_len_feature", "var_len_feature", b"var_len_feature"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["config", b"config", "fixed_len_feature", b"fixed_len_feature", "var_len_feature", b"var_len_feature"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["config", b"config"]) -> typing_extensions.Literal["fixed_len_feature", "var_len_feature"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["config", b"config", "fixed_len_feature", b"fixed_len_feature", "var_len_feature", b"var_len_feature"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["config", b"config", "fixed_len_feature", b"fixed_len_feature", "var_len_feature", b"var_len_feature"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["config", b"config"]) -> typing.Literal["fixed_len_feature", "var_len_feature"] | None: ...
|
||||
|
||||
global___FeatureConfiguration = FeatureConfiguration
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ExampleParserConfiguration(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FeatureMapEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -107,8 +108,8 @@ class ExampleParserConfiguration(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___FeatureConfiguration | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
FEATURE_MAP_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
@@ -118,6 +119,6 @@ class ExampleParserConfiguration(google.protobuf.message.Message):
|
||||
*,
|
||||
feature_map: collections.abc.Mapping[builtins.str, global___FeatureConfiguration] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["feature_map", b"feature_map"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["feature_map", b"feature_map"]) -> None: ...
|
||||
|
||||
global___ExampleParserConfiguration = ExampleParserConfiguration
|
||||
|
||||
@@ -4,8 +4,9 @@ isort:skip_file
|
||||
Protocol messages for describing input data Examples for machine learning
|
||||
model training or inference.
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.message
|
||||
@@ -13,7 +14,7 @@ import tensorflow.core.example.feature_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Example(google.protobuf.message.Message):
|
||||
"""An Example is a mostly-normalized data format for storing data for
|
||||
training and inference. It contains a key-value store (features); where
|
||||
@@ -99,12 +100,12 @@ class Example(google.protobuf.message.Message):
|
||||
*,
|
||||
features: tensorflow.core.example.feature_pb2.Features | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["features", b"features"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["features", b"features"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["features", b"features"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["features", b"features"]) -> None: ...
|
||||
|
||||
global___Example = Example
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SequenceExample(google.protobuf.message.Message):
|
||||
"""A SequenceExample is an Example representing one or more sequences, and
|
||||
some context. The context contains features which apply to the entire
|
||||
@@ -327,7 +328,7 @@ class SequenceExample(google.protobuf.message.Message):
|
||||
context: tensorflow.core.example.feature_pb2.Features | None = ...,
|
||||
feature_lists: tensorflow.core.example.feature_pb2.FeatureLists | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["context", b"context", "feature_lists", b"feature_lists"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["context", b"context", "feature_lists", b"feature_lists"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["context", b"context", "feature_lists", b"feature_lists"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["context", b"context", "feature_lists", b"feature_lists"]) -> None: ...
|
||||
|
||||
global___SequenceExample = SequenceExample
|
||||
|
||||
@@ -55,9 +55,10 @@ Example Features for a movie recommendation application:
|
||||
}}
|
||||
}
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -65,7 +66,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BytesList(google.protobuf.message.Message):
|
||||
"""LINT.IfChange
|
||||
Containers to hold repeated fundamental values.
|
||||
@@ -81,11 +82,11 @@ class BytesList(google.protobuf.message.Message):
|
||||
*,
|
||||
value: collections.abc.Iterable[builtins.bytes] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["value", b"value"]) -> None: ...
|
||||
|
||||
global___BytesList = BytesList
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FloatList(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -97,11 +98,11 @@ class FloatList(google.protobuf.message.Message):
|
||||
*,
|
||||
value: collections.abc.Iterable[builtins.float] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["value", b"value"]) -> None: ...
|
||||
|
||||
global___FloatList = FloatList
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Int64List(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -113,11 +114,11 @@ class Int64List(google.protobuf.message.Message):
|
||||
*,
|
||||
value: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["value", b"value"]) -> None: ...
|
||||
|
||||
global___Int64List = Int64List
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Feature(google.protobuf.message.Message):
|
||||
"""Containers for non-sequential data."""
|
||||
|
||||
@@ -139,17 +140,17 @@ class Feature(google.protobuf.message.Message):
|
||||
float_list: global___FloatList | None = ...,
|
||||
int64_list: global___Int64List | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["bytes_list", b"bytes_list", "float_list", b"float_list", "int64_list", b"int64_list", "kind", b"kind"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bytes_list", b"bytes_list", "float_list", b"float_list", "int64_list", b"int64_list", "kind", b"kind"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["kind", b"kind"]) -> typing_extensions.Literal["bytes_list", "float_list", "int64_list"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["bytes_list", b"bytes_list", "float_list", b"float_list", "int64_list", b"int64_list", "kind", b"kind"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["bytes_list", b"bytes_list", "float_list", b"float_list", "int64_list", b"int64_list", "kind", b"kind"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["kind", b"kind"]) -> typing.Literal["bytes_list", "float_list", "int64_list"] | None: ...
|
||||
|
||||
global___Feature = Feature
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Features(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FeatureEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -164,23 +165,24 @@ class Features(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___Feature | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
FEATURE_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def feature(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, global___Feature]:
|
||||
"""Map from feature name to feature."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
feature: collections.abc.Mapping[builtins.str, global___Feature] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["feature", b"feature"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["feature", b"feature"]) -> None: ...
|
||||
|
||||
global___Features = Features
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FeatureList(google.protobuf.message.Message):
|
||||
"""Containers for sequential data.
|
||||
|
||||
@@ -201,15 +203,15 @@ class FeatureList(google.protobuf.message.Message):
|
||||
*,
|
||||
feature: collections.abc.Iterable[global___Feature] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["feature", b"feature"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["feature", b"feature"]) -> None: ...
|
||||
|
||||
global___FeatureList = FeatureList
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FeatureLists(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FeatureListEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -224,18 +226,19 @@ class FeatureLists(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___FeatureList | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
FEATURE_LIST_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def feature_list(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, global___FeatureList]:
|
||||
"""Map from feature name to feature list."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
feature_list: collections.abc.Mapping[builtins.str, global___FeatureList] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["feature_list", b"feature_list"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["feature_list", b"feature_list"]) -> None: ...
|
||||
|
||||
global___FeatureLists = FeatureLists
|
||||
|
||||
@@ -2,15 +2,16 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AllocationDescription(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -42,6 +43,6 @@ class AllocationDescription(google.protobuf.message.Message):
|
||||
has_single_reference: builtins.bool | None = ...,
|
||||
ptr: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allocated_bytes", b"allocated_bytes", "allocation_id", b"allocation_id", "allocator_name", b"allocator_name", "has_single_reference", b"has_single_reference", "ptr", b"ptr", "requested_bytes", b"requested_bytes"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["allocated_bytes", b"allocated_bytes", "allocation_id", b"allocation_id", "allocator_name", b"allocator_name", "has_single_reference", b"has_single_reference", "ptr", b"ptr", "requested_bytes", b"requested_bytes"]) -> None: ...
|
||||
|
||||
global___AllocationDescription = AllocationDescription
|
||||
|
||||
@@ -4,6 +4,7 @@ isort:skip_file
|
||||
Defines the text format for including per-op API definition and
|
||||
overrides for client language op code generators.
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -22,7 +23,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ApiDef(google.protobuf.message.Message):
|
||||
"""Used to specify and override the default API & behavior in the
|
||||
generated code for client languages, from what you would get from
|
||||
@@ -81,7 +82,7 @@ class ApiDef(google.protobuf.message.Message):
|
||||
is appropriate in the target language).
|
||||
"""
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Endpoint(google.protobuf.message.Message):
|
||||
"""If you specify any endpoint, this will replace all of the
|
||||
inherited endpoints. The first endpoint should be the
|
||||
@@ -116,9 +117,9 @@ class ApiDef(google.protobuf.message.Message):
|
||||
deprecated: builtins.bool | None = ...,
|
||||
deprecation_version: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["deprecated", b"deprecated", "deprecation_version", b"deprecation_version", "name", b"name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["deprecated", b"deprecated", "deprecation_version", b"deprecation_version", "name", b"name"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Arg(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -143,9 +144,9 @@ class ApiDef(google.protobuf.message.Message):
|
||||
rename_to: builtins.str | None = ...,
|
||||
description: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["description", b"description", "name", b"name", "rename_to", b"rename_to"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["description", b"description", "name", b"name", "rename_to", b"rename_to"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Attr(google.protobuf.message.Message):
|
||||
"""Description of the graph-construction-time configuration of this
|
||||
Op. That is to say, this describes the attr fields that will
|
||||
@@ -164,6 +165,10 @@ class ApiDef(google.protobuf.message.Message):
|
||||
is used in the GraphDef. Note that these names in `backticks`
|
||||
will also be replaced in the summary & description fields.
|
||||
"""
|
||||
description: builtins.str
|
||||
"""Note: this will replace any inherited attr doc, there is no current
|
||||
way of modifying attr descriptions as can be done with op descriptions.
|
||||
"""
|
||||
@property
|
||||
def default_value(self) -> tensorflow.core.framework.attr_value_pb2.AttrValue:
|
||||
"""Specify a new default value to use for this attr. This default
|
||||
@@ -171,10 +176,7 @@ class ApiDef(google.protobuf.message.Message):
|
||||
default in the OpDef, which will be used when interpreting old
|
||||
GraphDefs.
|
||||
"""
|
||||
description: builtins.str
|
||||
"""Note: this will replace any inherited attr doc, there is no current
|
||||
way of modifying attr descriptions as can be done with op descriptions.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -183,8 +185,8 @@ class ApiDef(google.protobuf.message.Message):
|
||||
default_value: tensorflow.core.framework.attr_value_pb2.AttrValue | None = ...,
|
||||
description: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["default_value", b"default_value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["default_value", b"default_value", "description", b"description", "name", b"name", "rename_to", b"rename_to"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["default_value", b"default_value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["default_value", b"default_value", "description", b"description", "name", b"name", "rename_to", b"rename_to"]) -> None: ...
|
||||
|
||||
GRAPH_OP_NAME_FIELD_NUMBER: builtins.int
|
||||
DEPRECATION_MESSAGE_FIELD_NUMBER: builtins.int
|
||||
@@ -212,6 +214,15 @@ class ApiDef(google.protobuf.message.Message):
|
||||
deprecated in versions before that.
|
||||
"""
|
||||
visibility: global___ApiDef.Visibility.ValueType
|
||||
summary: builtins.str
|
||||
"""One-line human-readable description of what the Op does."""
|
||||
description: builtins.str
|
||||
"""Additional, longer human-readable description of what the Op does."""
|
||||
description_prefix: builtins.str
|
||||
"""Modify an existing/inherited description by adding text to the beginning
|
||||
or end.
|
||||
"""
|
||||
description_suffix: builtins.str
|
||||
@property
|
||||
def endpoint(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ApiDef.Endpoint]: ...
|
||||
@property
|
||||
@@ -224,17 +235,9 @@ class ApiDef(google.protobuf.message.Message):
|
||||
Length of arg_order should be either empty to keep current order
|
||||
or match size of in_arg.
|
||||
"""
|
||||
|
||||
@property
|
||||
def attr(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ApiDef.Attr]: ...
|
||||
summary: builtins.str
|
||||
"""One-line human-readable description of what the Op does."""
|
||||
description: builtins.str
|
||||
"""Additional, longer human-readable description of what the Op does."""
|
||||
description_prefix: builtins.str
|
||||
"""Modify an existing/inherited description by adding text to the beginning
|
||||
or end.
|
||||
"""
|
||||
description_suffix: builtins.str
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -252,11 +255,11 @@ class ApiDef(google.protobuf.message.Message):
|
||||
description_prefix: builtins.str | None = ...,
|
||||
description_suffix: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["arg_order", b"arg_order", "attr", b"attr", "deprecation_message", b"deprecation_message", "deprecation_version", b"deprecation_version", "description", b"description", "description_prefix", b"description_prefix", "description_suffix", b"description_suffix", "endpoint", b"endpoint", "graph_op_name", b"graph_op_name", "in_arg", b"in_arg", "out_arg", b"out_arg", "summary", b"summary", "visibility", b"visibility"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["arg_order", b"arg_order", "attr", b"attr", "deprecation_message", b"deprecation_message", "deprecation_version", b"deprecation_version", "description", b"description", "description_prefix", b"description_prefix", "description_suffix", b"description_suffix", "endpoint", b"endpoint", "graph_op_name", b"graph_op_name", "in_arg", b"in_arg", "out_arg", b"out_arg", "summary", b"summary", "visibility", b"visibility"]) -> None: ...
|
||||
|
||||
global___ApiDef = ApiDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ApiDefs(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -268,6 +271,6 @@ class ApiDefs(google.protobuf.message.Message):
|
||||
*,
|
||||
op: collections.abc.Iterable[global___ApiDef] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["op", b"op"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["op", b"op"]) -> None: ...
|
||||
|
||||
global___ApiDefs = ApiDefs
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -15,7 +16,7 @@ import tensorflow.core.framework.types_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AttrValue(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing the value for an attr used to configure an Op.
|
||||
Comment indicates the corresponding attr type. Only the field matching the
|
||||
@@ -24,7 +25,7 @@ class AttrValue(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ListValue(google.protobuf.message.Message):
|
||||
"""LINT.IfChange"""
|
||||
|
||||
@@ -41,27 +42,35 @@ class AttrValue(google.protobuf.message.Message):
|
||||
@property
|
||||
def s(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bytes]:
|
||||
""""list(string)" """
|
||||
|
||||
@property
|
||||
def i(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
""""list(int)" """
|
||||
|
||||
@property
|
||||
def f(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.float]:
|
||||
""""list(float)" """
|
||||
|
||||
@property
|
||||
def b(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bool]:
|
||||
""""list(bool)" """
|
||||
|
||||
@property
|
||||
def type(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[tensorflow.core.framework.types_pb2.DataType.ValueType]:
|
||||
""""list(type)" """
|
||||
|
||||
@property
|
||||
def shape(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto]:
|
||||
""""list(shape)" """
|
||||
|
||||
@property
|
||||
def tensor(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.tensor_pb2.TensorProto]:
|
||||
""""list(tensor)" """
|
||||
|
||||
@property
|
||||
def func(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___NameAttrList]:
|
||||
""""list(attr)" """
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -74,7 +83,7 @@ class AttrValue(google.protobuf.message.Message):
|
||||
tensor: collections.abc.Iterable[tensorflow.core.framework.tensor_pb2.TensorProto] | None = ...,
|
||||
func: collections.abc.Iterable[global___NameAttrList] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["b", b"b", "f", b"f", "func", b"func", "i", b"i", "s", b"s", "shape", b"shape", "tensor", b"tensor", "type", b"type"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["b", b"b", "f", b"f", "func", b"func", "i", b"i", "s", b"s", "shape", b"shape", "tensor", b"tensor", "type", b"type"]) -> None: ...
|
||||
|
||||
S_FIELD_NUMBER: builtins.int
|
||||
I_FIELD_NUMBER: builtins.int
|
||||
@@ -96,22 +105,6 @@ class AttrValue(google.protobuf.message.Message):
|
||||
""""bool" """
|
||||
type: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
""""type" """
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto:
|
||||
""""shape" """
|
||||
@property
|
||||
def tensor(self) -> tensorflow.core.framework.tensor_pb2.TensorProto:
|
||||
""""tensor" """
|
||||
@property
|
||||
def list(self) -> global___AttrValue.ListValue:
|
||||
"""any "list(...)" """
|
||||
@property
|
||||
def func(self) -> global___NameAttrList:
|
||||
""""func" represents a function. func.name is a function's name or
|
||||
a primitive op's name. func.attr.first is the name of an attr
|
||||
defined for that function. func.attr.second is the value for
|
||||
that attr in the instantiation.
|
||||
"""
|
||||
placeholder: builtins.str
|
||||
"""This is a placeholder only used in nodes defined inside a
|
||||
function. It indicates the attr value will be supplied when
|
||||
@@ -121,6 +114,26 @@ class AttrValue(google.protobuf.message.Message):
|
||||
set to "bar", the instantiated node N's attr A will have been
|
||||
given the value "bar".
|
||||
"""
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto:
|
||||
""""shape" """
|
||||
|
||||
@property
|
||||
def tensor(self) -> tensorflow.core.framework.tensor_pb2.TensorProto:
|
||||
""""tensor" """
|
||||
|
||||
@property
|
||||
def list(self) -> global___AttrValue.ListValue:
|
||||
"""any "list(...)" """
|
||||
|
||||
@property
|
||||
def func(self) -> global___NameAttrList:
|
||||
""""func" represents a function. func.name is a function's name or
|
||||
a primitive op's name. func.attr.first is the name of an attr
|
||||
defined for that function. func.attr.second is the value for
|
||||
that attr in the instantiation.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -135,13 +148,13 @@ class AttrValue(google.protobuf.message.Message):
|
||||
func: global___NameAttrList | None = ...,
|
||||
placeholder: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["b", b"b", "f", b"f", "func", b"func", "i", b"i", "list", b"list", "placeholder", b"placeholder", "s", b"s", "shape", b"shape", "tensor", b"tensor", "type", b"type", "value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["b", b"b", "f", b"f", "func", b"func", "i", b"i", "list", b"list", "placeholder", b"placeholder", "s", b"s", "shape", b"shape", "tensor", b"tensor", "type", b"type", "value", b"value"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["value", b"value"]) -> typing_extensions.Literal["s", "i", "f", "b", "type", "shape", "tensor", "list", "func", "placeholder"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["b", b"b", "f", b"f", "func", b"func", "i", b"i", "list", b"list", "placeholder", b"placeholder", "s", b"s", "shape", b"shape", "tensor", b"tensor", "type", b"type", "value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["b", b"b", "f", b"f", "func", b"func", "i", b"i", "list", b"list", "placeholder", b"placeholder", "s", b"s", "shape", b"shape", "tensor", b"tensor", "type", b"type", "value", b"value"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["value", b"value"]) -> typing.Literal["s", "i", "f", "b", "type", "shape", "tensor", "list", "func", "placeholder"] | None: ...
|
||||
|
||||
global___AttrValue = AttrValue
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class NameAttrList(google.protobuf.message.Message):
|
||||
"""A list of attr names and their values. The whole list is attached
|
||||
with a string name. E.g., MatMul[T=float].
|
||||
@@ -149,7 +162,7 @@ class NameAttrList(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AttrEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -164,8 +177,8 @@ class NameAttrList(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___AttrValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
ATTR_FIELD_NUMBER: builtins.int
|
||||
@@ -178,6 +191,6 @@ class NameAttrList(google.protobuf.message.Message):
|
||||
name: builtins.str | None = ...,
|
||||
attr: collections.abc.Mapping[builtins.str, global___AttrValue] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["attr", b"attr", "name", b"name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["attr", b"attr", "name", b"name"]) -> None: ...
|
||||
|
||||
global___NameAttrList = NameAttrList
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -14,15 +15,15 @@ import tensorflow.core.framework.types_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CostGraphDef(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Node(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class InputInfo(google.protobuf.message.Message):
|
||||
"""Inputs of this node. They must be executed before this node can be
|
||||
executed. An input is a particular output of another node, specified
|
||||
@@ -41,9 +42,9 @@ class CostGraphDef(google.protobuf.message.Message):
|
||||
preceding_node: builtins.int | None = ...,
|
||||
preceding_port: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["preceding_node", b"preceding_node", "preceding_port", b"preceding_port"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["preceding_node", b"preceding_node", "preceding_port", b"preceding_port"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OutputInfo(google.protobuf.message.Message):
|
||||
"""Outputs of this node."""
|
||||
|
||||
@@ -59,9 +60,9 @@ class CostGraphDef(google.protobuf.message.Message):
|
||||
may itself be an alias. The algorithm will therefore need to follow
|
||||
those pointers.
|
||||
"""
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto: ...
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -70,8 +71,8 @@ class CostGraphDef(google.protobuf.message.Message):
|
||||
shape: tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto | None = ...,
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["alias_input_port", b"alias_input_port", "dtype", b"dtype", "shape", b"shape", "size", b"size"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["alias_input_port", b"alias_input_port", "dtype", b"dtype", "shape", b"shape", "size", b"size"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
DEVICE_FIELD_NUMBER: builtins.int
|
||||
@@ -97,10 +98,6 @@ class CostGraphDef(google.protobuf.message.Message):
|
||||
"""
|
||||
id: builtins.int
|
||||
"""The id of the node. Node ids are only unique inside a partition."""
|
||||
@property
|
||||
def input_info(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___CostGraphDef.Node.InputInfo]: ...
|
||||
@property
|
||||
def output_info(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___CostGraphDef.Node.OutputInfo]: ...
|
||||
temporary_memory_size: builtins.int
|
||||
"""Temporary memory used by this node."""
|
||||
persistent_memory_size: builtins.int
|
||||
@@ -122,11 +119,16 @@ class CostGraphDef(google.protobuf.message.Message):
|
||||
"""If true, the output is permanent: it can't be discarded, because this
|
||||
node is part of the "final output". Nodes may depend on final nodes.
|
||||
"""
|
||||
inaccurate: builtins.bool
|
||||
"""Are the costs inaccurate?"""
|
||||
@property
|
||||
def input_info(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___CostGraphDef.Node.InputInfo]: ...
|
||||
@property
|
||||
def output_info(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___CostGraphDef.Node.OutputInfo]: ...
|
||||
@property
|
||||
def control_input(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Ids of the control inputs for this node."""
|
||||
inaccurate: builtins.bool
|
||||
"""Are the costs inaccurate?"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -147,9 +149,9 @@ class CostGraphDef(google.protobuf.message.Message):
|
||||
control_input: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
inaccurate: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["compute_cost", b"compute_cost", "compute_time", b"compute_time", "control_input", b"control_input", "device", b"device", "device_persistent_memory_size", b"device_persistent_memory_size", "device_temp_memory_size", b"device_temp_memory_size", "host_temp_memory_size", b"host_temp_memory_size", "id", b"id", "inaccurate", b"inaccurate", "input_info", b"input_info", "is_final", b"is_final", "memory_time", b"memory_time", "name", b"name", "output_info", b"output_info", "persistent_memory_size", b"persistent_memory_size", "temporary_memory_size", b"temporary_memory_size"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["compute_cost", b"compute_cost", "compute_time", b"compute_time", "control_input", b"control_input", "device", b"device", "device_persistent_memory_size", b"device_persistent_memory_size", "device_temp_memory_size", b"device_temp_memory_size", "host_temp_memory_size", b"host_temp_memory_size", "id", b"id", "inaccurate", b"inaccurate", "input_info", b"input_info", "is_final", b"is_final", "memory_time", b"memory_time", "name", b"name", "output_info", b"output_info", "persistent_memory_size", b"persistent_memory_size", "temporary_memory_size", b"temporary_memory_size"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AggregatedCost(google.protobuf.message.Message):
|
||||
"""Total cost of this graph, typically used for balancing decisions."""
|
||||
|
||||
@@ -167,7 +169,7 @@ class CostGraphDef(google.protobuf.message.Message):
|
||||
cost: builtins.float | None = ...,
|
||||
dimension: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cost", b"cost", "dimension", b"dimension"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["cost", b"cost", "dimension", b"dimension"]) -> None: ...
|
||||
|
||||
NODE_FIELD_NUMBER: builtins.int
|
||||
COST_FIELD_NUMBER: builtins.int
|
||||
@@ -181,6 +183,6 @@ class CostGraphDef(google.protobuf.message.Message):
|
||||
node: collections.abc.Iterable[global___CostGraphDef.Node] | None = ...,
|
||||
cost: collections.abc.Iterable[global___CostGraphDef.AggregatedCost] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cost", b"cost", "node", b"node"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["cost", b"cost", "node", b"node"]) -> None: ...
|
||||
|
||||
global___CostGraphDef = CostGraphDef
|
||||
|
||||
@@ -2,15 +2,16 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Metadata(google.protobuf.message.Message):
|
||||
"""next: 2"""
|
||||
|
||||
@@ -23,6 +24,6 @@ class Metadata(google.protobuf.message.Message):
|
||||
*,
|
||||
name: builtins.bytes | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["name", b"name"]) -> None: ...
|
||||
|
||||
global___Metadata = Metadata
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import sys
|
||||
import typing
|
||||
@@ -88,7 +89,7 @@ POLICY_IGNORE: ExternalStatePolicy.ValueType # 1
|
||||
POLICY_FAIL: ExternalStatePolicy.ValueType # 2
|
||||
global___ExternalStatePolicy = ExternalStatePolicy
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AutotuneOptions(google.protobuf.message.Message):
|
||||
"""next: 5"""
|
||||
|
||||
@@ -110,20 +111,20 @@ class AutotuneOptions(google.protobuf.message.Message):
|
||||
ram_budget: builtins.int | None = ...,
|
||||
autotune_algorithm: tensorflow.core.framework.model_pb2.AutotuneAlgorithm.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["autotune_algorithm", b"autotune_algorithm", "cpu_budget", b"cpu_budget", "enabled", b"enabled", "optional_autotune_algorithm", b"optional_autotune_algorithm", "optional_cpu_budget", b"optional_cpu_budget", "optional_enabled", b"optional_enabled", "optional_ram_budget", b"optional_ram_budget", "ram_budget", b"ram_budget"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["autotune_algorithm", b"autotune_algorithm", "cpu_budget", b"cpu_budget", "enabled", b"enabled", "optional_autotune_algorithm", b"optional_autotune_algorithm", "optional_cpu_budget", b"optional_cpu_budget", "optional_enabled", b"optional_enabled", "optional_ram_budget", b"optional_ram_budget", "ram_budget", b"ram_budget"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["autotune_algorithm", b"autotune_algorithm", "cpu_budget", b"cpu_budget", "enabled", b"enabled", "optional_autotune_algorithm", b"optional_autotune_algorithm", "optional_cpu_budget", b"optional_cpu_budget", "optional_enabled", b"optional_enabled", "optional_ram_budget", b"optional_ram_budget", "ram_budget", b"ram_budget"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["autotune_algorithm", b"autotune_algorithm", "cpu_budget", b"cpu_budget", "enabled", b"enabled", "optional_autotune_algorithm", b"optional_autotune_algorithm", "optional_cpu_budget", b"optional_cpu_budget", "optional_enabled", b"optional_enabled", "optional_ram_budget", b"optional_ram_budget", "ram_budget", b"ram_budget"]) -> None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_autotune_algorithm", b"optional_autotune_algorithm"]) -> typing_extensions.Literal["autotune_algorithm"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_autotune_algorithm", b"optional_autotune_algorithm"]) -> typing.Literal["autotune_algorithm"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_cpu_budget", b"optional_cpu_budget"]) -> typing_extensions.Literal["cpu_budget"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_cpu_budget", b"optional_cpu_budget"]) -> typing.Literal["cpu_budget"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_enabled", b"optional_enabled"]) -> typing_extensions.Literal["enabled"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_enabled", b"optional_enabled"]) -> typing.Literal["enabled"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_ram_budget", b"optional_ram_budget"]) -> typing_extensions.Literal["ram_budget"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_ram_budget", b"optional_ram_budget"]) -> typing.Literal["ram_budget"] | None: ...
|
||||
|
||||
global___AutotuneOptions = AutotuneOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CardinalityOptions(google.protobuf.message.Message):
|
||||
"""next: 2"""
|
||||
|
||||
@@ -169,11 +170,11 @@ class CardinalityOptions(google.protobuf.message.Message):
|
||||
*,
|
||||
compute_level: global___CardinalityOptions.ComputeLevel.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["compute_level", b"compute_level"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["compute_level", b"compute_level"]) -> None: ...
|
||||
|
||||
global___CardinalityOptions = CardinalityOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DistributeOptions(google.protobuf.message.Message):
|
||||
"""next: 3"""
|
||||
|
||||
@@ -189,13 +190,13 @@ class DistributeOptions(google.protobuf.message.Message):
|
||||
auto_shard_policy: global___AutoShardPolicy.ValueType | None = ...,
|
||||
num_devices: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["num_devices", b"num_devices", "optional_num_devices", b"optional_num_devices"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["auto_shard_policy", b"auto_shard_policy", "num_devices", b"num_devices", "optional_num_devices", b"optional_num_devices"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_num_devices", b"optional_num_devices"]) -> typing_extensions.Literal["num_devices"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["num_devices", b"num_devices", "optional_num_devices", b"optional_num_devices"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["auto_shard_policy", b"auto_shard_policy", "num_devices", b"num_devices", "optional_num_devices", b"optional_num_devices"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_num_devices", b"optional_num_devices"]) -> typing.Literal["num_devices"] | None: ...
|
||||
|
||||
global___DistributeOptions = DistributeOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OptimizationOptions(google.protobuf.message.Message):
|
||||
"""next: 20"""
|
||||
|
||||
@@ -238,34 +239,34 @@ class OptimizationOptions(google.protobuf.message.Message):
|
||||
filter_parallelization: builtins.bool | None = ...,
|
||||
inject_prefetch: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["apply_default_optimizations", b"apply_default_optimizations", "filter_fusion", b"filter_fusion", "filter_parallelization", b"filter_parallelization", "inject_prefetch", b"inject_prefetch", "map_and_batch_fusion", b"map_and_batch_fusion", "map_and_filter_fusion", b"map_and_filter_fusion", "map_fusion", b"map_fusion", "map_parallelization", b"map_parallelization", "noop_elimination", b"noop_elimination", "optional_apply_default_optimizations", b"optional_apply_default_optimizations", "optional_filter_fusion", b"optional_filter_fusion", "optional_filter_parallelization", b"optional_filter_parallelization", "optional_inject_prefetch", b"optional_inject_prefetch", "optional_map_and_batch_fusion", b"optional_map_and_batch_fusion", "optional_map_and_filter_fusion", b"optional_map_and_filter_fusion", "optional_map_fusion", b"optional_map_fusion", "optional_map_parallelization", b"optional_map_parallelization", "optional_noop_elimination", b"optional_noop_elimination", "optional_parallel_batch", b"optional_parallel_batch", "optional_shuffle_and_repeat_fusion", b"optional_shuffle_and_repeat_fusion", "parallel_batch", b"parallel_batch", "shuffle_and_repeat_fusion", b"shuffle_and_repeat_fusion"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["apply_default_optimizations", b"apply_default_optimizations", "filter_fusion", b"filter_fusion", "filter_parallelization", b"filter_parallelization", "inject_prefetch", b"inject_prefetch", "map_and_batch_fusion", b"map_and_batch_fusion", "map_and_filter_fusion", b"map_and_filter_fusion", "map_fusion", b"map_fusion", "map_parallelization", b"map_parallelization", "noop_elimination", b"noop_elimination", "optional_apply_default_optimizations", b"optional_apply_default_optimizations", "optional_filter_fusion", b"optional_filter_fusion", "optional_filter_parallelization", b"optional_filter_parallelization", "optional_inject_prefetch", b"optional_inject_prefetch", "optional_map_and_batch_fusion", b"optional_map_and_batch_fusion", "optional_map_and_filter_fusion", b"optional_map_and_filter_fusion", "optional_map_fusion", b"optional_map_fusion", "optional_map_parallelization", b"optional_map_parallelization", "optional_noop_elimination", b"optional_noop_elimination", "optional_parallel_batch", b"optional_parallel_batch", "optional_shuffle_and_repeat_fusion", b"optional_shuffle_and_repeat_fusion", "parallel_batch", b"parallel_batch", "shuffle_and_repeat_fusion", b"shuffle_and_repeat_fusion"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["apply_default_optimizations", b"apply_default_optimizations", "filter_fusion", b"filter_fusion", "filter_parallelization", b"filter_parallelization", "inject_prefetch", b"inject_prefetch", "map_and_batch_fusion", b"map_and_batch_fusion", "map_and_filter_fusion", b"map_and_filter_fusion", "map_fusion", b"map_fusion", "map_parallelization", b"map_parallelization", "noop_elimination", b"noop_elimination", "optional_apply_default_optimizations", b"optional_apply_default_optimizations", "optional_filter_fusion", b"optional_filter_fusion", "optional_filter_parallelization", b"optional_filter_parallelization", "optional_inject_prefetch", b"optional_inject_prefetch", "optional_map_and_batch_fusion", b"optional_map_and_batch_fusion", "optional_map_and_filter_fusion", b"optional_map_and_filter_fusion", "optional_map_fusion", b"optional_map_fusion", "optional_map_parallelization", b"optional_map_parallelization", "optional_noop_elimination", b"optional_noop_elimination", "optional_parallel_batch", b"optional_parallel_batch", "optional_shuffle_and_repeat_fusion", b"optional_shuffle_and_repeat_fusion", "parallel_batch", b"parallel_batch", "shuffle_and_repeat_fusion", b"shuffle_and_repeat_fusion"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["apply_default_optimizations", b"apply_default_optimizations", "filter_fusion", b"filter_fusion", "filter_parallelization", b"filter_parallelization", "inject_prefetch", b"inject_prefetch", "map_and_batch_fusion", b"map_and_batch_fusion", "map_and_filter_fusion", b"map_and_filter_fusion", "map_fusion", b"map_fusion", "map_parallelization", b"map_parallelization", "noop_elimination", b"noop_elimination", "optional_apply_default_optimizations", b"optional_apply_default_optimizations", "optional_filter_fusion", b"optional_filter_fusion", "optional_filter_parallelization", b"optional_filter_parallelization", "optional_inject_prefetch", b"optional_inject_prefetch", "optional_map_and_batch_fusion", b"optional_map_and_batch_fusion", "optional_map_and_filter_fusion", b"optional_map_and_filter_fusion", "optional_map_fusion", b"optional_map_fusion", "optional_map_parallelization", b"optional_map_parallelization", "optional_noop_elimination", b"optional_noop_elimination", "optional_parallel_batch", b"optional_parallel_batch", "optional_shuffle_and_repeat_fusion", b"optional_shuffle_and_repeat_fusion", "parallel_batch", b"parallel_batch", "shuffle_and_repeat_fusion", b"shuffle_and_repeat_fusion"]) -> None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_apply_default_optimizations", b"optional_apply_default_optimizations"]) -> typing_extensions.Literal["apply_default_optimizations"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_apply_default_optimizations", b"optional_apply_default_optimizations"]) -> typing.Literal["apply_default_optimizations"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_filter_fusion", b"optional_filter_fusion"]) -> typing_extensions.Literal["filter_fusion"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_filter_fusion", b"optional_filter_fusion"]) -> typing.Literal["filter_fusion"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_filter_parallelization", b"optional_filter_parallelization"]) -> typing_extensions.Literal["filter_parallelization"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_filter_parallelization", b"optional_filter_parallelization"]) -> typing.Literal["filter_parallelization"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_inject_prefetch", b"optional_inject_prefetch"]) -> typing_extensions.Literal["inject_prefetch"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_inject_prefetch", b"optional_inject_prefetch"]) -> typing.Literal["inject_prefetch"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_map_and_batch_fusion", b"optional_map_and_batch_fusion"]) -> typing_extensions.Literal["map_and_batch_fusion"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_map_and_batch_fusion", b"optional_map_and_batch_fusion"]) -> typing.Literal["map_and_batch_fusion"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_map_and_filter_fusion", b"optional_map_and_filter_fusion"]) -> typing_extensions.Literal["map_and_filter_fusion"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_map_and_filter_fusion", b"optional_map_and_filter_fusion"]) -> typing.Literal["map_and_filter_fusion"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_map_fusion", b"optional_map_fusion"]) -> typing_extensions.Literal["map_fusion"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_map_fusion", b"optional_map_fusion"]) -> typing.Literal["map_fusion"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_map_parallelization", b"optional_map_parallelization"]) -> typing_extensions.Literal["map_parallelization"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_map_parallelization", b"optional_map_parallelization"]) -> typing.Literal["map_parallelization"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_noop_elimination", b"optional_noop_elimination"]) -> typing_extensions.Literal["noop_elimination"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_noop_elimination", b"optional_noop_elimination"]) -> typing.Literal["noop_elimination"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_parallel_batch", b"optional_parallel_batch"]) -> typing_extensions.Literal["parallel_batch"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_parallel_batch", b"optional_parallel_batch"]) -> typing.Literal["parallel_batch"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_shuffle_and_repeat_fusion", b"optional_shuffle_and_repeat_fusion"]) -> typing_extensions.Literal["shuffle_and_repeat_fusion"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_shuffle_and_repeat_fusion", b"optional_shuffle_and_repeat_fusion"]) -> typing.Literal["shuffle_and_repeat_fusion"] | None: ...
|
||||
|
||||
global___OptimizationOptions = OptimizationOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ThreadingOptions(google.protobuf.message.Message):
|
||||
"""next: 3"""
|
||||
|
||||
@@ -281,16 +282,16 @@ class ThreadingOptions(google.protobuf.message.Message):
|
||||
max_intra_op_parallelism: builtins.int | None = ...,
|
||||
private_threadpool_size: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["max_intra_op_parallelism", b"max_intra_op_parallelism", "optional_max_intra_op_parallelism", b"optional_max_intra_op_parallelism", "optional_private_threadpool_size", b"optional_private_threadpool_size", "private_threadpool_size", b"private_threadpool_size"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["max_intra_op_parallelism", b"max_intra_op_parallelism", "optional_max_intra_op_parallelism", b"optional_max_intra_op_parallelism", "optional_private_threadpool_size", b"optional_private_threadpool_size", "private_threadpool_size", b"private_threadpool_size"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["max_intra_op_parallelism", b"max_intra_op_parallelism", "optional_max_intra_op_parallelism", b"optional_max_intra_op_parallelism", "optional_private_threadpool_size", b"optional_private_threadpool_size", "private_threadpool_size", b"private_threadpool_size"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["max_intra_op_parallelism", b"max_intra_op_parallelism", "optional_max_intra_op_parallelism", b"optional_max_intra_op_parallelism", "optional_private_threadpool_size", b"optional_private_threadpool_size", "private_threadpool_size", b"private_threadpool_size"]) -> None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_max_intra_op_parallelism", b"optional_max_intra_op_parallelism"]) -> typing_extensions.Literal["max_intra_op_parallelism"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_max_intra_op_parallelism", b"optional_max_intra_op_parallelism"]) -> typing.Literal["max_intra_op_parallelism"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_private_threadpool_size", b"optional_private_threadpool_size"]) -> typing_extensions.Literal["private_threadpool_size"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_private_threadpool_size", b"optional_private_threadpool_size"]) -> typing.Literal["private_threadpool_size"] | None: ...
|
||||
|
||||
global___ThreadingOptions = ThreadingOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Options(google.protobuf.message.Message):
|
||||
"""Message stored with Dataset objects to control how datasets are processed and
|
||||
optimized.
|
||||
@@ -309,21 +310,25 @@ class Options(google.protobuf.message.Message):
|
||||
EXTERNAL_STATE_POLICY_FIELD_NUMBER: builtins.int
|
||||
SYMBOLIC_CHECKPOINT_FIELD_NUMBER: builtins.int
|
||||
deterministic: builtins.bool
|
||||
slack: builtins.bool
|
||||
external_state_policy: global___ExternalStatePolicy.ValueType
|
||||
symbolic_checkpoint: builtins.bool
|
||||
@property
|
||||
def autotune_options(self) -> global___AutotuneOptions:
|
||||
"""The distribution strategy options associated with the dataset."""
|
||||
|
||||
@property
|
||||
def distribute_options(self) -> global___DistributeOptions:
|
||||
"""The distribution strategy options associated with the dataset."""
|
||||
|
||||
@property
|
||||
def optimization_options(self) -> global___OptimizationOptions:
|
||||
"""The optimization options associated with the dataset."""
|
||||
slack: builtins.bool
|
||||
|
||||
@property
|
||||
def threading_options(self) -> global___ThreadingOptions:
|
||||
"""The threading options associated with the dataset."""
|
||||
external_state_policy: global___ExternalStatePolicy.ValueType
|
||||
symbolic_checkpoint: builtins.bool
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -336,15 +341,15 @@ class Options(google.protobuf.message.Message):
|
||||
external_state_policy: global___ExternalStatePolicy.ValueType | None = ...,
|
||||
symbolic_checkpoint: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["autotune_options", b"autotune_options", "deterministic", b"deterministic", "distribute_options", b"distribute_options", "external_state_policy", b"external_state_policy", "optimization_options", b"optimization_options", "optional_deterministic", b"optional_deterministic", "optional_external_state_policy", b"optional_external_state_policy", "optional_slack", b"optional_slack", "optional_symbolic_checkpoint", b"optional_symbolic_checkpoint", "slack", b"slack", "symbolic_checkpoint", b"symbolic_checkpoint", "threading_options", b"threading_options"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["autotune_options", b"autotune_options", "deterministic", b"deterministic", "distribute_options", b"distribute_options", "external_state_policy", b"external_state_policy", "optimization_options", b"optimization_options", "optional_deterministic", b"optional_deterministic", "optional_external_state_policy", b"optional_external_state_policy", "optional_slack", b"optional_slack", "optional_symbolic_checkpoint", b"optional_symbolic_checkpoint", "slack", b"slack", "symbolic_checkpoint", b"symbolic_checkpoint", "threading_options", b"threading_options"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["autotune_options", b"autotune_options", "deterministic", b"deterministic", "distribute_options", b"distribute_options", "external_state_policy", b"external_state_policy", "optimization_options", b"optimization_options", "optional_deterministic", b"optional_deterministic", "optional_external_state_policy", b"optional_external_state_policy", "optional_slack", b"optional_slack", "optional_symbolic_checkpoint", b"optional_symbolic_checkpoint", "slack", b"slack", "symbolic_checkpoint", b"symbolic_checkpoint", "threading_options", b"threading_options"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["autotune_options", b"autotune_options", "deterministic", b"deterministic", "distribute_options", b"distribute_options", "external_state_policy", b"external_state_policy", "optimization_options", b"optimization_options", "optional_deterministic", b"optional_deterministic", "optional_external_state_policy", b"optional_external_state_policy", "optional_slack", b"optional_slack", "optional_symbolic_checkpoint", b"optional_symbolic_checkpoint", "slack", b"slack", "symbolic_checkpoint", b"symbolic_checkpoint", "threading_options", b"threading_options"]) -> None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_deterministic", b"optional_deterministic"]) -> typing_extensions.Literal["deterministic"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_deterministic", b"optional_deterministic"]) -> typing.Literal["deterministic"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_external_state_policy", b"optional_external_state_policy"]) -> typing_extensions.Literal["external_state_policy"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_external_state_policy", b"optional_external_state_policy"]) -> typing.Literal["external_state_policy"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_slack", b"optional_slack"]) -> typing_extensions.Literal["slack"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_slack", b"optional_slack"]) -> typing.Literal["slack"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_symbolic_checkpoint", b"optional_symbolic_checkpoint"]) -> typing_extensions.Literal["symbolic_checkpoint"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_symbolic_checkpoint", b"optional_symbolic_checkpoint"]) -> typing.Literal["symbolic_checkpoint"] | None: ...
|
||||
|
||||
global___Options = Options
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -15,7 +16,7 @@ import tensorflow.core.framework.types_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CompressedComponentMetadata(google.protobuf.message.Message):
|
||||
"""This file contains protocol buffers for working with tf.data Datasets.
|
||||
|
||||
@@ -32,6 +33,7 @@ class CompressedComponentMetadata(google.protobuf.message.Message):
|
||||
@property
|
||||
def tensor_shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto:
|
||||
"""The shape of the component tensor."""
|
||||
|
||||
@property
|
||||
def uncompressed_bytes(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The amount of uncompressed tensor data.
|
||||
@@ -40,6 +42,7 @@ class CompressedComponentMetadata(google.protobuf.message.Message):
|
||||
- For all other tensors, there is a single element indicating the size of
|
||||
the tensor.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -47,12 +50,12 @@ class CompressedComponentMetadata(google.protobuf.message.Message):
|
||||
tensor_shape: tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto | None = ...,
|
||||
uncompressed_bytes: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["tensor_shape", b"tensor_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dtype", b"dtype", "tensor_shape", b"tensor_shape", "uncompressed_bytes", b"uncompressed_bytes"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["tensor_shape", b"tensor_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["dtype", b"dtype", "tensor_shape", b"tensor_shape", "uncompressed_bytes", b"uncompressed_bytes"]) -> None: ...
|
||||
|
||||
global___CompressedComponentMetadata = CompressedComponentMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CompressedElement(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -61,9 +64,6 @@ class CompressedElement(google.protobuf.message.Message):
|
||||
VERSION_FIELD_NUMBER: builtins.int
|
||||
data: builtins.bytes
|
||||
"""Compressed tensor bytes for all components of the element."""
|
||||
@property
|
||||
def component_metadata(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___CompressedComponentMetadata]:
|
||||
"""Metadata for the components of the element."""
|
||||
version: builtins.int
|
||||
"""Version of the CompressedElement. CompressedElements may be stored on disk
|
||||
and read back by later versions of code, so we store a version number to
|
||||
@@ -71,6 +71,10 @@ class CompressedElement(google.protobuf.message.Message):
|
||||
field to this proto, you need to increment kCompressedElementVersion in
|
||||
tensorflow/core/data/compression_utils.cc.
|
||||
"""
|
||||
@property
|
||||
def component_metadata(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___CompressedComponentMetadata]:
|
||||
"""Metadata for the components of the element."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -78,11 +82,11 @@ class CompressedElement(google.protobuf.message.Message):
|
||||
component_metadata: collections.abc.Iterable[global___CompressedComponentMetadata] | None = ...,
|
||||
version: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["component_metadata", b"component_metadata", "data", b"data", "version", b"version"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["component_metadata", b"component_metadata", "data", b"data", "version", b"version"]) -> None: ...
|
||||
|
||||
global___CompressedElement = CompressedElement
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class UncompressedElement(google.protobuf.message.Message):
|
||||
"""An uncompressed dataset element."""
|
||||
|
||||
@@ -96,6 +100,6 @@ class UncompressedElement(google.protobuf.message.Message):
|
||||
*,
|
||||
components: collections.abc.Iterable[tensorflow.core.framework.tensor_pb2.TensorProto] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["components", b"components"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["components", b"components"]) -> None: ...
|
||||
|
||||
global___UncompressedElement = UncompressedElement
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,7 +13,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class InterconnectLink(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -29,11 +30,11 @@ class InterconnectLink(google.protobuf.message.Message):
|
||||
type: builtins.str | None = ...,
|
||||
strength: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device_id", b"device_id", "strength", b"strength", "type", b"type"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["device_id", b"device_id", "strength", b"strength", "type", b"type"]) -> None: ...
|
||||
|
||||
global___InterconnectLink = InterconnectLink
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class LocalLinks(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -45,11 +46,11 @@ class LocalLinks(google.protobuf.message.Message):
|
||||
*,
|
||||
link: collections.abc.Iterable[global___InterconnectLink] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["link", b"link"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["link", b"link"]) -> None: ...
|
||||
|
||||
global___LocalLinks = LocalLinks
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DeviceLocality(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -65,6 +66,7 @@ class DeviceLocality(google.protobuf.message.Message):
|
||||
@property
|
||||
def links(self) -> global___LocalLinks:
|
||||
"""Optional local interconnect links to other devices."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -72,12 +74,12 @@ class DeviceLocality(google.protobuf.message.Message):
|
||||
numa_node: builtins.int | None = ...,
|
||||
links: global___LocalLinks | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["links", b"links"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bus_id", b"bus_id", "links", b"links", "numa_node", b"numa_node"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["links", b"links"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["bus_id", b"bus_id", "links", b"links", "numa_node", b"numa_node"]) -> None: ...
|
||||
|
||||
global___DeviceLocality = DeviceLocality
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DeviceAttributes(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -94,11 +96,6 @@ class DeviceAttributes(google.protobuf.message.Message):
|
||||
"""String representation of device_type."""
|
||||
memory_limit: builtins.int
|
||||
"""Memory capacity of device in bytes."""
|
||||
@property
|
||||
def locality(self) -> global___DeviceLocality:
|
||||
"""Platform-specific data about device that may be useful
|
||||
for supporting efficient data transfers.
|
||||
"""
|
||||
incarnation: builtins.int
|
||||
"""A device is assigned a global unique number each time it is
|
||||
initialized. "incarnation" should never be 0.
|
||||
@@ -110,6 +107,12 @@ class DeviceAttributes(google.protobuf.message.Message):
|
||||
clients in a multi-client setup. Set to -1 if unavailable, non-negative
|
||||
otherwise.
|
||||
"""
|
||||
@property
|
||||
def locality(self) -> global___DeviceLocality:
|
||||
"""Platform-specific data about device that may be useful
|
||||
for supporting efficient data transfers.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -121,7 +124,7 @@ class DeviceAttributes(google.protobuf.message.Message):
|
||||
physical_device_desc: builtins.str | None = ...,
|
||||
xla_global_id: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["locality", b"locality"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device_type", b"device_type", "incarnation", b"incarnation", "locality", b"locality", "memory_limit", b"memory_limit", "name", b"name", "physical_device_desc", b"physical_device_desc", "xla_global_id", b"xla_global_id"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["locality", b"locality"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["device_type", b"device_type", "incarnation", b"incarnation", "locality", b"locality", "memory_limit", b"memory_limit", "name", b"name", "physical_device_desc", b"physical_device_desc", "xla_global_id", b"xla_global_id"]) -> None: ...
|
||||
|
||||
global___DeviceAttributes = DeviceAttributes
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -573,7 +574,7 @@ not a subtype of LEGACY_VARIANT.
|
||||
"""
|
||||
global___FullTypeId = FullTypeId
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FullTypeDef(google.protobuf.message.Message):
|
||||
"""Highly experimental and very likely to change.
|
||||
This encoding uses tags instead of dedicated messages for regularity. In
|
||||
@@ -592,11 +593,11 @@ class FullTypeDef(google.protobuf.message.Message):
|
||||
(Tensor, Dataset) a type variable (used for dependent types) a type
|
||||
symbol (Any, Union). See FullTypeId for details.
|
||||
"""
|
||||
@property
|
||||
def args(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___FullTypeDef]: ...
|
||||
s: builtins.str
|
||||
i: builtins.int
|
||||
"""TODO(mdan): list/tensor, map? Need to reconcile with TFT_RECORD, etc."""
|
||||
@property
|
||||
def args(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___FullTypeDef]: ...
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -605,8 +606,8 @@ class FullTypeDef(google.protobuf.message.Message):
|
||||
s: builtins.str | None = ...,
|
||||
i: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["attr", b"attr", "i", b"i", "s", b"s"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["args", b"args", "attr", b"attr", "i", b"i", "s", b"s", "type_id", b"type_id"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["attr", b"attr"]) -> typing_extensions.Literal["s", "i"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["attr", b"attr", "i", b"i", "s", b"s"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["args", b"args", "attr", b"attr", "i", b"i", "s", b"s", "type_id", b"type_id"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["attr", b"attr"]) -> typing.Literal["s", "i"] | None: ...
|
||||
|
||||
global___FullTypeDef = FullTypeDef
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -15,7 +16,7 @@ import tensorflow.core.framework.op_def_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FunctionDefLibrary(google.protobuf.message.Message):
|
||||
"""A library is a set of named functions."""
|
||||
|
||||
@@ -37,11 +38,11 @@ class FunctionDefLibrary(google.protobuf.message.Message):
|
||||
gradient: collections.abc.Iterable[global___GradientDef] | None = ...,
|
||||
registered_gradients: collections.abc.Iterable[global___RegisteredGradient] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["function", b"function", "gradient", b"gradient", "registered_gradients", b"registered_gradients"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["function", b"function", "gradient", b"gradient", "registered_gradients", b"registered_gradients"]) -> None: ...
|
||||
|
||||
global___FunctionDefLibrary = FunctionDefLibrary
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FunctionDef(google.protobuf.message.Message):
|
||||
"""A function can be instantiated when the runtime can bind every attr
|
||||
with a value. When a GraphDef has a call to a function, it must
|
||||
@@ -53,7 +54,7 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AttrEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -68,10 +69,10 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: tensorflow.core.framework.attr_value_pb2.AttrValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ArgAttrs(google.protobuf.message.Message):
|
||||
"""Attributes for function arguments. These attributes are the same set of
|
||||
valid attributes as to _Arg nodes.
|
||||
@@ -79,7 +80,7 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AttrEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -94,8 +95,8 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: tensorflow.core.framework.attr_value_pb2.AttrValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
ATTR_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
@@ -105,9 +106,9 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
*,
|
||||
attr: collections.abc.Mapping[builtins.str, tensorflow.core.framework.attr_value_pb2.AttrValue] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["attr", b"attr"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["attr", b"attr"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ArgAttrEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -122,10 +123,10 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
key: builtins.int | None = ...,
|
||||
value: global___FunctionDef.ArgAttrs | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ResourceArgUniqueIdEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -139,9 +140,9 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
key: builtins.int | None = ...,
|
||||
value: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RetEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -155,9 +156,9 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ControlRetEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -171,7 +172,7 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
SIGNATURE_FIELD_NUMBER: builtins.int
|
||||
ATTR_FIELD_NUMBER: builtins.int
|
||||
@@ -185,9 +186,11 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
"""The definition of the function's name, arguments, return values,
|
||||
attrs etc.
|
||||
"""
|
||||
|
||||
@property
|
||||
def attr(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, tensorflow.core.framework.attr_value_pb2.AttrValue]:
|
||||
"""Attributes specific to this function definition."""
|
||||
|
||||
@property
|
||||
def arg_attr(self) -> google.protobuf.internal.containers.MessageMap[builtins.int, global___FunctionDef.ArgAttrs]: ...
|
||||
@property
|
||||
@@ -202,6 +205,7 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
When instantiated, the unique IDs will be attached to the _Arg nodes'
|
||||
"_resource_arg_unique_id" attribute.
|
||||
"""
|
||||
|
||||
@property
|
||||
def node_def(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.node_def_pb2.NodeDef]:
|
||||
"""The body of the function. Unlike the NodeDefs in a GraphDef, attrs
|
||||
@@ -212,16 +216,19 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
user-defined library first. If not resolved, "func" is assumed to
|
||||
be a builtin op.
|
||||
"""
|
||||
|
||||
@property
|
||||
def ret(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]:
|
||||
"""A mapping from the output arg names from `signature` to the
|
||||
outputs from `node_def` that should be returned by the function.
|
||||
"""
|
||||
|
||||
@property
|
||||
def control_ret(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]:
|
||||
"""A mapping from control output names from `signature` to node names in
|
||||
`node_def` which should be control outputs of this function.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -233,12 +240,12 @@ class FunctionDef(google.protobuf.message.Message):
|
||||
ret: collections.abc.Mapping[builtins.str, builtins.str] | None = ...,
|
||||
control_ret: collections.abc.Mapping[builtins.str, builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["signature", b"signature"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["arg_attr", b"arg_attr", "attr", b"attr", "control_ret", b"control_ret", "node_def", b"node_def", "resource_arg_unique_id", b"resource_arg_unique_id", "ret", b"ret", "signature", b"signature"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["signature", b"signature"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["arg_attr", b"arg_attr", "attr", b"attr", "control_ret", b"control_ret", "node_def", b"node_def", "resource_arg_unique_id", b"resource_arg_unique_id", "ret", b"ret", "signature", b"signature"]) -> None: ...
|
||||
|
||||
global___FunctionDef = FunctionDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GradientDef(google.protobuf.message.Message):
|
||||
"""GradientDef defines the gradient function of a function defined in
|
||||
a function library.
|
||||
@@ -274,11 +281,11 @@ class GradientDef(google.protobuf.message.Message):
|
||||
function_name: builtins.str | None = ...,
|
||||
gradient_func: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["function_name", b"function_name", "gradient_func", b"gradient_func"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["function_name", b"function_name", "gradient_func", b"gradient_func"]) -> None: ...
|
||||
|
||||
global___GradientDef = GradientDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RegisteredGradient(google.protobuf.message.Message):
|
||||
"""RegisteredGradient stores a gradient function that is registered in the
|
||||
gradients library and used in the ops of a function in the function library.
|
||||
@@ -300,6 +307,6 @@ class RegisteredGradient(google.protobuf.message.Message):
|
||||
gradient_func: builtins.str | None = ...,
|
||||
registered_op_type: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["gradient_func", b"gradient_func", "registered_op_type", b"registered_op_type"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["gradient_func", b"gradient_func", "registered_op_type", b"registered_op_type"]) -> None: ...
|
||||
|
||||
global___RegisteredGradient = RegisteredGradient
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -15,7 +16,7 @@ import tensorflow.core.framework.versions_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphDef(google.protobuf.message.Message):
|
||||
"""Represents the graph of operations"""
|
||||
|
||||
@@ -25,6 +26,11 @@ class GraphDef(google.protobuf.message.Message):
|
||||
VERSIONS_FIELD_NUMBER: builtins.int
|
||||
VERSION_FIELD_NUMBER: builtins.int
|
||||
LIBRARY_FIELD_NUMBER: builtins.int
|
||||
version: builtins.int
|
||||
"""Deprecated single version field; use versions above instead. Since all
|
||||
GraphDef changes before "versions" was introduced were forward
|
||||
compatible, this field is entirely ignored.
|
||||
"""
|
||||
@property
|
||||
def node(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.node_def_pb2.NodeDef]: ...
|
||||
@property
|
||||
@@ -33,11 +39,7 @@ class GraphDef(google.protobuf.message.Message):
|
||||
history. The GraphDef version is distinct from the TensorFlow version, and
|
||||
each release of TensorFlow will support a range of GraphDef versions.
|
||||
"""
|
||||
version: builtins.int
|
||||
"""Deprecated single version field; use versions above instead. Since all
|
||||
GraphDef changes before "versions" was introduced were forward
|
||||
compatible, this field is entirely ignored.
|
||||
"""
|
||||
|
||||
@property
|
||||
def library(self) -> tensorflow.core.framework.function_pb2.FunctionDefLibrary:
|
||||
""""library" provides user-defined functions.
|
||||
@@ -67,6 +69,7 @@ class GraphDef(google.protobuf.message.Message):
|
||||
consumer does not start until all return values of the callee
|
||||
function are ready.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -75,7 +78,7 @@ class GraphDef(google.protobuf.message.Message):
|
||||
version: builtins.int | None = ...,
|
||||
library: tensorflow.core.framework.function_pb2.FunctionDefLibrary | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["library", b"library", "versions", b"versions"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["library", b"library", "node", b"node", "version", b"version", "versions", b"versions"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["library", b"library", "versions", b"versions"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["library", b"library", "node", b"node", "version", b"version", "versions", b"versions"]) -> None: ...
|
||||
|
||||
global___GraphDef = GraphDef
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -20,7 +21,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphTransferNodeInput(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -34,11 +35,11 @@ class GraphTransferNodeInput(google.protobuf.message.Message):
|
||||
node_id: builtins.int | None = ...,
|
||||
output_port: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["node_id", b"node_id", "output_port", b"output_port"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["node_id", b"node_id", "output_port", b"output_port"]) -> None: ...
|
||||
|
||||
global___GraphTransferNodeInput = GraphTransferNodeInput
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphTransferNodeInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -67,11 +68,11 @@ class GraphTransferNodeInfo(google.protobuf.message.Message):
|
||||
input_count: builtins.int | None = ...,
|
||||
output_count: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["input_count", b"input_count", "name", b"name", "node_id", b"node_id", "output_count", b"output_count", "padding_id", b"padding_id", "soc_op_id", b"soc_op_id", "type_name", b"type_name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["input_count", b"input_count", "name", b"name", "node_id", b"node_id", "output_count", b"output_count", "padding_id", b"padding_id", "soc_op_id", b"soc_op_id", "type_name", b"type_name"]) -> None: ...
|
||||
|
||||
global___GraphTransferNodeInfo = GraphTransferNodeInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphTransferConstNodeInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -82,10 +83,10 @@ class GraphTransferConstNodeInfo(google.protobuf.message.Message):
|
||||
DTYPE_FIELD_NUMBER: builtins.int
|
||||
name: builtins.str
|
||||
node_id: builtins.int
|
||||
@property
|
||||
def shape(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
data: builtins.bytes
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
@property
|
||||
def shape(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -95,11 +96,11 @@ class GraphTransferConstNodeInfo(google.protobuf.message.Message):
|
||||
data: builtins.bytes | None = ...,
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["data", b"data", "dtype", b"dtype", "name", b"name", "node_id", b"node_id", "shape", b"shape"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["data", b"data", "dtype", b"dtype", "name", b"name", "node_id", b"node_id", "shape", b"shape"]) -> None: ...
|
||||
|
||||
global___GraphTransferConstNodeInfo = GraphTransferConstNodeInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphTransferNodeInputInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -114,11 +115,11 @@ class GraphTransferNodeInputInfo(google.protobuf.message.Message):
|
||||
node_id: builtins.int | None = ...,
|
||||
node_input: collections.abc.Iterable[global___GraphTransferNodeInput] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["node_id", b"node_id", "node_input", b"node_input"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["node_id", b"node_id", "node_input", b"node_input"]) -> None: ...
|
||||
|
||||
global___GraphTransferNodeInputInfo = GraphTransferNodeInputInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphTransferNodeOutputInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -133,11 +134,11 @@ class GraphTransferNodeOutputInfo(google.protobuf.message.Message):
|
||||
node_id: builtins.int | None = ...,
|
||||
max_byte_size: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["max_byte_size", b"max_byte_size", "node_id", b"node_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["max_byte_size", b"max_byte_size", "node_id", b"node_id"]) -> None: ...
|
||||
|
||||
global___GraphTransferNodeOutputInfo = GraphTransferNodeOutputInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphTransferGraphInputNodeInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -145,9 +146,9 @@ class GraphTransferGraphInputNodeInfo(google.protobuf.message.Message):
|
||||
SHAPE_FIELD_NUMBER: builtins.int
|
||||
DTYPE_FIELD_NUMBER: builtins.int
|
||||
name: builtins.str
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
@property
|
||||
def shape(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -155,11 +156,11 @@ class GraphTransferGraphInputNodeInfo(google.protobuf.message.Message):
|
||||
shape: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dtype", b"dtype", "name", b"name", "shape", b"shape"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["dtype", b"dtype", "name", b"name", "shape", b"shape"]) -> None: ...
|
||||
|
||||
global___GraphTransferGraphInputNodeInfo = GraphTransferGraphInputNodeInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphTransferGraphOutputNodeInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -167,9 +168,9 @@ class GraphTransferGraphOutputNodeInfo(google.protobuf.message.Message):
|
||||
SHAPE_FIELD_NUMBER: builtins.int
|
||||
DTYPE_FIELD_NUMBER: builtins.int
|
||||
name: builtins.str
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
@property
|
||||
def shape(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -177,11 +178,11 @@ class GraphTransferGraphOutputNodeInfo(google.protobuf.message.Message):
|
||||
shape: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dtype", b"dtype", "name", b"name", "shape", b"shape"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["dtype", b"dtype", "name", b"name", "shape", b"shape"]) -> None: ...
|
||||
|
||||
global___GraphTransferGraphOutputNodeInfo = GraphTransferGraphOutputNodeInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphTransferInfo(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing a handle to a tensorflow resource. Handles are
|
||||
not valid across executions, but can be serialized back and forth from within
|
||||
@@ -210,6 +211,8 @@ class GraphTransferInfo(google.protobuf.message.Message):
|
||||
GRAPH_INPUT_NODE_INFO_FIELD_NUMBER: builtins.int
|
||||
GRAPH_OUTPUT_NODE_INFO_FIELD_NUMBER: builtins.int
|
||||
DESTINATION_FIELD_NUMBER: builtins.int
|
||||
destination: global___GraphTransferInfo.Destination.ValueType
|
||||
"""Destination of graph transfer"""
|
||||
@property
|
||||
def node_info(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___GraphTransferNodeInfo]: ...
|
||||
@property
|
||||
@@ -221,10 +224,9 @@ class GraphTransferInfo(google.protobuf.message.Message):
|
||||
@property
|
||||
def graph_input_node_info(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___GraphTransferGraphInputNodeInfo]:
|
||||
"""Input Node parameters of transferred graph"""
|
||||
|
||||
@property
|
||||
def graph_output_node_info(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___GraphTransferGraphOutputNodeInfo]: ...
|
||||
destination: global___GraphTransferInfo.Destination.ValueType
|
||||
"""Destination of graph transfer"""
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -236,6 +238,6 @@ class GraphTransferInfo(google.protobuf.message.Message):
|
||||
graph_output_node_info: collections.abc.Iterable[global___GraphTransferGraphOutputNodeInfo] | None = ...,
|
||||
destination: global___GraphTransferInfo.Destination.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["const_node_info", b"const_node_info", "destination", b"destination", "graph_input_node_info", b"graph_input_node_info", "graph_output_node_info", b"graph_output_node_info", "node_info", b"node_info", "node_input_info", b"node_input_info", "node_output_info", b"node_output_info"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["const_node_info", b"const_node_info", "destination", b"destination", "graph_input_node_info", b"graph_input_node_info", "graph_output_node_info", b"graph_output_node_info", "node_info", b"node_info", "node_input_info", b"node_input_info", "node_output_info", b"node_output_info"]) -> None: ...
|
||||
|
||||
global___GraphTransferInfo = GraphTransferInfo
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -13,11 +14,11 @@ import tensorflow.core.framework.attr_value_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class KernelDef(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AttrConstraint(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -30,14 +31,15 @@ class KernelDef(google.protobuf.message.Message):
|
||||
"""A list of values that this kernel supports for this attr.
|
||||
Like OpDef.AttrDef.allowed_values, except for kernels instead of Ops.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
name: builtins.str | None = ...,
|
||||
allowed_values: tensorflow.core.framework.attr_value_pb2.AttrValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["allowed_values", b"allowed_values"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allowed_values", b"allowed_values", "name", b"name"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["allowed_values", b"allowed_values"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["allowed_values", b"allowed_values", "name", b"name"]) -> None: ...
|
||||
|
||||
OP_FIELD_NUMBER: builtins.int
|
||||
DEVICE_TYPE_FIELD_NUMBER: builtins.int
|
||||
@@ -49,13 +51,6 @@ class KernelDef(google.protobuf.message.Message):
|
||||
"""Must match the name of an Op."""
|
||||
device_type: builtins.str
|
||||
"""Type of device this kernel runs on."""
|
||||
@property
|
||||
def constraint(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___KernelDef.AttrConstraint]: ...
|
||||
@property
|
||||
def host_memory_arg(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Names of the Op's input_/output_args that reside in host memory
|
||||
instead of device memory.
|
||||
"""
|
||||
label: builtins.str
|
||||
"""This allows experimental kernels to be registered for an op that
|
||||
won't be used unless the user specifies a "_kernel" attr with
|
||||
@@ -66,6 +61,14 @@ class KernelDef(google.protobuf.message.Message):
|
||||
priority is 0. The higher the priority the better. By default (i.e. if
|
||||
this is not set), we prefer GPU kernels over CPU.
|
||||
"""
|
||||
@property
|
||||
def constraint(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___KernelDef.AttrConstraint]: ...
|
||||
@property
|
||||
def host_memory_arg(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Names of the Op's input_/output_args that reside in host memory
|
||||
instead of device memory.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -76,11 +79,11 @@ class KernelDef(google.protobuf.message.Message):
|
||||
label: builtins.str | None = ...,
|
||||
priority: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["constraint", b"constraint", "device_type", b"device_type", "host_memory_arg", b"host_memory_arg", "label", b"label", "op", b"op", "priority", b"priority"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["constraint", b"constraint", "device_type", b"device_type", "host_memory_arg", b"host_memory_arg", "label", b"label", "op", b"op", "priority", b"priority"]) -> None: ...
|
||||
|
||||
global___KernelDef = KernelDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class KernelList(google.protobuf.message.Message):
|
||||
"""A collection of KernelDefs"""
|
||||
|
||||
@@ -94,6 +97,6 @@ class KernelList(google.protobuf.message.Message):
|
||||
*,
|
||||
kernel: collections.abc.Iterable[global___KernelDef] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["kernel", b"kernel"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["kernel", b"kernel"]) -> None: ...
|
||||
|
||||
global___KernelList = KernelList
|
||||
|
||||
@@ -2,8 +2,9 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.message
|
||||
@@ -11,7 +12,7 @@ import tensorflow.core.framework.tensor_description_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemoryLogStep(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -27,11 +28,11 @@ class MemoryLogStep(google.protobuf.message.Message):
|
||||
step_id: builtins.int | None = ...,
|
||||
handle: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["handle", b"handle", "step_id", b"step_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["handle", b"handle", "step_id", b"step_id"]) -> None: ...
|
||||
|
||||
global___MemoryLogStep = MemoryLogStep
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemoryLogTensorAllocation(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -47,6 +48,7 @@ class MemoryLogTensorAllocation(google.protobuf.message.Message):
|
||||
@property
|
||||
def tensor(self) -> tensorflow.core.framework.tensor_description_pb2.TensorDescription:
|
||||
"""Allocated tensor details."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -54,12 +56,12 @@ class MemoryLogTensorAllocation(google.protobuf.message.Message):
|
||||
kernel_name: builtins.str | None = ...,
|
||||
tensor: tensorflow.core.framework.tensor_description_pb2.TensorDescription | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["tensor", b"tensor"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["kernel_name", b"kernel_name", "step_id", b"step_id", "tensor", b"tensor"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["tensor", b"tensor"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["kernel_name", b"kernel_name", "step_id", b"step_id", "tensor", b"tensor"]) -> None: ...
|
||||
|
||||
global___MemoryLogTensorAllocation = MemoryLogTensorAllocation
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemoryLogTensorDeallocation(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -77,11 +79,11 @@ class MemoryLogTensorDeallocation(google.protobuf.message.Message):
|
||||
allocation_id: builtins.int | None = ...,
|
||||
allocator_name: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allocation_id", b"allocation_id", "allocator_name", b"allocator_name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["allocation_id", b"allocation_id", "allocator_name", b"allocator_name"]) -> None: ...
|
||||
|
||||
global___MemoryLogTensorDeallocation = MemoryLogTensorDeallocation
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemoryLogTensorOutput(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -100,6 +102,7 @@ class MemoryLogTensorOutput(google.protobuf.message.Message):
|
||||
@property
|
||||
def tensor(self) -> tensorflow.core.framework.tensor_description_pb2.TensorDescription:
|
||||
"""Output tensor details."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -108,12 +111,12 @@ class MemoryLogTensorOutput(google.protobuf.message.Message):
|
||||
index: builtins.int | None = ...,
|
||||
tensor: tensorflow.core.framework.tensor_description_pb2.TensorDescription | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["tensor", b"tensor"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["index", b"index", "kernel_name", b"kernel_name", "step_id", b"step_id", "tensor", b"tensor"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["tensor", b"tensor"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["index", b"index", "kernel_name", b"kernel_name", "step_id", b"step_id", "tensor", b"tensor"]) -> None: ...
|
||||
|
||||
global___MemoryLogTensorOutput = MemoryLogTensorOutput
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemoryLogRawAllocation(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -147,11 +150,11 @@ class MemoryLogRawAllocation(google.protobuf.message.Message):
|
||||
allocation_id: builtins.int | None = ...,
|
||||
allocator_name: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allocation_id", b"allocation_id", "allocator_name", b"allocator_name", "num_bytes", b"num_bytes", "operation", b"operation", "ptr", b"ptr", "step_id", b"step_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["allocation_id", b"allocation_id", "allocator_name", b"allocator_name", "num_bytes", b"num_bytes", "operation", b"operation", "ptr", b"ptr", "step_id", b"step_id"]) -> None: ...
|
||||
|
||||
global___MemoryLogRawAllocation = MemoryLogRawAllocation
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemoryLogRawDeallocation(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -183,6 +186,6 @@ class MemoryLogRawDeallocation(google.protobuf.message.Message):
|
||||
allocator_name: builtins.str | None = ...,
|
||||
deferred: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allocation_id", b"allocation_id", "allocator_name", b"allocator_name", "deferred", b"deferred", "operation", b"operation", "step_id", b"step_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["allocation_id", b"allocation_id", "allocator_name", b"allocator_name", "deferred", b"deferred", "operation", b"operation", "step_id", b"step_id"]) -> None: ...
|
||||
|
||||
global___MemoryLogRawDeallocation = MemoryLogRawDeallocation
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -67,7 +68,7 @@ MAX_PARALLELISM: AutotuneAlgorithm.ValueType # 3
|
||||
STAGE_BASED: AutotuneAlgorithm.ValueType # 4
|
||||
global___AutotuneAlgorithm = AutotuneAlgorithm
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ModelProto(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing the data used by the autotuning modeling
|
||||
framework.
|
||||
@@ -75,13 +76,13 @@ class ModelProto(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Node(google.protobuf.message.Message):
|
||||
"""General representation of a node in the model."""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Parameter(google.protobuf.message.Message):
|
||||
"""Represents a node parameter."""
|
||||
|
||||
@@ -117,7 +118,7 @@ class ModelProto(google.protobuf.message.Message):
|
||||
max: builtins.float | None = ...,
|
||||
tunable: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["max", b"max", "min", b"min", "name", b"name", "state_value", b"state_value", "tunable", b"tunable", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["max", b"max", "min", b"min", "name", b"name", "state_value", b"state_value", "tunable", b"tunable", "value", b"value"]) -> None: ...
|
||||
|
||||
ID_FIELD_NUMBER: builtins.int
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
@@ -158,15 +159,9 @@ class ModelProto(google.protobuf.message.Message):
|
||||
"""An indication whether this node records metrics about produced and
|
||||
consumed elements.
|
||||
"""
|
||||
@property
|
||||
def parameters(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ModelProto.Node.Parameter]:
|
||||
"""Parameters of this node."""
|
||||
input_processing_time_sum: builtins.float
|
||||
"""Statistic of inputs processing time history."""
|
||||
input_processing_time_count: builtins.int
|
||||
@property
|
||||
def inputs(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""IDs of inputs of this node."""
|
||||
node_class: global___NodeClass.ValueType
|
||||
"""Class of this node."""
|
||||
ratio: builtins.float
|
||||
@@ -177,6 +172,14 @@ class ModelProto(google.protobuf.message.Message):
|
||||
"""Ratio identifies how many parallelism calls are introduced by one
|
||||
buffered element. This is only used by ASYNC_KNOWN_RATIO nodes.
|
||||
"""
|
||||
@property
|
||||
def parameters(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ModelProto.Node.Parameter]:
|
||||
"""Parameters of this node."""
|
||||
|
||||
@property
|
||||
def inputs(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""IDs of inputs of this node."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -198,9 +201,9 @@ class ModelProto(google.protobuf.message.Message):
|
||||
ratio: builtins.float | None = ...,
|
||||
memory_ratio: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["autotune", b"autotune", "buffered_bytes", b"buffered_bytes", "buffered_elements", b"buffered_elements", "bytes_consumed", b"bytes_consumed", "bytes_produced", b"bytes_produced", "id", b"id", "input_processing_time_count", b"input_processing_time_count", "input_processing_time_sum", b"input_processing_time_sum", "inputs", b"inputs", "memory_ratio", b"memory_ratio", "name", b"name", "node_class", b"node_class", "num_elements", b"num_elements", "parameters", b"parameters", "processing_time", b"processing_time", "ratio", b"ratio", "record_metrics", b"record_metrics"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["autotune", b"autotune", "buffered_bytes", b"buffered_bytes", "buffered_elements", b"buffered_elements", "bytes_consumed", b"bytes_consumed", "bytes_produced", b"bytes_produced", "id", b"id", "input_processing_time_count", b"input_processing_time_count", "input_processing_time_sum", b"input_processing_time_sum", "inputs", b"inputs", "memory_ratio", b"memory_ratio", "name", b"name", "node_class", b"node_class", "num_elements", b"num_elements", "parameters", b"parameters", "processing_time", b"processing_time", "ratio", b"ratio", "record_metrics", b"record_metrics"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class NodesEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -215,10 +218,10 @@ class ModelProto(google.protobuf.message.Message):
|
||||
key: builtins.int | None = ...,
|
||||
value: global___ModelProto.Node | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OptimizationParams(google.protobuf.message.Message):
|
||||
"""Contains parameters of the model autotuning optimization."""
|
||||
|
||||
@@ -246,19 +249,20 @@ class ModelProto(google.protobuf.message.Message):
|
||||
ram_budget: builtins.int | None = ...,
|
||||
model_input_time: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["algorithm", b"algorithm", "cpu_budget", b"cpu_budget", "model_input_time", b"model_input_time", "ram_budget", b"ram_budget"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["algorithm", b"algorithm", "cpu_budget", b"cpu_budget", "model_input_time", b"model_input_time", "ram_budget", b"ram_budget"]) -> None: ...
|
||||
|
||||
NODES_FIELD_NUMBER: builtins.int
|
||||
OUTPUT_FIELD_NUMBER: builtins.int
|
||||
ID_COUNTER_FIELD_NUMBER: builtins.int
|
||||
OPTIMIZATION_PARAMS_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def nodes(self) -> google.protobuf.internal.containers.MessageMap[builtins.int, global___ModelProto.Node]:
|
||||
"""Map of node IDs to nodes of this model."""
|
||||
output: builtins.int
|
||||
"""ID of the output node of this model."""
|
||||
id_counter: builtins.int
|
||||
"""Counter for node IDs of this model."""
|
||||
@property
|
||||
def nodes(self) -> google.protobuf.internal.containers.MessageMap[builtins.int, global___ModelProto.Node]:
|
||||
"""Map of node IDs to nodes of this model."""
|
||||
|
||||
@property
|
||||
def optimization_params(self) -> global___ModelProto.OptimizationParams: ...
|
||||
def __init__(
|
||||
@@ -269,7 +273,7 @@ class ModelProto(google.protobuf.message.Message):
|
||||
id_counter: builtins.int | None = ...,
|
||||
optimization_params: global___ModelProto.OptimizationParams | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["optimization_params", b"optimization_params"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["id_counter", b"id_counter", "nodes", b"nodes", "optimization_params", b"optimization_params", "output", b"output"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["optimization_params", b"optimization_params"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["id_counter", b"id_counter", "nodes", b"nodes", "optimization_params", b"optimization_params", "output", b"output"]) -> None: ...
|
||||
|
||||
global___ModelProto = ModelProto
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -14,11 +15,11 @@ import tensorflow.core.framework.full_type_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class NodeDef(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AttrEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -33,10 +34,10 @@ class NodeDef(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: tensorflow.core.framework.attr_value_pb2.AttrValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ExperimentalDebugInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -52,6 +53,7 @@ class NodeDef(google.protobuf.message.Message):
|
||||
be {A, B}. This information can be used to map errors originating at the
|
||||
current node to some top level source code.
|
||||
"""
|
||||
|
||||
@property
|
||||
def original_func_names(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""This is intended to store the list of names of the functions from the
|
||||
@@ -62,13 +64,14 @@ class NodeDef(google.protobuf.message.Message):
|
||||
`original_node_names` can be used to map errors originating at the
|
||||
current ndoe to some top level source code.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
original_node_names: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
original_func_names: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["original_func_names", b"original_func_names", "original_node_names", b"original_node_names"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["original_func_names", b"original_func_names", "original_node_names", b"original_node_names"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
OP_FIELD_NUMBER: builtins.int
|
||||
@@ -86,14 +89,6 @@ class NodeDef(google.protobuf.message.Message):
|
||||
"""The operation name. There may be custom parameters in attrs.
|
||||
Op names starting with an underscore are reserved for internal use.
|
||||
"""
|
||||
@property
|
||||
def input(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Each input is "node:src_output" with "node" being a string name and
|
||||
"src_output" indicating which output tensor to use from "node". If
|
||||
"src_output" is 0 the ":0" suffix can be omitted. Regular inputs
|
||||
may optionally be followed by control inputs that have the format
|
||||
"^node".
|
||||
"""
|
||||
device: builtins.str
|
||||
"""A (possibly partial) specification for the device on which this
|
||||
node should be placed.
|
||||
@@ -116,6 +111,15 @@ class NodeDef(google.protobuf.message.Message):
|
||||
field is empty or not present), the runtime will attempt to
|
||||
choose a device automatically.
|
||||
"""
|
||||
@property
|
||||
def input(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Each input is "node:src_output" with "node" being a string name and
|
||||
"src_output" indicating which output tensor to use from "node". If
|
||||
"src_output" is 0 the ":0" suffix can be omitted. Regular inputs
|
||||
may optionally be followed by control inputs that have the format
|
||||
"^node".
|
||||
"""
|
||||
|
||||
@property
|
||||
def attr(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, tensorflow.core.framework.attr_value_pb2.AttrValue]:
|
||||
"""Operation-specific graph-construction-time configuration.
|
||||
@@ -131,9 +135,11 @@ class NodeDef(google.protobuf.message.Message):
|
||||
attr's type field.
|
||||
TODO(josh11b): Add some examples here showing best practices.
|
||||
"""
|
||||
|
||||
@property
|
||||
def experimental_debug_info(self) -> global___NodeDef.ExperimentalDebugInfo:
|
||||
"""This stores debug information associated with the node."""
|
||||
|
||||
@property
|
||||
def experimental_type(self) -> tensorflow.core.framework.full_type_pb2.FullTypeDef:
|
||||
"""The complete type of this node. Experimental and subject to change.
|
||||
@@ -141,6 +147,7 @@ class NodeDef(google.protobuf.message.Message):
|
||||
extend in the future to contain the entire signature of the node, as a
|
||||
function type.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -152,7 +159,7 @@ class NodeDef(google.protobuf.message.Message):
|
||||
experimental_debug_info: global___NodeDef.ExperimentalDebugInfo | None = ...,
|
||||
experimental_type: tensorflow.core.framework.full_type_pb2.FullTypeDef | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["experimental_debug_info", b"experimental_debug_info", "experimental_type", b"experimental_type"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["attr", b"attr", "device", b"device", "experimental_debug_info", b"experimental_debug_info", "experimental_type", b"experimental_type", "input", b"input", "name", b"name", "op", b"op"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["experimental_debug_info", b"experimental_debug_info", "experimental_type", b"experimental_type"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["attr", b"attr", "device", b"device", "experimental_debug_info", b"experimental_debug_info", "experimental_type", b"experimental_type", "input", b"input", "name", b"name", "op", b"op"]) -> None: ...
|
||||
|
||||
global___NodeDef = NodeDef
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -16,7 +17,7 @@ import tensorflow.core.framework.types_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OpDef(google.protobuf.message.Message):
|
||||
"""Defines an operation. A NodeDef in a GraphDef specifies an Op by
|
||||
using the "op" field which should match the name of a OpDef.
|
||||
@@ -25,7 +26,7 @@ class OpDef(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ArgDef(google.protobuf.message.Message):
|
||||
"""For describing inputs and outputs."""
|
||||
|
||||
@@ -64,14 +65,15 @@ class OpDef(google.protobuf.message.Message):
|
||||
"""If specified, attr must have type "list(type)", and none of
|
||||
type, type_attr, and number_attr may be specified.
|
||||
"""
|
||||
@property
|
||||
def handle_data(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.resource_handle_pb2.ResourceHandleProto.DtypeAndShape]:
|
||||
"""The handle data for resource inputs."""
|
||||
is_ref: builtins.bool
|
||||
"""For inputs: if true, the inputs are required to be refs.
|
||||
By default, inputs can be either refs or non-refs.
|
||||
For outputs: if true, outputs are refs, otherwise they are not.
|
||||
"""
|
||||
@property
|
||||
def handle_data(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.resource_handle_pb2.ResourceHandleProto.DtypeAndShape]:
|
||||
"""The handle data for resource inputs."""
|
||||
|
||||
@property
|
||||
def experimental_full_type(self) -> tensorflow.core.framework.full_type_pb2.FullTypeDef:
|
||||
"""Experimental. Full type declaration for this argument.
|
||||
@@ -84,6 +86,7 @@ class OpDef(google.protobuf.message.Message):
|
||||
entire OpDef as a single type: a callable. In that context, this field is
|
||||
just the type of a single argument.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -97,10 +100,10 @@ class OpDef(google.protobuf.message.Message):
|
||||
is_ref: builtins.bool | None = ...,
|
||||
experimental_full_type: tensorflow.core.framework.full_type_pb2.FullTypeDef | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["experimental_full_type", b"experimental_full_type"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["description", b"description", "experimental_full_type", b"experimental_full_type", "handle_data", b"handle_data", "is_ref", b"is_ref", "name", b"name", "number_attr", b"number_attr", "type", b"type", "type_attr", b"type_attr", "type_list_attr", b"type_list_attr"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["experimental_full_type", b"experimental_full_type"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["description", b"description", "experimental_full_type", b"experimental_full_type", "handle_data", b"handle_data", "is_ref", b"is_ref", "name", b"name", "number_attr", b"number_attr", "type", b"type", "type_attr", b"type_attr", "type_list_attr", b"type_list_attr"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AttrDef(google.protobuf.message.Message):
|
||||
"""Description of the graph-construction-time configuration of this
|
||||
Op. That is to say, this describes the attr fields that will
|
||||
@@ -125,11 +128,6 @@ class OpDef(google.protobuf.message.Message):
|
||||
"""One of the type names from attr_value.proto ("string", "list(string)",
|
||||
"int", etc.).
|
||||
"""
|
||||
@property
|
||||
def default_value(self) -> tensorflow.core.framework.attr_value_pb2.AttrValue:
|
||||
"""A reasonable default for this attribute if the user does not supply
|
||||
a value. If not specified, the user must supply a value.
|
||||
"""
|
||||
description: builtins.str
|
||||
"""Human-readable description."""
|
||||
has_minimum: builtins.bool
|
||||
@@ -141,6 +139,12 @@ class OpDef(google.protobuf.message.Message):
|
||||
types, this is the minimum length.
|
||||
"""
|
||||
minimum: builtins.int
|
||||
@property
|
||||
def default_value(self) -> tensorflow.core.framework.attr_value_pb2.AttrValue:
|
||||
"""A reasonable default for this attribute if the user does not supply
|
||||
a value. If not specified, the user must supply a value.
|
||||
"""
|
||||
|
||||
@property
|
||||
def allowed_values(self) -> tensorflow.core.framework.attr_value_pb2.AttrValue:
|
||||
"""The set of allowed values. Has type that is the "list" version
|
||||
@@ -150,6 +154,7 @@ class OpDef(google.protobuf.message.Message):
|
||||
If type == "string" or "list(string)", then the "s" field of
|
||||
"allowed_values.list" has the set of allowed strings.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -161,8 +166,8 @@ class OpDef(google.protobuf.message.Message):
|
||||
minimum: builtins.int | None = ...,
|
||||
allowed_values: tensorflow.core.framework.attr_value_pb2.AttrValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["allowed_values", b"allowed_values", "default_value", b"default_value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allowed_values", b"allowed_values", "default_value", b"default_value", "description", b"description", "has_minimum", b"has_minimum", "minimum", b"minimum", "name", b"name", "type", b"type"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["allowed_values", b"allowed_values", "default_value", b"default_value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["allowed_values", b"allowed_values", "default_value", b"default_value", "description", b"description", "has_minimum", b"has_minimum", "minimum", b"minimum", "name", b"name", "type", b"type"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
INPUT_ARG_FIELD_NUMBER: builtins.int
|
||||
@@ -181,22 +186,6 @@ class OpDef(google.protobuf.message.Message):
|
||||
"""Op names starting with an underscore are reserved for internal use.
|
||||
Names should be CamelCase and match the regexp "[A-Z][a-zA-Z0-9>_]*".
|
||||
"""
|
||||
@property
|
||||
def input_arg(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___OpDef.ArgDef]:
|
||||
"""Description of the input(s)."""
|
||||
@property
|
||||
def output_arg(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___OpDef.ArgDef]:
|
||||
"""Description of the output(s)."""
|
||||
@property
|
||||
def control_output(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Named control outputs for this operation. Useful only for composite
|
||||
operations (i.e. functions) which want to name different control outputs.
|
||||
"""
|
||||
@property
|
||||
def attr(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___OpDef.AttrDef]: ...
|
||||
@property
|
||||
def deprecation(self) -> global___OpDeprecation:
|
||||
"""Optional deprecation based on GraphDef versions."""
|
||||
summary: builtins.str
|
||||
"""One-line human-readable description of what the Op does."""
|
||||
description: builtins.str
|
||||
@@ -250,6 +239,26 @@ class OpDef(google.protobuf.message.Message):
|
||||
If True, the op is allowed to return errors for network disconnection and
|
||||
trigger TF network failure handling logics.
|
||||
"""
|
||||
@property
|
||||
def input_arg(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___OpDef.ArgDef]:
|
||||
"""Description of the input(s)."""
|
||||
|
||||
@property
|
||||
def output_arg(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___OpDef.ArgDef]:
|
||||
"""Description of the output(s)."""
|
||||
|
||||
@property
|
||||
def control_output(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Named control outputs for this operation. Useful only for composite
|
||||
operations (i.e. functions) which want to name different control outputs.
|
||||
"""
|
||||
|
||||
@property
|
||||
def attr(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___OpDef.AttrDef]: ...
|
||||
@property
|
||||
def deprecation(self) -> global___OpDeprecation:
|
||||
"""Optional deprecation based on GraphDef versions."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -267,12 +276,12 @@ class OpDef(google.protobuf.message.Message):
|
||||
allows_uninitialized_input: builtins.bool | None = ...,
|
||||
is_distributed_communication: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["deprecation", b"deprecation"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allows_uninitialized_input", b"allows_uninitialized_input", "attr", b"attr", "control_output", b"control_output", "deprecation", b"deprecation", "description", b"description", "input_arg", b"input_arg", "is_aggregate", b"is_aggregate", "is_commutative", b"is_commutative", "is_distributed_communication", b"is_distributed_communication", "is_stateful", b"is_stateful", "name", b"name", "output_arg", b"output_arg", "summary", b"summary"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["deprecation", b"deprecation"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["allows_uninitialized_input", b"allows_uninitialized_input", "attr", b"attr", "control_output", b"control_output", "deprecation", b"deprecation", "description", b"description", "input_arg", b"input_arg", "is_aggregate", b"is_aggregate", "is_commutative", b"is_commutative", "is_distributed_communication", b"is_distributed_communication", "is_stateful", b"is_stateful", "name", b"name", "output_arg", b"output_arg", "summary", b"summary"]) -> None: ...
|
||||
|
||||
global___OpDef = OpDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OpDeprecation(google.protobuf.message.Message):
|
||||
"""Information about version-dependent deprecation of an op"""
|
||||
|
||||
@@ -290,11 +299,11 @@ class OpDeprecation(google.protobuf.message.Message):
|
||||
version: builtins.int | None = ...,
|
||||
explanation: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["explanation", b"explanation", "version", b"version"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["explanation", b"explanation", "version", b"version"]) -> None: ...
|
||||
|
||||
global___OpDeprecation = OpDeprecation
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OpList(google.protobuf.message.Message):
|
||||
"""A collection of OpDefs"""
|
||||
|
||||
@@ -308,6 +317,6 @@ class OpList(google.protobuf.message.Message):
|
||||
*,
|
||||
op: collections.abc.Iterable[global___OpDef] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["op", b"op"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["op", b"op"]) -> None: ...
|
||||
|
||||
global___OpList = OpList
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -14,7 +15,7 @@ import tensorflow.core.framework.types_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OptimizedFunctionGraph(google.protobuf.message.Message):
|
||||
"""Optimized function graph after instantiation-related graph optimization
|
||||
passes (up till before graph partitioning). The first half of the proto is
|
||||
@@ -24,7 +25,7 @@ class OptimizedFunctionGraph(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class NodeNameToControlRetEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -38,7 +39,7 @@ class OptimizedFunctionGraph(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
FUNCTION_GRAPH_FIELD_NUMBER: builtins.int
|
||||
@@ -49,21 +50,24 @@ class OptimizedFunctionGraph(google.protobuf.message.Message):
|
||||
"""Function name. It can be a human-readable SignatureDef's method name, or a
|
||||
FunctionDef name.
|
||||
"""
|
||||
num_return_nodes: builtins.int
|
||||
"""Number of return nodes. This is an output of graph preprocessing."""
|
||||
@property
|
||||
def function_graph(self) -> tensorflow.core.framework.graph_pb2.GraphDef:
|
||||
"""Optimized function graph."""
|
||||
|
||||
@property
|
||||
def node_name_to_control_ret(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]:
|
||||
"""Maps from node name to control ret. This is an output from running TF/XLA
|
||||
bridge.
|
||||
"""
|
||||
|
||||
@property
|
||||
def ret_types(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[tensorflow.core.framework.types_pb2.DataType.ValueType]:
|
||||
"""Return node types of the function. This is an output of graph
|
||||
preprocessing.
|
||||
"""
|
||||
num_return_nodes: builtins.int
|
||||
"""Number of return nodes. This is an output of graph preprocessing."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -73,7 +77,7 @@ class OptimizedFunctionGraph(google.protobuf.message.Message):
|
||||
ret_types: collections.abc.Iterable[tensorflow.core.framework.types_pb2.DataType.ValueType] | None = ...,
|
||||
num_return_nodes: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["function_graph", b"function_graph"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["function_graph", b"function_graph", "name", b"name", "node_name_to_control_ret", b"node_name_to_control_ret", "num_return_nodes", b"num_return_nodes", "ret_types", b"ret_types"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["function_graph", b"function_graph"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["function_graph", b"function_graph", "name", b"name", "node_name_to_control_ret", b"node_name_to_control_ret", "num_return_nodes", b"num_return_nodes", "ret_types", b"ret_types"]) -> None: ...
|
||||
|
||||
global___OptimizedFunctionGraph = OptimizedFunctionGraph
|
||||
|
||||
@@ -2,15 +2,16 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ReaderBaseState(google.protobuf.message.Message):
|
||||
"""For serializing and restoring the state of ReaderBase, see
|
||||
reader_base.h for details.
|
||||
@@ -34,6 +35,6 @@ class ReaderBaseState(google.protobuf.message.Message):
|
||||
num_records_produced: builtins.int | None = ...,
|
||||
current_work: builtins.bytes | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["current_work", b"current_work", "num_records_produced", b"num_records_produced", "work_finished", b"work_finished", "work_started", b"work_started"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["current_work", b"current_work", "num_records_produced", b"num_records_produced", "work_finished", b"work_finished", "work_started", b"work_started"]) -> None: ...
|
||||
|
||||
global___ReaderBaseState = ReaderBaseState
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -14,7 +15,7 @@ import tensorflow.core.framework.types_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ResourceHandleProto(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing a handle to a tensorflow resource. Handles are
|
||||
not valid across executions, but can be serialized back and forth from within
|
||||
@@ -23,7 +24,7 @@ class ResourceHandleProto(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DtypeAndShape(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing a pair of (data type, tensor shape)."""
|
||||
|
||||
@@ -40,8 +41,8 @@ class ResourceHandleProto(google.protobuf.message.Message):
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType | None = ...,
|
||||
shape: tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dtype", b"dtype", "shape", b"shape"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["dtype", b"dtype", "shape", b"shape"]) -> None: ...
|
||||
|
||||
DEVICE_FIELD_NUMBER: builtins.int
|
||||
CONTAINER_FIELD_NUMBER: builtins.int
|
||||
@@ -66,6 +67,7 @@ class ResourceHandleProto(google.protobuf.message.Message):
|
||||
@property
|
||||
def dtypes_and_shapes(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ResourceHandleProto.DtypeAndShape]:
|
||||
"""Data types and shapes for the underlying resource."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -76,6 +78,6 @@ class ResourceHandleProto(google.protobuf.message.Message):
|
||||
maybe_type_name: builtins.str | None = ...,
|
||||
dtypes_and_shapes: collections.abc.Iterable[global___ResourceHandleProto.DtypeAndShape] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["container", b"container", "device", b"device", "dtypes_and_shapes", b"dtypes_and_shapes", "hash_code", b"hash_code", "maybe_type_name", b"maybe_type_name", "name", b"name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["container", b"container", "device", b"device", "dtypes_and_shapes", b"dtypes_and_shapes", "hash_code", b"hash_code", "maybe_type_name", b"maybe_type_name", "name", b"name"]) -> None: ...
|
||||
|
||||
global___ResourceHandleProto = ResourceHandleProto
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -14,7 +15,7 @@ import tensorflow.core.framework.tensor_description_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AllocationRecord(google.protobuf.message.Message):
|
||||
"""An allocation/de-allocation operation performed by the allocator."""
|
||||
|
||||
@@ -32,11 +33,11 @@ class AllocationRecord(google.protobuf.message.Message):
|
||||
alloc_micros: builtins.int | None = ...,
|
||||
alloc_bytes: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["alloc_bytes", b"alloc_bytes", "alloc_micros", b"alloc_micros"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["alloc_bytes", b"alloc_bytes", "alloc_micros", b"alloc_micros"]) -> None: ...
|
||||
|
||||
global___AllocationRecord = AllocationRecord
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AllocatorMemoryUsed(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -52,13 +53,14 @@ class AllocatorMemoryUsed(google.protobuf.message.Message):
|
||||
peak_bytes: builtins.int
|
||||
live_bytes: builtins.int
|
||||
"""The bytes that are not deallocated."""
|
||||
@property
|
||||
def allocation_records(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___AllocationRecord]:
|
||||
"""The allocation and deallocation timeline."""
|
||||
allocator_bytes_in_use: builtins.int
|
||||
"""These are snapshots of the overall allocator memory stats.
|
||||
The number of live bytes currently allocated by the allocator.
|
||||
"""
|
||||
@property
|
||||
def allocation_records(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___AllocationRecord]:
|
||||
"""The allocation and deallocation timeline."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -69,11 +71,11 @@ class AllocatorMemoryUsed(google.protobuf.message.Message):
|
||||
allocation_records: collections.abc.Iterable[global___AllocationRecord] | None = ...,
|
||||
allocator_bytes_in_use: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allocation_records", b"allocation_records", "allocator_bytes_in_use", b"allocator_bytes_in_use", "allocator_name", b"allocator_name", "live_bytes", b"live_bytes", "peak_bytes", b"peak_bytes", "total_bytes", b"total_bytes"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["allocation_records", b"allocation_records", "allocator_bytes_in_use", b"allocator_bytes_in_use", "allocator_name", b"allocator_name", "live_bytes", b"live_bytes", "peak_bytes", b"peak_bytes", "total_bytes", b"total_bytes"]) -> None: ...
|
||||
|
||||
global___AllocatorMemoryUsed = AllocatorMemoryUsed
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class NodeOutput(google.protobuf.message.Message):
|
||||
"""Output sizes recorded for a single execution of a graph node."""
|
||||
|
||||
@@ -90,12 +92,12 @@ class NodeOutput(google.protobuf.message.Message):
|
||||
slot: builtins.int | None = ...,
|
||||
tensor_description: tensorflow.core.framework.tensor_description_pb2.TensorDescription | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["tensor_description", b"tensor_description"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["slot", b"slot", "tensor_description", b"tensor_description"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["tensor_description", b"tensor_description"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["slot", b"slot", "tensor_description", b"tensor_description"]) -> None: ...
|
||||
|
||||
global___NodeOutput = NodeOutput
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemoryStats(google.protobuf.message.Message):
|
||||
"""For memory tracking."""
|
||||
|
||||
@@ -109,11 +111,11 @@ class MemoryStats(google.protobuf.message.Message):
|
||||
DEVICE_PERSISTENT_TENSOR_ALLOC_IDS_FIELD_NUMBER: builtins.int
|
||||
temp_memory_size: builtins.int
|
||||
persistent_memory_size: builtins.int
|
||||
@property
|
||||
def persistent_tensor_alloc_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
device_temp_memory_size: builtins.int
|
||||
device_persistent_memory_size: builtins.int
|
||||
@property
|
||||
def persistent_tensor_alloc_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def device_persistent_tensor_alloc_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
def __init__(
|
||||
self,
|
||||
@@ -125,11 +127,11 @@ class MemoryStats(google.protobuf.message.Message):
|
||||
device_persistent_memory_size: builtins.int | None = ...,
|
||||
device_persistent_tensor_alloc_ids: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device_persistent_memory_size", b"device_persistent_memory_size", "device_persistent_tensor_alloc_ids", b"device_persistent_tensor_alloc_ids", "device_temp_memory_size", b"device_temp_memory_size", "persistent_memory_size", b"persistent_memory_size", "persistent_tensor_alloc_ids", b"persistent_tensor_alloc_ids", "temp_memory_size", b"temp_memory_size"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["device_persistent_memory_size", b"device_persistent_memory_size", "device_persistent_tensor_alloc_ids", b"device_persistent_tensor_alloc_ids", "device_temp_memory_size", b"device_temp_memory_size", "persistent_memory_size", b"persistent_memory_size", "persistent_tensor_alloc_ids", b"persistent_tensor_alloc_ids", "temp_memory_size", b"temp_memory_size"]) -> None: ...
|
||||
|
||||
global___MemoryStats = MemoryStats
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class NodeExecStats(google.protobuf.message.Message):
|
||||
"""Time/size stats recorded for a single execution of a graph node."""
|
||||
|
||||
@@ -162,22 +164,22 @@ class NodeExecStats(google.protobuf.message.Message):
|
||||
op_start_rel_micros: builtins.int
|
||||
op_end_rel_micros: builtins.int
|
||||
all_end_rel_micros: builtins.int
|
||||
@property
|
||||
def memory(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___AllocatorMemoryUsed]: ...
|
||||
@property
|
||||
def output(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___NodeOutput]: ...
|
||||
timeline_label: builtins.str
|
||||
scheduled_micros: builtins.int
|
||||
thread_id: builtins.int
|
||||
@property
|
||||
def referenced_tensor(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.allocation_description_pb2.AllocationDescription]: ...
|
||||
@property
|
||||
def memory_stats(self) -> global___MemoryStats: ...
|
||||
all_start_nanos: builtins.int
|
||||
op_start_rel_nanos: builtins.int
|
||||
op_end_rel_nanos: builtins.int
|
||||
all_end_rel_nanos: builtins.int
|
||||
scheduled_nanos: builtins.int
|
||||
@property
|
||||
def memory(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___AllocatorMemoryUsed]: ...
|
||||
@property
|
||||
def output(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___NodeOutput]: ...
|
||||
@property
|
||||
def referenced_tensor(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.allocation_description_pb2.AllocationDescription]: ...
|
||||
@property
|
||||
def memory_stats(self) -> global___MemoryStats: ...
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -199,16 +201,16 @@ class NodeExecStats(google.protobuf.message.Message):
|
||||
all_end_rel_nanos: builtins.int | None = ...,
|
||||
scheduled_nanos: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["memory_stats", b"memory_stats"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["all_end_rel_micros", b"all_end_rel_micros", "all_end_rel_nanos", b"all_end_rel_nanos", "all_start_micros", b"all_start_micros", "all_start_nanos", b"all_start_nanos", "memory", b"memory", "memory_stats", b"memory_stats", "node_name", b"node_name", "op_end_rel_micros", b"op_end_rel_micros", "op_end_rel_nanos", b"op_end_rel_nanos", "op_start_rel_micros", b"op_start_rel_micros", "op_start_rel_nanos", b"op_start_rel_nanos", "output", b"output", "referenced_tensor", b"referenced_tensor", "scheduled_micros", b"scheduled_micros", "scheduled_nanos", b"scheduled_nanos", "thread_id", b"thread_id", "timeline_label", b"timeline_label"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["memory_stats", b"memory_stats"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["all_end_rel_micros", b"all_end_rel_micros", "all_end_rel_nanos", b"all_end_rel_nanos", "all_start_micros", b"all_start_micros", "all_start_nanos", b"all_start_nanos", "memory", b"memory", "memory_stats", b"memory_stats", "node_name", b"node_name", "op_end_rel_micros", b"op_end_rel_micros", "op_end_rel_nanos", b"op_end_rel_nanos", "op_start_rel_micros", b"op_start_rel_micros", "op_start_rel_nanos", b"op_start_rel_nanos", "output", b"output", "referenced_tensor", b"referenced_tensor", "scheduled_micros", b"scheduled_micros", "scheduled_nanos", b"scheduled_nanos", "thread_id", b"thread_id", "timeline_label", b"timeline_label"]) -> None: ...
|
||||
|
||||
global___NodeExecStats = NodeExecStats
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DeviceStepStats(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ThreadNamesEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -222,7 +224,7 @@ class DeviceStepStats(google.protobuf.message.Message):
|
||||
key: builtins.int | None = ...,
|
||||
value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
DEVICE_FIELD_NUMBER: builtins.int
|
||||
NODE_STATS_FIELD_NUMBER: builtins.int
|
||||
@@ -233,6 +235,7 @@ class DeviceStepStats(google.protobuf.message.Message):
|
||||
@property
|
||||
def thread_names(self) -> google.protobuf.internal.containers.ScalarMap[builtins.int, builtins.str]:
|
||||
"""Its key is thread id."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -240,11 +243,11 @@ class DeviceStepStats(google.protobuf.message.Message):
|
||||
node_stats: collections.abc.Iterable[global___NodeExecStats] | None = ...,
|
||||
thread_names: collections.abc.Mapping[builtins.int, builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device", b"device", "node_stats", b"node_stats", "thread_names", b"thread_names"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["device", b"device", "node_stats", b"node_stats", "thread_names", b"thread_names"]) -> None: ...
|
||||
|
||||
global___DeviceStepStats = DeviceStepStats
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class StepStats(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -256,6 +259,6 @@ class StepStats(google.protobuf.message.Message):
|
||||
*,
|
||||
dev_stats: collections.abc.Iterable[global___DeviceStepStats] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dev_stats", b"dev_stats"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["dev_stats", b"dev_stats"]) -> None: ...
|
||||
|
||||
global___StepStats = StepStats
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -69,7 +70,7 @@ have `tensor` set to a rank-1 tensor of bytestring dtype.
|
||||
"""
|
||||
global___DataClass = DataClass
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SummaryDescription(google.protobuf.message.Message):
|
||||
"""Metadata associated with a series of Summary data"""
|
||||
|
||||
@@ -85,11 +86,11 @@ class SummaryDescription(google.protobuf.message.Message):
|
||||
*,
|
||||
type_hint: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["type_hint", b"type_hint"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["type_hint", b"type_hint"]) -> None: ...
|
||||
|
||||
global___SummaryDescription = SummaryDescription
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SummaryMetadata(google.protobuf.message.Message):
|
||||
"""A SummaryMetadata encapsulates information on which plugins are able to make
|
||||
use of a certain summary value.
|
||||
@@ -97,7 +98,7 @@ class SummaryMetadata(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class PluginData(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -115,15 +116,12 @@ class SummaryMetadata(google.protobuf.message.Message):
|
||||
plugin_name: builtins.str | None = ...,
|
||||
content: builtins.bytes | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["content", b"content", "plugin_name", b"plugin_name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["content", b"content", "plugin_name", b"plugin_name"]) -> None: ...
|
||||
|
||||
PLUGIN_DATA_FIELD_NUMBER: builtins.int
|
||||
DISPLAY_NAME_FIELD_NUMBER: builtins.int
|
||||
SUMMARY_DESCRIPTION_FIELD_NUMBER: builtins.int
|
||||
DATA_CLASS_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def plugin_data(self) -> global___SummaryMetadata.PluginData:
|
||||
"""Data that associates a summary with a certain plugin."""
|
||||
display_name: builtins.str
|
||||
"""Display name for viewing in TensorBoard."""
|
||||
summary_description: builtins.str
|
||||
@@ -134,6 +132,10 @@ class SummaryMetadata(google.protobuf.message.Message):
|
||||
imposes constraints on the dtype and shape of the corresponding tensor
|
||||
values. See `DataClass` docs for details.
|
||||
"""
|
||||
@property
|
||||
def plugin_data(self) -> global___SummaryMetadata.PluginData:
|
||||
"""Data that associates a summary with a certain plugin."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -142,12 +144,12 @@ class SummaryMetadata(google.protobuf.message.Message):
|
||||
summary_description: builtins.str | None = ...,
|
||||
data_class: global___DataClass.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["plugin_data", b"plugin_data"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["data_class", b"data_class", "display_name", b"display_name", "plugin_data", b"plugin_data", "summary_description", b"summary_description"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["plugin_data", b"plugin_data"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["data_class", b"data_class", "display_name", b"display_name", "plugin_data", b"plugin_data", "summary_description", b"summary_description"]) -> None: ...
|
||||
|
||||
global___SummaryMetadata = SummaryMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Summary(google.protobuf.message.Message):
|
||||
"""A Summary is a set of named values to be displayed by the
|
||||
visualizer.
|
||||
@@ -159,7 +161,7 @@ class Summary(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Image(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -191,9 +193,9 @@ class Summary(google.protobuf.message.Message):
|
||||
colorspace: builtins.int | None = ...,
|
||||
encoded_image_string: builtins.bytes | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["colorspace", b"colorspace", "encoded_image_string", b"encoded_image_string", "height", b"height", "width", b"width"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["colorspace", b"colorspace", "encoded_image_string", b"encoded_image_string", "height", b"height", "width", b"width"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Audio(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -222,9 +224,9 @@ class Summary(google.protobuf.message.Message):
|
||||
encoded_audio_string: builtins.bytes | None = ...,
|
||||
content_type: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["content_type", b"content_type", "encoded_audio_string", b"encoded_audio_string", "length_frames", b"length_frames", "num_channels", b"num_channels", "sample_rate", b"sample_rate"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["content_type", b"content_type", "encoded_audio_string", b"encoded_audio_string", "length_frames", b"length_frames", "num_channels", b"num_channels", "sample_rate", b"sample_rate"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Value(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -244,6 +246,8 @@ class Summary(google.protobuf.message.Message):
|
||||
are often organized by scope (which contains slashes to convey
|
||||
hierarchy). For example: foo/bar/0
|
||||
"""
|
||||
simple_value: builtins.float
|
||||
obsolete_old_style_histogram: builtins.bytes
|
||||
@property
|
||||
def metadata(self) -> global___SummaryMetadata:
|
||||
"""Contains metadata on the summary value such as which plugins may use it.
|
||||
@@ -252,8 +256,7 @@ class Summary(google.protobuf.message.Message):
|
||||
value with a certain tag for each tag. TensorBoard then remembers which
|
||||
tags are associated with which plugins. This saves space.
|
||||
"""
|
||||
simple_value: builtins.float
|
||||
obsolete_old_style_histogram: builtins.bytes
|
||||
|
||||
@property
|
||||
def image(self) -> global___Summary.Image: ...
|
||||
@property
|
||||
@@ -275,19 +278,20 @@ class Summary(google.protobuf.message.Message):
|
||||
audio: global___Summary.Audio | None = ...,
|
||||
tensor: tensorflow.core.framework.tensor_pb2.TensorProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["audio", b"audio", "histo", b"histo", "image", b"image", "metadata", b"metadata", "obsolete_old_style_histogram", b"obsolete_old_style_histogram", "simple_value", b"simple_value", "tensor", b"tensor", "value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["audio", b"audio", "histo", b"histo", "image", b"image", "metadata", b"metadata", "node_name", b"node_name", "obsolete_old_style_histogram", b"obsolete_old_style_histogram", "simple_value", b"simple_value", "tag", b"tag", "tensor", b"tensor", "value", b"value"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["value", b"value"]) -> typing_extensions.Literal["simple_value", "obsolete_old_style_histogram", "image", "histo", "audio", "tensor"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["audio", b"audio", "histo", b"histo", "image", b"image", "metadata", b"metadata", "obsolete_old_style_histogram", b"obsolete_old_style_histogram", "simple_value", b"simple_value", "tensor", b"tensor", "value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["audio", b"audio", "histo", b"histo", "image", b"image", "metadata", b"metadata", "node_name", b"node_name", "obsolete_old_style_histogram", b"obsolete_old_style_histogram", "simple_value", b"simple_value", "tag", b"tag", "tensor", b"tensor", "value", b"value"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["value", b"value"]) -> typing.Literal["simple_value", "obsolete_old_style_histogram", "image", "histo", "audio", "tensor"] | None: ...
|
||||
|
||||
VALUE_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def value(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___Summary.Value]:
|
||||
"""Set of values for the summary."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
value: collections.abc.Iterable[global___Summary.Value] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["value", b"value"]) -> None: ...
|
||||
|
||||
global___Summary = Summary
|
||||
|
||||
@@ -2,8 +2,9 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.message
|
||||
@@ -13,7 +14,7 @@ import tensorflow.core.framework.types_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TensorDescription(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -25,9 +26,11 @@ class TensorDescription(google.protobuf.message.Message):
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto:
|
||||
"""Shape of the tensor."""
|
||||
|
||||
@property
|
||||
def allocation_description(self) -> tensorflow.core.framework.allocation_description_pb2.AllocationDescription:
|
||||
"""Information about the size and allocator used for the data"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -35,7 +38,7 @@ class TensorDescription(google.protobuf.message.Message):
|
||||
shape: tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto | None = ...,
|
||||
allocation_description: tensorflow.core.framework.allocation_description_pb2.AllocationDescription | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["allocation_description", b"allocation_description", "shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allocation_description", b"allocation_description", "dtype", b"dtype", "shape", b"shape"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["allocation_description", b"allocation_description", "shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["allocation_description", b"allocation_description", "dtype", b"dtype", "shape", b"shape"]) -> None: ...
|
||||
|
||||
global___TensorDescription = TensorDescription
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -15,7 +16,7 @@ import tensorflow.core.framework.types_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TensorProto(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing a tensor."""
|
||||
|
||||
@@ -40,9 +41,6 @@ class TensorProto(google.protobuf.message.Message):
|
||||
UINT64_VAL_FIELD_NUMBER: builtins.int
|
||||
FLOAT8_VAL_FIELD_NUMBER: builtins.int
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
@property
|
||||
def tensor_shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto:
|
||||
"""Shape of the tensor. TODO(touts): sort out the 0-rank issues."""
|
||||
version_number: builtins.int
|
||||
"""Only one of the representations below is set, one of "tensor_contents" and
|
||||
the "xxx_val" attributes. We are not using oneof because as oneofs cannot
|
||||
@@ -61,6 +59,14 @@ class TensorProto(google.protobuf.message.Message):
|
||||
reduce serialization overhead during RPC call by avoiding serialization of
|
||||
many repeated small items.
|
||||
"""
|
||||
float8_val: builtins.bytes
|
||||
"""DT_FLOAT8_*, use variable-sized set of bytes
|
||||
(i.e. the equivalent of repeated uint8, if such a thing existed).
|
||||
"""
|
||||
@property
|
||||
def tensor_shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto:
|
||||
"""Shape of the tensor. TODO(touts): sort out the 0-rank issues."""
|
||||
|
||||
@property
|
||||
def half_val(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Type specific representations that make it easy to create tensor protos in
|
||||
@@ -71,50 +77,59 @@ class TensorProto(google.protobuf.message.Message):
|
||||
DT_HALF, DT_BFLOAT16. Note that since protobuf has no int16 type, we'll
|
||||
have some pointless zero padding for each value here.
|
||||
"""
|
||||
|
||||
@property
|
||||
def float_val(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.float]:
|
||||
"""DT_FLOAT."""
|
||||
|
||||
@property
|
||||
def double_val(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.float]:
|
||||
"""DT_DOUBLE."""
|
||||
|
||||
@property
|
||||
def int_val(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""DT_INT32, DT_INT16, DT_UINT16, DT_INT8, DT_UINT8."""
|
||||
|
||||
@property
|
||||
def string_val(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bytes]:
|
||||
"""DT_STRING"""
|
||||
|
||||
@property
|
||||
def scomplex_val(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.float]:
|
||||
"""DT_COMPLEX64. scomplex_val(2*i) and scomplex_val(2*i+1) are real
|
||||
and imaginary parts of i-th single precision complex.
|
||||
"""
|
||||
|
||||
@property
|
||||
def int64_val(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""DT_INT64"""
|
||||
|
||||
@property
|
||||
def bool_val(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bool]:
|
||||
"""DT_BOOL"""
|
||||
|
||||
@property
|
||||
def dcomplex_val(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.float]:
|
||||
"""DT_COMPLEX128. dcomplex_val(2*i) and dcomplex_val(2*i+1) are real
|
||||
and imaginary parts of i-th double precision complex.
|
||||
"""
|
||||
|
||||
@property
|
||||
def resource_handle_val(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.resource_handle_pb2.ResourceHandleProto]:
|
||||
"""DT_RESOURCE"""
|
||||
|
||||
@property
|
||||
def variant_val(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___VariantTensorDataProto]:
|
||||
"""DT_VARIANT"""
|
||||
|
||||
@property
|
||||
def uint32_val(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""DT_UINT32"""
|
||||
|
||||
@property
|
||||
def uint64_val(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""DT_UINT64"""
|
||||
float8_val: builtins.bytes
|
||||
"""DT_FLOAT8_*, use variable-sized set of bytes
|
||||
(i.e. the equivalent of repeated uint8, if such a thing existed).
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -137,12 +152,12 @@ class TensorProto(google.protobuf.message.Message):
|
||||
uint64_val: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
float8_val: builtins.bytes | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["tensor_shape", b"tensor_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bool_val", b"bool_val", "dcomplex_val", b"dcomplex_val", "double_val", b"double_val", "dtype", b"dtype", "float8_val", b"float8_val", "float_val", b"float_val", "half_val", b"half_val", "int64_val", b"int64_val", "int_val", b"int_val", "resource_handle_val", b"resource_handle_val", "scomplex_val", b"scomplex_val", "string_val", b"string_val", "tensor_content", b"tensor_content", "tensor_shape", b"tensor_shape", "uint32_val", b"uint32_val", "uint64_val", b"uint64_val", "variant_val", b"variant_val", "version_number", b"version_number"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["tensor_shape", b"tensor_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["bool_val", b"bool_val", "dcomplex_val", b"dcomplex_val", "double_val", b"double_val", "dtype", b"dtype", "float8_val", b"float8_val", "float_val", b"float_val", "half_val", b"half_val", "int64_val", b"int64_val", "int_val", b"int_val", "resource_handle_val", b"resource_handle_val", "scomplex_val", b"scomplex_val", "string_val", b"string_val", "tensor_content", b"tensor_content", "tensor_shape", b"tensor_shape", "uint32_val", b"uint32_val", "uint64_val", b"uint64_val", "variant_val", b"variant_val", "version_number", b"version_number"]) -> None: ...
|
||||
|
||||
global___TensorProto = TensorProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class VariantTensorDataProto(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing the serialization format of DT_VARIANT tensors."""
|
||||
|
||||
@@ -158,6 +173,7 @@ class VariantTensorDataProto(google.protobuf.message.Message):
|
||||
@property
|
||||
def tensors(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___TensorProto]:
|
||||
"""Tensors contained within objects being serialized."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -165,6 +181,6 @@ class VariantTensorDataProto(google.protobuf.message.Message):
|
||||
metadata: builtins.bytes | None = ...,
|
||||
tensors: collections.abc.Iterable[global___TensorProto] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["metadata", b"metadata", "tensors", b"tensors", "type_name", b"type_name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["metadata", b"metadata", "tensors", b"tensors", "type_name", b"type_name"]) -> None: ...
|
||||
|
||||
global___VariantTensorDataProto = VariantTensorDataProto
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
Protocol buffer representing the shape of tensors."""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,13 +13,13 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TensorShapeProto(google.protobuf.message.Message):
|
||||
"""Dimensions of a tensor."""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Dim(google.protobuf.message.Message):
|
||||
"""One dimension of the tensor."""
|
||||
|
||||
@@ -41,10 +42,15 @@ class TensorShapeProto(google.protobuf.message.Message):
|
||||
size: builtins.int | None = ...,
|
||||
name: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "size", b"size"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["name", b"name", "size", b"size"]) -> None: ...
|
||||
|
||||
DIM_FIELD_NUMBER: builtins.int
|
||||
UNKNOWN_RANK_FIELD_NUMBER: builtins.int
|
||||
unknown_rank: builtins.bool
|
||||
"""If true, the number of dimensions in the shape is unknown.
|
||||
|
||||
If true, "dim.size()" must be 0.
|
||||
"""
|
||||
@property
|
||||
def dim(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___TensorShapeProto.Dim]:
|
||||
"""Dimensions of the tensor, such as {"input", 30}, {"output", 40}
|
||||
@@ -61,17 +67,13 @@ class TensorShapeProto(google.protobuf.message.Message):
|
||||
|
||||
If "dim.size()" > 0, "unknown_rank" must be false.
|
||||
"""
|
||||
unknown_rank: builtins.bool
|
||||
"""If true, the number of dimensions in the shape is unknown.
|
||||
|
||||
If true, "dim.size()" must be 0.
|
||||
"""
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
dim: collections.abc.Iterable[global___TensorShapeProto.Dim] | None = ...,
|
||||
unknown_rank: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dim", b"dim", "unknown_rank", b"unknown_rank"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["dim", b"dim", "unknown_rank", b"unknown_rank"]) -> None: ...
|
||||
|
||||
global___TensorShapeProto = TensorShapeProto
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
Protocol buffer representing slices of a tensor"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,13 +13,13 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TensorSliceProto(google.protobuf.message.Message):
|
||||
"""Can only be interpreted if you know the corresponding TensorShape."""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Extent(google.protobuf.message.Message):
|
||||
"""Extent of the slice in one dimension.
|
||||
Either both or no attributes must be set. When no attribute is set
|
||||
@@ -38,9 +39,9 @@ class TensorSliceProto(google.protobuf.message.Message):
|
||||
start: builtins.int | None = ...,
|
||||
length: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["has_length", b"has_length", "length", b"length"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["has_length", b"has_length", "length", b"length", "start", b"start"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["has_length", b"has_length"]) -> typing_extensions.Literal["length"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["has_length", b"has_length", "length", b"length"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["has_length", b"has_length", "length", b"length", "start", b"start"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["has_length", b"has_length"]) -> typing.Literal["length"] | None: ...
|
||||
|
||||
EXTENT_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
@@ -51,11 +52,12 @@ class TensorSliceProto(google.protobuf.message.Message):
|
||||
slice belongs to. The order of sizes is the same as the order of
|
||||
dimensions in the TensorShape.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
extent: collections.abc.Iterable[global___TensorSliceProto.Extent] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["extent", b"extent"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["extent", b"extent"]) -> None: ...
|
||||
|
||||
global___TensorSliceProto = TensorSliceProto
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import sys
|
||||
import typing
|
||||
@@ -177,7 +178,7 @@ DT_FLOAT8_E5M2_REF: DataType.ValueType # 124
|
||||
DT_FLOAT8_E4M3FN_REF: DataType.ValueType # 125
|
||||
global___DataType = DataType
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SerializedDType(google.protobuf.message.Message):
|
||||
"""Represents a serialized tf.dtypes.Dtype"""
|
||||
|
||||
@@ -190,6 +191,6 @@ class SerializedDType(google.protobuf.message.Message):
|
||||
*,
|
||||
datatype: global___DataType.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["datatype", b"datatype"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["datatype", b"datatype"]) -> None: ...
|
||||
|
||||
global___SerializedDType = SerializedDType
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -109,7 +110,7 @@ global step counter.
|
||||
"""
|
||||
global___VariableAggregation = VariableAggregation
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class VariableDef(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing a Variable."""
|
||||
|
||||
@@ -132,9 +133,6 @@ class VariableDef(google.protobuf.message.Message):
|
||||
"""Name of the initializer op."""
|
||||
snapshot_name: builtins.str
|
||||
"""Name of the snapshot tensor."""
|
||||
@property
|
||||
def save_slice_info_def(self) -> global___SaveSliceInfoDef:
|
||||
"""Support for saving variables as slices of a larger variable."""
|
||||
is_resource: builtins.bool
|
||||
"""Whether to represent this as a ResourceVariable."""
|
||||
trainable: builtins.bool
|
||||
@@ -143,6 +141,10 @@ class VariableDef(google.protobuf.message.Message):
|
||||
"""Indicates when a distributed variable will be synced."""
|
||||
aggregation: global___VariableAggregation.ValueType
|
||||
"""Indicates how a distributed variable will be aggregated."""
|
||||
@property
|
||||
def save_slice_info_def(self) -> global___SaveSliceInfoDef:
|
||||
"""Support for saving variables as slices of a larger variable."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -156,12 +158,12 @@ class VariableDef(google.protobuf.message.Message):
|
||||
synchronization: global___VariableSynchronization.ValueType | None = ...,
|
||||
aggregation: global___VariableAggregation.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["save_slice_info_def", b"save_slice_info_def"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["aggregation", b"aggregation", "initial_value_name", b"initial_value_name", "initializer_name", b"initializer_name", "is_resource", b"is_resource", "save_slice_info_def", b"save_slice_info_def", "snapshot_name", b"snapshot_name", "synchronization", b"synchronization", "trainable", b"trainable", "variable_name", b"variable_name"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["save_slice_info_def", b"save_slice_info_def"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["aggregation", b"aggregation", "initial_value_name", b"initial_value_name", "initializer_name", b"initializer_name", "is_resource", b"is_resource", "save_slice_info_def", b"save_slice_info_def", "snapshot_name", b"snapshot_name", "synchronization", b"synchronization", "trainable", b"trainable", "variable_name", b"variable_name"]) -> None: ...
|
||||
|
||||
global___VariableDef = VariableDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SaveSliceInfoDef(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -174,12 +176,15 @@ class SaveSliceInfoDef(google.protobuf.message.Message):
|
||||
@property
|
||||
def full_shape(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Shape of the full variable."""
|
||||
|
||||
@property
|
||||
def var_offset(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Offset of this variable into the full variable."""
|
||||
|
||||
@property
|
||||
def var_shape(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Shape of this variable."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -188,6 +193,6 @@ class SaveSliceInfoDef(google.protobuf.message.Message):
|
||||
var_offset: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
var_shape: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["full_name", b"full_name", "full_shape", b"full_shape", "var_offset", b"var_offset", "var_shape", b"var_shape"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["full_name", b"full_name", "full_shape", b"full_shape", "var_offset", b"var_offset", "var_shape", b"var_shape"]) -> None: ...
|
||||
|
||||
global___SaveSliceInfoDef = SaveSliceInfoDef
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,7 +13,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class VersionDef(google.protobuf.message.Message):
|
||||
"""Version information for a piece of serialized data
|
||||
|
||||
@@ -40,6 +41,7 @@ class VersionDef(google.protobuf.message.Message):
|
||||
@property
|
||||
def bad_consumers(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Specific consumer versions which are disallowed (e.g. due to bugs)."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -47,6 +49,6 @@ class VersionDef(google.protobuf.message.Message):
|
||||
min_consumer: builtins.int | None = ...,
|
||||
bad_consumers: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bad_consumers", b"bad_consumers", "min_consumer", b"min_consumer", "producer", b"producer"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["bad_consumers", b"bad_consumers", "min_consumer", b"min_consumer", "producer", b"producer"]) -> None: ...
|
||||
|
||||
global___VersionDef = VersionDef
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import google.protobuf.descriptor
|
||||
from tensorflow.tsl.protobuf.bfc_memory_map_pb2 import (
|
||||
BinSummary as BinSummary,
|
||||
|
||||
@@ -16,9 +16,10 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
==============================================================================
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -26,7 +27,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class JobDef(google.protobuf.message.Message):
|
||||
"""This file contains protos to be used when defining a TensorFlow
|
||||
cluster.
|
||||
@@ -74,7 +75,7 @@ class JobDef(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TasksEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -88,7 +89,7 @@ class JobDef(google.protobuf.message.Message):
|
||||
key: builtins.int | None = ...,
|
||||
value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
TASKS_FIELD_NUMBER: builtins.int
|
||||
@@ -102,17 +103,18 @@ class JobDef(google.protobuf.message.Message):
|
||||
mapping from 7 to "example.org:2222", then the device prefix
|
||||
"/job:worker/task:7" will be assigned to "example.org:2222".
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
name: builtins.str | None = ...,
|
||||
tasks: collections.abc.Mapping[builtins.int, builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "tasks", b"tasks"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["name", b"name", "tasks", b"tasks"]) -> None: ...
|
||||
|
||||
global___JobDef = JobDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ClusterDef(google.protobuf.message.Message):
|
||||
"""Defines a TensorFlow cluster as a set of jobs."""
|
||||
|
||||
@@ -122,11 +124,12 @@ class ClusterDef(google.protobuf.message.Message):
|
||||
@property
|
||||
def job(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___JobDef]:
|
||||
"""The jobs that comprise the cluster."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
job: collections.abc.Iterable[global___JobDef] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["job", b"job"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["job", b"job"]) -> None: ...
|
||||
|
||||
global___ClusterDef = ClusterDef
|
||||
|
||||
@@ -2,8 +2,9 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.message
|
||||
@@ -11,7 +12,7 @@ import tensorflow.core.protobuf.struct_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CompositeTensorVariantMetadata(google.protobuf.message.Message):
|
||||
"""Metadata for CompositeTensorVariant, used when serializing as Variant.
|
||||
|
||||
@@ -30,7 +31,7 @@ class CompositeTensorVariantMetadata(google.protobuf.message.Message):
|
||||
*,
|
||||
type_spec_proto: tensorflow.core.protobuf.struct_pb2.TypeSpecProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["type_spec_proto", b"type_spec_proto"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["type_spec_proto", b"type_spec_proto"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["type_spec_proto", b"type_spec_proto"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["type_spec_proto", b"type_spec_proto"]) -> None: ...
|
||||
|
||||
global___CompositeTensorVariantMetadata = CompositeTensorVariantMetadata
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -27,15 +28,15 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GPUOptions(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Experimental(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class VirtualDevices(google.protobuf.message.Message):
|
||||
"""Configuration for breaking down a visible GPU into multiple "virtual"
|
||||
devices.
|
||||
@@ -57,6 +58,7 @@ class GPUOptions(google.protobuf.message.Message):
|
||||
For the concept of "visible" and "virtual" GPU, see the comments for
|
||||
"visible_device_list" above for more information.
|
||||
"""
|
||||
|
||||
@property
|
||||
def priority(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Priority values to use with the virtual devices. Use the cuda function
|
||||
@@ -70,6 +72,7 @@ class GPUOptions(google.protobuf.message.Message):
|
||||
created with the default. If this field has values set, then the size
|
||||
of this must match with the above memory_limit_mb.
|
||||
"""
|
||||
|
||||
@property
|
||||
def device_ordinal(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Virtual Device ordinal number determines the device ID of the device.
|
||||
@@ -77,6 +80,7 @@ class GPUOptions(google.protobuf.message.Message):
|
||||
smaller device id. The phyiscal device id and location in the
|
||||
virtual device list is used to break ties.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -84,7 +88,7 @@ class GPUOptions(google.protobuf.message.Message):
|
||||
priority: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
device_ordinal: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device_ordinal", b"device_ordinal", "memory_limit_mb", b"memory_limit_mb", "priority", b"priority"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["device_ordinal", b"device_ordinal", "memory_limit_mb", b"memory_limit_mb", "priority", b"priority"]) -> None: ...
|
||||
|
||||
VIRTUAL_DEVICES_FIELD_NUMBER: builtins.int
|
||||
USE_UNIFIED_MEMORY_FIELD_NUMBER: builtins.int
|
||||
@@ -99,47 +103,6 @@ class GPUOptions(google.protobuf.message.Message):
|
||||
DISALLOW_RETRY_ON_ALLOCATION_FAILURE_FIELD_NUMBER: builtins.int
|
||||
GPU_HOST_MEM_LIMIT_IN_MB_FIELD_NUMBER: builtins.int
|
||||
GPU_HOST_MEM_DISALLOW_GROWTH_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def virtual_devices(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___GPUOptions.Experimental.VirtualDevices]:
|
||||
"""The multi virtual device settings. If empty (not set), it will create
|
||||
single virtual device on each visible GPU, according to the settings
|
||||
in "visible_device_list" above. Otherwise, the number of elements in the
|
||||
list must be the same as the number of visible GPUs (after
|
||||
"visible_device_list" filtering if it is set), and the string represented
|
||||
device names (e.g. /device:GPU:<id>) will refer to the virtual
|
||||
devices and have the <id> field assigned sequentially starting from 0,
|
||||
according to the order of the virtual devices determined by
|
||||
device_ordinal and the location in the virtual device list.
|
||||
|
||||
For example,
|
||||
visible_device_list = "1,0"
|
||||
virtual_devices { memory_limit: 1GB memory_limit: 2GB }
|
||||
virtual_devices { memory_limit: 3GB memory_limit: 4GB }
|
||||
will create 4 virtual devices as:
|
||||
/device:GPU:0 -> visible GPU 1 with 1GB memory
|
||||
/device:GPU:1 -> visible GPU 1 with 2GB memory
|
||||
/device:GPU:2 -> visible GPU 0 with 3GB memory
|
||||
/device:GPU:3 -> visible GPU 0 with 4GB memory
|
||||
|
||||
but
|
||||
visible_device_list = "1,0"
|
||||
virtual_devices { memory_limit: 1GB memory_limit: 2GB
|
||||
device_ordinal: 10 device_ordinal: 20}
|
||||
virtual_devices { memory_limit: 3GB memory_limit: 4GB
|
||||
device_ordinal: 10 device_ordinal: 20}
|
||||
will create 4 virtual devices as:
|
||||
/device:GPU:0 -> visible GPU 1 with 1GB memory (ordinal 10)
|
||||
/device:GPU:1 -> visible GPU 0 with 3GB memory (ordinal 10)
|
||||
/device:GPU:2 -> visible GPU 1 with 2GB memory (ordinal 20)
|
||||
/device:GPU:3 -> visible GPU 0 with 4GB memory (ordinal 20)
|
||||
|
||||
NOTE:
|
||||
1. It's invalid to set both this and "per_process_gpu_memory_fraction"
|
||||
at the same time.
|
||||
2. Currently this setting is per-process, not per-session. Using
|
||||
different settings in different sessions within same process will
|
||||
result in undefined behavior.
|
||||
"""
|
||||
use_unified_memory: builtins.bool
|
||||
"""If true, uses CUDA unified memory for memory allocations. If
|
||||
per_process_gpu_memory_fraction option is greater than 1.0, then unified
|
||||
@@ -222,6 +185,48 @@ class GPUOptions(google.protobuf.message.Message):
|
||||
gpu_host_mem_limit_in_mb, because the default GPU host memory limit is
|
||||
quite high.
|
||||
"""
|
||||
@property
|
||||
def virtual_devices(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___GPUOptions.Experimental.VirtualDevices]:
|
||||
"""The multi virtual device settings. If empty (not set), it will create
|
||||
single virtual device on each visible GPU, according to the settings
|
||||
in "visible_device_list" above. Otherwise, the number of elements in the
|
||||
list must be the same as the number of visible GPUs (after
|
||||
"visible_device_list" filtering if it is set), and the string represented
|
||||
device names (e.g. /device:GPU:<id>) will refer to the virtual
|
||||
devices and have the <id> field assigned sequentially starting from 0,
|
||||
according to the order of the virtual devices determined by
|
||||
device_ordinal and the location in the virtual device list.
|
||||
|
||||
For example,
|
||||
visible_device_list = "1,0"
|
||||
virtual_devices { memory_limit: 1GB memory_limit: 2GB }
|
||||
virtual_devices { memory_limit: 3GB memory_limit: 4GB }
|
||||
will create 4 virtual devices as:
|
||||
/device:GPU:0 -> visible GPU 1 with 1GB memory
|
||||
/device:GPU:1 -> visible GPU 1 with 2GB memory
|
||||
/device:GPU:2 -> visible GPU 0 with 3GB memory
|
||||
/device:GPU:3 -> visible GPU 0 with 4GB memory
|
||||
|
||||
but
|
||||
visible_device_list = "1,0"
|
||||
virtual_devices { memory_limit: 1GB memory_limit: 2GB
|
||||
device_ordinal: 10 device_ordinal: 20}
|
||||
virtual_devices { memory_limit: 3GB memory_limit: 4GB
|
||||
device_ordinal: 10 device_ordinal: 20}
|
||||
will create 4 virtual devices as:
|
||||
/device:GPU:0 -> visible GPU 1 with 1GB memory (ordinal 10)
|
||||
/device:GPU:1 -> visible GPU 0 with 3GB memory (ordinal 10)
|
||||
/device:GPU:2 -> visible GPU 1 with 2GB memory (ordinal 20)
|
||||
/device:GPU:3 -> visible GPU 0 with 4GB memory (ordinal 20)
|
||||
|
||||
NOTE:
|
||||
1. It's invalid to set both this and "per_process_gpu_memory_fraction"
|
||||
at the same time.
|
||||
2. Currently this setting is per-process, not per-session. Using
|
||||
different settings in different sessions within same process will
|
||||
result in undefined behavior.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -239,7 +244,7 @@ class GPUOptions(google.protobuf.message.Message):
|
||||
gpu_host_mem_limit_in_mb: builtins.float | None = ...,
|
||||
gpu_host_mem_disallow_growth: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["collective_ring_order", b"collective_ring_order", "disallow_retry_on_allocation_failure", b"disallow_retry_on_allocation_failure", "gpu_host_mem_disallow_growth", b"gpu_host_mem_disallow_growth", "gpu_host_mem_limit_in_mb", b"gpu_host_mem_limit_in_mb", "internal_fragmentation_fraction", b"internal_fragmentation_fraction", "kernel_tracker_max_bytes", b"kernel_tracker_max_bytes", "kernel_tracker_max_interval", b"kernel_tracker_max_interval", "kernel_tracker_max_pending", b"kernel_tracker_max_pending", "num_dev_to_dev_copy_streams", b"num_dev_to_dev_copy_streams", "timestamped_allocator", b"timestamped_allocator", "use_cuda_malloc_async", b"use_cuda_malloc_async", "use_unified_memory", b"use_unified_memory", "virtual_devices", b"virtual_devices"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["collective_ring_order", b"collective_ring_order", "disallow_retry_on_allocation_failure", b"disallow_retry_on_allocation_failure", "gpu_host_mem_disallow_growth", b"gpu_host_mem_disallow_growth", "gpu_host_mem_limit_in_mb", b"gpu_host_mem_limit_in_mb", "internal_fragmentation_fraction", b"internal_fragmentation_fraction", "kernel_tracker_max_bytes", b"kernel_tracker_max_bytes", "kernel_tracker_max_interval", b"kernel_tracker_max_interval", "kernel_tracker_max_pending", b"kernel_tracker_max_pending", "num_dev_to_dev_copy_streams", b"num_dev_to_dev_copy_streams", "timestamped_allocator", b"timestamped_allocator", "use_cuda_malloc_async", b"use_cuda_malloc_async", "use_unified_memory", b"use_unified_memory", "virtual_devices", b"virtual_devices"]) -> None: ...
|
||||
|
||||
PER_PROCESS_GPU_MEMORY_FRACTION_FIELD_NUMBER: builtins.int
|
||||
ALLOW_GROWTH_FIELD_NUMBER: builtins.int
|
||||
@@ -336,6 +341,7 @@ class GPUOptions(google.protobuf.message.Message):
|
||||
to API stability guarantees in
|
||||
https://www.tensorflow.org/guide/version_compat.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -349,12 +355,12 @@ class GPUOptions(google.protobuf.message.Message):
|
||||
force_gpu_compatible: builtins.bool | None = ...,
|
||||
experimental: global___GPUOptions.Experimental | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["experimental", b"experimental"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allocator_type", b"allocator_type", "allow_growth", b"allow_growth", "deferred_deletion_bytes", b"deferred_deletion_bytes", "experimental", b"experimental", "force_gpu_compatible", b"force_gpu_compatible", "per_process_gpu_memory_fraction", b"per_process_gpu_memory_fraction", "polling_active_delay_usecs", b"polling_active_delay_usecs", "polling_inactive_delay_msecs", b"polling_inactive_delay_msecs", "visible_device_list", b"visible_device_list"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["experimental", b"experimental"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["allocator_type", b"allocator_type", "allow_growth", b"allow_growth", "deferred_deletion_bytes", b"deferred_deletion_bytes", "experimental", b"experimental", "force_gpu_compatible", b"force_gpu_compatible", "per_process_gpu_memory_fraction", b"per_process_gpu_memory_fraction", "polling_active_delay_usecs", b"polling_active_delay_usecs", "polling_inactive_delay_msecs", b"polling_inactive_delay_msecs", "visible_device_list", b"visible_device_list"]) -> None: ...
|
||||
|
||||
global___GPUOptions = GPUOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OptimizerOptions(google.protobuf.message.Message):
|
||||
"""Options passed to the graph optimizer"""
|
||||
|
||||
@@ -466,11 +472,11 @@ class OptimizerOptions(google.protobuf.message.Message):
|
||||
global_jit_level: global___OptimizerOptions.GlobalJitLevel.ValueType | None = ...,
|
||||
cpu_global_jit: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cpu_global_jit", b"cpu_global_jit", "do_common_subexpression_elimination", b"do_common_subexpression_elimination", "do_constant_folding", b"do_constant_folding", "do_function_inlining", b"do_function_inlining", "global_jit_level", b"global_jit_level", "max_folded_constant_in_bytes", b"max_folded_constant_in_bytes", "opt_level", b"opt_level"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["cpu_global_jit", b"cpu_global_jit", "do_common_subexpression_elimination", b"do_common_subexpression_elimination", "do_constant_folding", b"do_constant_folding", "do_function_inlining", b"do_function_inlining", "global_jit_level", b"global_jit_level", "max_folded_constant_in_bytes", b"max_folded_constant_in_bytes", "opt_level", b"opt_level"]) -> None: ...
|
||||
|
||||
global___OptimizerOptions = OptimizerOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphOptions(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -487,9 +493,6 @@ class GraphOptions(google.protobuf.message.Message):
|
||||
"""If true, use control flow to schedule the activation of Recv nodes.
|
||||
(Currently ignored.)
|
||||
"""
|
||||
@property
|
||||
def optimizer_options(self) -> global___OptimizerOptions:
|
||||
"""Options controlling how graph is optimized."""
|
||||
build_cost_model: builtins.int
|
||||
"""The number of steps to run before returning a cost model detailing
|
||||
the memory usage and performance of each node of the graph. 0 means
|
||||
@@ -518,12 +521,17 @@ class GraphOptions(google.protobuf.message.Message):
|
||||
"""If > 0, record a timeline every this many steps.
|
||||
EXPERIMENTAL: This currently has no effect in MasterSession.
|
||||
"""
|
||||
@property
|
||||
def optimizer_options(self) -> global___OptimizerOptions:
|
||||
"""Options controlling how graph is optimized."""
|
||||
|
||||
@property
|
||||
def rewrite_options(self) -> tensorflow.core.protobuf.rewriter_config_pb2.RewriterConfig:
|
||||
"""Options that control the type and amount of graph rewriting.
|
||||
Not currently configurable via the public Python API (i.e. there is no API
|
||||
stability guarantee if you import RewriterConfig explicitly).
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -537,12 +545,12 @@ class GraphOptions(google.protobuf.message.Message):
|
||||
timeline_step: builtins.int | None = ...,
|
||||
rewrite_options: tensorflow.core.protobuf.rewriter_config_pb2.RewriterConfig | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["optimizer_options", b"optimizer_options", "rewrite_options", b"rewrite_options"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["build_cost_model", b"build_cost_model", "build_cost_model_after", b"build_cost_model_after", "enable_bfloat16_sendrecv", b"enable_bfloat16_sendrecv", "enable_recv_scheduling", b"enable_recv_scheduling", "infer_shapes", b"infer_shapes", "optimizer_options", b"optimizer_options", "place_pruned_graph", b"place_pruned_graph", "rewrite_options", b"rewrite_options", "timeline_step", b"timeline_step"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["optimizer_options", b"optimizer_options", "rewrite_options", b"rewrite_options"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["build_cost_model", b"build_cost_model", "build_cost_model_after", b"build_cost_model_after", "enable_bfloat16_sendrecv", b"enable_bfloat16_sendrecv", "enable_recv_scheduling", b"enable_recv_scheduling", "infer_shapes", b"infer_shapes", "optimizer_options", b"optimizer_options", "place_pruned_graph", b"place_pruned_graph", "rewrite_options", b"rewrite_options", "timeline_step", b"timeline_step"]) -> None: ...
|
||||
|
||||
global___GraphOptions = GraphOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ThreadPoolOptionProto(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -577,11 +585,11 @@ class ThreadPoolOptionProto(google.protobuf.message.Message):
|
||||
num_threads: builtins.int | None = ...,
|
||||
global_name: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["global_name", b"global_name", "num_threads", b"num_threads"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["global_name", b"global_name", "num_threads", b"num_threads"]) -> None: ...
|
||||
|
||||
global___ThreadPoolOptionProto = ThreadPoolOptionProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SessionMetadata(google.protobuf.message.Message):
|
||||
"""Metadata about the session.
|
||||
|
||||
@@ -606,11 +614,11 @@ class SessionMetadata(google.protobuf.message.Message):
|
||||
name: builtins.str | None = ...,
|
||||
version: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "version", b"version"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["name", b"name", "version", b"version"]) -> None: ...
|
||||
|
||||
global___SessionMetadata = SessionMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ConfigProto(google.protobuf.message.Message):
|
||||
"""Session configuration parameters.
|
||||
The system picks appropriate values for fields that are not set.
|
||||
@@ -618,7 +626,7 @@ class ConfigProto(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DeviceCountEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -632,9 +640,9 @@ class ConfigProto(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Experimental(google.protobuf.message.Message):
|
||||
"""Everything inside Experimental is subject to change and is not subject
|
||||
to API stability guarantees in
|
||||
@@ -747,16 +755,6 @@ class ConfigProto(google.protobuf.message.Message):
|
||||
"""This was promoted to a non-experimental API. Please use
|
||||
ConfigProto.share_cluster_devices_in_session instead.
|
||||
"""
|
||||
@property
|
||||
def session_metadata(self) -> global___SessionMetadata:
|
||||
"""Metadata about the session.
|
||||
|
||||
If set, this can be used by the runtime and the Ops for debugging,
|
||||
monitoring, etc.
|
||||
|
||||
NOTE: This is currently used and propagated only by the direct session
|
||||
and EagerContext.
|
||||
"""
|
||||
optimize_for_static_graph: builtins.bool
|
||||
"""If true, the session may treat the graph as being static for optimization
|
||||
purposes.
|
||||
@@ -812,9 +810,6 @@ class ConfigProto(google.protobuf.message.Message):
|
||||
"""Provides a hint to XLA auto clustering to prefer forming a single large
|
||||
cluster that encompases most of the graph.
|
||||
"""
|
||||
@property
|
||||
def coordination_config(self) -> tensorflow.tsl.protobuf.coordination_config_pb2.CoordinationServiceConfig:
|
||||
"""Distributed coordination service configurations."""
|
||||
disable_optimize_for_static_graph: builtins.bool
|
||||
"""If true, the session will treat the graph as being non-static for
|
||||
optimization purposes.
|
||||
@@ -826,6 +821,21 @@ class ConfigProto(google.protobuf.message.Message):
|
||||
This option is meant to replace `optimize_for_static_graph` and it
|
||||
aims to negate its value.
|
||||
"""
|
||||
@property
|
||||
def session_metadata(self) -> global___SessionMetadata:
|
||||
"""Metadata about the session.
|
||||
|
||||
If set, this can be used by the runtime and the Ops for debugging,
|
||||
monitoring, etc.
|
||||
|
||||
NOTE: This is currently used and propagated only by the direct session
|
||||
and EagerContext.
|
||||
"""
|
||||
|
||||
@property
|
||||
def coordination_config(self) -> tensorflow.tsl.protobuf.coordination_config_pb2.CoordinationServiceConfig:
|
||||
"""Distributed coordination service configurations."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -851,8 +861,8 @@ class ConfigProto(google.protobuf.message.Message):
|
||||
coordination_config: tensorflow.tsl.protobuf.coordination_config_pb2.CoordinationServiceConfig | None = ...,
|
||||
disable_optimize_for_static_graph: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["coordination_config", b"coordination_config", "session_metadata", b"session_metadata"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["collective_deterministic_sequential_execution", b"collective_deterministic_sequential_execution", "collective_group_leader", b"collective_group_leader", "collective_nccl", b"collective_nccl", "coordination_config", b"coordination_config", "disable_functional_ops_lowering", b"disable_functional_ops_lowering", "disable_optimize_for_static_graph", b"disable_optimize_for_static_graph", "disable_output_partition_graphs", b"disable_output_partition_graphs", "disable_thread_spinning", b"disable_thread_spinning", "enable_mlir_bridge", b"enable_mlir_bridge", "enable_mlir_graph_optimization", b"enable_mlir_graph_optimization", "executor_type", b"executor_type", "mlir_bridge_rollout", b"mlir_bridge_rollout", "optimize_for_static_graph", b"optimize_for_static_graph", "recv_buf_max_chunk", b"recv_buf_max_chunk", "session_metadata", b"session_metadata", "share_cluster_devices_in_session", b"share_cluster_devices_in_session", "share_session_state_in_clusterspec_propagation", b"share_session_state_in_clusterspec_propagation", "use_numa_affinity", b"use_numa_affinity", "use_tfrt", b"use_tfrt", "xla_fusion_autotuner_thresh", b"xla_fusion_autotuner_thresh", "xla_prefer_single_graph_cluster", b"xla_prefer_single_graph_cluster"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["coordination_config", b"coordination_config", "session_metadata", b"session_metadata"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["collective_deterministic_sequential_execution", b"collective_deterministic_sequential_execution", "collective_group_leader", b"collective_group_leader", "collective_nccl", b"collective_nccl", "coordination_config", b"coordination_config", "disable_functional_ops_lowering", b"disable_functional_ops_lowering", "disable_optimize_for_static_graph", b"disable_optimize_for_static_graph", "disable_output_partition_graphs", b"disable_output_partition_graphs", "disable_thread_spinning", b"disable_thread_spinning", "enable_mlir_bridge", b"enable_mlir_bridge", "enable_mlir_graph_optimization", b"enable_mlir_graph_optimization", "executor_type", b"executor_type", "mlir_bridge_rollout", b"mlir_bridge_rollout", "optimize_for_static_graph", b"optimize_for_static_graph", "recv_buf_max_chunk", b"recv_buf_max_chunk", "session_metadata", b"session_metadata", "share_cluster_devices_in_session", b"share_cluster_devices_in_session", "share_session_state_in_clusterspec_propagation", b"share_session_state_in_clusterspec_propagation", "use_numa_affinity", b"use_numa_affinity", "use_tfrt", b"use_tfrt", "xla_fusion_autotuner_thresh", b"xla_fusion_autotuner_thresh", "xla_prefer_single_graph_cluster", b"xla_prefer_single_graph_cluster"]) -> None: ...
|
||||
|
||||
DEVICE_COUNT_FIELD_NUMBER: builtins.int
|
||||
INTRA_OP_PARALLELISM_THREADS_FIELD_NUMBER: builtins.int
|
||||
@@ -871,13 +881,6 @@ class ConfigProto(google.protobuf.message.Message):
|
||||
ISOLATE_SESSION_STATE_FIELD_NUMBER: builtins.int
|
||||
SHARE_CLUSTER_DEVICES_IN_SESSION_FIELD_NUMBER: builtins.int
|
||||
EXPERIMENTAL_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def device_count(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.int]:
|
||||
"""Map from device type name (e.g., "CPU" or "GPU" ) to maximum
|
||||
number of devices of that type to use. If a particular device
|
||||
type is not found in the map, the system picks an appropriate
|
||||
number.
|
||||
"""
|
||||
intra_op_parallelism_threads: builtins.int
|
||||
"""The execution of an individual op (for some op types) can be
|
||||
parallelized on a pool of intra_op_parallelism_threads.
|
||||
@@ -916,6 +919,46 @@ class ConfigProto(google.protobuf.message.Message):
|
||||
session_inter_op_thread_pool to have one element, whose num_threads equals
|
||||
inter_op_parallelism_threads.
|
||||
"""
|
||||
placement_period: builtins.int
|
||||
"""Assignment of Nodes to Devices is recomputed every placement_period
|
||||
steps until the system warms up (at which point the recomputation
|
||||
typically slows down automatically).
|
||||
"""
|
||||
allow_soft_placement: builtins.bool
|
||||
"""Whether soft placement is allowed. If allow_soft_placement is true,
|
||||
an op will be placed on CPU if
|
||||
1. there's no GPU implementation for the OP
|
||||
or
|
||||
2. no GPU devices are known or registered
|
||||
or
|
||||
3. need to co-locate with reftype input(s) which are from CPU.
|
||||
"""
|
||||
log_device_placement: builtins.bool
|
||||
"""Whether device placements should be logged."""
|
||||
operation_timeout_in_ms: builtins.int
|
||||
"""Global timeout for all blocking operations in this session. If non-zero,
|
||||
and not overridden on a per-operation basis, this value will be used as the
|
||||
deadline for all blocking operations.
|
||||
"""
|
||||
isolate_session_state: builtins.bool
|
||||
"""If true, any resources such as Variables used in the session will not be
|
||||
shared with other sessions. However, when clusterspec propagation is
|
||||
enabled, this field is ignored and sessions are always isolated.
|
||||
"""
|
||||
share_cluster_devices_in_session: builtins.bool
|
||||
"""When true, WorkerSessions are created with device attributes from the
|
||||
full cluster.
|
||||
This is helpful when a worker wants to partition a graph
|
||||
(for example during a PartitionedCallOp).
|
||||
"""
|
||||
@property
|
||||
def device_count(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.int]:
|
||||
"""Map from device type name (e.g., "CPU" or "GPU" ) to maximum
|
||||
number of devices of that type to use. If a particular device
|
||||
type is not found in the map, the system picks an appropriate
|
||||
number.
|
||||
"""
|
||||
|
||||
@property
|
||||
def session_inter_op_thread_pool(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ThreadPoolOptionProto]:
|
||||
"""This option is experimental - it may be replaced with a different mechanism
|
||||
@@ -938,56 +981,30 @@ class ConfigProto(google.protobuf.message.Message):
|
||||
run the non-low-priority work, even across sessions, in a single large
|
||||
pool.
|
||||
"""
|
||||
placement_period: builtins.int
|
||||
"""Assignment of Nodes to Devices is recomputed every placement_period
|
||||
steps until the system warms up (at which point the recomputation
|
||||
typically slows down automatically).
|
||||
"""
|
||||
|
||||
@property
|
||||
def device_filters(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""When any filters are present sessions will ignore all devices which do not
|
||||
match the filters. Each filter can be partially specified, e.g. "/job:ps"
|
||||
"/job:worker/replica:3", etc.
|
||||
"""
|
||||
|
||||
@property
|
||||
def gpu_options(self) -> global___GPUOptions:
|
||||
"""Options that apply to all GPUs."""
|
||||
allow_soft_placement: builtins.bool
|
||||
"""Whether soft placement is allowed. If allow_soft_placement is true,
|
||||
an op will be placed on CPU if
|
||||
1. there's no GPU implementation for the OP
|
||||
or
|
||||
2. no GPU devices are known or registered
|
||||
or
|
||||
3. need to co-locate with reftype input(s) which are from CPU.
|
||||
"""
|
||||
log_device_placement: builtins.bool
|
||||
"""Whether device placements should be logged."""
|
||||
|
||||
@property
|
||||
def graph_options(self) -> global___GraphOptions:
|
||||
"""Options that apply to all graphs."""
|
||||
operation_timeout_in_ms: builtins.int
|
||||
"""Global timeout for all blocking operations in this session. If non-zero,
|
||||
and not overridden on a per-operation basis, this value will be used as the
|
||||
deadline for all blocking operations.
|
||||
"""
|
||||
|
||||
@property
|
||||
def rpc_options(self) -> tensorflow.tsl.protobuf.rpc_options_pb2.RPCOptions:
|
||||
"""Options that apply when this session uses the distributed runtime."""
|
||||
|
||||
@property
|
||||
def cluster_def(self) -> tensorflow.core.protobuf.cluster_pb2.ClusterDef:
|
||||
"""Optional list of all workers to use in this session."""
|
||||
isolate_session_state: builtins.bool
|
||||
"""If true, any resources such as Variables used in the session will not be
|
||||
shared with other sessions. However, when clusterspec propagation is
|
||||
enabled, this field is ignored and sessions are always isolated.
|
||||
"""
|
||||
share_cluster_devices_in_session: builtins.bool
|
||||
"""When true, WorkerSessions are created with device attributes from the
|
||||
full cluster.
|
||||
This is helpful when a worker wants to partition a graph
|
||||
(for example during a PartitionedCallOp).
|
||||
"""
|
||||
|
||||
@property
|
||||
def experimental(self) -> global___ConfigProto.Experimental: ...
|
||||
def __init__(
|
||||
@@ -1011,12 +1028,12 @@ class ConfigProto(google.protobuf.message.Message):
|
||||
share_cluster_devices_in_session: builtins.bool | None = ...,
|
||||
experimental: global___ConfigProto.Experimental | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["cluster_def", b"cluster_def", "experimental", b"experimental", "gpu_options", b"gpu_options", "graph_options", b"graph_options", "rpc_options", b"rpc_options"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allow_soft_placement", b"allow_soft_placement", "cluster_def", b"cluster_def", "device_count", b"device_count", "device_filters", b"device_filters", "experimental", b"experimental", "gpu_options", b"gpu_options", "graph_options", b"graph_options", "inter_op_parallelism_threads", b"inter_op_parallelism_threads", "intra_op_parallelism_threads", b"intra_op_parallelism_threads", "isolate_session_state", b"isolate_session_state", "log_device_placement", b"log_device_placement", "operation_timeout_in_ms", b"operation_timeout_in_ms", "placement_period", b"placement_period", "rpc_options", b"rpc_options", "session_inter_op_thread_pool", b"session_inter_op_thread_pool", "share_cluster_devices_in_session", b"share_cluster_devices_in_session", "use_per_session_threads", b"use_per_session_threads"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["cluster_def", b"cluster_def", "experimental", b"experimental", "gpu_options", b"gpu_options", "graph_options", b"graph_options", "rpc_options", b"rpc_options"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["allow_soft_placement", b"allow_soft_placement", "cluster_def", b"cluster_def", "device_count", b"device_count", "device_filters", b"device_filters", "experimental", b"experimental", "gpu_options", b"gpu_options", "graph_options", b"graph_options", "inter_op_parallelism_threads", b"inter_op_parallelism_threads", "intra_op_parallelism_threads", b"intra_op_parallelism_threads", "isolate_session_state", b"isolate_session_state", "log_device_placement", b"log_device_placement", "operation_timeout_in_ms", b"operation_timeout_in_ms", "placement_period", b"placement_period", "rpc_options", b"rpc_options", "session_inter_op_thread_pool", b"session_inter_op_thread_pool", "share_cluster_devices_in_session", b"share_cluster_devices_in_session", "use_per_session_threads", b"use_per_session_threads"]) -> None: ...
|
||||
|
||||
global___ConfigProto = ConfigProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RunOptions(google.protobuf.message.Message):
|
||||
"""Options for a single Run() call."""
|
||||
|
||||
@@ -1043,7 +1060,7 @@ class RunOptions(google.protobuf.message.Message):
|
||||
HARDWARE_TRACE: RunOptions.TraceLevel.ValueType # 2
|
||||
FULL_TRACE: RunOptions.TraceLevel.ValueType # 3
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Experimental(google.protobuf.message.Message):
|
||||
"""Everything inside Experimental is subject to change and is not subject
|
||||
to API stability guarantees in
|
||||
@@ -1052,7 +1069,7 @@ class RunOptions(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RunHandlerPoolOptions(google.protobuf.message.Message):
|
||||
"""Options for run handler thread pool."""
|
||||
|
||||
@@ -1068,7 +1085,7 @@ class RunOptions(google.protobuf.message.Message):
|
||||
*,
|
||||
priority: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["priority", b"priority"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["priority", b"priority"]) -> None: ...
|
||||
|
||||
COLLECTIVE_GRAPH_KEY_FIELD_NUMBER: builtins.int
|
||||
USE_RUN_HANDLER_POOL_FIELD_NUMBER: builtins.int
|
||||
@@ -1094,8 +1111,8 @@ class RunOptions(google.protobuf.message.Message):
|
||||
use_run_handler_pool: builtins.bool | None = ...,
|
||||
run_handler_pool_options: global___RunOptions.Experimental.RunHandlerPoolOptions | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["run_handler_pool_options", b"run_handler_pool_options"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["collective_graph_key", b"collective_graph_key", "run_handler_pool_options", b"run_handler_pool_options", "use_run_handler_pool", b"use_run_handler_pool"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["run_handler_pool_options", b"run_handler_pool_options"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["collective_graph_key", b"collective_graph_key", "run_handler_pool_options", b"run_handler_pool_options", "use_run_handler_pool", b"use_run_handler_pool"]) -> None: ...
|
||||
|
||||
TRACE_LEVEL_FIELD_NUMBER: builtins.int
|
||||
TIMEOUT_IN_MS_FIELD_NUMBER: builtins.int
|
||||
@@ -1119,9 +1136,6 @@ class RunOptions(google.protobuf.message.Message):
|
||||
"""Whether the partition graph(s) executed by the executor(s) should be
|
||||
outputted via RunMetadata.
|
||||
"""
|
||||
@property
|
||||
def debug_options(self) -> tensorflow.core.protobuf.debug_pb2.DebugOptions:
|
||||
"""EXPERIMENTAL. Options used to initialize DebuggerState, if enabled."""
|
||||
report_tensor_allocations_upon_oom: builtins.bool
|
||||
"""When enabled, causes tensor allocation information to be included in
|
||||
the error message when the Run() call fails because the allocator ran
|
||||
@@ -1129,6 +1143,10 @@ class RunOptions(google.protobuf.message.Message):
|
||||
|
||||
Enabling this option can slow down the Run() call.
|
||||
"""
|
||||
@property
|
||||
def debug_options(self) -> tensorflow.core.protobuf.debug_pb2.DebugOptions:
|
||||
"""EXPERIMENTAL. Options used to initialize DebuggerState, if enabled."""
|
||||
|
||||
@property
|
||||
def experimental(self) -> global___RunOptions.Experimental: ...
|
||||
def __init__(
|
||||
@@ -1142,18 +1160,18 @@ class RunOptions(google.protobuf.message.Message):
|
||||
report_tensor_allocations_upon_oom: builtins.bool | None = ...,
|
||||
experimental: global___RunOptions.Experimental | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["debug_options", b"debug_options", "experimental", b"experimental"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["debug_options", b"debug_options", "experimental", b"experimental", "inter_op_thread_pool", b"inter_op_thread_pool", "output_partition_graphs", b"output_partition_graphs", "report_tensor_allocations_upon_oom", b"report_tensor_allocations_upon_oom", "timeout_in_ms", b"timeout_in_ms", "trace_level", b"trace_level"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["debug_options", b"debug_options", "experimental", b"experimental"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["debug_options", b"debug_options", "experimental", b"experimental", "inter_op_thread_pool", b"inter_op_thread_pool", "output_partition_graphs", b"output_partition_graphs", "report_tensor_allocations_upon_oom", b"report_tensor_allocations_upon_oom", "timeout_in_ms", b"timeout_in_ms", "trace_level", b"trace_level"]) -> None: ...
|
||||
|
||||
global___RunOptions = RunOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RunMetadata(google.protobuf.message.Message):
|
||||
"""Metadata output (i.e., non-Tensor) for a single Run() call."""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FunctionGraphs(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -1163,6 +1181,7 @@ class RunMetadata(google.protobuf.message.Message):
|
||||
@property
|
||||
def partition_graphs(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.graph_pb2.GraphDef]:
|
||||
"""TODO(nareshmodi): Include some sort of function/cache-key identifier?"""
|
||||
|
||||
@property
|
||||
def pre_optimization_graph(self) -> tensorflow.core.framework.graph_pb2.GraphDef: ...
|
||||
@property
|
||||
@@ -1174,8 +1193,8 @@ class RunMetadata(google.protobuf.message.Message):
|
||||
pre_optimization_graph: tensorflow.core.framework.graph_pb2.GraphDef | None = ...,
|
||||
post_optimization_graph: tensorflow.core.framework.graph_pb2.GraphDef | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["post_optimization_graph", b"post_optimization_graph", "pre_optimization_graph", b"pre_optimization_graph"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["partition_graphs", b"partition_graphs", "post_optimization_graph", b"post_optimization_graph", "pre_optimization_graph", b"pre_optimization_graph"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["post_optimization_graph", b"post_optimization_graph", "pre_optimization_graph", b"pre_optimization_graph"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["partition_graphs", b"partition_graphs", "post_optimization_graph", b"post_optimization_graph", "pre_optimization_graph", b"pre_optimization_graph"]) -> None: ...
|
||||
|
||||
STEP_STATS_FIELD_NUMBER: builtins.int
|
||||
COST_GRAPH_FIELD_NUMBER: builtins.int
|
||||
@@ -1188,12 +1207,15 @@ class RunMetadata(google.protobuf.message.Message):
|
||||
"RunOptions" proto.
|
||||
EXPERIMENTAL: The format and set of events may change in future versions.
|
||||
"""
|
||||
|
||||
@property
|
||||
def cost_graph(self) -> tensorflow.core.framework.cost_graph_pb2.CostGraphDef:
|
||||
"""The cost graph for the computation defined by the run call."""
|
||||
|
||||
@property
|
||||
def partition_graphs(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.graph_pb2.GraphDef]:
|
||||
"""Graphs of the partitions executed by executors."""
|
||||
|
||||
@property
|
||||
def function_graphs(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___RunMetadata.FunctionGraphs]:
|
||||
"""This is only populated for graphs that are run as functions in TensorFlow
|
||||
@@ -1207,9 +1229,11 @@ class RunMetadata(google.protobuf.message.Message):
|
||||
level idea of what the built graph looks like (since the various graph
|
||||
optimization passes might change the structure of the graph significantly).
|
||||
"""
|
||||
|
||||
@property
|
||||
def session_metadata(self) -> global___SessionMetadata:
|
||||
"""Metadata about the session."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1219,12 +1243,12 @@ class RunMetadata(google.protobuf.message.Message):
|
||||
function_graphs: collections.abc.Iterable[global___RunMetadata.FunctionGraphs] | None = ...,
|
||||
session_metadata: global___SessionMetadata | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["cost_graph", b"cost_graph", "session_metadata", b"session_metadata", "step_stats", b"step_stats"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cost_graph", b"cost_graph", "function_graphs", b"function_graphs", "partition_graphs", b"partition_graphs", "session_metadata", b"session_metadata", "step_stats", b"step_stats"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["cost_graph", b"cost_graph", "session_metadata", b"session_metadata", "step_stats", b"step_stats"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["cost_graph", b"cost_graph", "function_graphs", b"function_graphs", "partition_graphs", b"partition_graphs", "session_metadata", b"session_metadata", "step_stats", b"step_stats"]) -> None: ...
|
||||
|
||||
global___RunMetadata = RunMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TensorConnection(google.protobuf.message.Message):
|
||||
"""Defines a connection between two tensors in a `GraphDef`."""
|
||||
|
||||
@@ -1246,11 +1270,11 @@ class TensorConnection(google.protobuf.message.Message):
|
||||
from_tensor: builtins.str | None = ...,
|
||||
to_tensor: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["from_tensor", b"from_tensor", "to_tensor", b"to_tensor"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["from_tensor", b"from_tensor", "to_tensor", b"to_tensor"]) -> None: ...
|
||||
|
||||
global___TensorConnection = TensorConnection
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CallableOptions(google.protobuf.message.Message):
|
||||
"""Defines a subgraph in another `GraphDef` as a set of feed points and nodes
|
||||
to be fetched or executed.
|
||||
@@ -1260,7 +1284,7 @@ class CallableOptions(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FeedDevicesEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -1274,9 +1298,9 @@ class CallableOptions(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FetchDevicesEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -1290,7 +1314,7 @@ class CallableOptions(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
FEED_FIELD_NUMBER: builtins.int
|
||||
FETCH_FIELD_NUMBER: builtins.int
|
||||
@@ -1300,29 +1324,46 @@ class CallableOptions(google.protobuf.message.Message):
|
||||
FEED_DEVICES_FIELD_NUMBER: builtins.int
|
||||
FETCH_DEVICES_FIELD_NUMBER: builtins.int
|
||||
FETCH_SKIP_SYNC_FIELD_NUMBER: builtins.int
|
||||
fetch_skip_sync: builtins.bool
|
||||
"""By default, RunCallable() will synchronize the GPU stream before returning
|
||||
fetched tensors on a GPU device, to ensure that the values in those tensors
|
||||
have been produced. This simplifies interacting with the tensors, but
|
||||
potentially incurs a performance hit.
|
||||
|
||||
If this options is set to true, the caller is responsible for ensuring
|
||||
that the values in the fetched tensors have been produced before they are
|
||||
used. The caller can do this by invoking `Device::Sync()` on the underlying
|
||||
device(s), or by feeding the tensors back to the same Session using
|
||||
`feed_devices` with the same corresponding device name.
|
||||
"""
|
||||
@property
|
||||
def feed(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Tensors to be fed in the callable. Each feed is the name of a tensor."""
|
||||
|
||||
@property
|
||||
def fetch(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Fetches. A list of tensor names. The caller of the callable expects a
|
||||
tensor to be returned for each fetch[i] (see RunStepResponse.tensor). The
|
||||
order of specified fetches does not change the execution order.
|
||||
"""
|
||||
|
||||
@property
|
||||
def target(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Target Nodes. A list of node names. The named nodes will be run by the
|
||||
callable but their outputs will not be returned.
|
||||
"""
|
||||
|
||||
@property
|
||||
def run_options(self) -> global___RunOptions:
|
||||
"""Options that will be applied to each run."""
|
||||
|
||||
@property
|
||||
def tensor_connection(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___TensorConnection]:
|
||||
"""Tensors to be connected in the callable. Each TensorConnection denotes
|
||||
a pair of tensors in the graph, between which an edge will be created
|
||||
in the callable.
|
||||
"""
|
||||
|
||||
@property
|
||||
def feed_devices(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]:
|
||||
"""The Tensor objects fed in the callable and fetched from the callable
|
||||
@@ -1373,20 +1414,9 @@ class CallableOptions(google.protobuf.message.Message):
|
||||
CUDA stream has been synchronized (e.g., via cuCtxSynchronize() or
|
||||
cuStreamSynchronize()).
|
||||
"""
|
||||
|
||||
@property
|
||||
def fetch_devices(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]: ...
|
||||
fetch_skip_sync: builtins.bool
|
||||
"""By default, RunCallable() will synchronize the GPU stream before returning
|
||||
fetched tensors on a GPU device, to ensure that the values in those tensors
|
||||
have been produced. This simplifies interacting with the tensors, but
|
||||
potentially incurs a performance hit.
|
||||
|
||||
If this options is set to true, the caller is responsible for ensuring
|
||||
that the values in the fetched tensors have been produced before they are
|
||||
used. The caller can do this by invoking `Device::Sync()` on the underlying
|
||||
device(s), or by feeding the tensors back to the same Session using
|
||||
`feed_devices` with the same corresponding device name.
|
||||
"""
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -1399,7 +1429,7 @@ class CallableOptions(google.protobuf.message.Message):
|
||||
fetch_devices: collections.abc.Mapping[builtins.str, builtins.str] | None = ...,
|
||||
fetch_skip_sync: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["run_options", b"run_options"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["feed", b"feed", "feed_devices", b"feed_devices", "fetch", b"fetch", "fetch_devices", b"fetch_devices", "fetch_skip_sync", b"fetch_skip_sync", "run_options", b"run_options", "target", b"target", "tensor_connection", b"tensor_connection"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["run_options", b"run_options"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["feed", b"feed", "feed_devices", b"feed_devices", "fetch", b"fetch", "fetch_devices", b"fetch_devices", "fetch_skip_sync", b"fetch_skip_sync", "run_options", b"run_options", "target", b"target", "tensor_connection", b"tensor_connection"]) -> None: ...
|
||||
|
||||
global___CallableOptions = CallableOptions
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,7 +13,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ValuesDef(google.protobuf.message.Message):
|
||||
"""Control flow context related protocol buffers.
|
||||
|
||||
@@ -21,7 +22,7 @@ class ValuesDef(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ExternalValuesEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -35,27 +36,29 @@ class ValuesDef(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
VALUES_FIELD_NUMBER: builtins.int
|
||||
EXTERNAL_VALUES_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def values(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Value names that have been seen in this context."""
|
||||
|
||||
@property
|
||||
def external_values(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]:
|
||||
"""Value names referenced by but external to this context."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
values: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
external_values: collections.abc.Mapping[builtins.str, builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["external_values", b"external_values", "values", b"values"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["external_values", b"external_values", "values", b"values"]) -> None: ...
|
||||
|
||||
global___ValuesDef = ValuesDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ControlFlowContextDef(google.protobuf.message.Message):
|
||||
"""Container for any kind of control flow context. Any other control flow
|
||||
contexts that are added below should also be added here.
|
||||
@@ -75,13 +78,13 @@ class ControlFlowContextDef(google.protobuf.message.Message):
|
||||
cond_ctxt: global___CondContextDef | None = ...,
|
||||
while_ctxt: global___WhileContextDef | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["cond_ctxt", b"cond_ctxt", "ctxt", b"ctxt", "while_ctxt", b"while_ctxt"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cond_ctxt", b"cond_ctxt", "ctxt", b"ctxt", "while_ctxt", b"while_ctxt"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["ctxt", b"ctxt"]) -> typing_extensions.Literal["cond_ctxt", "while_ctxt"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["cond_ctxt", b"cond_ctxt", "ctxt", b"ctxt", "while_ctxt", b"while_ctxt"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["cond_ctxt", b"cond_ctxt", "ctxt", b"ctxt", "while_ctxt", b"while_ctxt"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["ctxt", b"ctxt"]) -> typing.Literal["cond_ctxt", "while_ctxt"] | None: ...
|
||||
|
||||
global___ControlFlowContextDef = ControlFlowContextDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CondContextDef(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing a CondContext object."""
|
||||
|
||||
@@ -104,9 +107,11 @@ class CondContextDef(google.protobuf.message.Message):
|
||||
@property
|
||||
def values_def(self) -> global___ValuesDef:
|
||||
"""Values and external values in control flow context."""
|
||||
|
||||
@property
|
||||
def nested_contexts(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ControlFlowContextDef]:
|
||||
"""Contexts contained inside this context (e.g. nested conds)."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -117,12 +122,12 @@ class CondContextDef(google.protobuf.message.Message):
|
||||
values_def: global___ValuesDef | None = ...,
|
||||
nested_contexts: collections.abc.Iterable[global___ControlFlowContextDef] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["values_def", b"values_def"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["branch", b"branch", "context_name", b"context_name", "nested_contexts", b"nested_contexts", "pivot_name", b"pivot_name", "pred_name", b"pred_name", "values_def", b"values_def"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["values_def", b"values_def"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["branch", b"branch", "context_name", b"context_name", "nested_contexts", b"nested_contexts", "pivot_name", b"pivot_name", "pred_name", b"pred_name", "values_def", b"values_def"]) -> None: ...
|
||||
|
||||
global___CondContextDef = CondContextDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class WhileContextDef(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing a WhileContext object."""
|
||||
|
||||
@@ -154,20 +159,24 @@ class WhileContextDef(google.protobuf.message.Message):
|
||||
"""Name of the pivot_for_pred tensor."""
|
||||
pivot_for_body_name: builtins.str
|
||||
"""Name of the pivot_for_body tensor."""
|
||||
@property
|
||||
def loop_exit_names(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""List of names for exit tensors."""
|
||||
@property
|
||||
def loop_enter_names(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""List of names for enter tensors."""
|
||||
@property
|
||||
def values_def(self) -> global___ValuesDef:
|
||||
"""Values and external values in control flow context."""
|
||||
maximum_iterations_name: builtins.str
|
||||
"""Optional name of the maximum_iterations tensor."""
|
||||
@property
|
||||
def loop_exit_names(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""List of names for exit tensors."""
|
||||
|
||||
@property
|
||||
def loop_enter_names(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""List of names for enter tensors."""
|
||||
|
||||
@property
|
||||
def values_def(self) -> global___ValuesDef:
|
||||
"""Values and external values in control flow context."""
|
||||
|
||||
@property
|
||||
def nested_contexts(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ControlFlowContextDef]:
|
||||
"""Contexts contained inside this context (e.g. nested whiles)."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -184,7 +193,7 @@ class WhileContextDef(google.protobuf.message.Message):
|
||||
maximum_iterations_name: builtins.str | None = ...,
|
||||
nested_contexts: collections.abc.Iterable[global___ControlFlowContextDef] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["values_def", b"values_def"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["back_prop", b"back_prop", "context_name", b"context_name", "loop_enter_names", b"loop_enter_names", "loop_exit_names", b"loop_exit_names", "maximum_iterations_name", b"maximum_iterations_name", "nested_contexts", b"nested_contexts", "parallel_iterations", b"parallel_iterations", "pivot_for_body_name", b"pivot_for_body_name", "pivot_for_pred_name", b"pivot_for_pred_name", "pivot_name", b"pivot_name", "swap_memory", b"swap_memory", "values_def", b"values_def"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["values_def", b"values_def"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["back_prop", b"back_prop", "context_name", b"context_name", "loop_enter_names", b"loop_enter_names", "loop_exit_names", b"loop_exit_names", "maximum_iterations_name", b"maximum_iterations_name", "nested_contexts", b"nested_contexts", "parallel_iterations", b"parallel_iterations", "pivot_for_body_name", b"pivot_for_body_name", "pivot_for_pred_name", b"pivot_for_pred_name", "pivot_name", b"pivot_name", "swap_memory", b"swap_memory", "values_def", b"values_def"]) -> None: ...
|
||||
|
||||
global___WhileContextDef = WhileContextDef
|
||||
|
||||
@@ -1,108 +0,0 @@
|
||||
"""
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
class CoordinatedJob(google.protobuf.message.Message):
|
||||
"""Represents a job type and the number of tasks under this job.
|
||||
For example, ("worker", 20) implies that there will be 20 worker tasks.
|
||||
"""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
NUM_TASKS_FIELD_NUMBER: builtins.int
|
||||
name: builtins.str
|
||||
num_tasks: builtins.int
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
name: builtins.str | None = ...,
|
||||
num_tasks: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "num_tasks", b"num_tasks"]) -> None: ...
|
||||
|
||||
global___CoordinatedJob = CoordinatedJob
|
||||
|
||||
@typing_extensions.final
|
||||
class CoordinationServiceConfig(google.protobuf.message.Message):
|
||||
"""Coordination service configuration parameters.
|
||||
The system picks appropriate values for fields that are not set.
|
||||
"""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
SERVICE_TYPE_FIELD_NUMBER: builtins.int
|
||||
SERVICE_LEADER_FIELD_NUMBER: builtins.int
|
||||
ENABLE_HEALTH_CHECK_FIELD_NUMBER: builtins.int
|
||||
CLUSTER_REGISTER_TIMEOUT_IN_MS_FIELD_NUMBER: builtins.int
|
||||
HEARTBEAT_TIMEOUT_IN_MS_FIELD_NUMBER: builtins.int
|
||||
COORDINATED_JOB_LIST_FIELD_NUMBER: builtins.int
|
||||
SHUTDOWN_BARRIER_TIMEOUT_IN_MS_FIELD_NUMBER: builtins.int
|
||||
AGENT_DESTRUCTION_WITHOUT_SHUTDOWN_FIELD_NUMBER: builtins.int
|
||||
RECOVERABLE_JOBS_FIELD_NUMBER: builtins.int
|
||||
service_type: builtins.str
|
||||
"""Type of coordination service implementation to enable.
|
||||
For example, setting the service type as "standalone" starts a service
|
||||
instance on the leader task to provide the coordination services such as
|
||||
heartbeats and consistent key-value store.
|
||||
"""
|
||||
service_leader: builtins.str
|
||||
"""Address where the coordination service instance is hosted."""
|
||||
enable_health_check: builtins.bool
|
||||
"""Whether to enable the health check mechanism."""
|
||||
cluster_register_timeout_in_ms: builtins.int
|
||||
"""Maximum wait time for all members in the cluster to be registered."""
|
||||
heartbeat_timeout_in_ms: builtins.int
|
||||
"""Heartbeat timeout, if a task does not record heartbeat in this time
|
||||
window, it will be considered disconnected.
|
||||
Note: This is also used as a grace period to accept any heartbeats after
|
||||
the agent has disconnected, to account for the lag time between the service
|
||||
recording the state change and the agent stopping heartbeats.
|
||||
"""
|
||||
@property
|
||||
def coordinated_job_list(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___CoordinatedJob]: ...
|
||||
shutdown_barrier_timeout_in_ms: builtins.int
|
||||
"""Denotes how long to wait for all coordination agents to reach the barriers
|
||||
(after the first shutdown request) before disconnecting together. If
|
||||
set to 0, no barrier is imposed upon shutdown and each worker can
|
||||
disconnect individually.
|
||||
"""
|
||||
agent_destruction_without_shutdown: builtins.bool
|
||||
"""If set, agents do not make an explicit Shutdown() call. Service will only
|
||||
find out about the disconnecte agent via stale heartbeats. Used for
|
||||
testing.
|
||||
"""
|
||||
@property
|
||||
def recoverable_jobs(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""The list of jobs which are recoverable. If a task in this list fails,
|
||||
it will not propagate error to other tasks.
|
||||
If empty, no jobs will be recoverable and every task failure will cause
|
||||
error propagation to other tasks.
|
||||
"""
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
service_type: builtins.str | None = ...,
|
||||
service_leader: builtins.str | None = ...,
|
||||
enable_health_check: builtins.bool | None = ...,
|
||||
cluster_register_timeout_in_ms: builtins.int | None = ...,
|
||||
heartbeat_timeout_in_ms: builtins.int | None = ...,
|
||||
coordinated_job_list: collections.abc.Iterable[global___CoordinatedJob] | None = ...,
|
||||
shutdown_barrier_timeout_in_ms: builtins.int | None = ...,
|
||||
agent_destruction_without_shutdown: builtins.bool | None = ...,
|
||||
recoverable_jobs: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["agent_destruction_without_shutdown", b"agent_destruction_without_shutdown", "cluster_register_timeout_in_ms", b"cluster_register_timeout_in_ms", "coordinated_job_list", b"coordinated_job_list", "enable_health_check", b"enable_health_check", "heartbeat_timeout_in_ms", b"heartbeat_timeout_in_ms", "recoverable_jobs", b"recoverable_jobs", "service_leader", b"service_leader", "service_type", b"service_type", "shutdown_barrier_timeout_in_ms", b"shutdown_barrier_timeout_in_ms"]) -> None: ...
|
||||
|
||||
global___CoordinationServiceConfig = CoordinationServiceConfig
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import sys
|
||||
import typing
|
||||
@@ -17,7 +18,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ErrorSourceProto(google.protobuf.message.Message):
|
||||
"""If included as a payload, this message contains the error source information
|
||||
where the error was raised.
|
||||
@@ -62,6 +63,6 @@ class ErrorSourceProto(google.protobuf.message.Message):
|
||||
*,
|
||||
error_source: global___ErrorSourceProto.ErrorSource.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["error_source", b"error_source"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["error_source", b"error_source"]) -> None: ...
|
||||
|
||||
global___ErrorSourceProto = ErrorSourceProto
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import sys
|
||||
import typing
|
||||
@@ -47,7 +48,7 @@ hosts.
|
||||
"""
|
||||
global___DeploymentMode = DeploymentMode
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ProcessingModeDef(google.protobuf.message.Message):
|
||||
"""Next tag: 2"""
|
||||
|
||||
@@ -145,11 +146,11 @@ class ProcessingModeDef(google.protobuf.message.Message):
|
||||
*,
|
||||
sharding_policy: global___ProcessingModeDef.ShardingPolicy.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["sharding_policy", b"sharding_policy"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["sharding_policy", b"sharding_policy"]) -> None: ...
|
||||
|
||||
global___ProcessingModeDef = ProcessingModeDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DataServiceMetadata(google.protobuf.message.Message):
|
||||
"""Metadata related to tf.data service datasets.
|
||||
Next tag: 4
|
||||
@@ -191,13 +192,13 @@ class DataServiceMetadata(google.protobuf.message.Message):
|
||||
compression: global___DataServiceMetadata.Compression.ValueType | None = ...,
|
||||
cardinality: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["element_spec", b"element_spec", "optional_element_spec", b"optional_element_spec"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cardinality", b"cardinality", "compression", b"compression", "element_spec", b"element_spec", "optional_element_spec", b"optional_element_spec"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_element_spec", b"optional_element_spec"]) -> typing_extensions.Literal["element_spec"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["element_spec", b"element_spec", "optional_element_spec", b"optional_element_spec"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["cardinality", b"cardinality", "compression", b"compression", "element_spec", b"element_spec", "optional_element_spec", b"optional_element_spec"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_element_spec", b"optional_element_spec"]) -> typing.Literal["element_spec"] | None: ...
|
||||
|
||||
global___DataServiceMetadata = DataServiceMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CrossTrainerCacheOptions(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -208,11 +209,11 @@ class CrossTrainerCacheOptions(google.protobuf.message.Message):
|
||||
*,
|
||||
trainer_id: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["trainer_id", b"trainer_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["trainer_id", b"trainer_id"]) -> None: ...
|
||||
|
||||
global___CrossTrainerCacheOptions = CrossTrainerCacheOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DataServiceConfig(google.protobuf.message.Message):
|
||||
"""Data service config available to the client through GetDataServiceConfig RPC.
|
||||
Next tag: 2
|
||||
@@ -227,6 +228,6 @@ class DataServiceConfig(google.protobuf.message.Message):
|
||||
*,
|
||||
deployment_mode: global___DeploymentMode.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["deployment_mode", b"deployment_mode"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["deployment_mode", b"deployment_mode"]) -> None: ...
|
||||
|
||||
global___DataServiceConfig = DataServiceConfig
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -130,7 +131,7 @@ REDUCE_INF_NAN_THREE_SLOTS: TensorDebugMode.ValueType # 8
|
||||
"""
|
||||
global___TensorDebugMode = TensorDebugMode
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DebugEvent(google.protobuf.message.Message):
|
||||
"""An Event related to the debugging of a TensorFlow program."""
|
||||
|
||||
@@ -151,40 +152,48 @@ class DebugEvent(google.protobuf.message.Message):
|
||||
"""Timestamp in seconds (with microsecond precision)."""
|
||||
step: builtins.int
|
||||
"""Step of training (if available)."""
|
||||
@property
|
||||
def debug_metadata(self) -> global___DebugMetadata:
|
||||
"""Metadata related to this debugging data."""
|
||||
@property
|
||||
def source_file(self) -> global___SourceFile:
|
||||
"""The content of a source file."""
|
||||
@property
|
||||
def stack_frame_with_id(self) -> global___StackFrameWithId:
|
||||
"""A stack frame (filename, line number and column number, function name and
|
||||
code string) with ID.
|
||||
"""
|
||||
@property
|
||||
def graph_op_creation(self) -> global___GraphOpCreation:
|
||||
"""The creation of an op within a graph (e.g., a FuncGraph compiled from
|
||||
a Python function).
|
||||
"""
|
||||
@property
|
||||
def debugged_graph(self) -> global___DebuggedGraph:
|
||||
"""Information about a debugged graph."""
|
||||
@property
|
||||
def execution(self) -> global___Execution:
|
||||
"""Execution of an op or a Graph (e.g., a tf.function)."""
|
||||
@property
|
||||
def graph_execution_trace(self) -> global___GraphExecutionTrace:
|
||||
"""A graph execution trace: Contains information about the intermediate
|
||||
tensors computed during the graph execution.
|
||||
"""
|
||||
graph_id: builtins.str
|
||||
"""The ID of the graph (i.e., FuncGraph) executed here: applicable only
|
||||
to the execution of a FuncGraph.
|
||||
"""
|
||||
@property
|
||||
def debug_metadata(self) -> global___DebugMetadata:
|
||||
"""Metadata related to this debugging data."""
|
||||
|
||||
@property
|
||||
def source_file(self) -> global___SourceFile:
|
||||
"""The content of a source file."""
|
||||
|
||||
@property
|
||||
def stack_frame_with_id(self) -> global___StackFrameWithId:
|
||||
"""A stack frame (filename, line number and column number, function name and
|
||||
code string) with ID.
|
||||
"""
|
||||
|
||||
@property
|
||||
def graph_op_creation(self) -> global___GraphOpCreation:
|
||||
"""The creation of an op within a graph (e.g., a FuncGraph compiled from
|
||||
a Python function).
|
||||
"""
|
||||
|
||||
@property
|
||||
def debugged_graph(self) -> global___DebuggedGraph:
|
||||
"""Information about a debugged graph."""
|
||||
|
||||
@property
|
||||
def execution(self) -> global___Execution:
|
||||
"""Execution of an op or a Graph (e.g., a tf.function)."""
|
||||
|
||||
@property
|
||||
def graph_execution_trace(self) -> global___GraphExecutionTrace:
|
||||
"""A graph execution trace: Contains information about the intermediate
|
||||
tensors computed during the graph execution.
|
||||
"""
|
||||
|
||||
@property
|
||||
def debugged_device(self) -> global___DebuggedDevice:
|
||||
"""A device on which debugger-instrumented ops and/or tensors reside."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -200,13 +209,13 @@ class DebugEvent(google.protobuf.message.Message):
|
||||
graph_id: builtins.str | None = ...,
|
||||
debugged_device: global___DebuggedDevice | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["debug_metadata", b"debug_metadata", "debugged_device", b"debugged_device", "debugged_graph", b"debugged_graph", "execution", b"execution", "graph_execution_trace", b"graph_execution_trace", "graph_id", b"graph_id", "graph_op_creation", b"graph_op_creation", "source_file", b"source_file", "stack_frame_with_id", b"stack_frame_with_id", "what", b"what"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["debug_metadata", b"debug_metadata", "debugged_device", b"debugged_device", "debugged_graph", b"debugged_graph", "execution", b"execution", "graph_execution_trace", b"graph_execution_trace", "graph_id", b"graph_id", "graph_op_creation", b"graph_op_creation", "source_file", b"source_file", "stack_frame_with_id", b"stack_frame_with_id", "step", b"step", "wall_time", b"wall_time", "what", b"what"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["what", b"what"]) -> typing_extensions.Literal["debug_metadata", "source_file", "stack_frame_with_id", "graph_op_creation", "debugged_graph", "execution", "graph_execution_trace", "graph_id", "debugged_device"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["debug_metadata", b"debug_metadata", "debugged_device", b"debugged_device", "debugged_graph", b"debugged_graph", "execution", b"execution", "graph_execution_trace", b"graph_execution_trace", "graph_id", b"graph_id", "graph_op_creation", b"graph_op_creation", "source_file", b"source_file", "stack_frame_with_id", b"stack_frame_with_id", "what", b"what"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["debug_metadata", b"debug_metadata", "debugged_device", b"debugged_device", "debugged_graph", b"debugged_graph", "execution", b"execution", "graph_execution_trace", b"graph_execution_trace", "graph_id", b"graph_id", "graph_op_creation", b"graph_op_creation", "source_file", b"source_file", "stack_frame_with_id", b"stack_frame_with_id", "step", b"step", "wall_time", b"wall_time", "what", b"what"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["what", b"what"]) -> typing.Literal["debug_metadata", "source_file", "stack_frame_with_id", "graph_op_creation", "debugged_graph", "execution", "graph_execution_trace", "graph_id", "debugged_device"] | None: ...
|
||||
|
||||
global___DebugEvent = DebugEvent
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DebugMetadata(google.protobuf.message.Message):
|
||||
"""Metadata about the debugger and the debugged TensorFlow program."""
|
||||
|
||||
@@ -234,11 +243,11 @@ class DebugMetadata(google.protobuf.message.Message):
|
||||
file_version: builtins.str | None = ...,
|
||||
tfdbg_run_id: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["file_version", b"file_version", "tensorflow_version", b"tensorflow_version", "tfdbg_run_id", b"tfdbg_run_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["file_version", b"file_version", "tensorflow_version", b"tensorflow_version", "tfdbg_run_id", b"tfdbg_run_id"]) -> None: ...
|
||||
|
||||
global___DebugMetadata = DebugMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SourceFile(google.protobuf.message.Message):
|
||||
"""Content of a source file involved in the execution of the debugged TensorFlow
|
||||
program.
|
||||
@@ -256,6 +265,7 @@ class SourceFile(google.protobuf.message.Message):
|
||||
@property
|
||||
def lines(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Line-by-line content of the file."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -263,11 +273,11 @@ class SourceFile(google.protobuf.message.Message):
|
||||
host_name: builtins.str | None = ...,
|
||||
lines: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["file_path", b"file_path", "host_name", b"host_name", "lines", b"lines"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["file_path", b"file_path", "host_name", b"host_name", "lines", b"lines"]) -> None: ...
|
||||
|
||||
global___SourceFile = SourceFile
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class StackFrameWithId(google.protobuf.message.Message):
|
||||
"""A stack frame with ID."""
|
||||
|
||||
@@ -283,18 +293,19 @@ class StackFrameWithId(google.protobuf.message.Message):
|
||||
regarding the file name, line number, function name, code content
|
||||
of the line, and column number (if available).
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
id: builtins.str | None = ...,
|
||||
file_line_col: tensorflow.core.protobuf.graph_debug_info_pb2.GraphDebugInfo.FileLineCol | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["file_line_col", b"file_line_col"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["file_line_col", b"file_line_col", "id", b"id"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["file_line_col", b"file_line_col"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["file_line_col", b"file_line_col", "id", b"id"]) -> None: ...
|
||||
|
||||
global___StackFrameWithId = StackFrameWithId
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CodeLocation(google.protobuf.message.Message):
|
||||
"""Code location information: A stack trace with host-name information.
|
||||
Instead of encoding the detailed stack trace, this proto refers to IDs of
|
||||
@@ -313,17 +324,18 @@ class CodeLocation(google.protobuf.message.Message):
|
||||
by a unique ID. The ordering of the frames is consistent with Python's
|
||||
`traceback.extract_tb()`.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
host_name: builtins.str | None = ...,
|
||||
stack_frame_ids: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["host_name", b"host_name", "stack_frame_ids", b"stack_frame_ids"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["host_name", b"host_name", "stack_frame_ids", b"stack_frame_ids"]) -> None: ...
|
||||
|
||||
global___CodeLocation = CodeLocation
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphOpCreation(google.protobuf.message.Message):
|
||||
"""The creation of an op in a TensorFlow Graph (e.g., FuncGraph in TF2)."""
|
||||
|
||||
@@ -350,17 +362,20 @@ class GraphOpCreation(google.protobuf.message.Message):
|
||||
"""
|
||||
device_name: builtins.str
|
||||
"""Name of the device that the op is assigned to (if available)."""
|
||||
@property
|
||||
def input_names(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Names of the input tensors to the op."""
|
||||
num_outputs: builtins.int
|
||||
"""Number of output tensors emitted by the op."""
|
||||
@property
|
||||
def input_names(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Names of the input tensors to the op."""
|
||||
|
||||
@property
|
||||
def code_location(self) -> global___CodeLocation:
|
||||
"""The unique ID for code location (stack trace) of the op's creation."""
|
||||
|
||||
@property
|
||||
def output_tensor_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Unique IDs for the output tensors of this op."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -374,12 +389,12 @@ class GraphOpCreation(google.protobuf.message.Message):
|
||||
code_location: global___CodeLocation | None = ...,
|
||||
output_tensor_ids: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["code_location", b"code_location"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["code_location", b"code_location", "device_name", b"device_name", "graph_id", b"graph_id", "graph_name", b"graph_name", "input_names", b"input_names", "num_outputs", b"num_outputs", "op_name", b"op_name", "op_type", b"op_type", "output_tensor_ids", b"output_tensor_ids"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["code_location", b"code_location"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["code_location", b"code_location", "device_name", b"device_name", "graph_id", b"graph_id", "graph_name", b"graph_name", "input_names", b"input_names", "num_outputs", b"num_outputs", "op_name", b"op_name", "op_type", b"op_type", "output_tensor_ids", b"output_tensor_ids"]) -> None: ...
|
||||
|
||||
global___GraphOpCreation = GraphOpCreation
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DebuggedGraph(google.protobuf.message.Message):
|
||||
"""A debugger-instrumented graph."""
|
||||
|
||||
@@ -397,11 +412,6 @@ class DebuggedGraph(google.protobuf.message.Message):
|
||||
"""
|
||||
graph_name: builtins.str
|
||||
"""Name of the graph (if available)."""
|
||||
@property
|
||||
def instrumented_ops(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Names of the instrumented ops. This can be used to look up op name
|
||||
based on the numeric-summary tensors (2nd column).
|
||||
"""
|
||||
original_graph_def: builtins.bytes
|
||||
"""Original (uninstrumented) GraphDef (if available)."""
|
||||
instrumented_graph_def: builtins.bytes
|
||||
@@ -410,6 +420,12 @@ class DebuggedGraph(google.protobuf.message.Message):
|
||||
"""
|
||||
outer_context_id: builtins.str
|
||||
"""IDs of the immediate enclosing context (graph), if any."""
|
||||
@property
|
||||
def instrumented_ops(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Names of the instrumented ops. This can be used to look up op name
|
||||
based on the numeric-summary tensors (2nd column).
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -420,11 +436,11 @@ class DebuggedGraph(google.protobuf.message.Message):
|
||||
instrumented_graph_def: builtins.bytes | None = ...,
|
||||
outer_context_id: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["graph_id", b"graph_id", "graph_name", b"graph_name", "instrumented_graph_def", b"instrumented_graph_def", "instrumented_ops", b"instrumented_ops", "original_graph_def", b"original_graph_def", "outer_context_id", b"outer_context_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["graph_id", b"graph_id", "graph_name", b"graph_name", "instrumented_graph_def", b"instrumented_graph_def", "instrumented_ops", b"instrumented_ops", "original_graph_def", b"original_graph_def", "outer_context_id", b"outer_context_id"]) -> None: ...
|
||||
|
||||
global___DebuggedGraph = DebuggedGraph
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DebuggedDevice(google.protobuf.message.Message):
|
||||
"""A device on which ops and/or tensors are instrumented by the debugger."""
|
||||
|
||||
@@ -446,11 +462,11 @@ class DebuggedDevice(google.protobuf.message.Message):
|
||||
device_name: builtins.str | None = ...,
|
||||
device_id: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device_id", b"device_id", "device_name", b"device_name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["device_id", b"device_id", "device_name", b"device_name"]) -> None: ...
|
||||
|
||||
global___DebuggedDevice = DebuggedDevice
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Execution(google.protobuf.message.Message):
|
||||
"""Data relating to the eager execution of an op or a Graph.
|
||||
For a op that generates N output tensors (N >= 0), only one
|
||||
@@ -478,30 +494,35 @@ class Execution(google.protobuf.message.Message):
|
||||
"""The graph that's executed: applicable only to the eager
|
||||
execution of a FuncGraph.
|
||||
"""
|
||||
tensor_debug_mode: global___TensorDebugMode.ValueType
|
||||
"""Type of the tensor value encapsulated in this proto."""
|
||||
@property
|
||||
def input_tensor_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""IDs of the input tensors (if available)."""
|
||||
|
||||
@property
|
||||
def output_tensor_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""IDs of the output tensors (if availbable).
|
||||
If specified, must have the same length as tensor_protos.
|
||||
"""
|
||||
tensor_debug_mode: global___TensorDebugMode.ValueType
|
||||
"""Type of the tensor value encapsulated in this proto."""
|
||||
|
||||
@property
|
||||
def tensor_protos(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.tensor_pb2.TensorProto]:
|
||||
"""Output Tensor values in the type described by `tensor_value_type`.
|
||||
The length of this should match `num_outputs`.
|
||||
"""
|
||||
|
||||
@property
|
||||
def code_location(self) -> global___CodeLocation:
|
||||
"""Stack trace of the eager execution."""
|
||||
|
||||
@property
|
||||
def output_tensor_device_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Debugged-generated IDs of the devices on which the output tensors reside.
|
||||
To look up details about the device (e.g., name), cross-reference this
|
||||
field with the DebuggedDevice messages.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -515,12 +536,12 @@ class Execution(google.protobuf.message.Message):
|
||||
code_location: global___CodeLocation | None = ...,
|
||||
output_tensor_device_ids: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["code_location", b"code_location"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["code_location", b"code_location", "graph_id", b"graph_id", "input_tensor_ids", b"input_tensor_ids", "num_outputs", b"num_outputs", "op_type", b"op_type", "output_tensor_device_ids", b"output_tensor_device_ids", "output_tensor_ids", b"output_tensor_ids", "tensor_debug_mode", b"tensor_debug_mode", "tensor_protos", b"tensor_protos"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["code_location", b"code_location"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["code_location", b"code_location", "graph_id", b"graph_id", "input_tensor_ids", b"input_tensor_ids", "num_outputs", b"num_outputs", "op_type", b"op_type", "output_tensor_device_ids", b"output_tensor_device_ids", "output_tensor_ids", b"output_tensor_ids", "tensor_debug_mode", b"tensor_debug_mode", "tensor_protos", b"tensor_protos"]) -> None: ...
|
||||
|
||||
global___Execution = Execution
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphExecutionTrace(google.protobuf.message.Message):
|
||||
"""Data relating to an execution of a Graph (e.g., an eager execution of a
|
||||
FuncGraph).
|
||||
@@ -552,14 +573,15 @@ class GraphExecutionTrace(google.protobuf.message.Message):
|
||||
"""
|
||||
tensor_debug_mode: global___TensorDebugMode.ValueType
|
||||
"""Type of the tensor value encapsulated in this proto."""
|
||||
device_name: builtins.str
|
||||
"""Name of the device that the op belongs to."""
|
||||
@property
|
||||
def tensor_proto(self) -> tensorflow.core.framework.tensor_pb2.TensorProto:
|
||||
"""Tensor value in the type described by `tensor_value_type`.
|
||||
This tensor may summarize the value of a single intermediate op of the
|
||||
graph, or those of multiple intermediate tensors.
|
||||
"""
|
||||
device_name: builtins.str
|
||||
"""Name of the device that the op belongs to."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -570,7 +592,7 @@ class GraphExecutionTrace(google.protobuf.message.Message):
|
||||
tensor_proto: tensorflow.core.framework.tensor_pb2.TensorProto | None = ...,
|
||||
device_name: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["tensor_proto", b"tensor_proto"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device_name", b"device_name", "op_name", b"op_name", "output_slot", b"output_slot", "tensor_debug_mode", b"tensor_debug_mode", "tensor_proto", b"tensor_proto", "tfdbg_context_id", b"tfdbg_context_id"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["tensor_proto", b"tensor_proto"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["device_name", b"device_name", "op_name", b"op_name", "output_slot", b"output_slot", "tensor_debug_mode", b"tensor_debug_mode", "tensor_proto", b"tensor_proto", "tfdbg_context_id", b"tfdbg_context_id"]) -> None: ...
|
||||
|
||||
global___GraphExecutionTrace = GraphExecutionTrace
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,7 +13,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DebugTensorWatch(google.protobuf.message.Message):
|
||||
"""Option for watching a node in TensorFlow Debugger (tfdbg)."""
|
||||
|
||||
@@ -35,12 +36,17 @@ class DebugTensorWatch(google.protobuf.message.Message):
|
||||
Other negative values of output_slot are invalid and will lead to
|
||||
errors currently.
|
||||
"""
|
||||
tolerate_debug_op_creation_failures: builtins.bool
|
||||
"""Do not error out if debug op creation fails (e.g., due to dtype
|
||||
incompatibility). Instead, just log the failure.
|
||||
"""
|
||||
@property
|
||||
def debug_ops(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Name(s) of the debugging op(s).
|
||||
One or more than one probes on a tensor.
|
||||
e.g., {"DebugIdentity", "DebugNanCount"}
|
||||
"""
|
||||
|
||||
@property
|
||||
def debug_urls(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""URL(s) for debug targets(s).
|
||||
@@ -64,10 +70,7 @@ class DebugTensorWatch(google.protobuf.message.Message):
|
||||
among the invocations.
|
||||
TODO(cais): More visible documentation of this in g3docs.
|
||||
"""
|
||||
tolerate_debug_op_creation_failures: builtins.bool
|
||||
"""Do not error out if debug op creation fails (e.g., due to dtype
|
||||
incompatibility). Instead, just log the failure.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -77,11 +80,11 @@ class DebugTensorWatch(google.protobuf.message.Message):
|
||||
debug_urls: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
tolerate_debug_op_creation_failures: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["debug_ops", b"debug_ops", "debug_urls", b"debug_urls", "node_name", b"node_name", "output_slot", b"output_slot", "tolerate_debug_op_creation_failures", b"tolerate_debug_op_creation_failures"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["debug_ops", b"debug_ops", "debug_urls", b"debug_urls", "node_name", b"node_name", "output_slot", b"output_slot", "tolerate_debug_op_creation_failures", b"tolerate_debug_op_creation_failures"]) -> None: ...
|
||||
|
||||
global___DebugTensorWatch = DebugTensorWatch
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DebugOptions(google.protobuf.message.Message):
|
||||
"""Options for initializing DebuggerState in TensorFlow Debugger (tfdbg)."""
|
||||
|
||||
@@ -90,9 +93,6 @@ class DebugOptions(google.protobuf.message.Message):
|
||||
DEBUG_TENSOR_WATCH_OPTS_FIELD_NUMBER: builtins.int
|
||||
GLOBAL_STEP_FIELD_NUMBER: builtins.int
|
||||
RESET_DISK_BYTE_USAGE_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def debug_tensor_watch_opts(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___DebugTensorWatch]:
|
||||
"""Debugging options"""
|
||||
global_step: builtins.int
|
||||
"""Caller-specified global step count.
|
||||
Note that this is distinct from the session run count and the executor
|
||||
@@ -104,6 +104,10 @@ class DebugOptions(google.protobuf.message.Message):
|
||||
such as the local CLI ones to indicate that the dumped tensors
|
||||
are cleaned up from the disk after each Session.run.
|
||||
"""
|
||||
@property
|
||||
def debug_tensor_watch_opts(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___DebugTensorWatch]:
|
||||
"""Debugging options"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -111,11 +115,11 @@ class DebugOptions(google.protobuf.message.Message):
|
||||
global_step: builtins.int | None = ...,
|
||||
reset_disk_byte_usage: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["debug_tensor_watch_opts", b"debug_tensor_watch_opts", "global_step", b"global_step", "reset_disk_byte_usage", b"reset_disk_byte_usage"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["debug_tensor_watch_opts", b"debug_tensor_watch_opts", "global_step", b"global_step", "reset_disk_byte_usage", b"reset_disk_byte_usage"]) -> None: ...
|
||||
|
||||
global___DebugOptions = DebugOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DebuggedSourceFile(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -135,6 +139,7 @@ class DebuggedSourceFile(google.protobuf.message.Message):
|
||||
@property
|
||||
def lines(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Line-by-line content of the source code file."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -144,11 +149,11 @@ class DebuggedSourceFile(google.protobuf.message.Message):
|
||||
bytes: builtins.int | None = ...,
|
||||
lines: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bytes", b"bytes", "file_path", b"file_path", "host", b"host", "last_modified", b"last_modified", "lines", b"lines"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["bytes", b"bytes", "file_path", b"file_path", "host", b"host", "last_modified", b"last_modified", "lines", b"lines"]) -> None: ...
|
||||
|
||||
global___DebuggedSourceFile = DebuggedSourceFile
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DebuggedSourceFiles(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -156,11 +161,12 @@ class DebuggedSourceFiles(google.protobuf.message.Message):
|
||||
@property
|
||||
def source_files(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___DebuggedSourceFile]:
|
||||
"""A collection of source code files."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
source_files: collections.abc.Iterable[global___DebuggedSourceFile] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["source_files", b"source_files"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["source_files", b"source_files"]) -> None: ...
|
||||
|
||||
global___DebuggedSourceFiles = DebuggedSourceFiles
|
||||
|
||||
@@ -16,9 +16,10 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
==============================================================================
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -26,7 +27,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TaskDeviceFilters(google.protobuf.message.Message):
|
||||
"""This file contains protos to be used when defining a TensorFlow
|
||||
cluster.
|
||||
@@ -71,17 +72,17 @@ class TaskDeviceFilters(google.protobuf.message.Message):
|
||||
*,
|
||||
device_filters: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device_filters", b"device_filters"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["device_filters", b"device_filters"]) -> None: ...
|
||||
|
||||
global___TaskDeviceFilters = TaskDeviceFilters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class JobDeviceFilters(google.protobuf.message.Message):
|
||||
"""Defines the device filters for tasks in a job."""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TasksEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -96,8 +97,8 @@ class JobDeviceFilters(google.protobuf.message.Message):
|
||||
key: builtins.int | None = ...,
|
||||
value: global___TaskDeviceFilters | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
TASKS_FIELD_NUMBER: builtins.int
|
||||
@@ -106,17 +107,18 @@ class JobDeviceFilters(google.protobuf.message.Message):
|
||||
@property
|
||||
def tasks(self) -> google.protobuf.internal.containers.MessageMap[builtins.int, global___TaskDeviceFilters]:
|
||||
"""Mapping from task ID to task device filters."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
name: builtins.str | None = ...,
|
||||
tasks: collections.abc.Mapping[builtins.int, global___TaskDeviceFilters] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "tasks", b"tasks"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["name", b"name", "tasks", b"tasks"]) -> None: ...
|
||||
|
||||
global___JobDeviceFilters = JobDeviceFilters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ClusterDeviceFilters(google.protobuf.message.Message):
|
||||
"""Defines the device filters for jobs in a cluster."""
|
||||
|
||||
@@ -130,6 +132,6 @@ class ClusterDeviceFilters(google.protobuf.message.Message):
|
||||
*,
|
||||
jobs: collections.abc.Iterable[global___JobDeviceFilters] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["jobs", b"jobs"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["jobs", b"jobs"]) -> None: ...
|
||||
|
||||
global___ClusterDeviceFilters = ClusterDeviceFilters
|
||||
|
||||
@@ -16,9 +16,10 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
==============================================================================
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -26,11 +27,11 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DeviceProperties(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class EnvironmentEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -44,7 +45,7 @@ class DeviceProperties(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
TYPE_FIELD_NUMBER: builtins.int
|
||||
VENDOR_FIELD_NUMBER: builtins.int
|
||||
@@ -69,11 +70,6 @@ class DeviceProperties(google.protobuf.message.Message):
|
||||
"""Core Frequency in Mhz"""
|
||||
num_cores: builtins.int
|
||||
"""Number of cores"""
|
||||
@property
|
||||
def environment(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]:
|
||||
"""Version of the tools and libraries used with this device (e.g. gcc 4.9,
|
||||
cudnn 5.1)
|
||||
"""
|
||||
num_registers: builtins.int
|
||||
"""Number of registers per core."""
|
||||
l1_cache_size: builtins.int
|
||||
@@ -90,6 +86,12 @@ class DeviceProperties(google.protobuf.message.Message):
|
||||
"""Memory size in bytes"""
|
||||
bandwidth: builtins.int
|
||||
"""Memory bandwidth in KB/s"""
|
||||
@property
|
||||
def environment(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]:
|
||||
"""Version of the tools and libraries used with this device (e.g. gcc 4.9,
|
||||
cudnn 5.1)
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -107,11 +109,11 @@ class DeviceProperties(google.protobuf.message.Message):
|
||||
memory_size: builtins.int | None = ...,
|
||||
bandwidth: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bandwidth", b"bandwidth", "environment", b"environment", "frequency", b"frequency", "l1_cache_size", b"l1_cache_size", "l2_cache_size", b"l2_cache_size", "l3_cache_size", b"l3_cache_size", "memory_size", b"memory_size", "model", b"model", "num_cores", b"num_cores", "num_registers", b"num_registers", "shared_memory_size_per_multiprocessor", b"shared_memory_size_per_multiprocessor", "type", b"type", "vendor", b"vendor"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["bandwidth", b"bandwidth", "environment", b"environment", "frequency", b"frequency", "l1_cache_size", b"l1_cache_size", "l2_cache_size", b"l2_cache_size", "l3_cache_size", b"l3_cache_size", "memory_size", b"memory_size", "model", b"model", "num_cores", b"num_cores", "num_registers", b"num_registers", "shared_memory_size_per_multiprocessor", b"shared_memory_size_per_multiprocessor", "type", b"type", "vendor", b"vendor"]) -> None: ...
|
||||
|
||||
global___DeviceProperties = DeviceProperties
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class NamedDevice(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -126,7 +128,7 @@ class NamedDevice(google.protobuf.message.Message):
|
||||
name: builtins.str | None = ...,
|
||||
properties: global___DeviceProperties | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["properties", b"properties"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "properties", b"properties"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["properties", b"properties"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["name", b"name", "properties", b"properties"]) -> None: ...
|
||||
|
||||
global___NamedDevice = NamedDevice
|
||||
|
||||
@@ -1,81 +0,0 @@
|
||||
"""
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
class GrpcPayloadContainer(google.protobuf.message.Message):
|
||||
"""Used to serialize and transmit tensorflow::Status payloads through
|
||||
grpc::Status `error_details` since grpc::Status lacks payload API.
|
||||
TODO(b/204231601): Use GRPC API once supported.
|
||||
"""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
class PayloadsEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
KEY_FIELD_NUMBER: builtins.int
|
||||
VALUE_FIELD_NUMBER: builtins.int
|
||||
key: builtins.str
|
||||
value: builtins.bytes
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.bytes | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
PAYLOADS_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def payloads(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.bytes]: ...
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
payloads: collections.abc.Mapping[builtins.str, builtins.bytes] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["payloads", b"payloads"]) -> None: ...
|
||||
|
||||
global___GrpcPayloadContainer = GrpcPayloadContainer
|
||||
|
||||
@typing_extensions.final
|
||||
class GrpcPayloadsLost(google.protobuf.message.Message):
|
||||
"""If included as a payload, this message flags the Status to have lost payloads
|
||||
during the GRPC transmission.
|
||||
URI: "type.googleapis.com/tensorflow.distributed_runtime.GrpcPayloadsLost"
|
||||
"""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
) -> None: ...
|
||||
|
||||
global___GrpcPayloadsLost = GrpcPayloadsLost
|
||||
|
||||
@typing_extensions.final
|
||||
class WorkerPossiblyRestarted(google.protobuf.message.Message):
|
||||
"""If included as a payload, this message flags the Status to be a possible
|
||||
outcome of a worker restart.
|
||||
URI:
|
||||
"type.googleapis.com/tensorflow.distributed_runtime.WorkerPossiblyRestarted"
|
||||
"""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
) -> None: ...
|
||||
|
||||
global___WorkerPossiblyRestarted = WorkerPossiblyRestarted
|
||||
@@ -6,6 +6,7 @@ core/lib/core/error_codes.proto, or having tensorflow.error, like
|
||||
tsl/protobuf/error_codes.proto, results in name collision errors in generated
|
||||
code for some users that use JS through J2CL.
|
||||
"""
|
||||
|
||||
import google.protobuf.descriptor
|
||||
from tensorflow.tsl.protobuf.error_codes_pb2 import (
|
||||
ABORTED as ABORTED,
|
||||
|
||||
@@ -2,8 +2,9 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.message
|
||||
@@ -11,7 +12,7 @@ import tensorflow.core.framework.versions_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FingerprintDef(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing a SavedModel Fingerprint.
|
||||
|
||||
@@ -40,6 +41,7 @@ class FingerprintDef(google.protobuf.message.Message):
|
||||
@property
|
||||
def version(self) -> tensorflow.core.framework.versions_pb2.VersionDef:
|
||||
"""Version specification of the fingerprint."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -50,7 +52,7 @@ class FingerprintDef(google.protobuf.message.Message):
|
||||
checkpoint_hash: builtins.int | None = ...,
|
||||
version: tensorflow.core.framework.versions_pb2.VersionDef | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["version", b"version"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["checkpoint_hash", b"checkpoint_hash", "graph_def_program_hash", b"graph_def_program_hash", "saved_model_checksum", b"saved_model_checksum", "saved_object_graph_hash", b"saved_object_graph_hash", "signature_def_hash", b"signature_def_hash", "version", b"version"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["version", b"version"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["checkpoint_hash", b"checkpoint_hash", "graph_def_program_hash", b"graph_def_program_hash", "saved_model_checksum", b"saved_model_checksum", "saved_object_graph_hash", b"saved_object_graph_hash", "signature_def_hash", b"signature_def_hash", "version", b"version"]) -> None: ...
|
||||
|
||||
global___FingerprintDef = FingerprintDef
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,11 +13,11 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GraphDebugInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FileLineCol(google.protobuf.message.Message):
|
||||
"""This represents a file/line location in the source code."""
|
||||
|
||||
@@ -48,9 +49,9 @@ class GraphDebugInfo(google.protobuf.message.Message):
|
||||
func: builtins.str | None = ...,
|
||||
code: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["code", b"code", "col", b"col", "file_index", b"file_index", "func", b"func", "line", b"line"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["code", b"code", "col", b"col", "file_index", b"file_index", "func", b"func", "line", b"line"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class StackTrace(google.protobuf.message.Message):
|
||||
"""This represents a stack trace which is a ordered list of `FileLineCol`."""
|
||||
|
||||
@@ -60,14 +61,15 @@ class GraphDebugInfo(google.protobuf.message.Message):
|
||||
@property
|
||||
def file_line_cols(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___GraphDebugInfo.FileLineCol]:
|
||||
"""Each line in the stack trace."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
file_line_cols: collections.abc.Iterable[global___GraphDebugInfo.FileLineCol] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["file_line_cols", b"file_line_cols"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["file_line_cols", b"file_line_cols"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TracesEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -82,8 +84,8 @@ class GraphDebugInfo(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___GraphDebugInfo.StackTrace | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
FILES_FIELD_NUMBER: builtins.int
|
||||
TRACES_FIELD_NUMBER: builtins.int
|
||||
@@ -92,6 +94,7 @@ class GraphDebugInfo(google.protobuf.message.Message):
|
||||
"""This stores all the source code file names and can be indexed by the
|
||||
`file_index`.
|
||||
"""
|
||||
|
||||
@property
|
||||
def traces(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, global___GraphDebugInfo.StackTrace]:
|
||||
"""This maps a node name to a stack trace in the source code.
|
||||
@@ -105,12 +108,13 @@ class GraphDebugInfo(google.protobuf.message.Message):
|
||||
It would be preferable to avoid mangling and use a tuple key of (op.name,
|
||||
func_name), but this is not supported with protocol buffers.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
files: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
traces: collections.abc.Mapping[builtins.str, global___GraphDebugInfo.StackTrace] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["files", b"files", "traces", b"traces"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["files", b"files", "traces", b"traces"]) -> None: ...
|
||||
|
||||
global___GraphDebugInfo = GraphDebugInfo
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.any_pb2
|
||||
import google.protobuf.descriptor
|
||||
@@ -20,7 +21,7 @@ import tensorflow.core.protobuf.struct_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MetaGraphDef(google.protobuf.message.Message):
|
||||
"""Protocol buffer containing the following which are necessary to restart
|
||||
training, run inference. It can be used to serialize/de-serialize memory
|
||||
@@ -37,7 +38,7 @@ class MetaGraphDef(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MetaInfoDef(google.protobuf.message.Message):
|
||||
"""Meta information regarding the graph to be exported. To be used by users
|
||||
of this protocol buffer to encode information regarding their meta graph.
|
||||
@@ -45,7 +46,7 @@ class MetaGraphDef(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FunctionAliasesEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -59,7 +60,7 @@ class MetaGraphDef(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
META_GRAPH_VERSION_FIELD_NUMBER: builtins.int
|
||||
STRIPPED_OP_LIST_FIELD_NUMBER: builtins.int
|
||||
@@ -73,25 +74,6 @@ class MetaGraphDef(google.protobuf.message.Message):
|
||||
"""User specified Version string. Can be the name of the model and revision,
|
||||
steps this model has been trained to, etc.
|
||||
"""
|
||||
@property
|
||||
def stripped_op_list(self) -> tensorflow.core.framework.op_def_pb2.OpList:
|
||||
"""A copy of the OpDefs used by the producer of this graph_def.
|
||||
Descriptions and Ops not used in graph_def are stripped out.
|
||||
"""
|
||||
@property
|
||||
def any_info(self) -> google.protobuf.any_pb2.Any:
|
||||
"""A serialized protobuf. Can be the time this meta graph is created, or
|
||||
modified, or name of the model.
|
||||
"""
|
||||
@property
|
||||
def tags(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""User supplied tag(s) on the meta_graph and included graph_def.
|
||||
|
||||
MetaGraphDefs should be tagged with their capabilities or use-cases.
|
||||
Examples: "train", "serve", "gpu", "tpu", etc.
|
||||
These tags enable loaders to access the MetaGraph(s) appropriate for a
|
||||
specific use-case or runtime environment.
|
||||
"""
|
||||
tensorflow_version: builtins.str
|
||||
"""The __version__ string of the tensorflow build used to write this graph.
|
||||
This will be populated by the framework, which will overwrite any user
|
||||
@@ -106,9 +88,32 @@ class MetaGraphDef(google.protobuf.message.Message):
|
||||
"""A flag to denote whether default-valued attrs have been stripped from
|
||||
the nodes in this graph_def.
|
||||
"""
|
||||
@property
|
||||
def stripped_op_list(self) -> tensorflow.core.framework.op_def_pb2.OpList:
|
||||
"""A copy of the OpDefs used by the producer of this graph_def.
|
||||
Descriptions and Ops not used in graph_def are stripped out.
|
||||
"""
|
||||
|
||||
@property
|
||||
def any_info(self) -> google.protobuf.any_pb2.Any:
|
||||
"""A serialized protobuf. Can be the time this meta graph is created, or
|
||||
modified, or name of the model.
|
||||
"""
|
||||
|
||||
@property
|
||||
def tags(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""User supplied tag(s) on the meta_graph and included graph_def.
|
||||
|
||||
MetaGraphDefs should be tagged with their capabilities or use-cases.
|
||||
Examples: "train", "serve", "gpu", "tpu", etc.
|
||||
These tags enable loaders to access the MetaGraph(s) appropriate for a
|
||||
specific use-case or runtime environment.
|
||||
"""
|
||||
|
||||
@property
|
||||
def function_aliases(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]:
|
||||
"""FunctionDef name to aliases mapping."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -121,10 +126,10 @@ class MetaGraphDef(google.protobuf.message.Message):
|
||||
stripped_default_attrs: builtins.bool | None = ...,
|
||||
function_aliases: collections.abc.Mapping[builtins.str, builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["any_info", b"any_info", "stripped_op_list", b"stripped_op_list"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["any_info", b"any_info", "function_aliases", b"function_aliases", "meta_graph_version", b"meta_graph_version", "stripped_default_attrs", b"stripped_default_attrs", "stripped_op_list", b"stripped_op_list", "tags", b"tags", "tensorflow_git_version", b"tensorflow_git_version", "tensorflow_version", b"tensorflow_version"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["any_info", b"any_info", "stripped_op_list", b"stripped_op_list"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["any_info", b"any_info", "function_aliases", b"function_aliases", "meta_graph_version", b"meta_graph_version", "stripped_default_attrs", b"stripped_default_attrs", "stripped_op_list", b"stripped_op_list", "tags", b"tags", "tensorflow_git_version", b"tensorflow_git_version", "tensorflow_version", b"tensorflow_version"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CollectionDefEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -139,10 +144,10 @@ class MetaGraphDef(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___CollectionDef | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SignatureDefEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -157,8 +162,8 @@ class MetaGraphDef(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___SignatureDef | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
META_INFO_DEF_FIELD_NUMBER: builtins.int
|
||||
GRAPH_DEF_FIELD_NUMBER: builtins.int
|
||||
@@ -172,25 +177,31 @@ class MetaGraphDef(google.protobuf.message.Message):
|
||||
@property
|
||||
def graph_def(self) -> tensorflow.core.framework.graph_pb2.GraphDef:
|
||||
"""GraphDef."""
|
||||
|
||||
@property
|
||||
def saver_def(self) -> tensorflow.core.protobuf.saver_pb2.SaverDef:
|
||||
"""SaverDef."""
|
||||
|
||||
@property
|
||||
def collection_def(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, global___CollectionDef]:
|
||||
"""collection_def: Map from collection name to collections.
|
||||
See CollectionDef section for details.
|
||||
"""
|
||||
|
||||
@property
|
||||
def signature_def(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, global___SignatureDef]:
|
||||
"""signature_def: Map from user supplied key for a signature to a single
|
||||
SignatureDef.
|
||||
"""
|
||||
|
||||
@property
|
||||
def asset_file_def(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___AssetFileDef]:
|
||||
"""Asset file def to be used with the defined graph."""
|
||||
|
||||
@property
|
||||
def object_graph_def(self) -> tensorflow.core.protobuf.saved_object_graph_pb2.SavedObjectGraph:
|
||||
"""Extra information about the structure of functions and stateful objects."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -202,12 +213,12 @@ class MetaGraphDef(google.protobuf.message.Message):
|
||||
asset_file_def: collections.abc.Iterable[global___AssetFileDef] | None = ...,
|
||||
object_graph_def: tensorflow.core.protobuf.saved_object_graph_pb2.SavedObjectGraph | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["graph_def", b"graph_def", "meta_info_def", b"meta_info_def", "object_graph_def", b"object_graph_def", "saver_def", b"saver_def"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["asset_file_def", b"asset_file_def", "collection_def", b"collection_def", "graph_def", b"graph_def", "meta_info_def", b"meta_info_def", "object_graph_def", b"object_graph_def", "saver_def", b"saver_def", "signature_def", b"signature_def"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["graph_def", b"graph_def", "meta_info_def", b"meta_info_def", "object_graph_def", b"object_graph_def", "saver_def", b"saver_def"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["asset_file_def", b"asset_file_def", "collection_def", b"collection_def", "graph_def", b"graph_def", "meta_info_def", b"meta_info_def", "object_graph_def", b"object_graph_def", "saver_def", b"saver_def", "signature_def", b"signature_def"]) -> None: ...
|
||||
|
||||
global___MetaGraphDef = MetaGraphDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CollectionDef(google.protobuf.message.Message):
|
||||
"""CollectionDef should cover most collections.
|
||||
To add a user-defined collection, do one of the following:
|
||||
@@ -275,7 +286,7 @@ class CollectionDef(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class NodeList(google.protobuf.message.Message):
|
||||
"""NodeList is used for collecting nodes in graph. For example
|
||||
collection_def {
|
||||
@@ -299,9 +310,9 @@ class CollectionDef(google.protobuf.message.Message):
|
||||
*,
|
||||
value: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BytesList(google.protobuf.message.Message):
|
||||
"""BytesList is used for collecting strings and serialized protobufs. For
|
||||
example:
|
||||
@@ -328,9 +339,9 @@ class CollectionDef(google.protobuf.message.Message):
|
||||
*,
|
||||
value: collections.abc.Iterable[builtins.bytes] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Int64List(google.protobuf.message.Message):
|
||||
"""Int64List is used for collecting int, int64 and long values."""
|
||||
|
||||
@@ -344,9 +355,9 @@ class CollectionDef(google.protobuf.message.Message):
|
||||
*,
|
||||
value: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FloatList(google.protobuf.message.Message):
|
||||
"""FloatList is used for collecting float values."""
|
||||
|
||||
@@ -360,9 +371,9 @@ class CollectionDef(google.protobuf.message.Message):
|
||||
*,
|
||||
value: collections.abc.Iterable[builtins.float] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AnyList(google.protobuf.message.Message):
|
||||
"""AnyList is used for collecting Any protos."""
|
||||
|
||||
@@ -376,7 +387,7 @@ class CollectionDef(google.protobuf.message.Message):
|
||||
*,
|
||||
value: collections.abc.Iterable[google.protobuf.any_pb2.Any] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["value", b"value"]) -> None: ...
|
||||
|
||||
NODE_LIST_FIELD_NUMBER: builtins.int
|
||||
BYTES_LIST_FIELD_NUMBER: builtins.int
|
||||
@@ -402,19 +413,19 @@ class CollectionDef(google.protobuf.message.Message):
|
||||
float_list: global___CollectionDef.FloatList | None = ...,
|
||||
any_list: global___CollectionDef.AnyList | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["any_list", b"any_list", "bytes_list", b"bytes_list", "float_list", b"float_list", "int64_list", b"int64_list", "kind", b"kind", "node_list", b"node_list"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["any_list", b"any_list", "bytes_list", b"bytes_list", "float_list", b"float_list", "int64_list", b"int64_list", "kind", b"kind", "node_list", b"node_list"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["kind", b"kind"]) -> typing_extensions.Literal["node_list", "bytes_list", "int64_list", "float_list", "any_list"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["any_list", b"any_list", "bytes_list", b"bytes_list", "float_list", b"float_list", "int64_list", b"int64_list", "kind", b"kind", "node_list", b"node_list"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["any_list", b"any_list", "bytes_list", b"bytes_list", "float_list", b"float_list", "int64_list", b"int64_list", "kind", b"kind", "node_list", b"node_list"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["kind", b"kind"]) -> typing.Literal["node_list", "bytes_list", "int64_list", "float_list", "any_list"] | None: ...
|
||||
|
||||
global___CollectionDef = CollectionDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TensorInfo(google.protobuf.message.Message):
|
||||
"""Information about a Tensor necessary for feeding or retrieval."""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CooSparse(google.protobuf.message.Message):
|
||||
"""For sparse tensors, The COO encoding stores a triple of values, indices,
|
||||
and shape.
|
||||
@@ -442,9 +453,9 @@ class TensorInfo(google.protobuf.message.Message):
|
||||
indices_tensor_name: builtins.str | None = ...,
|
||||
dense_shape_tensor_name: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dense_shape_tensor_name", b"dense_shape_tensor_name", "indices_tensor_name", b"indices_tensor_name", "values_tensor_name", b"values_tensor_name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["dense_shape_tensor_name", b"dense_shape_tensor_name", "indices_tensor_name", b"indices_tensor_name", "values_tensor_name", b"values_tensor_name"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CompositeTensor(google.protobuf.message.Message):
|
||||
"""Generic encoding for composite tensors."""
|
||||
|
||||
@@ -455,17 +466,19 @@ class TensorInfo(google.protobuf.message.Message):
|
||||
@property
|
||||
def type_spec(self) -> tensorflow.core.protobuf.struct_pb2.TypeSpecProto:
|
||||
"""The serialized TypeSpec for the composite tensor."""
|
||||
|
||||
@property
|
||||
def components(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___TensorInfo]:
|
||||
"""A TensorInfo for each flattened component tensor."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
type_spec: tensorflow.core.protobuf.struct_pb2.TypeSpecProto | None = ...,
|
||||
components: collections.abc.Iterable[global___TensorInfo] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["type_spec", b"type_spec"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["components", b"components", "type_spec", b"type_spec"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["type_spec", b"type_spec"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["components", b"components", "type_spec", b"type_spec"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
COO_SPARSE_FIELD_NUMBER: builtins.int
|
||||
@@ -474,6 +487,7 @@ class TensorInfo(google.protobuf.message.Message):
|
||||
TENSOR_SHAPE_FIELD_NUMBER: builtins.int
|
||||
name: builtins.str
|
||||
"""For dense `Tensor`s, the name of the tensor in the graph."""
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
@property
|
||||
def coo_sparse(self) -> global___TensorInfo.CooSparse:
|
||||
"""There are many possible encodings of sparse matrices
|
||||
@@ -481,16 +495,18 @@ class TensorInfo(google.protobuf.message.Message):
|
||||
uses only the COO encoding. This is supported and documented in the
|
||||
SparseTensor Python class.
|
||||
"""
|
||||
|
||||
@property
|
||||
def composite_tensor(self) -> global___TensorInfo.CompositeTensor:
|
||||
"""Generic encoding for CompositeTensors."""
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
|
||||
@property
|
||||
def tensor_shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto:
|
||||
"""The static shape should be recorded here, to the extent that it can
|
||||
be known in advance. In the case of a SparseTensor, this field describes
|
||||
the logical shape of the represented tensor (aka dense_shape).
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -500,13 +516,13 @@ class TensorInfo(google.protobuf.message.Message):
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType | None = ...,
|
||||
tensor_shape: tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["composite_tensor", b"composite_tensor", "coo_sparse", b"coo_sparse", "encoding", b"encoding", "name", b"name", "tensor_shape", b"tensor_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["composite_tensor", b"composite_tensor", "coo_sparse", b"coo_sparse", "dtype", b"dtype", "encoding", b"encoding", "name", b"name", "tensor_shape", b"tensor_shape"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["encoding", b"encoding"]) -> typing_extensions.Literal["name", "coo_sparse", "composite_tensor"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["composite_tensor", b"composite_tensor", "coo_sparse", b"coo_sparse", "encoding", b"encoding", "name", b"name", "tensor_shape", b"tensor_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["composite_tensor", b"composite_tensor", "coo_sparse", b"coo_sparse", "dtype", b"dtype", "encoding", b"encoding", "name", b"name", "tensor_shape", b"tensor_shape"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["encoding", b"encoding"]) -> typing.Literal["name", "coo_sparse", "composite_tensor"] | None: ...
|
||||
|
||||
global___TensorInfo = TensorInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SignatureDef(google.protobuf.message.Message):
|
||||
"""SignatureDef defines the signature of a computation supported by a TensorFlow
|
||||
graph.
|
||||
@@ -569,7 +585,7 @@ class SignatureDef(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class InputsEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -584,10 +600,10 @@ class SignatureDef(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___TensorInfo | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OutputsEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -602,18 +618,12 @@ class SignatureDef(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___TensorInfo | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
INPUTS_FIELD_NUMBER: builtins.int
|
||||
OUTPUTS_FIELD_NUMBER: builtins.int
|
||||
METHOD_NAME_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def inputs(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, global___TensorInfo]:
|
||||
"""Named input parameters."""
|
||||
@property
|
||||
def outputs(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, global___TensorInfo]:
|
||||
"""Named output parameters."""
|
||||
method_name: builtins.str
|
||||
"""Extensible method_name information enabling third-party users to mark a
|
||||
SignatureDef as supporting a particular method. This enables producers and
|
||||
@@ -624,6 +634,14 @@ class SignatureDef(google.protobuf.message.Message):
|
||||
method_name. This is commonly used to support multi-headed computation,
|
||||
where a single graph computation may return multiple results.
|
||||
"""
|
||||
@property
|
||||
def inputs(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, global___TensorInfo]:
|
||||
"""Named input parameters."""
|
||||
|
||||
@property
|
||||
def outputs(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, global___TensorInfo]:
|
||||
"""Named output parameters."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -631,11 +649,11 @@ class SignatureDef(google.protobuf.message.Message):
|
||||
outputs: collections.abc.Mapping[builtins.str, global___TensorInfo] | None = ...,
|
||||
method_name: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["inputs", b"inputs", "method_name", b"method_name", "outputs", b"outputs"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["inputs", b"inputs", "method_name", b"method_name", "outputs", b"outputs"]) -> None: ...
|
||||
|
||||
global___SignatureDef = SignatureDef
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AssetFileDef(google.protobuf.message.Message):
|
||||
"""An asset file def for a single file or a set of sharded files with the same
|
||||
name.
|
||||
@@ -645,21 +663,22 @@ class AssetFileDef(google.protobuf.message.Message):
|
||||
|
||||
TENSOR_INFO_FIELD_NUMBER: builtins.int
|
||||
FILENAME_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def tensor_info(self) -> global___TensorInfo:
|
||||
"""The tensor to bind the asset filename to."""
|
||||
filename: builtins.str
|
||||
"""The filename within an assets directory. Note: does not include the path
|
||||
prefix, i.e. directories. For an asset at /tmp/path/vocab.txt, the filename
|
||||
would be "vocab.txt".
|
||||
"""
|
||||
@property
|
||||
def tensor_info(self) -> global___TensorInfo:
|
||||
"""The tensor to bind the asset filename to."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
tensor_info: global___TensorInfo | None = ...,
|
||||
filename: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["tensor_info", b"tensor_info"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["filename", b"filename", "tensor_info", b"tensor_info"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["tensor_info", b"tensor_info"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["filename", b"filename", "tensor_info", b"tensor_info"]) -> None: ...
|
||||
|
||||
global___AssetFileDef = AssetFileDef
|
||||
|
||||
@@ -2,8 +2,9 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.message
|
||||
@@ -11,7 +12,7 @@ import tensorflow.core.framework.tensor_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class NamedTensorProto(google.protobuf.message.Message):
|
||||
"""A pair of tensor name and tensor values."""
|
||||
|
||||
@@ -30,13 +31,14 @@ class NamedTensorProto(google.protobuf.message.Message):
|
||||
filled tensor fields (float_val, int_val, etc.) or encoded in a
|
||||
compact form in tensor.tensor_content.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
name: builtins.str | None = ...,
|
||||
tensor: tensorflow.core.framework.tensor_pb2.TensorProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["tensor", b"tensor"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "tensor", b"tensor"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["tensor", b"tensor"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["name", b"name", "tensor", b"tensor"]) -> None: ...
|
||||
|
||||
global___NamedTensorProto = NamedTensorProto
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -13,7 +14,7 @@ import tensorflow.tsl.protobuf.error_codes_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class QueueRunnerDef(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing a QueueRunner."""
|
||||
|
||||
@@ -26,18 +27,20 @@ class QueueRunnerDef(google.protobuf.message.Message):
|
||||
QUEUE_CLOSED_EXCEPTION_TYPES_FIELD_NUMBER: builtins.int
|
||||
queue_name: builtins.str
|
||||
"""Queue name."""
|
||||
@property
|
||||
def enqueue_op_name(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""A list of enqueue operations."""
|
||||
close_op_name: builtins.str
|
||||
"""The operation to run to close the queue."""
|
||||
cancel_op_name: builtins.str
|
||||
"""The operation to run to cancel the queue."""
|
||||
@property
|
||||
def enqueue_op_name(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""A list of enqueue operations."""
|
||||
|
||||
@property
|
||||
def queue_closed_exception_types(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[tensorflow.tsl.protobuf.error_codes_pb2.Code.ValueType]:
|
||||
"""A list of exception types considered to signal a safely closed queue
|
||||
if raised during enqueue operations.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -47,6 +50,6 @@ class QueueRunnerDef(google.protobuf.message.Message):
|
||||
cancel_op_name: builtins.str | None = ...,
|
||||
queue_closed_exception_types: collections.abc.Iterable[tensorflow.tsl.protobuf.error_codes_pb2.Code.ValueType] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cancel_op_name", b"cancel_op_name", "close_op_name", b"close_op_name", "enqueue_op_name", b"enqueue_op_name", "queue_closed_exception_types", b"queue_closed_exception_types", "queue_name", b"queue_name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["cancel_op_name", b"cancel_op_name", "close_op_name", b"close_op_name", "enqueue_op_name", b"enqueue_op_name", "queue_closed_exception_types", b"queue_closed_exception_types", "queue_name", b"queue_name"]) -> None: ...
|
||||
|
||||
global___QueueRunnerDef = QueueRunnerDef
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -14,7 +15,7 @@ import tensorflow.core.framework.types_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ResourceDtypeAndShape(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -29,12 +30,12 @@ class ResourceDtypeAndShape(google.protobuf.message.Message):
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType | None = ...,
|
||||
shape: tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dtype", b"dtype", "shape", b"shape"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["dtype", b"dtype", "shape", b"shape"]) -> None: ...
|
||||
|
||||
global___ResourceDtypeAndShape = ResourceDtypeAndShape
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RemoteTensorHandle(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -61,6 +62,7 @@ class RemoteTensorHandle(google.protobuf.message.Message):
|
||||
@property
|
||||
def resource_dtypes_and_shapes(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ResourceDtypeAndShape]:
|
||||
"""Optional data types and shapes of a remote resource variable."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -71,6 +73,6 @@ class RemoteTensorHandle(google.protobuf.message.Message):
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType | None = ...,
|
||||
resource_dtypes_and_shapes: collections.abc.Iterable[global___ResourceDtypeAndShape] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device", b"device", "dtype", b"dtype", "op_device", b"op_device", "op_id", b"op_id", "output_num", b"output_num", "resource_dtypes_and_shapes", b"resource_dtypes_and_shapes"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["device", b"device", "dtype", b"dtype", "op_device", b"op_device", "op_id", b"op_id", "output_num", b"output_num", "resource_dtypes_and_shapes", b"resource_dtypes_and_shapes"]) -> None: ...
|
||||
|
||||
global___RemoteTensorHandle = RemoteTensorHandle
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -21,7 +22,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AutoParallelOptions(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -35,11 +36,11 @@ class AutoParallelOptions(google.protobuf.message.Message):
|
||||
enable: builtins.bool | None = ...,
|
||||
num_replicas: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["enable", b"enable", "num_replicas", b"num_replicas"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["enable", b"enable", "num_replicas", b"num_replicas"]) -> None: ...
|
||||
|
||||
global___AutoParallelOptions = AutoParallelOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ScopedAllocatorOptions(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -47,16 +48,17 @@ class ScopedAllocatorOptions(google.protobuf.message.Message):
|
||||
@property
|
||||
def enable_op(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""If present, only perform optimization for these ops."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
enable_op: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["enable_op", b"enable_op"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["enable_op", b"enable_op"]) -> None: ...
|
||||
|
||||
global___ScopedAllocatorOptions = ScopedAllocatorOptions
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RewriterConfig(google.protobuf.message.Message):
|
||||
"""Graph rewriting is experimental and subject to change, not covered by any
|
||||
API stability guarantees.
|
||||
@@ -207,13 +209,13 @@ class RewriterConfig(google.protobuf.message.Message):
|
||||
HEURISTICS: RewriterConfig.MemOptType.ValueType # 3
|
||||
"""Use any combination of swapping and recomputation heuristics."""
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CustomGraphOptimizer(google.protobuf.message.Message):
|
||||
"""Message to describe custom graph optimizer and its parameters"""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ParameterMapEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -228,8 +230,8 @@ class RewriterConfig(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: tensorflow.core.framework.attr_value_pb2.AttrValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
PARAMETER_MAP_FIELD_NUMBER: builtins.int
|
||||
@@ -242,7 +244,7 @@ class RewriterConfig(google.protobuf.message.Message):
|
||||
name: builtins.str | None = ...,
|
||||
parameter_map: collections.abc.Mapping[builtins.str, tensorflow.core.framework.attr_value_pb2.AttrValue] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "parameter_map", b"parameter_map"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["name", b"name", "parameter_map", b"parameter_map"]) -> None: ...
|
||||
|
||||
CPU_LAYOUT_CONVERSION_FIELD_NUMBER: builtins.int
|
||||
LAYOUT_OPTIMIZER_FIELD_NUMBER: builtins.int
|
||||
@@ -403,16 +405,17 @@ class RewriterConfig(google.protobuf.message.Message):
|
||||
timing out. If less than or equal to 0 (default value) the optimizer will
|
||||
never time out.
|
||||
"""
|
||||
@property
|
||||
def auto_parallel(self) -> global___AutoParallelOptions:
|
||||
"""Configures AutoParallel optimization passes either through the
|
||||
meta-optimizer or when manually specified through the optimizers field.
|
||||
"""
|
||||
fail_on_optimizer_errors: builtins.bool
|
||||
"""If true, any optimization pass failing will cause the MetaOptimizer to
|
||||
stop with an error. By default - or when set to false, failing passes are
|
||||
skipped silently.
|
||||
"""
|
||||
@property
|
||||
def auto_parallel(self) -> global___AutoParallelOptions:
|
||||
"""Configures AutoParallel optimization passes either through the
|
||||
meta-optimizer or when manually specified through the optimizers field.
|
||||
"""
|
||||
|
||||
@property
|
||||
def scoped_allocator_opts(self) -> global___ScopedAllocatorOptions: ...
|
||||
@property
|
||||
@@ -430,17 +433,21 @@ class RewriterConfig(google.protobuf.message.Message):
|
||||
Custom optimizers (see custom_optimizers) that are not part of this
|
||||
schedule will be run after - in the order that they were specified.
|
||||
"""
|
||||
|
||||
@property
|
||||
def custom_optimizers(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___RewriterConfig.CustomGraphOptimizer]:
|
||||
"""list of CustomGraphOptimizers to apply."""
|
||||
|
||||
@property
|
||||
def inter_optimizer_verifier_config(self) -> tensorflow.core.protobuf.verifier_config_pb2.VerifierConfig:
|
||||
"""VerifierConfig specifying the verifiers to be run after every optimizer."""
|
||||
|
||||
@property
|
||||
def post_optimization_verifier_config(self) -> tensorflow.core.protobuf.verifier_config_pb2.VerifierConfig:
|
||||
"""VerifierConfig specifying the verifiers to be run at the end, after all
|
||||
optimizers have run.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -481,7 +488,7 @@ class RewriterConfig(google.protobuf.message.Message):
|
||||
inter_optimizer_verifier_config: tensorflow.core.protobuf.verifier_config_pb2.VerifierConfig | None = ...,
|
||||
post_optimization_verifier_config: tensorflow.core.protobuf.verifier_config_pb2.VerifierConfig | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["auto_parallel", b"auto_parallel", "inter_optimizer_verifier_config", b"inter_optimizer_verifier_config", "post_optimization_verifier_config", b"post_optimization_verifier_config", "scoped_allocator_opts", b"scoped_allocator_opts"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["arithmetic_optimization", b"arithmetic_optimization", "auto_mixed_precision", b"auto_mixed_precision", "auto_mixed_precision_cpu", b"auto_mixed_precision_cpu", "auto_mixed_precision_mkl", b"auto_mixed_precision_mkl", "auto_mixed_precision_onednn_bfloat16", b"auto_mixed_precision_onednn_bfloat16", "auto_parallel", b"auto_parallel", "common_subgraph_elimination", b"common_subgraph_elimination", "constant_folding", b"constant_folding", "cpu_layout_conversion", b"cpu_layout_conversion", "custom_optimizers", b"custom_optimizers", "debug_stripper", b"debug_stripper", "dependency_optimization", b"dependency_optimization", "disable_meta_optimizer", b"disable_meta_optimizer", "disable_model_pruning", b"disable_model_pruning", "experimental_conditional_code_motion", b"experimental_conditional_code_motion", "experimental_disable_compressed_tensor_optimization", b"experimental_disable_compressed_tensor_optimization", "experimental_disable_folding_quantization_emulation", b"experimental_disable_folding_quantization_emulation", "fail_on_optimizer_errors", b"fail_on_optimizer_errors", "function_optimization", b"function_optimization", "implementation_selector", b"implementation_selector", "inter_optimizer_verifier_config", b"inter_optimizer_verifier_config", "layout_optimizer", b"layout_optimizer", "loop_optimization", b"loop_optimization", "memory_optimization", b"memory_optimization", "memory_optimizer_target_node_name_scope", b"memory_optimizer_target_node_name_scope", "meta_optimizer_iterations", b"meta_optimizer_iterations", "meta_optimizer_timeout_ms", b"meta_optimizer_timeout_ms", "min_graph_nodes", b"min_graph_nodes", "optimizers", b"optimizers", "pin_to_host_optimization", b"pin_to_host_optimization", "post_optimization_verifier_config", b"post_optimization_verifier_config", "remapping", b"remapping", "scoped_allocator_optimization", b"scoped_allocator_optimization", "scoped_allocator_opts", b"scoped_allocator_opts", "shape_optimization", b"shape_optimization", "use_plugin_optimizers", b"use_plugin_optimizers"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["auto_parallel", b"auto_parallel", "inter_optimizer_verifier_config", b"inter_optimizer_verifier_config", "post_optimization_verifier_config", b"post_optimization_verifier_config", "scoped_allocator_opts", b"scoped_allocator_opts"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["arithmetic_optimization", b"arithmetic_optimization", "auto_mixed_precision", b"auto_mixed_precision", "auto_mixed_precision_cpu", b"auto_mixed_precision_cpu", "auto_mixed_precision_mkl", b"auto_mixed_precision_mkl", "auto_mixed_precision_onednn_bfloat16", b"auto_mixed_precision_onednn_bfloat16", "auto_parallel", b"auto_parallel", "common_subgraph_elimination", b"common_subgraph_elimination", "constant_folding", b"constant_folding", "cpu_layout_conversion", b"cpu_layout_conversion", "custom_optimizers", b"custom_optimizers", "debug_stripper", b"debug_stripper", "dependency_optimization", b"dependency_optimization", "disable_meta_optimizer", b"disable_meta_optimizer", "disable_model_pruning", b"disable_model_pruning", "experimental_conditional_code_motion", b"experimental_conditional_code_motion", "experimental_disable_compressed_tensor_optimization", b"experimental_disable_compressed_tensor_optimization", "experimental_disable_folding_quantization_emulation", b"experimental_disable_folding_quantization_emulation", "fail_on_optimizer_errors", b"fail_on_optimizer_errors", "function_optimization", b"function_optimization", "implementation_selector", b"implementation_selector", "inter_optimizer_verifier_config", b"inter_optimizer_verifier_config", "layout_optimizer", b"layout_optimizer", "loop_optimization", b"loop_optimization", "memory_optimization", b"memory_optimization", "memory_optimizer_target_node_name_scope", b"memory_optimizer_target_node_name_scope", "meta_optimizer_iterations", b"meta_optimizer_iterations", "meta_optimizer_timeout_ms", b"meta_optimizer_timeout_ms", "min_graph_nodes", b"min_graph_nodes", "optimizers", b"optimizers", "pin_to_host_optimization", b"pin_to_host_optimization", "post_optimization_verifier_config", b"post_optimization_verifier_config", "remapping", b"remapping", "scoped_allocator_optimization", b"scoped_allocator_optimization", "scoped_allocator_opts", b"scoped_allocator_opts", "shape_optimization", b"shape_optimization", "use_plugin_optimizers", b"use_plugin_optimizers"]) -> None: ...
|
||||
|
||||
global___RewriterConfig = RewriterConfig
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import google.protobuf.descriptor
|
||||
from tensorflow.tsl.protobuf.rpc_options_pb2 import RPCOptions as RPCOptions
|
||||
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -13,7 +14,7 @@ import tensorflow.core.protobuf.meta_graph_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedModel(google.protobuf.message.Message):
|
||||
"""SavedModel is the high level serialization format for TensorFlow Models.
|
||||
See [todo: doc links, similar to session_bundle] for more information.
|
||||
@@ -31,12 +32,13 @@ class SavedModel(google.protobuf.message.Message):
|
||||
@property
|
||||
def meta_graphs(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.protobuf.meta_graph_pb2.MetaGraphDef]:
|
||||
"""One or more MetaGraphs."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
saved_model_schema_version: builtins.int | None = ...,
|
||||
meta_graphs: collections.abc.Iterable[tensorflow.core.protobuf.meta_graph_pb2.MetaGraphDef] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["meta_graphs", b"meta_graphs", "saved_model_schema_version", b"saved_model_schema_version"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["meta_graphs", b"meta_graphs", "saved_model_schema_version", b"saved_model_schema_version"]) -> None: ...
|
||||
|
||||
global___SavedModel = SavedModel
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -26,7 +27,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedObjectGraph(google.protobuf.message.Message):
|
||||
"""SavedObjectGraph shares some structure with TrackableObjectGraph, but
|
||||
SavedObjectGraph belongs to the MetaGraph and contains pointers to functions
|
||||
@@ -36,7 +37,7 @@ class SavedObjectGraph(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ConcreteFunctionsEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -51,8 +52,8 @@ class SavedObjectGraph(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___SavedConcreteFunction | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
NODES_FIELD_NUMBER: builtins.int
|
||||
CONCRETE_FUNCTIONS_FIELD_NUMBER: builtins.int
|
||||
@@ -63,26 +64,28 @@ class SavedObjectGraph(google.protobuf.message.Message):
|
||||
The position of the object in this list indicates its id.
|
||||
Nodes[0] is considered the root node.
|
||||
"""
|
||||
|
||||
@property
|
||||
def concrete_functions(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, global___SavedConcreteFunction]:
|
||||
"""Information about captures and output structures in concrete functions.
|
||||
Referenced from SavedBareConcreteFunction and SavedFunction.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
nodes: collections.abc.Iterable[global___SavedObject] | None = ...,
|
||||
concrete_functions: collections.abc.Mapping[builtins.str, global___SavedConcreteFunction] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["concrete_functions", b"concrete_functions", "nodes", b"nodes"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["concrete_functions", b"concrete_functions", "nodes", b"nodes"]) -> None: ...
|
||||
|
||||
global___SavedObjectGraph = SavedObjectGraph
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedObject(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SaveableObjectsEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -97,8 +100,8 @@ class SavedObject(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___SaveableObject | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
CHILDREN_FIELD_NUMBER: builtins.int
|
||||
DEPENDENCIES_FIELD_NUMBER: builtins.int
|
||||
@@ -115,6 +118,28 @@ class SavedObject(google.protobuf.message.Message):
|
||||
REGISTERED_NAME_FIELD_NUMBER: builtins.int
|
||||
SERIALIZED_USER_PROTO_FIELD_NUMBER: builtins.int
|
||||
REGISTERED_SAVER_FIELD_NUMBER: builtins.int
|
||||
registered_name: builtins.str
|
||||
"""The fields below are filled when the user serializes a registered Trackable
|
||||
class or an object with a registered saver function.
|
||||
|
||||
Registered classes may save additional metadata and supersede the
|
||||
default loading process where nodes are recreated from the proto.
|
||||
If the registered class cannot be found, then the object will load as one
|
||||
one of the default trackable objects: Autotrackable (a class similar to
|
||||
tf.Module), tf.function, or tf.Variable.
|
||||
|
||||
Unlike SaveableObjects, which store the functions for saving and restoring
|
||||
from tensors, registered savers allow Trackables to write checkpoint shards
|
||||
directly (e.g. for performance or coordination reasons).
|
||||
*All registered savers must be available when loading the SavedModel.*
|
||||
|
||||
The name of the registered class of the form "{package}.{class_name}".
|
||||
This field is used to search for the registered class at loading time.
|
||||
"""
|
||||
registered_saver: builtins.str
|
||||
"""String name of the registered saver. At most one of `saveable_objects` or
|
||||
`registered_saver` is defined for each SavedObject.
|
||||
"""
|
||||
@property
|
||||
def children(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.protobuf.trackable_object_graph_pb2.TrackableObjectGraph.TrackableObject.ObjectReference]:
|
||||
"""Objects which this object depends on: named edges in the dependency
|
||||
@@ -123,12 +148,14 @@ class SavedObject(google.protobuf.message.Message):
|
||||
Note: All kinds of SavedObject may have children, except
|
||||
"constant" and "captured_tensor".
|
||||
"""
|
||||
|
||||
@property
|
||||
def dependencies(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.protobuf.trackable_object_graph_pb2.TrackableObjectGraph.TrackableObject.ObjectReference]:
|
||||
"""Ordered list of dependencies that must be loaded before this object.
|
||||
SavedModel loads with the bottom-up approach, by first creating all objects
|
||||
(in the order defined by the dependencies), then connecting the edges.
|
||||
"""
|
||||
|
||||
@property
|
||||
def slot_variables(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.protobuf.trackable_object_graph_pb2.TrackableObjectGraph.TrackableObject.SlotVariableReference]:
|
||||
"""Slot variables owned by this object. This describes the three-way
|
||||
@@ -137,6 +164,7 @@ class SavedObject(google.protobuf.message.Message):
|
||||
|
||||
Note: currently only valid if kind == "user_object".
|
||||
"""
|
||||
|
||||
@property
|
||||
def user_object(self) -> global___SavedUserObject: ...
|
||||
@property
|
||||
@@ -160,34 +188,14 @@ class SavedObject(google.protobuf.message.Message):
|
||||
See the comment below for the difference between SaveableObject and
|
||||
registered savers.
|
||||
"""
|
||||
registered_name: builtins.str
|
||||
"""The fields below are filled when the user serializes a registered Trackable
|
||||
class or an object with a registered saver function.
|
||||
|
||||
Registered classes may save additional metadata and supersede the
|
||||
default loading process where nodes are recreated from the proto.
|
||||
If the registered class cannot be found, then the object will load as one
|
||||
one of the default trackable objects: Autotrackable (a class similar to
|
||||
tf.Module), tf.function, or tf.Variable.
|
||||
|
||||
Unlike SaveableObjects, which store the functions for saving and restoring
|
||||
from tensors, registered savers allow Trackables to write checkpoint shards
|
||||
directly (e.g. for performance or coordination reasons).
|
||||
*All registered savers must be available when loading the SavedModel.*
|
||||
|
||||
The name of the registered class of the form "{package}.{class_name}".
|
||||
This field is used to search for the registered class at loading time.
|
||||
"""
|
||||
@property
|
||||
def serialized_user_proto(self) -> google.protobuf.any_pb2.Any:
|
||||
"""The user-generated proto storing metadata for this object, to be passed to
|
||||
the registered classes's _deserialize_from_proto method when this object is
|
||||
loaded from the SavedModel.
|
||||
"""
|
||||
registered_saver: builtins.str
|
||||
"""String name of the registered saver. At most one of `saveable_objects` or
|
||||
`registered_saver` is defined for each SavedObject.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -207,13 +215,13 @@ class SavedObject(google.protobuf.message.Message):
|
||||
serialized_user_proto: google.protobuf.any_pb2.Any | None = ...,
|
||||
registered_saver: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["asset", b"asset", "bare_concrete_function", b"bare_concrete_function", "captured_tensor", b"captured_tensor", "constant", b"constant", "function", b"function", "kind", b"kind", "resource", b"resource", "serialized_user_proto", b"serialized_user_proto", "user_object", b"user_object", "variable", b"variable"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["asset", b"asset", "bare_concrete_function", b"bare_concrete_function", "captured_tensor", b"captured_tensor", "children", b"children", "constant", b"constant", "dependencies", b"dependencies", "function", b"function", "kind", b"kind", "registered_name", b"registered_name", "registered_saver", b"registered_saver", "resource", b"resource", "saveable_objects", b"saveable_objects", "serialized_user_proto", b"serialized_user_proto", "slot_variables", b"slot_variables", "user_object", b"user_object", "variable", b"variable"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["kind", b"kind"]) -> typing_extensions.Literal["user_object", "asset", "function", "variable", "bare_concrete_function", "constant", "resource", "captured_tensor"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["asset", b"asset", "bare_concrete_function", b"bare_concrete_function", "captured_tensor", b"captured_tensor", "constant", b"constant", "function", b"function", "kind", b"kind", "resource", b"resource", "serialized_user_proto", b"serialized_user_proto", "user_object", b"user_object", "variable", b"variable"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["asset", b"asset", "bare_concrete_function", b"bare_concrete_function", "captured_tensor", b"captured_tensor", "children", b"children", "constant", b"constant", "dependencies", b"dependencies", "function", b"function", "kind", b"kind", "registered_name", b"registered_name", "registered_saver", b"registered_saver", "resource", b"resource", "saveable_objects", b"saveable_objects", "serialized_user_proto", b"serialized_user_proto", "slot_variables", b"slot_variables", "user_object", b"user_object", "variable", b"variable"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["kind", b"kind"]) -> typing.Literal["user_object", "asset", "function", "variable", "bare_concrete_function", "constant", "resource", "captured_tensor"] | None: ...
|
||||
|
||||
global___SavedObject = SavedObject
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedUserObject(google.protobuf.message.Message):
|
||||
"""A SavedUserObject is an object (in the object-oriented language of the
|
||||
TensorFlow program) of some user- or framework-defined class other than
|
||||
@@ -230,9 +238,6 @@ class SavedUserObject(google.protobuf.message.Message):
|
||||
METADATA_FIELD_NUMBER: builtins.int
|
||||
identifier: builtins.str
|
||||
"""Corresponds to a registration of the type to use in the loading program."""
|
||||
@property
|
||||
def version(self) -> tensorflow.core.framework.versions_pb2.VersionDef:
|
||||
"""Version information from the producer of this SavedUserObject."""
|
||||
metadata: builtins.str
|
||||
"""Metadata for deserializing this object.
|
||||
|
||||
@@ -240,6 +245,10 @@ class SavedUserObject(google.protobuf.message.Message):
|
||||
field, and its saving and loading code will be updated shortly.
|
||||
Please save your application-specific metadata to a separate file.
|
||||
"""
|
||||
@property
|
||||
def version(self) -> tensorflow.core.framework.versions_pb2.VersionDef:
|
||||
"""Version information from the producer of this SavedUserObject."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -247,12 +256,12 @@ class SavedUserObject(google.protobuf.message.Message):
|
||||
version: tensorflow.core.framework.versions_pb2.VersionDef | None = ...,
|
||||
metadata: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["version", b"version"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["identifier", b"identifier", "metadata", b"metadata", "version", b"version"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["version", b"version"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["identifier", b"identifier", "metadata", b"metadata", "version", b"version"]) -> None: ...
|
||||
|
||||
global___SavedUserObject = SavedUserObject
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedAsset(google.protobuf.message.Message):
|
||||
"""A SavedAsset points to an asset in the MetaGraph.
|
||||
|
||||
@@ -275,11 +284,11 @@ class SavedAsset(google.protobuf.message.Message):
|
||||
*,
|
||||
asset_file_def_index: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["asset_file_def_index", b"asset_file_def_index"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["asset_file_def_index", b"asset_file_def_index"]) -> None: ...
|
||||
|
||||
global___SavedAsset = SavedAsset
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedFunction(google.protobuf.message.Message):
|
||||
"""A function with multiple signatures, possibly with non-Tensor arguments."""
|
||||
|
||||
@@ -297,12 +306,12 @@ class SavedFunction(google.protobuf.message.Message):
|
||||
concrete_functions: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
function_spec: global___FunctionSpec | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["function_spec", b"function_spec"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["concrete_functions", b"concrete_functions", "function_spec", b"function_spec"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["function_spec", b"function_spec"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["concrete_functions", b"concrete_functions", "function_spec", b"function_spec"]) -> None: ...
|
||||
|
||||
global___SavedFunction = SavedFunction
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CapturedTensor(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -318,11 +327,11 @@ class CapturedTensor(google.protobuf.message.Message):
|
||||
name: builtins.str | None = ...,
|
||||
concrete_function: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["concrete_function", b"concrete_function", "name", b"name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["concrete_function", b"concrete_function", "name", b"name"]) -> None: ...
|
||||
|
||||
global___CapturedTensor = CapturedTensor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedConcreteFunction(google.protobuf.message.Message):
|
||||
"""Stores low-level information about a concrete function. Referenced in either
|
||||
a SavedFunction or a SavedBareConcreteFunction.
|
||||
@@ -340,12 +349,14 @@ class SavedConcreteFunction(google.protobuf.message.Message):
|
||||
"""Input in canonicalized form that was received to create this concrete
|
||||
function.
|
||||
"""
|
||||
|
||||
@property
|
||||
def output_signature(self) -> tensorflow.core.protobuf.struct_pb2.StructuredValue:
|
||||
"""Output that was the return value of this function after replacing all
|
||||
Tensors with TensorSpecs. This can be an arbitrary nested function and will
|
||||
be used to reconstruct the full structure from pure tensors.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -353,12 +364,12 @@ class SavedConcreteFunction(google.protobuf.message.Message):
|
||||
canonicalized_input_signature: tensorflow.core.protobuf.struct_pb2.StructuredValue | None = ...,
|
||||
output_signature: tensorflow.core.protobuf.struct_pb2.StructuredValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["canonicalized_input_signature", b"canonicalized_input_signature", "output_signature", b"output_signature"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bound_inputs", b"bound_inputs", "canonicalized_input_signature", b"canonicalized_input_signature", "output_signature", b"output_signature"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["canonicalized_input_signature", b"canonicalized_input_signature", "output_signature", b"output_signature"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["bound_inputs", b"bound_inputs", "canonicalized_input_signature", b"canonicalized_input_signature", "output_signature", b"output_signature"]) -> None: ...
|
||||
|
||||
global___SavedConcreteFunction = SavedConcreteFunction
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedBareConcreteFunction(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -368,11 +379,12 @@ class SavedBareConcreteFunction(google.protobuf.message.Message):
|
||||
FUNCTION_SPEC_FIELD_NUMBER: builtins.int
|
||||
concrete_function_name: builtins.str
|
||||
"""Identifies a SavedConcreteFunction."""
|
||||
allowed_positional_arguments: builtins.int
|
||||
"""The prefix of `argument_keywords` which may be identified by position."""
|
||||
@property
|
||||
def argument_keywords(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""A sequence of unique strings, one per Tensor argument."""
|
||||
allowed_positional_arguments: builtins.int
|
||||
"""The prefix of `argument_keywords` which may be identified by position."""
|
||||
|
||||
@property
|
||||
def function_spec(self) -> global___FunctionSpec:
|
||||
"""The spec of the function that this ConcreteFunction is traced from. This
|
||||
@@ -382,6 +394,7 @@ class SavedBareConcreteFunction(google.protobuf.message.Message):
|
||||
TODO(b/169361281): support calling saved ConcreteFunction with structured
|
||||
inputs in C++ SavedModel API.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -390,12 +403,12 @@ class SavedBareConcreteFunction(google.protobuf.message.Message):
|
||||
allowed_positional_arguments: builtins.int | None = ...,
|
||||
function_spec: global___FunctionSpec | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["function_spec", b"function_spec"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allowed_positional_arguments", b"allowed_positional_arguments", "argument_keywords", b"argument_keywords", "concrete_function_name", b"concrete_function_name", "function_spec", b"function_spec"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["function_spec", b"function_spec"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["allowed_positional_arguments", b"allowed_positional_arguments", "argument_keywords", b"argument_keywords", "concrete_function_name", b"concrete_function_name", "function_spec", b"function_spec"]) -> None: ...
|
||||
|
||||
global___SavedBareConcreteFunction = SavedBareConcreteFunction
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedConstant(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -407,11 +420,11 @@ class SavedConstant(google.protobuf.message.Message):
|
||||
*,
|
||||
operation: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["operation", b"operation"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["operation", b"operation"]) -> None: ...
|
||||
|
||||
global___SavedConstant = SavedConstant
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedVariable(google.protobuf.message.Message):
|
||||
"""Represents a Variable that is initialized by loading the contents from the
|
||||
checkpoint.
|
||||
@@ -428,14 +441,14 @@ class SavedVariable(google.protobuf.message.Message):
|
||||
DEVICE_FIELD_NUMBER: builtins.int
|
||||
EXPERIMENTAL_DISTRIBUTED_VARIABLE_COMPONENTS_FIELD_NUMBER: builtins.int
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto: ...
|
||||
trainable: builtins.bool
|
||||
synchronization: tensorflow.core.framework.variable_pb2.VariableSynchronization.ValueType
|
||||
aggregation: tensorflow.core.framework.variable_pb2.VariableAggregation.ValueType
|
||||
name: builtins.str
|
||||
device: builtins.str
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto: ...
|
||||
@property
|
||||
def experimental_distributed_variable_components(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___SavedVariable]:
|
||||
"""List of component variables for a distributed variable.
|
||||
|
||||
@@ -444,6 +457,7 @@ class SavedVariable(google.protobuf.message.Message):
|
||||
|
||||
This is only supported by experimental loaders at the moment.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -456,12 +470,12 @@ class SavedVariable(google.protobuf.message.Message):
|
||||
device: builtins.str | None = ...,
|
||||
experimental_distributed_variable_components: collections.abc.Iterable[global___SavedVariable] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["aggregation", b"aggregation", "device", b"device", "dtype", b"dtype", "experimental_distributed_variable_components", b"experimental_distributed_variable_components", "name", b"name", "shape", b"shape", "synchronization", b"synchronization", "trainable", b"trainable"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["aggregation", b"aggregation", "device", b"device", "dtype", b"dtype", "experimental_distributed_variable_components", b"experimental_distributed_variable_components", "name", b"name", "shape", b"shape", "synchronization", b"synchronization", "trainable", b"trainable"]) -> None: ...
|
||||
|
||||
global___SavedVariable = SavedVariable
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FunctionSpec(google.protobuf.message.Message):
|
||||
"""Represents `FunctionSpec` used in `Function`. This represents a
|
||||
function that has been wrapped as a TensorFlow `Function`.
|
||||
@@ -498,15 +512,17 @@ class FunctionSpec(google.protobuf.message.Message):
|
||||
IS_METHOD_FIELD_NUMBER: builtins.int
|
||||
INPUT_SIGNATURE_FIELD_NUMBER: builtins.int
|
||||
JIT_COMPILE_FIELD_NUMBER: builtins.int
|
||||
is_method: builtins.bool
|
||||
"""Whether this represents a class method."""
|
||||
jit_compile: global___FunctionSpec.JitCompile.ValueType
|
||||
@property
|
||||
def fullargspec(self) -> tensorflow.core.protobuf.struct_pb2.StructuredValue:
|
||||
"""Full arg spec from inspect.getfullargspec()."""
|
||||
is_method: builtins.bool
|
||||
"""Whether this represents a class method."""
|
||||
|
||||
@property
|
||||
def input_signature(self) -> tensorflow.core.protobuf.struct_pb2.StructuredValue:
|
||||
"""The input signature, if specified."""
|
||||
jit_compile: global___FunctionSpec.JitCompile.ValueType
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -515,12 +531,12 @@ class FunctionSpec(google.protobuf.message.Message):
|
||||
input_signature: tensorflow.core.protobuf.struct_pb2.StructuredValue | None = ...,
|
||||
jit_compile: global___FunctionSpec.JitCompile.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["fullargspec", b"fullargspec", "input_signature", b"input_signature"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["fullargspec", b"fullargspec", "input_signature", b"input_signature", "is_method", b"is_method", "jit_compile", b"jit_compile"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["fullargspec", b"fullargspec", "input_signature", b"input_signature"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["fullargspec", b"fullargspec", "input_signature", b"input_signature", "is_method", b"is_method", "jit_compile", b"jit_compile"]) -> None: ...
|
||||
|
||||
global___FunctionSpec = FunctionSpec
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedResource(google.protobuf.message.Message):
|
||||
"""A SavedResource represents a TF object that holds state during its lifetime.
|
||||
An object of this type can have a reference to a:
|
||||
@@ -540,11 +556,11 @@ class SavedResource(google.protobuf.message.Message):
|
||||
*,
|
||||
device: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device", b"device"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["device", b"device"]) -> None: ...
|
||||
|
||||
global___SavedResource = SavedResource
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SaveableObject(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -561,6 +577,6 @@ class SaveableObject(google.protobuf.message.Message):
|
||||
save_function: builtins.int | None = ...,
|
||||
restore_function: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["restore_function", b"restore_function", "save_function", b"save_function"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["restore_function", b"restore_function", "save_function", b"save_function"]) -> None: ...
|
||||
|
||||
global___SaveableObject = SaveableObject
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import sys
|
||||
import typing
|
||||
@@ -17,7 +18,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SaverDef(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing the configuration of a Saver."""
|
||||
|
||||
@@ -87,6 +88,6 @@ class SaverDef(google.protobuf.message.Message):
|
||||
keep_checkpoint_every_n_hours: builtins.float | None = ...,
|
||||
version: global___SaverDef.CheckpointFormatVersion.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["filename_tensor_name", b"filename_tensor_name", "keep_checkpoint_every_n_hours", b"keep_checkpoint_every_n_hours", "max_to_keep", b"max_to_keep", "restore_op_name", b"restore_op_name", "save_tensor_name", b"save_tensor_name", "sharded", b"sharded", "version", b"version"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["filename_tensor_name", b"filename_tensor_name", "keep_checkpoint_every_n_hours", b"keep_checkpoint_every_n_hours", "max_to_keep", b"max_to_keep", "restore_op_name", b"restore_op_name", "save_tensor_name", b"save_tensor_name", "sharded", b"sharded", "version", b"version"]) -> None: ...
|
||||
|
||||
global___SaverDef = SaverDef
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -13,7 +14,7 @@ import tensorflow.core.protobuf.data_service_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DispatcherConfig(google.protobuf.message.Message):
|
||||
"""Configuration for a tf.data service DispatchServer.
|
||||
Next id: 11
|
||||
@@ -45,13 +46,6 @@ class DispatcherConfig(google.protobuf.message.Message):
|
||||
"""Whether to run in fault tolerant mode, where dispatcher state is saved
|
||||
across restarts. Requires that `work_dir` is nonempty.
|
||||
"""
|
||||
@property
|
||||
def worker_addresses(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""(Optional.) If the job uses auto-sharding, it needs to specify a fixed list
|
||||
of worker addresses that will register with the dispatcher. The worker
|
||||
addresses should be in the format "host" or "host:port", where "port" is an
|
||||
integer, named port, or %port% to match any port.
|
||||
"""
|
||||
deployment_mode: tensorflow.core.protobuf.data_service_pb2.DeploymentMode.ValueType
|
||||
"""(Optional.) tf.data service deployment mode. Supported values are "REMOTE",
|
||||
"COLOCATED", and "HYBRID". If unspecified, it is assumed to be "REMOTE".
|
||||
@@ -76,6 +70,14 @@ class DispatcherConfig(google.protobuf.message.Message):
|
||||
"""How long to wait for a worker to heartbeat before considering it missing.
|
||||
A value of 0 indicates that the timeout should be left to the runtime.
|
||||
"""
|
||||
@property
|
||||
def worker_addresses(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""(Optional.) If the job uses auto-sharding, it needs to specify a fixed list
|
||||
of worker addresses that will register with the dispatcher. The worker
|
||||
addresses should be in the format "host" or "host:port", where "port" is an
|
||||
integer, named port, or %port% to match any port.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -90,11 +92,11 @@ class DispatcherConfig(google.protobuf.message.Message):
|
||||
client_timeout_ms: builtins.int | None = ...,
|
||||
worker_timeout_ms: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["client_timeout_ms", b"client_timeout_ms", "deployment_mode", b"deployment_mode", "fault_tolerant_mode", b"fault_tolerant_mode", "job_gc_check_interval_ms", b"job_gc_check_interval_ms", "job_gc_timeout_ms", b"job_gc_timeout_ms", "port", b"port", "protocol", b"protocol", "work_dir", b"work_dir", "worker_addresses", b"worker_addresses", "worker_timeout_ms", b"worker_timeout_ms"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["client_timeout_ms", b"client_timeout_ms", "deployment_mode", b"deployment_mode", "fault_tolerant_mode", b"fault_tolerant_mode", "job_gc_check_interval_ms", b"job_gc_check_interval_ms", "job_gc_timeout_ms", b"job_gc_timeout_ms", "port", b"port", "protocol", b"protocol", "work_dir", b"work_dir", "worker_addresses", b"worker_addresses", "worker_timeout_ms", b"worker_timeout_ms"]) -> None: ...
|
||||
|
||||
global___DispatcherConfig = DispatcherConfig
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class WorkerConfig(google.protobuf.message.Message):
|
||||
"""Configuration for a tf.data service WorkerServer.
|
||||
Next id: 12
|
||||
@@ -126,13 +128,6 @@ class WorkerConfig(google.protobuf.message.Message):
|
||||
will be replaced with the worker's bound port. This is useful when the port
|
||||
is set to `0`.
|
||||
"""
|
||||
@property
|
||||
def worker_tags(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Tags attached to the worker. This allows reading from selected workers.
|
||||
For example, by applying a "COLOCATED" tag, tf.data service is able to read
|
||||
from the local tf.data worker if one exists, then from off-TF-host workers,
|
||||
to avoid cross-TF-host reads.
|
||||
"""
|
||||
heartbeat_interval_ms: builtins.int
|
||||
"""How often the worker should heartbeat to the master. A value of 0 indicates
|
||||
that the decision should be left up to the runtime.
|
||||
@@ -158,6 +153,14 @@ class WorkerConfig(google.protobuf.message.Message):
|
||||
process the final requests. This is used to achieve clean shutdown in unit
|
||||
tests.
|
||||
"""
|
||||
@property
|
||||
def worker_tags(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Tags attached to the worker. This allows reading from selected workers.
|
||||
For example, by applying a "COLOCATED" tag, tf.data service is able to read
|
||||
from the local tf.data worker if one exists, then from off-TF-host workers,
|
||||
to avoid cross-TF-host reads.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -173,6 +176,6 @@ class WorkerConfig(google.protobuf.message.Message):
|
||||
cross_trainer_cache_size_bytes: builtins.int | None = ...,
|
||||
shutdown_quiet_period_ms: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cross_trainer_cache_size_bytes", b"cross_trainer_cache_size_bytes", "data_transfer_address", b"data_transfer_address", "data_transfer_protocol", b"data_transfer_protocol", "dispatcher_address", b"dispatcher_address", "dispatcher_timeout_ms", b"dispatcher_timeout_ms", "heartbeat_interval_ms", b"heartbeat_interval_ms", "port", b"port", "protocol", b"protocol", "shutdown_quiet_period_ms", b"shutdown_quiet_period_ms", "worker_address", b"worker_address", "worker_tags", b"worker_tags"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["cross_trainer_cache_size_bytes", b"cross_trainer_cache_size_bytes", "data_transfer_address", b"data_transfer_address", "data_transfer_protocol", b"data_transfer_protocol", "dispatcher_address", b"dispatcher_address", "dispatcher_timeout_ms", b"dispatcher_timeout_ms", "heartbeat_interval_ms", b"heartbeat_interval_ms", "port", b"port", "protocol", b"protocol", "shutdown_quiet_period_ms", b"shutdown_quiet_period_ms", "worker_address", b"worker_address", "worker_tags", b"worker_tags"]) -> None: ...
|
||||
|
||||
global___WorkerConfig = WorkerConfig
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -15,7 +16,7 @@ import tensorflow.core.framework.types_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SnapshotRecord(google.protobuf.message.Message):
|
||||
"""Each SnapshotRecord represents one batch of pre-processed input data. A batch
|
||||
consists of a list of tensors that we encode as TensorProtos. This message
|
||||
@@ -32,11 +33,11 @@ class SnapshotRecord(google.protobuf.message.Message):
|
||||
*,
|
||||
tensor: collections.abc.Iterable[tensorflow.core.framework.tensor_pb2.TensorProto] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["tensor", b"tensor"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["tensor", b"tensor"]) -> None: ...
|
||||
|
||||
global___SnapshotRecord = SnapshotRecord
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SnapshotMetadataRecord(google.protobuf.message.Message):
|
||||
"""This stores the metadata information present in each snapshot record."""
|
||||
|
||||
@@ -59,12 +60,13 @@ class SnapshotMetadataRecord(google.protobuf.message.Message):
|
||||
"""Time when we started creating this snapshot."""
|
||||
version: builtins.int
|
||||
"""Version of the snapshot data file format."""
|
||||
@property
|
||||
def dtype(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[tensorflow.core.framework.types_pb2.DataType.ValueType]:
|
||||
"""A list of tensor dtype corresponding to each element of the snapshot."""
|
||||
num_elements: builtins.int
|
||||
"""The number of elements in the snapshot."""
|
||||
finalized: builtins.bool
|
||||
@property
|
||||
def dtype(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[tensorflow.core.framework.types_pb2.DataType.ValueType]:
|
||||
"""A list of tensor dtype corresponding to each element of the snapshot."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -76,11 +78,11 @@ class SnapshotMetadataRecord(google.protobuf.message.Message):
|
||||
num_elements: builtins.int | None = ...,
|
||||
finalized: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["creation_timestamp", b"creation_timestamp", "dtype", b"dtype", "finalized", b"finalized", "graph_hash", b"graph_hash", "num_elements", b"num_elements", "run_id", b"run_id", "version", b"version"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["creation_timestamp", b"creation_timestamp", "dtype", b"dtype", "finalized", b"finalized", "graph_hash", b"graph_hash", "num_elements", b"num_elements", "run_id", b"run_id", "version", b"version"]) -> None: ...
|
||||
|
||||
global___SnapshotMetadataRecord = SnapshotMetadataRecord
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TensorMetadata(google.protobuf.message.Message):
|
||||
"""Metadata for a single tensor in the Snapshot Record."""
|
||||
|
||||
@@ -88,22 +90,22 @@ class TensorMetadata(google.protobuf.message.Message):
|
||||
|
||||
TENSOR_SHAPE_FIELD_NUMBER: builtins.int
|
||||
TENSOR_SIZE_BYTES_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def tensor_shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto: ...
|
||||
tensor_size_bytes: builtins.int
|
||||
"""Number of uncompressed bytes used to store the tensor representation."""
|
||||
@property
|
||||
def tensor_shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto: ...
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
tensor_shape: tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto | None = ...,
|
||||
tensor_size_bytes: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["tensor_shape", b"tensor_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["tensor_shape", b"tensor_shape", "tensor_size_bytes", b"tensor_size_bytes"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["tensor_shape", b"tensor_shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["tensor_shape", b"tensor_shape", "tensor_size_bytes", b"tensor_size_bytes"]) -> None: ...
|
||||
|
||||
global___TensorMetadata = TensorMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SnapshotTensorMetadata(google.protobuf.message.Message):
|
||||
"""Metadata for all the tensors in a Snapshot Record."""
|
||||
|
||||
@@ -117,11 +119,11 @@ class SnapshotTensorMetadata(google.protobuf.message.Message):
|
||||
*,
|
||||
tensor_metadata: collections.abc.Iterable[global___TensorMetadata] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["tensor_metadata", b"tensor_metadata"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["tensor_metadata", b"tensor_metadata"]) -> None: ...
|
||||
|
||||
global___SnapshotTensorMetadata = SnapshotTensorMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DistributedSnapshotMetadata(google.protobuf.message.Message):
|
||||
"""Metadata for a `tf.data.Dataset` distributed snapshot."""
|
||||
|
||||
@@ -142,6 +144,6 @@ class DistributedSnapshotMetadata(google.protobuf.message.Message):
|
||||
element_spec: builtins.bytes | None = ...,
|
||||
compression: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["compression", b"compression", "element_spec", b"element_spec"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["compression", b"compression", "element_spec", b"element_spec"]) -> None: ...
|
||||
|
||||
global___DistributedSnapshotMetadata = DistributedSnapshotMetadata
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -22,7 +23,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class StructuredValue(google.protobuf.message.Message):
|
||||
"""`StructuredValue` represents a dynamically typed value representing various
|
||||
data structures that are inspired by Python data structures typically used in
|
||||
@@ -66,9 +67,6 @@ class StructuredValue(google.protobuf.message.Message):
|
||||
TUPLE_VALUE_FIELD_NUMBER: builtins.int
|
||||
DICT_VALUE_FIELD_NUMBER: builtins.int
|
||||
NAMED_TUPLE_VALUE_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def none_value(self) -> global___NoneValue:
|
||||
"""Represents None."""
|
||||
float64_value: builtins.float
|
||||
"""Represents a double-precision floating-point value (a Python `float`)."""
|
||||
int64_value: builtins.int
|
||||
@@ -85,32 +83,44 @@ class StructuredValue(google.protobuf.message.Message):
|
||||
"""
|
||||
bool_value: builtins.bool
|
||||
"""Represents a boolean value."""
|
||||
@property
|
||||
def tensor_shape_value(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto:
|
||||
"""Represents a TensorShape."""
|
||||
tensor_dtype_value: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
"""Represents an enum value for dtype."""
|
||||
@property
|
||||
def none_value(self) -> global___NoneValue:
|
||||
"""Represents None."""
|
||||
|
||||
@property
|
||||
def tensor_shape_value(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto:
|
||||
"""Represents a TensorShape."""
|
||||
|
||||
@property
|
||||
def tensor_spec_value(self) -> global___TensorSpecProto:
|
||||
"""Represents a value for tf.TensorSpec."""
|
||||
|
||||
@property
|
||||
def type_spec_value(self) -> global___TypeSpecProto:
|
||||
"""Represents a value for tf.TypeSpec."""
|
||||
|
||||
@property
|
||||
def bounded_tensor_spec_value(self) -> global___BoundedTensorSpecProto:
|
||||
"""Represents a value for tf.BoundedTensorSpec."""
|
||||
|
||||
@property
|
||||
def list_value(self) -> global___ListValue:
|
||||
"""Represents a list of `Value`."""
|
||||
|
||||
@property
|
||||
def tuple_value(self) -> global___TupleValue:
|
||||
"""Represents a tuple of `Value`."""
|
||||
|
||||
@property
|
||||
def dict_value(self) -> global___DictValue:
|
||||
"""Represents a dict `Value`."""
|
||||
|
||||
@property
|
||||
def named_tuple_value(self) -> global___NamedTupleValue:
|
||||
"""Represents Python's namedtuple."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -129,13 +139,13 @@ class StructuredValue(google.protobuf.message.Message):
|
||||
dict_value: global___DictValue | None = ...,
|
||||
named_tuple_value: global___NamedTupleValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["bool_value", b"bool_value", "bounded_tensor_spec_value", b"bounded_tensor_spec_value", "dict_value", b"dict_value", "float64_value", b"float64_value", "int64_value", b"int64_value", "kind", b"kind", "list_value", b"list_value", "named_tuple_value", b"named_tuple_value", "none_value", b"none_value", "string_value", b"string_value", "tensor_dtype_value", b"tensor_dtype_value", "tensor_shape_value", b"tensor_shape_value", "tensor_spec_value", b"tensor_spec_value", "tuple_value", b"tuple_value", "type_spec_value", b"type_spec_value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bool_value", b"bool_value", "bounded_tensor_spec_value", b"bounded_tensor_spec_value", "dict_value", b"dict_value", "float64_value", b"float64_value", "int64_value", b"int64_value", "kind", b"kind", "list_value", b"list_value", "named_tuple_value", b"named_tuple_value", "none_value", b"none_value", "string_value", b"string_value", "tensor_dtype_value", b"tensor_dtype_value", "tensor_shape_value", b"tensor_shape_value", "tensor_spec_value", b"tensor_spec_value", "tuple_value", b"tuple_value", "type_spec_value", b"type_spec_value"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["kind", b"kind"]) -> typing_extensions.Literal["none_value", "float64_value", "int64_value", "string_value", "bool_value", "tensor_shape_value", "tensor_dtype_value", "tensor_spec_value", "type_spec_value", "bounded_tensor_spec_value", "list_value", "tuple_value", "dict_value", "named_tuple_value"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["bool_value", b"bool_value", "bounded_tensor_spec_value", b"bounded_tensor_spec_value", "dict_value", b"dict_value", "float64_value", b"float64_value", "int64_value", b"int64_value", "kind", b"kind", "list_value", b"list_value", "named_tuple_value", b"named_tuple_value", "none_value", b"none_value", "string_value", b"string_value", "tensor_dtype_value", b"tensor_dtype_value", "tensor_shape_value", b"tensor_shape_value", "tensor_spec_value", b"tensor_spec_value", "tuple_value", b"tuple_value", "type_spec_value", b"type_spec_value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["bool_value", b"bool_value", "bounded_tensor_spec_value", b"bounded_tensor_spec_value", "dict_value", b"dict_value", "float64_value", b"float64_value", "int64_value", b"int64_value", "kind", b"kind", "list_value", b"list_value", "named_tuple_value", b"named_tuple_value", "none_value", b"none_value", "string_value", b"string_value", "tensor_dtype_value", b"tensor_dtype_value", "tensor_shape_value", b"tensor_shape_value", "tensor_spec_value", b"tensor_spec_value", "tuple_value", b"tuple_value", "type_spec_value", b"type_spec_value"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["kind", b"kind"]) -> typing.Literal["none_value", "float64_value", "int64_value", "string_value", "bool_value", "tensor_shape_value", "tensor_dtype_value", "tensor_spec_value", "type_spec_value", "bounded_tensor_spec_value", "list_value", "tuple_value", "dict_value", "named_tuple_value"] | None: ...
|
||||
|
||||
global___StructuredValue = StructuredValue
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class NoneValue(google.protobuf.message.Message):
|
||||
"""Represents None."""
|
||||
|
||||
@@ -147,7 +157,7 @@ class NoneValue(google.protobuf.message.Message):
|
||||
|
||||
global___NoneValue = NoneValue
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ListValue(google.protobuf.message.Message):
|
||||
"""Represents a Python list."""
|
||||
|
||||
@@ -161,11 +171,11 @@ class ListValue(google.protobuf.message.Message):
|
||||
*,
|
||||
values: collections.abc.Iterable[global___StructuredValue] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["values", b"values"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["values", b"values"]) -> None: ...
|
||||
|
||||
global___ListValue = ListValue
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TupleValue(google.protobuf.message.Message):
|
||||
"""Represents a Python tuple."""
|
||||
|
||||
@@ -179,11 +189,11 @@ class TupleValue(google.protobuf.message.Message):
|
||||
*,
|
||||
values: collections.abc.Iterable[global___StructuredValue] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["values", b"values"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["values", b"values"]) -> None: ...
|
||||
|
||||
global___TupleValue = TupleValue
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DictValue(google.protobuf.message.Message):
|
||||
"""Represents a Python dict keyed by `str`.
|
||||
The comment on Unicode from Value.string_value applies analogously.
|
||||
@@ -191,7 +201,7 @@ class DictValue(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FieldsEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -206,8 +216,8 @@ class DictValue(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___StructuredValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
FIELDS_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
@@ -217,11 +227,11 @@ class DictValue(google.protobuf.message.Message):
|
||||
*,
|
||||
fields: collections.abc.Mapping[builtins.str, global___StructuredValue] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["fields", b"fields"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["fields", b"fields"]) -> None: ...
|
||||
|
||||
global___DictValue = DictValue
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class PairValue(google.protobuf.message.Message):
|
||||
"""Represents a (key, value) pair."""
|
||||
|
||||
@@ -238,12 +248,12 @@ class PairValue(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___StructuredValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
global___PairValue = PairValue
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class NamedTupleValue(google.protobuf.message.Message):
|
||||
"""Represents Python's namedtuple."""
|
||||
|
||||
@@ -260,11 +270,11 @@ class NamedTupleValue(google.protobuf.message.Message):
|
||||
name: builtins.str | None = ...,
|
||||
values: collections.abc.Iterable[global___PairValue] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "values", b"values"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["name", b"name", "values", b"values"]) -> None: ...
|
||||
|
||||
global___NamedTupleValue = NamedTupleValue
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TensorSpecProto(google.protobuf.message.Message):
|
||||
"""A protobuf to represent tf.TensorSpec."""
|
||||
|
||||
@@ -274,9 +284,9 @@ class TensorSpecProto(google.protobuf.message.Message):
|
||||
SHAPE_FIELD_NUMBER: builtins.int
|
||||
DTYPE_FIELD_NUMBER: builtins.int
|
||||
name: builtins.str
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto: ...
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -284,12 +294,12 @@ class TensorSpecProto(google.protobuf.message.Message):
|
||||
shape: tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto | None = ...,
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dtype", b"dtype", "name", b"name", "shape", b"shape"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["dtype", b"dtype", "name", b"name", "shape", b"shape"]) -> None: ...
|
||||
|
||||
global___TensorSpecProto = TensorSpecProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BoundedTensorSpecProto(google.protobuf.message.Message):
|
||||
"""A protobuf to represent tf.BoundedTensorSpec."""
|
||||
|
||||
@@ -301,9 +311,9 @@ class BoundedTensorSpecProto(google.protobuf.message.Message):
|
||||
MINIMUM_FIELD_NUMBER: builtins.int
|
||||
MAXIMUM_FIELD_NUMBER: builtins.int
|
||||
name: builtins.str
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto: ...
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
@property
|
||||
def minimum(self) -> tensorflow.core.framework.tensor_pb2.TensorProto: ...
|
||||
@property
|
||||
@@ -317,12 +327,12 @@ class BoundedTensorSpecProto(google.protobuf.message.Message):
|
||||
minimum: tensorflow.core.framework.tensor_pb2.TensorProto | None = ...,
|
||||
maximum: tensorflow.core.framework.tensor_pb2.TensorProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["maximum", b"maximum", "minimum", b"minimum", "shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dtype", b"dtype", "maximum", b"maximum", "minimum", b"minimum", "name", b"name", "shape", b"shape"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["maximum", b"maximum", "minimum", b"minimum", "shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["dtype", b"dtype", "maximum", b"maximum", "minimum", b"minimum", "name", b"name", "shape", b"shape"]) -> None: ...
|
||||
|
||||
global___BoundedTensorSpecProto = BoundedTensorSpecProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TypeSpecProto(google.protobuf.message.Message):
|
||||
"""Represents a tf.TypeSpec"""
|
||||
|
||||
@@ -392,9 +402,6 @@ class TypeSpecProto(google.protobuf.message.Message):
|
||||
TYPE_SPEC_CLASS_NAME_FIELD_NUMBER: builtins.int
|
||||
NUM_FLAT_COMPONENTS_FIELD_NUMBER: builtins.int
|
||||
type_spec_class: global___TypeSpecProto.TypeSpecClass.ValueType
|
||||
@property
|
||||
def type_state(self) -> global___StructuredValue:
|
||||
"""The value returned by TypeSpec._serialize()."""
|
||||
type_spec_class_name: builtins.str
|
||||
"""The name of the TypeSpec class.
|
||||
* If type_spec_class == REGISTERED_TYPE_SPEC, the TypeSpec class is
|
||||
@@ -407,6 +414,10 @@ class TypeSpecProto(google.protobuf.message.Message):
|
||||
"""
|
||||
num_flat_components: builtins.int
|
||||
"""The number of flat tensor components required by this TypeSpec."""
|
||||
@property
|
||||
def type_state(self) -> global___StructuredValue:
|
||||
"""The value returned by TypeSpec._serialize()."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -415,7 +426,7 @@ class TypeSpecProto(google.protobuf.message.Message):
|
||||
type_spec_class_name: builtins.str | None = ...,
|
||||
num_flat_components: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["type_state", b"type_state"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["num_flat_components", b"num_flat_components", "type_spec_class", b"type_spec_class", "type_spec_class_name", b"type_spec_class_name", "type_state", b"type_state"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["type_state", b"type_state"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["num_flat_components", b"num_flat_components", "type_spec_class", b"type_spec_class", "type_spec_class_name", b"type_spec_class_name", "type_state", b"type_state"]) -> None: ...
|
||||
|
||||
global___TypeSpecProto = TypeSpecProto
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -23,7 +24,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BundleHeaderProto(google.protobuf.message.Message):
|
||||
"""Protos used in the tensor bundle module (tf/core/util/tensor_bundle/).
|
||||
|
||||
@@ -67,6 +68,7 @@ class BundleHeaderProto(google.protobuf.message.Message):
|
||||
@property
|
||||
def version(self) -> tensorflow.core.framework.versions_pb2.VersionDef:
|
||||
"""Versioning of the tensor bundle format."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -74,12 +76,12 @@ class BundleHeaderProto(google.protobuf.message.Message):
|
||||
endianness: global___BundleHeaderProto.Endianness.ValueType | None = ...,
|
||||
version: tensorflow.core.framework.versions_pb2.VersionDef | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["version", b"version"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["endianness", b"endianness", "num_shards", b"num_shards", "version", b"version"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["version", b"version"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["endianness", b"endianness", "num_shards", b"num_shards", "version", b"version"]) -> None: ...
|
||||
|
||||
global___BundleHeaderProto = BundleHeaderProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BundleEntryProto(google.protobuf.message.Message):
|
||||
"""Describes the metadata related to a checkpointed tensor."""
|
||||
|
||||
@@ -94,8 +96,6 @@ class BundleEntryProto(google.protobuf.message.Message):
|
||||
SLICES_FIELD_NUMBER: builtins.int
|
||||
dtype: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
"""The tensor dtype and shape."""
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto: ...
|
||||
shard_id: builtins.int
|
||||
"""The binary content of the tensor lies in:
|
||||
File "shard_id": bytes [offset, offset + size).
|
||||
@@ -105,6 +105,8 @@ class BundleEntryProto(google.protobuf.message.Message):
|
||||
crc32c: builtins.int
|
||||
"""The CRC32C checksum of the tensor bytes."""
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto: ...
|
||||
@property
|
||||
def slices(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.tensor_slice_pb2.TensorSliceProto]:
|
||||
"""Iff present, this entry represents a partitioned tensor. The previous
|
||||
fields are interpreted as follows:
|
||||
@@ -114,6 +116,7 @@ class BundleEntryProto(google.protobuf.message.Message):
|
||||
These information for each slice can be looked up in their own
|
||||
BundleEntryProto, keyed by each "slice_name".
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -125,7 +128,7 @@ class BundleEntryProto(google.protobuf.message.Message):
|
||||
crc32c: builtins.int | None = ...,
|
||||
slices: collections.abc.Iterable[tensorflow.core.framework.tensor_slice_pb2.TensorSliceProto] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["crc32c", b"crc32c", "dtype", b"dtype", "offset", b"offset", "shape", b"shape", "shard_id", b"shard_id", "size", b"size", "slices", b"slices"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["crc32c", b"crc32c", "dtype", b"dtype", "offset", b"offset", "shape", b"shape", "shard_id", b"shard_id", "size", b"size", "slices", b"slices"]) -> None: ...
|
||||
|
||||
global___BundleEntryProto = BundleEntryProto
|
||||
|
||||
@@ -16,8 +16,9 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
==============================================================================
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.message
|
||||
@@ -27,7 +28,7 @@ import tensorflow.core.protobuf.device_filters_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ServerDef(google.protobuf.message.Message):
|
||||
"""Defines the configuration of a single TensorFlow server."""
|
||||
|
||||
@@ -40,9 +41,6 @@ class ServerDef(google.protobuf.message.Message):
|
||||
PROTOCOL_FIELD_NUMBER: builtins.int
|
||||
PORT_FIELD_NUMBER: builtins.int
|
||||
CLUSTER_DEVICE_FILTERS_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def cluster(self) -> tensorflow.core.protobuf.cluster_pb2.ClusterDef:
|
||||
"""The cluster of which this server is a member."""
|
||||
job_name: builtins.str
|
||||
"""The name of the job of which this server is a member.
|
||||
|
||||
@@ -55,9 +53,6 @@ class ServerDef(google.protobuf.message.Message):
|
||||
NOTE: The `cluster` field must contain a `JobDef` with a matching `name`
|
||||
and a mapping in its `tasks` field for this index.
|
||||
"""
|
||||
@property
|
||||
def default_session_config(self) -> tensorflow.core.protobuf.config_pb2.ConfigProto:
|
||||
"""The default configuration for sessions that run on this server."""
|
||||
protocol: builtins.str
|
||||
"""The protocol to be used by this server.
|
||||
|
||||
@@ -65,11 +60,20 @@ class ServerDef(google.protobuf.message.Message):
|
||||
"""
|
||||
port: builtins.int
|
||||
"""The server port. If not set, then we identify the port from the job_name."""
|
||||
@property
|
||||
def cluster(self) -> tensorflow.core.protobuf.cluster_pb2.ClusterDef:
|
||||
"""The cluster of which this server is a member."""
|
||||
|
||||
@property
|
||||
def default_session_config(self) -> tensorflow.core.protobuf.config_pb2.ConfigProto:
|
||||
"""The default configuration for sessions that run on this server."""
|
||||
|
||||
@property
|
||||
def cluster_device_filters(self) -> tensorflow.core.protobuf.device_filters_pb2.ClusterDeviceFilters:
|
||||
"""Device filters for remote tasks in the cluster.
|
||||
NOTE: This is an experimental feature and only effective in TensorFlow 2.x.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -81,7 +85,7 @@ class ServerDef(google.protobuf.message.Message):
|
||||
port: builtins.int | None = ...,
|
||||
cluster_device_filters: tensorflow.core.protobuf.device_filters_pb2.ClusterDeviceFilters | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["cluster", b"cluster", "cluster_device_filters", b"cluster_device_filters", "default_session_config", b"default_session_config"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cluster", b"cluster", "cluster_device_filters", b"cluster_device_filters", "default_session_config", b"default_session_config", "job_name", b"job_name", "port", b"port", "protocol", b"protocol", "task_index", b"task_index"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["cluster", b"cluster", "cluster_device_filters", b"cluster_device_filters", "default_session_config", b"default_session_config"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["cluster", b"cluster", "cluster_device_filters", b"cluster_device_filters", "default_session_config", b"default_session_config", "job_name", b"job_name", "port", b"port", "protocol", b"protocol", "task_index", b"task_index"]) -> None: ...
|
||||
|
||||
global___ServerDef = ServerDef
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -21,7 +22,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CompilationResultProto(google.protobuf.message.Message):
|
||||
"""Describes the result of a TPU compilation. This is also used as TPU
|
||||
compilation result status payload.
|
||||
@@ -50,10 +51,11 @@ class CompilationResultProto(google.protobuf.message.Message):
|
||||
status_code: tensorflow.tsl.protobuf.error_codes_pb2.Code.ValueType
|
||||
"""The error message, if any, returned during compilation."""
|
||||
status_error_message: builtins.str
|
||||
error_code: global___CompilationResultProto.ErrorCode.ValueType
|
||||
@property
|
||||
def hlo_protos(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.compiler.xla.service.hlo_pb2.HloProto]:
|
||||
"""HLO proto."""
|
||||
error_code: global___CompilationResultProto.ErrorCode.ValueType
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -62,6 +64,6 @@ class CompilationResultProto(google.protobuf.message.Message):
|
||||
hlo_protos: collections.abc.Iterable[tensorflow.compiler.xla.service.hlo_pb2.HloProto] | None = ...,
|
||||
error_code: global___CompilationResultProto.ErrorCode.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["error_code", b"error_code", "hlo_protos", b"hlo_protos", "status_code", b"status_code", "status_error_message", b"status_error_message"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["error_code", b"error_code", "hlo_protos", b"hlo_protos", "status_code", b"status_code", "status_error_message", b"status_error_message"]) -> None: ...
|
||||
|
||||
global___CompilationResultProto = CompilationResultProto
|
||||
|
||||
@@ -2,15 +2,16 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class PaddingMap(google.protobuf.message.Message):
|
||||
"""A mapping between the dynamic shape dimension of an input and the arg that
|
||||
represents the real shape.
|
||||
@@ -36,6 +37,6 @@ class PaddingMap(google.protobuf.message.Message):
|
||||
shape_index: builtins.int | None = ...,
|
||||
padding_arg_index: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["arg_index", b"arg_index", "padding_arg_index", b"padding_arg_index", "shape_index", b"shape_index"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["arg_index", b"arg_index", "padding_arg_index", b"padding_arg_index", "shape_index", b"shape_index"]) -> None: ...
|
||||
|
||||
global___PaddingMap = PaddingMap
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import sys
|
||||
import typing
|
||||
@@ -19,7 +20,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ClippingLimits(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -28,21 +29,23 @@ class ClippingLimits(google.protobuf.message.Message):
|
||||
@property
|
||||
def lower(self) -> google.protobuf.wrappers_pb2.FloatValue:
|
||||
"""-inf if not set"""
|
||||
|
||||
@property
|
||||
def upper(self) -> google.protobuf.wrappers_pb2.FloatValue:
|
||||
"""+inf if not set"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
lower: google.protobuf.wrappers_pb2.FloatValue | None = ...,
|
||||
upper: google.protobuf.wrappers_pb2.FloatValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["lower", b"lower", "upper", b"upper"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["lower", b"lower", "upper", b"upper"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["lower", b"lower", "upper", b"upper"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["lower", b"lower", "upper", b"upper"]) -> None: ...
|
||||
|
||||
global___ClippingLimits = ClippingLimits
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SimulatedQuantization(google.protobuf.message.Message):
|
||||
"""Configuration for simulated quantization; simulated quantization is used to
|
||||
reduce training/serving skew when the serving variables are quantized. The
|
||||
@@ -66,11 +69,12 @@ class SimulatedQuantization(google.protobuf.message.Message):
|
||||
NUM_BUCKETS_FIELD_NUMBER: builtins.int
|
||||
enabled: builtins.bool
|
||||
"""Whether simulated quantization is enabled."""
|
||||
num_buckets: builtins.int
|
||||
"""Number of possible quantized values."""
|
||||
@property
|
||||
def clipping_limits(self) -> global___ClippingLimits:
|
||||
"""Minimum and maximum values of the range used for quantization."""
|
||||
num_buckets: builtins.int
|
||||
"""Number of possible quantized values."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -78,12 +82,12 @@ class SimulatedQuantization(google.protobuf.message.Message):
|
||||
clipping_limits: global___ClippingLimits | None = ...,
|
||||
num_buckets: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["clipping_limits", b"clipping_limits"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["clipping_limits", b"clipping_limits", "enabled", b"enabled", "num_buckets", b"num_buckets"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["clipping_limits", b"clipping_limits"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["clipping_limits", b"clipping_limits", "enabled", b"enabled", "num_buckets", b"num_buckets"]) -> None: ...
|
||||
|
||||
global___SimulatedQuantization = SimulatedQuantization
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DynamicLearningRate(google.protobuf.message.Message):
|
||||
"""Dynamic learning rate specification in the TPUEmbeddingConfiguration. The
|
||||
actual learning rates are provided as a scalar input list to the
|
||||
@@ -127,11 +131,11 @@ class DynamicLearningRate(google.protobuf.message.Message):
|
||||
*,
|
||||
tag: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["tag", b"tag"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["tag", b"tag"]) -> None: ...
|
||||
|
||||
global___DynamicLearningRate = DynamicLearningRate
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class LearningRate(google.protobuf.message.Message):
|
||||
"""Source of learning rate to use."""
|
||||
|
||||
@@ -148,13 +152,13 @@ class LearningRate(google.protobuf.message.Message):
|
||||
constant: builtins.float | None = ...,
|
||||
dynamic: global___DynamicLearningRate | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["constant", b"constant", "dynamic", b"dynamic", "learning_rate", b"learning_rate"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["constant", b"constant", "dynamic", b"dynamic", "learning_rate", b"learning_rate"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["learning_rate", b"learning_rate"]) -> typing_extensions.Literal["constant", "dynamic"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["constant", b"constant", "dynamic", b"dynamic", "learning_rate", b"learning_rate"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["constant", b"constant", "dynamic", b"dynamic", "learning_rate", b"learning_rate"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["learning_rate", b"learning_rate"]) -> typing.Literal["constant", "dynamic"] | None: ...
|
||||
|
||||
global___LearningRate = LearningRate
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AdagradParameters(google.protobuf.message.Message):
|
||||
"""Each optimizer's parameter proto has a link to its documentation and CPU
|
||||
implementation (if available) for user reference.
|
||||
@@ -171,7 +175,7 @@ class AdagradParameters(google.protobuf.message.Message):
|
||||
|
||||
global___AdagradParameters = AdagradParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AdagradMomentumParameters(google.protobuf.message.Message):
|
||||
"""This optimizer combines the Adagrad and Momentum update rules.
|
||||
accum(new) = beta2 == 1.0 ?
|
||||
@@ -212,11 +216,11 @@ class AdagradMomentumParameters(google.protobuf.message.Message):
|
||||
beta2: builtins.float | None = ...,
|
||||
epsilon: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["beta2", b"beta2", "epsilon", b"epsilon", "exponent", b"exponent", "momentum", b"momentum", "use_nesterov", b"use_nesterov"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["beta2", b"beta2", "epsilon", b"epsilon", "exponent", b"exponent", "momentum", b"momentum", "use_nesterov", b"use_nesterov"]) -> None: ...
|
||||
|
||||
global___AdagradMomentumParameters = AdagradMomentumParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BoundedAdagradParameters(google.protobuf.message.Message):
|
||||
"""Algorithm in http://www.jmlr.org/papers/volume12/duchi11a/duchi11a.pdf."""
|
||||
|
||||
@@ -245,11 +249,11 @@ class BoundedAdagradParameters(google.protobuf.message.Message):
|
||||
max_var_update: builtins.float | None = ...,
|
||||
max_accumulator: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["max_accumulator", b"max_accumulator", "max_var_update", b"max_var_update", "update_accumulator_first", b"update_accumulator_first"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["max_accumulator", b"max_accumulator", "max_var_update", b"max_var_update", "update_accumulator_first", b"update_accumulator_first"]) -> None: ...
|
||||
|
||||
global___BoundedAdagradParameters = BoundedAdagradParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class StochasticGradientDescentParameters(google.protobuf.message.Message):
|
||||
"""https://www.tensorflow.org/api_docs/python/tf/keras/optimizers/SGD
|
||||
https://github.com/tensorflow/tensorflow/blob/6b6471f3ffb7f1fefe42d814aa5fb9ab7a535b58/tensorflow/core/kernels/training_ops.cc#L629
|
||||
@@ -263,7 +267,7 @@ class StochasticGradientDescentParameters(google.protobuf.message.Message):
|
||||
|
||||
global___StochasticGradientDescentParameters = StochasticGradientDescentParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FtrlParameters(google.protobuf.message.Message):
|
||||
"""https://www.tensorflow.org/api_docs/python/tf/keras/optimizers/Ftrl
|
||||
https://static.googleusercontent.com/media/research.google.com/en//pubs/archive/41159.pdf
|
||||
@@ -313,11 +317,11 @@ class FtrlParameters(google.protobuf.message.Message):
|
||||
multiply_linear_by_lr: builtins.bool | None = ...,
|
||||
allow_zero_accumulator: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allow_zero_accumulator", b"allow_zero_accumulator", "beta", b"beta", "l1", b"l1", "l2", b"l2", "lr_power", b"lr_power", "multiply_linear_by_lr", b"multiply_linear_by_lr"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["allow_zero_accumulator", b"allow_zero_accumulator", "beta", b"beta", "l1", b"l1", "l2", b"l2", "lr_power", b"lr_power", "multiply_linear_by_lr", b"multiply_linear_by_lr"]) -> None: ...
|
||||
|
||||
global___FtrlParameters = FtrlParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AdamParameters(google.protobuf.message.Message):
|
||||
"""The Adam optimizer does not implement hyper-parameter update due to hardware
|
||||
limitations; use the dynamic learning rate feature instead, setting the
|
||||
@@ -362,11 +366,11 @@ class AdamParameters(google.protobuf.message.Message):
|
||||
use_non_lazy_adam: builtins.bool | None = ...,
|
||||
use_sum_inside_sqrt: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["beta1", b"beta1", "beta2", b"beta2", "epsilon", b"epsilon", "use_non_lazy_adam", b"use_non_lazy_adam", "use_sum_inside_sqrt", b"use_sum_inside_sqrt"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["beta1", b"beta1", "beta2", b"beta2", "epsilon", b"epsilon", "use_non_lazy_adam", b"use_non_lazy_adam", "use_sum_inside_sqrt", b"use_sum_inside_sqrt"]) -> None: ...
|
||||
|
||||
global___AdamParameters = AdamParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MomentumParameters(google.protobuf.message.Message):
|
||||
"""https://www.tensorflow.org/api_docs/python/tf/keras/optimizers/SGD
|
||||
https://github.com/tensorflow/tensorflow/blob/6b6471f3ffb7f1fefe42d814aa5fb9ab7a535b58/tensorflow/core/kernels/training_ops.cc#L3068
|
||||
@@ -384,11 +388,11 @@ class MomentumParameters(google.protobuf.message.Message):
|
||||
momentum: builtins.float | None = ...,
|
||||
use_nesterov: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["momentum", b"momentum", "use_nesterov", b"use_nesterov"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["momentum", b"momentum", "use_nesterov", b"use_nesterov"]) -> None: ...
|
||||
|
||||
global___MomentumParameters = MomentumParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RmsPropParameters(google.protobuf.message.Message):
|
||||
"""https://www.tensorflow.org/api_docs/python/tf/keras/optimizers/RMSprop
|
||||
https://github.com/tensorflow/tensorflow/blob/6b6471f3ffb7f1fefe42d814aa5fb9ab7a535b58/tensorflow/core/kernels/training_ops.cc#L4229
|
||||
@@ -409,11 +413,11 @@ class RmsPropParameters(google.protobuf.message.Message):
|
||||
momentum: builtins.float | None = ...,
|
||||
epsilon: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["epsilon", b"epsilon", "momentum", b"momentum", "rho", b"rho"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["epsilon", b"epsilon", "momentum", b"momentum", "rho", b"rho"]) -> None: ...
|
||||
|
||||
global___RmsPropParameters = RmsPropParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CenteredRmsPropParameters(google.protobuf.message.Message):
|
||||
"""https://www.tensorflow.org/api_docs/python/tf/keras/optimizers/RMSprop
|
||||
https://github.com/tensorflow/tensorflow/blob/6b6471f3ffb7f1fefe42d814aa5fb9ab7a535b58/tensorflow/core/kernels/training_ops.cc#L4358
|
||||
@@ -434,11 +438,11 @@ class CenteredRmsPropParameters(google.protobuf.message.Message):
|
||||
momentum: builtins.float | None = ...,
|
||||
epsilon: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["epsilon", b"epsilon", "momentum", b"momentum", "rho", b"rho"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["epsilon", b"epsilon", "momentum", b"momentum", "rho", b"rho"]) -> None: ...
|
||||
|
||||
global___CenteredRmsPropParameters = CenteredRmsPropParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MdlAdagradLightParameters(google.protobuf.message.Message):
|
||||
"""Variant of algorithm in http://proceedings.mlr.press/v44/shamir15.pdf"""
|
||||
|
||||
@@ -484,11 +488,11 @@ class MdlAdagradLightParameters(google.protobuf.message.Message):
|
||||
hard_limit_min_benefit: builtins.bool | None = ...,
|
||||
mdl_regularize: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["benefit_revisit_scale", b"benefit_revisit_scale", "hard_limit_min_benefit", b"hard_limit_min_benefit", "l2", b"l2", "lr_power", b"lr_power", "max_event_benefit", b"max_event_benefit", "max_total_benefit", b"max_total_benefit", "mdl_benefit_rampup_coeff", b"mdl_benefit_rampup_coeff", "mdl_hard_limit", b"mdl_hard_limit", "mdl_min_weight", b"mdl_min_weight", "mdl_mix_in_margin", b"mdl_mix_in_margin", "mdl_regularize", b"mdl_regularize", "min_servable_mdl_benefit", b"min_servable_mdl_benefit"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["benefit_revisit_scale", b"benefit_revisit_scale", "hard_limit_min_benefit", b"hard_limit_min_benefit", "l2", b"l2", "lr_power", b"lr_power", "max_event_benefit", b"max_event_benefit", "max_total_benefit", b"max_total_benefit", "mdl_benefit_rampup_coeff", b"mdl_benefit_rampup_coeff", "mdl_hard_limit", b"mdl_hard_limit", "mdl_min_weight", b"mdl_min_weight", "mdl_mix_in_margin", b"mdl_mix_in_margin", "mdl_regularize", b"mdl_regularize", "min_servable_mdl_benefit", b"min_servable_mdl_benefit"]) -> None: ...
|
||||
|
||||
global___MdlAdagradLightParameters = MdlAdagradLightParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AdadeltaParameters(google.protobuf.message.Message):
|
||||
"""https://www.tensorflow.org/api_docs/python/tf/keras/optimizers/Adadelta
|
||||
https://github.com/tensorflow/tensorflow/blob/6b6471f3ffb7f1fefe42d814aa5fb9ab7a535b58/tensorflow/core/kernels/training_ops.cc#L933
|
||||
@@ -506,11 +510,11 @@ class AdadeltaParameters(google.protobuf.message.Message):
|
||||
rho: builtins.float | None = ...,
|
||||
epsilon: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["epsilon", b"epsilon", "rho", b"rho"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["epsilon", b"epsilon", "rho", b"rho"]) -> None: ...
|
||||
|
||||
global___AdadeltaParameters = AdadeltaParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ProximalAdagradParameters(google.protobuf.message.Message):
|
||||
"""https://www.tensorflow.org/api_docs/python/tf/compat/v1/train/ProximalAdagradOptimizer
|
||||
https://github.com/tensorflow/tensorflow/blob/6b6471f3ffb7f1fefe42d814aa5fb9ab7a535b58/tensorflow/core/kernels/training_ops.cc#L1961
|
||||
@@ -528,11 +532,11 @@ class ProximalAdagradParameters(google.protobuf.message.Message):
|
||||
l1: builtins.float | None = ...,
|
||||
l2: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["l1", b"l1", "l2", b"l2"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["l1", b"l1", "l2", b"l2"]) -> None: ...
|
||||
|
||||
global___ProximalAdagradParameters = ProximalAdagradParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OnlineYogiParameters(google.protobuf.message.Message):
|
||||
"""The online Yogi optimizer does not implement hyper-parameter update; use the
|
||||
dynamic learning rate feature instead, setting the learning rate to:
|
||||
@@ -563,11 +567,11 @@ class OnlineYogiParameters(google.protobuf.message.Message):
|
||||
l2: builtins.float | None = ...,
|
||||
beta2: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["beta2", b"beta2", "l1", b"l1", "l2", b"l2"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["beta2", b"beta2", "l1", b"l1", "l2", b"l2"]) -> None: ...
|
||||
|
||||
global___OnlineYogiParameters = OnlineYogiParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ProximalYogiParameters(google.protobuf.message.Message):
|
||||
"""The online Yogi optimizer does not implement hyper-parameter update; use the
|
||||
dynamic learning rate feature instead, setting the learning rate to:
|
||||
@@ -606,11 +610,11 @@ class ProximalYogiParameters(google.protobuf.message.Message):
|
||||
beta2: builtins.float | None = ...,
|
||||
epsilon: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["beta1", b"beta1", "beta2", b"beta2", "epsilon", b"epsilon", "l1", b"l1", "l2", b"l2"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["beta1", b"beta1", "beta2", b"beta2", "epsilon", b"epsilon", "l1", b"l1", "l2", b"l2"]) -> None: ...
|
||||
|
||||
global___ProximalYogiParameters = ProximalYogiParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FrequencyEstimatorParameters(google.protobuf.message.Message):
|
||||
"""Estimator for the frequency of updates to a lookup table. It maintains an
|
||||
array (tf.Variable) D, where each element records the average number of
|
||||
@@ -664,11 +668,11 @@ class FrequencyEstimatorParameters(google.protobuf.message.Message):
|
||||
outlier_threshold: builtins.float | None = ...,
|
||||
weight_exponent: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["max_delta", b"max_delta", "outlier_threshold", b"outlier_threshold", "tau", b"tau", "weight_exponent", b"weight_exponent"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["max_delta", b"max_delta", "outlier_threshold", b"outlier_threshold", "tau", b"tau", "weight_exponent", b"weight_exponent"]) -> None: ...
|
||||
|
||||
global___FrequencyEstimatorParameters = FrequencyEstimatorParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class UserDefinedProgramParameters(google.protobuf.message.Message):
|
||||
"""A user-defined optimizer.
|
||||
The contained HLO program must take the following arguments in the following
|
||||
@@ -701,12 +705,12 @@ class UserDefinedProgramParameters(google.protobuf.message.Message):
|
||||
*,
|
||||
program: tensorflow.compiler.xla.service.hlo_pb2.HloModuleProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["program", b"program"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["program", b"program"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["program", b"program"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["program", b"program"]) -> None: ...
|
||||
|
||||
global___UserDefinedProgramParameters = UserDefinedProgramParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AssignParameters(google.protobuf.message.Message):
|
||||
"""Optimizer that just sets the variable to the value of the gradient. To be
|
||||
correct, this requires either gradient accumulation (to sum the values of a
|
||||
@@ -722,7 +726,7 @@ class AssignParameters(google.protobuf.message.Message):
|
||||
|
||||
global___AssignParameters = AssignParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GradientAccumulationStatus(google.protobuf.message.Message):
|
||||
"""Status of using gradient accumulation (doing two passes over the input
|
||||
gradients: one to accumulate them into a temporary array and another to apply
|
||||
@@ -755,7 +759,7 @@ class GradientAccumulationStatus(google.protobuf.message.Message):
|
||||
|
||||
global___GradientAccumulationStatus = GradientAccumulationStatus
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class LowDimensionalPackingStatus(google.protobuf.message.Message):
|
||||
"""Whether to optimize the packing of low-dimensional embedding tables in HBM
|
||||
(high bandwidth memory). TPUs access HBM at 32-byte (8-float) granularity.
|
||||
@@ -832,7 +836,7 @@ class LowDimensionalPackingStatus(google.protobuf.message.Message):
|
||||
|
||||
global___LowDimensionalPackingStatus = LowDimensionalPackingStatus
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HotIdReplicationConfiguration(google.protobuf.message.Message):
|
||||
"""Configuration proto for hot ID optimization. This is an experimental feature
|
||||
that is currently disabled (by default).
|
||||
@@ -870,11 +874,11 @@ class HotIdReplicationConfiguration(google.protobuf.message.Message):
|
||||
*,
|
||||
status: global___HotIdReplicationConfiguration.Status.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["status", b"status"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["status", b"status"]) -> None: ...
|
||||
|
||||
global___HotIdReplicationConfiguration = HotIdReplicationConfiguration
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class OptimizationParameters(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -904,19 +908,6 @@ class OptimizationParameters(google.protobuf.message.Message):
|
||||
FREQUENCY_ESTIMATOR_FIELD_NUMBER: builtins.int
|
||||
USER_DEFINED_PROGRAM_FIELD_NUMBER: builtins.int
|
||||
ASSIGN_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def learning_rate(self) -> global___LearningRate:
|
||||
"""Learning rate used for updating the embedding layer parameters."""
|
||||
@property
|
||||
def clipping_limits(self) -> global___ClippingLimits:
|
||||
"""Limits to which to clip the weight values after the backward pass; not
|
||||
present means no limits are applied.
|
||||
"""
|
||||
@property
|
||||
def gradient_clipping_limits(self) -> global___ClippingLimits:
|
||||
"""Limits to which to clip the backward pass gradient before using it for
|
||||
updates; not present means no limits are applied.
|
||||
"""
|
||||
weight_decay_factor: builtins.float
|
||||
"""Amount of weight decay to apply; see weight_decay_optimizers.py for
|
||||
details. All optimizers except MDL Adagrad Light are supported with this
|
||||
@@ -929,13 +920,6 @@ class OptimizationParameters(google.protobuf.message.Message):
|
||||
before use; this is to match the note in DecoupledWeightDecayExtension in
|
||||
weight_decay_optimizers.py.
|
||||
"""
|
||||
@property
|
||||
def simulated_quantization(self) -> global___SimulatedQuantization:
|
||||
"""Configuration for simulated quantization which is used to reduce
|
||||
training/serving skew when the serving variables are quantized. The same
|
||||
quantization operations are executed during training to minimize
|
||||
differences with serving.
|
||||
"""
|
||||
gradient_accumulation_status: global___GradientAccumulationStatus.Status.ValueType
|
||||
"""Status of using gradient accumulation (doing two passes over the input
|
||||
gradients: one to accumulate them into a temporary array and another to
|
||||
@@ -946,11 +930,36 @@ class OptimizationParameters(google.protobuf.message.Message):
|
||||
whether to optimize the packing of 1-dimensional, 2-dimensional, and
|
||||
4-dimensional embedding tables in memory.
|
||||
"""
|
||||
@property
|
||||
def learning_rate(self) -> global___LearningRate:
|
||||
"""Learning rate used for updating the embedding layer parameters."""
|
||||
|
||||
@property
|
||||
def clipping_limits(self) -> global___ClippingLimits:
|
||||
"""Limits to which to clip the weight values after the backward pass; not
|
||||
present means no limits are applied.
|
||||
"""
|
||||
|
||||
@property
|
||||
def gradient_clipping_limits(self) -> global___ClippingLimits:
|
||||
"""Limits to which to clip the backward pass gradient before using it for
|
||||
updates; not present means no limits are applied.
|
||||
"""
|
||||
|
||||
@property
|
||||
def simulated_quantization(self) -> global___SimulatedQuantization:
|
||||
"""Configuration for simulated quantization which is used to reduce
|
||||
training/serving skew when the serving variables are quantized. The same
|
||||
quantization operations are executed during training to minimize
|
||||
differences with serving.
|
||||
"""
|
||||
|
||||
@property
|
||||
def hot_id_replication_configuration(self) -> global___HotIdReplicationConfiguration:
|
||||
"""Configuration proto for hot ID replication. This is an experimental
|
||||
feature that is currently disabled (by default).
|
||||
"""
|
||||
|
||||
@property
|
||||
def adagrad(self) -> global___AdagradParameters: ...
|
||||
@property
|
||||
@@ -1015,13 +1024,13 @@ class OptimizationParameters(google.protobuf.message.Message):
|
||||
user_defined_program: global___UserDefinedProgramParameters | None = ...,
|
||||
assign: global___AssignParameters | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["adadelta", b"adadelta", "adagrad", b"adagrad", "adagrad_momentum", b"adagrad_momentum", "adam", b"adam", "assign", b"assign", "bounded_adagrad", b"bounded_adagrad", "centered_rms_prop", b"centered_rms_prop", "clipping_limits", b"clipping_limits", "frequency_estimator", b"frequency_estimator", "ftrl", b"ftrl", "gradient_clipping_limits", b"gradient_clipping_limits", "hot_id_replication_configuration", b"hot_id_replication_configuration", "learning_rate", b"learning_rate", "mdl_adagrad_light", b"mdl_adagrad_light", "momentum", b"momentum", "online_yogi", b"online_yogi", "parameters", b"parameters", "proximal_adagrad", b"proximal_adagrad", "proximal_yogi", b"proximal_yogi", "rms_prop", b"rms_prop", "simulated_quantization", b"simulated_quantization", "stochastic_gradient_descent", b"stochastic_gradient_descent", "user_defined_program", b"user_defined_program"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["adadelta", b"adadelta", "adagrad", b"adagrad", "adagrad_momentum", b"adagrad_momentum", "adam", b"adam", "assign", b"assign", "bounded_adagrad", b"bounded_adagrad", "centered_rms_prop", b"centered_rms_prop", "clipping_limits", b"clipping_limits", "frequency_estimator", b"frequency_estimator", "ftrl", b"ftrl", "gradient_accumulation_status", b"gradient_accumulation_status", "gradient_clipping_limits", b"gradient_clipping_limits", "hot_id_replication_configuration", b"hot_id_replication_configuration", "learning_rate", b"learning_rate", "low_dimensional_packing_status", b"low_dimensional_packing_status", "mdl_adagrad_light", b"mdl_adagrad_light", "momentum", b"momentum", "multiply_weight_decay_factor_by_learning_rate", b"multiply_weight_decay_factor_by_learning_rate", "online_yogi", b"online_yogi", "parameters", b"parameters", "proximal_adagrad", b"proximal_adagrad", "proximal_yogi", b"proximal_yogi", "rms_prop", b"rms_prop", "simulated_quantization", b"simulated_quantization", "stochastic_gradient_descent", b"stochastic_gradient_descent", "user_defined_program", b"user_defined_program", "weight_decay_factor", b"weight_decay_factor"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["parameters", b"parameters"]) -> typing_extensions.Literal["adagrad", "adagrad_momentum", "bounded_adagrad", "stochastic_gradient_descent", "ftrl", "adam", "momentum", "rms_prop", "centered_rms_prop", "mdl_adagrad_light", "adadelta", "proximal_adagrad", "online_yogi", "proximal_yogi", "frequency_estimator", "user_defined_program", "assign"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["adadelta", b"adadelta", "adagrad", b"adagrad", "adagrad_momentum", b"adagrad_momentum", "adam", b"adam", "assign", b"assign", "bounded_adagrad", b"bounded_adagrad", "centered_rms_prop", b"centered_rms_prop", "clipping_limits", b"clipping_limits", "frequency_estimator", b"frequency_estimator", "ftrl", b"ftrl", "gradient_clipping_limits", b"gradient_clipping_limits", "hot_id_replication_configuration", b"hot_id_replication_configuration", "learning_rate", b"learning_rate", "mdl_adagrad_light", b"mdl_adagrad_light", "momentum", b"momentum", "online_yogi", b"online_yogi", "parameters", b"parameters", "proximal_adagrad", b"proximal_adagrad", "proximal_yogi", b"proximal_yogi", "rms_prop", b"rms_prop", "simulated_quantization", b"simulated_quantization", "stochastic_gradient_descent", b"stochastic_gradient_descent", "user_defined_program", b"user_defined_program"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["adadelta", b"adadelta", "adagrad", b"adagrad", "adagrad_momentum", b"adagrad_momentum", "adam", b"adam", "assign", b"assign", "bounded_adagrad", b"bounded_adagrad", "centered_rms_prop", b"centered_rms_prop", "clipping_limits", b"clipping_limits", "frequency_estimator", b"frequency_estimator", "ftrl", b"ftrl", "gradient_accumulation_status", b"gradient_accumulation_status", "gradient_clipping_limits", b"gradient_clipping_limits", "hot_id_replication_configuration", b"hot_id_replication_configuration", "learning_rate", b"learning_rate", "low_dimensional_packing_status", b"low_dimensional_packing_status", "mdl_adagrad_light", b"mdl_adagrad_light", "momentum", b"momentum", "multiply_weight_decay_factor_by_learning_rate", b"multiply_weight_decay_factor_by_learning_rate", "online_yogi", b"online_yogi", "parameters", b"parameters", "proximal_adagrad", b"proximal_adagrad", "proximal_yogi", b"proximal_yogi", "rms_prop", b"rms_prop", "simulated_quantization", b"simulated_quantization", "stochastic_gradient_descent", b"stochastic_gradient_descent", "user_defined_program", b"user_defined_program", "weight_decay_factor", b"weight_decay_factor"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["parameters", b"parameters"]) -> typing.Literal["adagrad", "adagrad_momentum", "bounded_adagrad", "stochastic_gradient_descent", "ftrl", "adam", "momentum", "rms_prop", "centered_rms_prop", "mdl_adagrad_light", "adadelta", "proximal_adagrad", "online_yogi", "proximal_yogi", "frequency_estimator", "user_defined_program", "assign"] | None: ...
|
||||
|
||||
global___OptimizationParameters = OptimizationParameters
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class StateVariableSpecification(google.protobuf.message.Message):
|
||||
"""Specification of an optimization algorithm's state variables (both the main
|
||||
value vector and any extra accumulators, etc.). This proto is only used
|
||||
@@ -1030,7 +1039,7 @@ class StateVariableSpecification(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class UserDefined(google.protobuf.message.Message):
|
||||
"""A normal state variable that should be saved and restored in checkpoints
|
||||
and used as an input or output to non-debug TensorFlow ops.
|
||||
@@ -1042,7 +1051,7 @@ class StateVariableSpecification(google.protobuf.message.Message):
|
||||
self,
|
||||
) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FillWithConstant(google.protobuf.message.Message):
|
||||
"""A state variable that should be filled with a constant and normally hidden
|
||||
from users (used for intermediate gradients being accumulated, for
|
||||
@@ -1058,7 +1067,7 @@ class StateVariableSpecification(google.protobuf.message.Message):
|
||||
*,
|
||||
initial_value: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["initial_value", b"initial_value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["initial_value", b"initial_value"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
USER_DEFINED_FIELD_NUMBER: builtins.int
|
||||
@@ -1076,8 +1085,8 @@ class StateVariableSpecification(google.protobuf.message.Message):
|
||||
user_defined: global___StateVariableSpecification.UserDefined | None = ...,
|
||||
fill_with_constant: global___StateVariableSpecification.FillWithConstant | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["fill_with_constant", b"fill_with_constant", "usage", b"usage", "user_defined", b"user_defined"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["fill_with_constant", b"fill_with_constant", "name", b"name", "usage", b"usage", "user_defined", b"user_defined"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["usage", b"usage"]) -> typing_extensions.Literal["user_defined", "fill_with_constant"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["fill_with_constant", b"fill_with_constant", "usage", b"usage", "user_defined", b"user_defined"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["fill_with_constant", b"fill_with_constant", "name", b"name", "usage", b"usage", "user_defined", b"user_defined"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["usage", b"usage"]) -> typing.Literal["user_defined", "fill_with_constant"] | None: ...
|
||||
|
||||
global___StateVariableSpecification = StateVariableSpecification
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -19,7 +20,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TPUHardwareFeature(google.protobuf.message.Message):
|
||||
"""Describes features of a tpu."""
|
||||
|
||||
@@ -67,11 +68,11 @@ class TPUHardwareFeature(google.protobuf.message.Message):
|
||||
*,
|
||||
embedding_feature: global___TPUHardwareFeature.EmbeddingFeature.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["embedding_feature", b"embedding_feature"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["embedding_feature", b"embedding_feature"]) -> None: ...
|
||||
|
||||
global___TPUHardwareFeature = TPUHardwareFeature
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TopologyProto(google.protobuf.message.Message):
|
||||
"""Describes the geometry of a TPU mesh."""
|
||||
|
||||
@@ -82,6 +83,10 @@ class TopologyProto(google.protobuf.message.Message):
|
||||
NUM_TPU_DEVICES_PER_TASK_FIELD_NUMBER: builtins.int
|
||||
DEVICE_COORDINATES_FIELD_NUMBER: builtins.int
|
||||
TPU_HARDWARE_FEATURE_FIELD_NUMBER: builtins.int
|
||||
num_tasks: builtins.int
|
||||
"""Number of TensorFlow tasks in the cluster."""
|
||||
num_tpu_devices_per_task: builtins.int
|
||||
"""Number of TPU devices per task."""
|
||||
@property
|
||||
def mesh_shape(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""The dimensions of the TPU topology, in cores. Typically, this is a 4D
|
||||
@@ -89,10 +94,7 @@ class TopologyProto(google.protobuf.message.Message):
|
||||
chips, and the minor dimension describes the number of cores on a multicore
|
||||
chip.
|
||||
"""
|
||||
num_tasks: builtins.int
|
||||
"""Number of TensorFlow tasks in the cluster."""
|
||||
num_tpu_devices_per_task: builtins.int
|
||||
"""Number of TPU devices per task."""
|
||||
|
||||
@property
|
||||
def device_coordinates(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""A flattened rank 3 int32 array with shape
|
||||
@@ -102,9 +104,11 @@ class TopologyProto(google.protobuf.message.Message):
|
||||
in the TPU mesh topology. Each entry [task, device, axis] gives the
|
||||
`axis`-th coordinate in the topology of a task/device pair.
|
||||
"""
|
||||
|
||||
@property
|
||||
def tpu_hardware_feature(self) -> global___TPUHardwareFeature:
|
||||
"""TPU supported features."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -114,7 +118,7 @@ class TopologyProto(google.protobuf.message.Message):
|
||||
device_coordinates: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
tpu_hardware_feature: global___TPUHardwareFeature | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["tpu_hardware_feature", b"tpu_hardware_feature"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device_coordinates", b"device_coordinates", "mesh_shape", b"mesh_shape", "num_tasks", b"num_tasks", "num_tpu_devices_per_task", b"num_tpu_devices_per_task", "tpu_hardware_feature", b"tpu_hardware_feature"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["tpu_hardware_feature", b"tpu_hardware_feature"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["device_coordinates", b"device_coordinates", "mesh_shape", b"mesh_shape", "num_tasks", b"num_tasks", "num_tpu_devices_per_task", b"num_tpu_devices_per_task", "tpu_hardware_feature", b"tpu_hardware_feature"]) -> None: ...
|
||||
|
||||
global___TopologyProto = TopologyProto
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -20,7 +21,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TPUEmbeddingConfiguration(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -72,7 +73,7 @@ class TPUEmbeddingConfiguration(google.protobuf.message.Message):
|
||||
DIV_DEFAULT: TPUEmbeddingConfiguration.ShardingStrategy.ValueType # 0
|
||||
MOD: TPUEmbeddingConfiguration.ShardingStrategy.ValueType # 1
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TableDescriptor(google.protobuf.message.Message):
|
||||
"""Description of the various embedding tables."""
|
||||
|
||||
@@ -96,6 +97,7 @@ class TPUEmbeddingConfiguration(google.protobuf.message.Message):
|
||||
"""Details of the learning algorithm used to update the embedding
|
||||
parameters.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -105,10 +107,10 @@ class TPUEmbeddingConfiguration(google.protobuf.message.Message):
|
||||
num_features: builtins.int | None = ...,
|
||||
optimization_parameters: tensorflow.core.protobuf.tpu.optimization_parameters_pb2.OptimizationParameters | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["optimization_parameters", b"optimization_parameters"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["dimension", b"dimension", "name", b"name", "num_features", b"num_features", "optimization_parameters", b"optimization_parameters", "vocabulary_size", b"vocabulary_size"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["optimization_parameters", b"optimization_parameters"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["dimension", b"dimension", "name", b"name", "num_features", b"num_features", "optimization_parameters", b"optimization_parameters", "vocabulary_size", b"vocabulary_size"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FeatureDescriptor(google.protobuf.message.Message):
|
||||
"""Description of different input features."""
|
||||
|
||||
@@ -131,6 +133,7 @@ class TPUEmbeddingConfiguration(google.protobuf.message.Message):
|
||||
the reduction axis) and the embedding dimension is d, the output received
|
||||
at the TensorCore will have shape [m, n, k, d].
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -138,9 +141,9 @@ class TPUEmbeddingConfiguration(google.protobuf.message.Message):
|
||||
table_id: builtins.int | None = ...,
|
||||
input_shape: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["input_shape", b"input_shape", "name", b"name", "table_id", b"table_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["input_shape", b"input_shape", "name", b"name", "table_id", b"table_id"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SpmdSharding(google.protobuf.message.Message):
|
||||
"""SPMD (Single Program Multiple Data) sharding configuration for
|
||||
TPUEmbedding. When model parallelism is used on the TensorCore, the number
|
||||
@@ -162,7 +165,7 @@ class TPUEmbeddingConfiguration(google.protobuf.message.Message):
|
||||
enabled: builtins.bool | None = ...,
|
||||
num_cores_per_replica: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["enabled", b"enabled", "num_cores_per_replica", b"num_cores_per_replica"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["enabled", b"enabled", "num_cores_per_replica", b"num_cores_per_replica"]) -> None: ...
|
||||
|
||||
TABLE_DESCRIPTOR_FIELD_NUMBER: builtins.int
|
||||
MODE_FIELD_NUMBER: builtins.int
|
||||
@@ -174,8 +177,6 @@ class TPUEmbeddingConfiguration(google.protobuf.message.Message):
|
||||
PROFILE_DATA_DIRECTORY_FIELD_NUMBER: builtins.int
|
||||
FEATURE_DESCRIPTOR_FIELD_NUMBER: builtins.int
|
||||
SPMD_SHARDING_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def table_descriptor(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___TPUEmbeddingConfiguration.TableDescriptor]: ...
|
||||
mode: global___TPUEmbeddingConfiguration.Mode.ValueType
|
||||
batch_size_per_tensor_core: builtins.int
|
||||
"""Number of samples in each batch of embedding layer activations sent to
|
||||
@@ -231,11 +232,14 @@ class TPUEmbeddingConfiguration(google.protobuf.message.Message):
|
||||
models to reuse embedding lookup statistics.
|
||||
"""
|
||||
@property
|
||||
def table_descriptor(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___TPUEmbeddingConfiguration.TableDescriptor]: ...
|
||||
@property
|
||||
def feature_descriptor(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___TPUEmbeddingConfiguration.FeatureDescriptor]:
|
||||
"""If the feature_descriptor field is populated, the model should NOT populate
|
||||
TableDescriptor.num_features and batch_size_per_tensor_core. These two
|
||||
fields will be auto-populated by the TPUEmbedding rewrite passes.
|
||||
"""
|
||||
|
||||
@property
|
||||
def spmd_sharding(self) -> global___TPUEmbeddingConfiguration.SpmdSharding: ...
|
||||
def __init__(
|
||||
@@ -252,12 +256,12 @@ class TPUEmbeddingConfiguration(google.protobuf.message.Message):
|
||||
feature_descriptor: collections.abc.Iterable[global___TPUEmbeddingConfiguration.FeatureDescriptor] | None = ...,
|
||||
spmd_sharding: global___TPUEmbeddingConfiguration.SpmdSharding | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["spmd_sharding", b"spmd_sharding"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["batch_size_per_tensor_core", b"batch_size_per_tensor_core", "feature_descriptor", b"feature_descriptor", "mode", b"mode", "num_hosts", b"num_hosts", "num_tensor_cores", b"num_tensor_cores", "pipeline_execution_with_tensor_core", b"pipeline_execution_with_tensor_core", "profile_data_directory", b"profile_data_directory", "sharding_strategy", b"sharding_strategy", "spmd_sharding", b"spmd_sharding", "table_descriptor", b"table_descriptor"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["spmd_sharding", b"spmd_sharding"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["batch_size_per_tensor_core", b"batch_size_per_tensor_core", "feature_descriptor", b"feature_descriptor", "mode", b"mode", "num_hosts", b"num_hosts", "num_tensor_cores", b"num_tensor_cores", "pipeline_execution_with_tensor_core", b"pipeline_execution_with_tensor_core", "profile_data_directory", b"profile_data_directory", "sharding_strategy", b"sharding_strategy", "spmd_sharding", b"spmd_sharding", "table_descriptor", b"table_descriptor"]) -> None: ...
|
||||
|
||||
global___TPUEmbeddingConfiguration = TPUEmbeddingConfiguration
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TPUEmbeddingError(google.protobuf.message.Message):
|
||||
"""A placeholder message that is used to define a unique Status payload
|
||||
URL for TPU embedding errors.
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -13,7 +14,7 @@ import google.protobuf.wrappers_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TrackableObjectGraph(google.protobuf.message.Message):
|
||||
"""A TensorBundle addition which saves extra information about the objects which
|
||||
own variables, allowing for more robust checkpoint loading into modified
|
||||
@@ -22,11 +23,11 @@ class TrackableObjectGraph(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TrackableObject(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ObjectReference(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -44,9 +45,9 @@ class TrackableObjectGraph(google.protobuf.message.Message):
|
||||
node_id: builtins.int | None = ...,
|
||||
local_name: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["local_name", b"local_name", "node_id", b"node_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["local_name", b"local_name", "node_id", b"node_id"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SerializedTensor(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -73,9 +74,9 @@ class TrackableObjectGraph(google.protobuf.message.Message):
|
||||
full_name: builtins.str | None = ...,
|
||||
checkpoint_key: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["checkpoint_key", b"checkpoint_key", "full_name", b"full_name", "name", b"name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["checkpoint_key", b"checkpoint_key", "full_name", b"full_name", "name", b"name"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SlotVariableReference(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -99,7 +100,7 @@ class TrackableObjectGraph(google.protobuf.message.Message):
|
||||
slot_name: builtins.str | None = ...,
|
||||
slot_variable_node_id: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["original_variable_node_id", b"original_variable_node_id", "slot_name", b"slot_name", "slot_variable_node_id", b"slot_variable_node_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["original_variable_node_id", b"original_variable_node_id", "slot_name", b"slot_name", "slot_variable_node_id", b"slot_variable_node_id"]) -> None: ...
|
||||
|
||||
CHILDREN_FIELD_NUMBER: builtins.int
|
||||
ATTRIBUTES_FIELD_NUMBER: builtins.int
|
||||
@@ -109,17 +110,21 @@ class TrackableObjectGraph(google.protobuf.message.Message):
|
||||
@property
|
||||
def children(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___TrackableObjectGraph.TrackableObject.ObjectReference]:
|
||||
"""Objects which this object depends on."""
|
||||
|
||||
@property
|
||||
def attributes(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___TrackableObjectGraph.TrackableObject.SerializedTensor]:
|
||||
"""Serialized data specific to this object."""
|
||||
|
||||
@property
|
||||
def slot_variables(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___TrackableObjectGraph.TrackableObject.SlotVariableReference]:
|
||||
"""Slot variables owned by this object."""
|
||||
|
||||
@property
|
||||
def registered_saver(self) -> global___RegisteredSaver:
|
||||
"""The registered saver used to save this object. If this saver is not
|
||||
present when loading the checkpoint, then loading will fail.
|
||||
"""
|
||||
|
||||
@property
|
||||
def has_checkpoint_values(self) -> google.protobuf.wrappers_pb2.BoolValue:
|
||||
"""Whether this object has checkpoint values or descendants with checkpoint
|
||||
@@ -127,6 +132,7 @@ class TrackableObjectGraph(google.protobuf.message.Message):
|
||||
object graph proto when restoring (which also has to traverse the live
|
||||
object graph).
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -136,8 +142,8 @@ class TrackableObjectGraph(google.protobuf.message.Message):
|
||||
registered_saver: global___RegisteredSaver | None = ...,
|
||||
has_checkpoint_values: google.protobuf.wrappers_pb2.BoolValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["has_checkpoint_values", b"has_checkpoint_values", "registered_saver", b"registered_saver"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["attributes", b"attributes", "children", b"children", "has_checkpoint_values", b"has_checkpoint_values", "registered_saver", b"registered_saver", "slot_variables", b"slot_variables"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["has_checkpoint_values", b"has_checkpoint_values", "registered_saver", b"registered_saver"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["attributes", b"attributes", "children", b"children", "has_checkpoint_values", b"has_checkpoint_values", "registered_saver", b"registered_saver", "slot_variables", b"slot_variables"]) -> None: ...
|
||||
|
||||
NODES_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
@@ -147,11 +153,11 @@ class TrackableObjectGraph(google.protobuf.message.Message):
|
||||
*,
|
||||
nodes: collections.abc.Iterable[global___TrackableObjectGraph.TrackableObject] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["nodes", b"nodes"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["nodes", b"nodes"]) -> None: ...
|
||||
|
||||
global___TrackableObjectGraph = TrackableObjectGraph
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RegisteredSaver(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -167,6 +173,6 @@ class RegisteredSaver(google.protobuf.message.Message):
|
||||
name: builtins.str | None = ...,
|
||||
object_name: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "object_name", b"object_name"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["name", b"name", "object_name", b"object_name"]) -> None: ...
|
||||
|
||||
global___RegisteredSaver = RegisteredSaver
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,7 +13,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RecvBufRespExtra(google.protobuf.message.Message):
|
||||
"""Extra data needed on a non-RDMA RecvBufResponse."""
|
||||
|
||||
@@ -26,6 +27,6 @@ class RecvBufRespExtra(google.protobuf.message.Message):
|
||||
*,
|
||||
tensor_content: collections.abc.Iterable[builtins.bytes] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["tensor_content", b"tensor_content"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["tensor_content", b"tensor_content"]) -> None: ...
|
||||
|
||||
global___RecvBufRespExtra = RecvBufRespExtra
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import sys
|
||||
import typing
|
||||
@@ -17,7 +18,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class VerifierConfig(google.protobuf.message.Message):
|
||||
"""The config for graph verifiers."""
|
||||
|
||||
@@ -52,6 +53,6 @@ class VerifierConfig(google.protobuf.message.Message):
|
||||
verification_timeout_in_ms: builtins.int | None = ...,
|
||||
structure_verifier: global___VerifierConfig.Toggle.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["structure_verifier", b"structure_verifier", "verification_timeout_in_ms", b"verification_timeout_in_ms"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["structure_verifier", b"structure_verifier", "verification_timeout_in_ms", b"verification_timeout_in_ms"]) -> None: ...
|
||||
|
||||
global___VerifierConfig = VerifierConfig
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -70,7 +71,7 @@ WAIT_FOR_COORDINATOR: WorkerShutdownMode.ValueType # 2
|
||||
SHUTDOWN_AFTER_TIMEOUT: WorkerShutdownMode.ValueType # 3
|
||||
global___WorkerShutdownMode = WorkerShutdownMode
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class Event(google.protobuf.message.Message):
|
||||
"""Protocol buffer representing an event that happened during
|
||||
the execution of a Brain model.
|
||||
@@ -100,28 +101,33 @@ class Event(google.protobuf.message.Message):
|
||||
"""
|
||||
graph_def: builtins.bytes
|
||||
"""An encoded version of a GraphDef."""
|
||||
meta_graph_def: builtins.bytes
|
||||
"""An encoded version of a MetaGraphDef."""
|
||||
@property
|
||||
def summary(self) -> tensorflow.core.framework.summary_pb2.Summary:
|
||||
"""A summary was generated."""
|
||||
|
||||
@property
|
||||
def log_message(self) -> global___LogMessage:
|
||||
"""The user output a log message. This was theoretically used by the defunct
|
||||
tensorboard_logging module, which has since been removed; this field is
|
||||
now deprecated and should not be used.
|
||||
"""
|
||||
|
||||
@property
|
||||
def session_log(self) -> global___SessionLog:
|
||||
"""The state of the session which can be used for restarting after crashes."""
|
||||
|
||||
@property
|
||||
def tagged_run_metadata(self) -> global___TaggedRunMetadata:
|
||||
"""The metadata returned by running a session.run() call."""
|
||||
meta_graph_def: builtins.bytes
|
||||
"""An encoded version of a MetaGraphDef."""
|
||||
|
||||
@property
|
||||
def source_metadata(self) -> global___SourceMetadata:
|
||||
"""Information of the source that writes the events, this is only logged in
|
||||
the very first event along with the `file_version` field.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -136,13 +142,13 @@ class Event(google.protobuf.message.Message):
|
||||
meta_graph_def: builtins.bytes | None = ...,
|
||||
source_metadata: global___SourceMetadata | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["file_version", b"file_version", "graph_def", b"graph_def", "log_message", b"log_message", "meta_graph_def", b"meta_graph_def", "session_log", b"session_log", "source_metadata", b"source_metadata", "summary", b"summary", "tagged_run_metadata", b"tagged_run_metadata", "what", b"what"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["file_version", b"file_version", "graph_def", b"graph_def", "log_message", b"log_message", "meta_graph_def", b"meta_graph_def", "session_log", b"session_log", "source_metadata", b"source_metadata", "step", b"step", "summary", b"summary", "tagged_run_metadata", b"tagged_run_metadata", "wall_time", b"wall_time", "what", b"what"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["what", b"what"]) -> typing_extensions.Literal["file_version", "graph_def", "summary", "log_message", "session_log", "tagged_run_metadata", "meta_graph_def"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["file_version", b"file_version", "graph_def", b"graph_def", "log_message", b"log_message", "meta_graph_def", b"meta_graph_def", "session_log", b"session_log", "source_metadata", b"source_metadata", "summary", b"summary", "tagged_run_metadata", b"tagged_run_metadata", "what", b"what"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["file_version", b"file_version", "graph_def", b"graph_def", "log_message", b"log_message", "meta_graph_def", b"meta_graph_def", "session_log", b"session_log", "source_metadata", b"source_metadata", "step", b"step", "summary", b"summary", "tagged_run_metadata", b"tagged_run_metadata", "wall_time", b"wall_time", "what", b"what"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["what", b"what"]) -> typing.Literal["file_version", "graph_def", "summary", "log_message", "session_log", "tagged_run_metadata", "meta_graph_def"] | None: ...
|
||||
|
||||
global___Event = Event
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SourceMetadata(google.protobuf.message.Message):
|
||||
"""Holds the information of the source that writes the events."""
|
||||
|
||||
@@ -158,11 +164,11 @@ class SourceMetadata(google.protobuf.message.Message):
|
||||
*,
|
||||
writer: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["writer", b"writer"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["writer", b"writer"]) -> None: ...
|
||||
|
||||
global___SourceMetadata = SourceMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class LogMessage(google.protobuf.message.Message):
|
||||
"""Protocol buffer used for logging messages to the events file.
|
||||
|
||||
@@ -213,11 +219,11 @@ class LogMessage(google.protobuf.message.Message):
|
||||
level: global___LogMessage.Level.ValueType | None = ...,
|
||||
message: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["level", b"level", "message", b"message"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["level", b"level", "message", b"message"]) -> None: ...
|
||||
|
||||
global___LogMessage = LogMessage
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SessionLog(google.protobuf.message.Message):
|
||||
"""Protocol buffer used for logging session state."""
|
||||
|
||||
@@ -254,11 +260,11 @@ class SessionLog(google.protobuf.message.Message):
|
||||
checkpoint_path: builtins.str | None = ...,
|
||||
msg: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["checkpoint_path", b"checkpoint_path", "msg", b"msg", "status", b"status"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["checkpoint_path", b"checkpoint_path", "msg", b"msg", "status", b"status"]) -> None: ...
|
||||
|
||||
global___SessionLog = SessionLog
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TaggedRunMetadata(google.protobuf.message.Message):
|
||||
"""For logging the metadata output for a single session.run() call."""
|
||||
|
||||
@@ -278,11 +284,11 @@ class TaggedRunMetadata(google.protobuf.message.Message):
|
||||
tag: builtins.str | None = ...,
|
||||
run_metadata: builtins.bytes | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["run_metadata", b"run_metadata", "tag", b"tag"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["run_metadata", b"run_metadata", "tag", b"tag"]) -> None: ...
|
||||
|
||||
global___TaggedRunMetadata = TaggedRunMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class WatchdogConfig(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -293,11 +299,11 @@ class WatchdogConfig(google.protobuf.message.Message):
|
||||
*,
|
||||
timeout_ms: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["timeout_ms", b"timeout_ms"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["timeout_ms", b"timeout_ms"]) -> None: ...
|
||||
|
||||
global___WatchdogConfig = WatchdogConfig
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RequestedExitCode(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -308,11 +314,11 @@ class RequestedExitCode(google.protobuf.message.Message):
|
||||
*,
|
||||
exit_code: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["exit_code", b"exit_code"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["exit_code", b"exit_code"]) -> None: ...
|
||||
|
||||
global___RequestedExitCode = RequestedExitCode
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class WorkerHeartbeatRequest(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -331,12 +337,12 @@ class WorkerHeartbeatRequest(google.protobuf.message.Message):
|
||||
watchdog_config: global___WatchdogConfig | None = ...,
|
||||
exit_code: global___RequestedExitCode | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["exit_code", b"exit_code", "watchdog_config", b"watchdog_config"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["exit_code", b"exit_code", "shutdown_mode", b"shutdown_mode", "watchdog_config", b"watchdog_config"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["exit_code", b"exit_code", "watchdog_config", b"watchdog_config"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["exit_code", b"exit_code", "shutdown_mode", b"shutdown_mode", "watchdog_config", b"watchdog_config"]) -> None: ...
|
||||
|
||||
global___WorkerHeartbeatRequest = WorkerHeartbeatRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class WorkerHeartbeatResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -344,9 +350,9 @@ class WorkerHeartbeatResponse(google.protobuf.message.Message):
|
||||
WORKER_LOG_FIELD_NUMBER: builtins.int
|
||||
HOSTNAME_FIELD_NUMBER: builtins.int
|
||||
health_status: global___WorkerHealth.ValueType
|
||||
hostname: builtins.str
|
||||
@property
|
||||
def worker_log(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___Event]: ...
|
||||
hostname: builtins.str
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -354,6 +360,6 @@ class WorkerHeartbeatResponse(google.protobuf.message.Message):
|
||||
worker_log: collections.abc.Iterable[global___Event] | None = ...,
|
||||
hostname: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["health_status", b"health_status", "hostname", b"hostname", "worker_log", b"worker_log"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["health_status", b"health_status", "hostname", b"hostname", "worker_log", b"worker_log"]) -> None: ...
|
||||
|
||||
global___WorkerHeartbeatResponse = WorkerHeartbeatResponse
|
||||
|
||||
@@ -16,9 +16,10 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
==============================================================================
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -26,7 +27,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemmappedFileSystemDirectoryElement(google.protobuf.message.Message):
|
||||
"""A message that describes one region of memmapped file."""
|
||||
|
||||
@@ -45,11 +46,11 @@ class MemmappedFileSystemDirectoryElement(google.protobuf.message.Message):
|
||||
name: builtins.str | None = ...,
|
||||
length: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["length", b"length", "name", b"name", "offset", b"offset"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["length", b"length", "name", b"name", "offset", b"offset"]) -> None: ...
|
||||
|
||||
global___MemmappedFileSystemDirectoryElement = MemmappedFileSystemDirectoryElement
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemmappedFileSystemDirectory(google.protobuf.message.Message):
|
||||
"""A directory of regions in a memmapped file."""
|
||||
|
||||
@@ -63,6 +64,6 @@ class MemmappedFileSystemDirectory(google.protobuf.message.Message):
|
||||
*,
|
||||
element: collections.abc.Iterable[global___MemmappedFileSystemDirectoryElement] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["element", b"element"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["element", b"element"]) -> None: ...
|
||||
|
||||
global___MemmappedFileSystemDirectory = MemmappedFileSystemDirectory
|
||||
|
||||
@@ -15,9 +15,10 @@ ordered code that encodes the name of the tensor and the slice
|
||||
information. The name is also stored in the SaveSlice message for ease of
|
||||
debugging and manual examination.
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -30,7 +31,7 @@ import tensorflow.core.framework.versions_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedSliceMeta(google.protobuf.message.Message):
|
||||
"""Metadata describing the set of slices of the same tensor saved in a
|
||||
checkpoint file.
|
||||
@@ -44,14 +45,16 @@ class SavedSliceMeta(google.protobuf.message.Message):
|
||||
SLICE_FIELD_NUMBER: builtins.int
|
||||
name: builtins.str
|
||||
"""Name of the tensor."""
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto:
|
||||
"""Shape of the tensor"""
|
||||
type: tensorflow.core.framework.types_pb2.DataType.ValueType
|
||||
"""Type of the tensor"""
|
||||
@property
|
||||
def shape(self) -> tensorflow.core.framework.tensor_shape_pb2.TensorShapeProto:
|
||||
"""Shape of the tensor"""
|
||||
|
||||
@property
|
||||
def slice(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[tensorflow.core.framework.tensor_slice_pb2.TensorSliceProto]:
|
||||
"""Explicit list of slices saved in the checkpoint file."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -60,12 +63,12 @@ class SavedSliceMeta(google.protobuf.message.Message):
|
||||
type: tensorflow.core.framework.types_pb2.DataType.ValueType | None = ...,
|
||||
slice: collections.abc.Iterable[tensorflow.core.framework.tensor_slice_pb2.TensorSliceProto] | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "shape", b"shape", "slice", b"slice", "type", b"type"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["shape", b"shape"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["name", b"name", "shape", b"shape", "slice", b"slice", "type", b"type"]) -> None: ...
|
||||
|
||||
global___SavedSliceMeta = SavedSliceMeta
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedTensorSliceMeta(google.protobuf.message.Message):
|
||||
"""Metadata describing the set of tensor slices saved in a checkpoint file.
|
||||
It is always stored at the beginning of each checkpoint file.
|
||||
@@ -78,23 +81,25 @@ class SavedTensorSliceMeta(google.protobuf.message.Message):
|
||||
@property
|
||||
def tensor(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___SavedSliceMeta]:
|
||||
"""Each SavedSliceMeta describes the slices for one tensor."""
|
||||
|
||||
@property
|
||||
def versions(self) -> tensorflow.core.framework.versions_pb2.VersionDef:
|
||||
"""Compatibility version of this checkpoint. See core/public/version.h
|
||||
for version history.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
tensor: collections.abc.Iterable[global___SavedSliceMeta] | None = ...,
|
||||
versions: tensorflow.core.framework.versions_pb2.VersionDef | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["versions", b"versions"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["tensor", b"tensor", "versions", b"versions"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["versions", b"versions"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["tensor", b"tensor", "versions", b"versions"]) -> None: ...
|
||||
|
||||
global___SavedTensorSliceMeta = SavedTensorSliceMeta
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedSlice(google.protobuf.message.Message):
|
||||
"""Saved tensor slice: it stores the name of the tensors, the slice, and the
|
||||
raw data.
|
||||
@@ -114,11 +119,13 @@ class SavedSlice(google.protobuf.message.Message):
|
||||
"""Extent of the slice. Must have one entry for each of the dimension of the
|
||||
tensor that this slice belongs to.
|
||||
"""
|
||||
|
||||
@property
|
||||
def data(self) -> tensorflow.core.framework.tensor_pb2.TensorProto:
|
||||
"""The raw data of the slice is stored as a TensorProto. Only raw data are
|
||||
stored (we don't fill in fields such as dtype or tensor_shape).
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -126,12 +133,12 @@ class SavedSlice(google.protobuf.message.Message):
|
||||
slice: tensorflow.core.framework.tensor_slice_pb2.TensorSliceProto | None = ...,
|
||||
data: tensorflow.core.framework.tensor_pb2.TensorProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["data", b"data", "slice", b"slice"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["data", b"data", "name", b"name", "slice", b"slice"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["data", b"data", "slice", b"slice"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["data", b"data", "name", b"name", "slice", b"slice"]) -> None: ...
|
||||
|
||||
global___SavedSlice = SavedSlice
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedTensorSlices(google.protobuf.message.Message):
|
||||
"""Each record in a v3 checkpoint file is a serialized SavedTensorSlices
|
||||
message.
|
||||
@@ -146,16 +153,18 @@ class SavedTensorSlices(google.protobuf.message.Message):
|
||||
"""This is only present at the first item of each checkpoint file and serves
|
||||
as a table of contents, listing all the tensor slices saved in this file.
|
||||
"""
|
||||
|
||||
@property
|
||||
def data(self) -> global___SavedSlice:
|
||||
"""This exists in all but the first item of each checkpoint file."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
meta: global___SavedTensorSliceMeta | None = ...,
|
||||
data: global___SavedSlice | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["data", b"data", "meta", b"meta"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["data", b"data", "meta", b"meta"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["data", b"data", "meta", b"meta"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["data", b"data", "meta", b"meta"]) -> None: ...
|
||||
|
||||
global___SavedTensorSlices = SavedTensorSlices
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
Protocol messages for describing the results of benchmarks and unit tests."""
|
||||
|
||||
import google.protobuf.descriptor
|
||||
from tensorflow.tsl.protobuf.test_log_pb2 import (
|
||||
AvailableDeviceInfo as AvailableDeviceInfo,
|
||||
|
||||
@@ -5,9 +5,10 @@ This file is a copy of the TensorBoard ProjectorConfig proto.
|
||||
Keep this file in sync with the source proto definition at
|
||||
https://github.com/tensorflow/tensorboard/blob/master/tensorboard/plugins/projector/projector_config.proto
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -15,7 +16,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SpriteMetadata(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -25,17 +26,18 @@ class SpriteMetadata(google.protobuf.message.Message):
|
||||
@property
|
||||
def single_image_dim(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""[width, height] of a single image in the sprite."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
image_path: builtins.str | None = ...,
|
||||
single_image_dim: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["image_path", b"image_path", "single_image_dim", b"single_image_dim"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["image_path", b"image_path", "single_image_dim", b"single_image_dim"]) -> None: ...
|
||||
|
||||
global___SpriteMetadata = SpriteMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class EmbeddingInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -48,17 +50,18 @@ class EmbeddingInfo(google.protobuf.message.Message):
|
||||
tensor_name: builtins.str
|
||||
metadata_path: builtins.str
|
||||
bookmarks_path: builtins.str
|
||||
tensor_path: builtins.str
|
||||
"""Path to the TSV file holding the tensor values. If missing, the tensor
|
||||
is assumed to be stored in the model checkpoint.
|
||||
"""
|
||||
@property
|
||||
def tensor_shape(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Shape of the 2D tensor [N x D]. If missing, it will be inferred from the
|
||||
model checkpoint.
|
||||
"""
|
||||
|
||||
@property
|
||||
def sprite(self) -> global___SpriteMetadata: ...
|
||||
tensor_path: builtins.str
|
||||
"""Path to the TSV file holding the tensor values. If missing, the tensor
|
||||
is assumed to be stored in the model checkpoint.
|
||||
"""
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -69,12 +72,12 @@ class EmbeddingInfo(google.protobuf.message.Message):
|
||||
sprite: global___SpriteMetadata | None = ...,
|
||||
tensor_path: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["sprite", b"sprite"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bookmarks_path", b"bookmarks_path", "metadata_path", b"metadata_path", "sprite", b"sprite", "tensor_name", b"tensor_name", "tensor_path", b"tensor_path", "tensor_shape", b"tensor_shape"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["sprite", b"sprite"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["bookmarks_path", b"bookmarks_path", "metadata_path", b"metadata_path", "sprite", b"sprite", "tensor_name", b"tensor_name", "tensor_path", b"tensor_path", "tensor_shape", b"tensor_shape"]) -> None: ...
|
||||
|
||||
global___EmbeddingInfo = EmbeddingInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ProjectorConfig(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -83,12 +86,12 @@ class ProjectorConfig(google.protobuf.message.Message):
|
||||
MODEL_CHECKPOINT_DIR_FIELD_NUMBER: builtins.int
|
||||
model_checkpoint_path: builtins.str
|
||||
"""Path to the checkpoint file. Use either this or model_checkpoint_dir."""
|
||||
@property
|
||||
def embeddings(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___EmbeddingInfo]: ...
|
||||
model_checkpoint_dir: builtins.str
|
||||
"""Path to the checkpoint directory. The directory will be scanned for the
|
||||
latest checkpoint file.
|
||||
"""
|
||||
@property
|
||||
def embeddings(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___EmbeddingInfo]: ...
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -96,6 +99,6 @@ class ProjectorConfig(google.protobuf.message.Message):
|
||||
embeddings: collections.abc.Iterable[global___EmbeddingInfo] | None = ...,
|
||||
model_checkpoint_dir: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["embeddings", b"embeddings", "model_checkpoint_dir", b"model_checkpoint_dir", "model_checkpoint_path", b"model_checkpoint_path"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["embeddings", b"embeddings", "model_checkpoint_dir", b"model_checkpoint_dir", "model_checkpoint_path", b"model_checkpoint_path"]) -> None: ...
|
||||
|
||||
global___ProjectorConfig = ProjectorConfig
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
Protobuf containing the metadata for each Keras object saved in a SavedModel."""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -13,7 +14,7 @@ import tensorflow.python.keras.protobuf.versions_pb2
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedMetadata(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -23,16 +24,17 @@ class SavedMetadata(google.protobuf.message.Message):
|
||||
"""Nodes represent trackable objects in the SavedModel. The data for every
|
||||
Keras object is stored.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
nodes: collections.abc.Iterable[global___SavedObject] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["nodes", b"nodes"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["nodes", b"nodes"]) -> None: ...
|
||||
|
||||
global___SavedMetadata = SavedMetadata
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SavedObject(google.protobuf.message.Message):
|
||||
"""Metadata of an individual Keras object."""
|
||||
|
||||
@@ -61,6 +63,7 @@ class SavedObject(google.protobuf.message.Message):
|
||||
@property
|
||||
def version(self) -> tensorflow.python.keras.protobuf.versions_pb2.VersionDef:
|
||||
"""Version defined by the code serializing this Keras object."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -70,7 +73,7 @@ class SavedObject(google.protobuf.message.Message):
|
||||
metadata: builtins.str | None = ...,
|
||||
version: tensorflow.python.keras.protobuf.versions_pb2.VersionDef | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["version", b"version"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["identifier", b"identifier", "metadata", b"metadata", "node_id", b"node_id", "node_path", b"node_path", "version", b"version"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["version", b"version"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["identifier", b"identifier", "metadata", b"metadata", "node_id", b"node_id", "node_path", b"node_path", "version", b"version"]) -> None: ...
|
||||
|
||||
global___SavedObject = SavedObject
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,7 +13,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class VersionDef(google.protobuf.message.Message):
|
||||
"""This file is a copy of the TensorFlow Versions proto.
|
||||
Keep this file in sync with the source proto definition at
|
||||
@@ -46,6 +47,7 @@ class VersionDef(google.protobuf.message.Message):
|
||||
@property
|
||||
def bad_consumers(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]:
|
||||
"""Specific consumer versions which are disallowed (e.g. due to bugs)."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -53,6 +55,6 @@ class VersionDef(google.protobuf.message.Message):
|
||||
min_consumer: builtins.int | None = ...,
|
||||
bad_consumers: collections.abc.Iterable[builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bad_consumers", b"bad_consumers", "min_consumer", b"min_consumer", "producer", b"producer"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["bad_consumers", b"bad_consumers", "min_consumer", b"min_consumer", "producer", b"producer"]) -> None: ...
|
||||
|
||||
global___VersionDef = VersionDef
|
||||
|
||||
@@ -7,6 +7,7 @@ operations.
|
||||
They are in proto format because we want to log them structured. They offer
|
||||
tremendous statistical, testing, and debugging value.
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -27,7 +28,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CudnnVersion(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -44,11 +45,11 @@ class CudnnVersion(google.protobuf.message.Message):
|
||||
minor: builtins.int | None = ...,
|
||||
patch: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["major", b"major", "minor", b"minor", "patch", b"patch"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["major", b"major", "minor", b"minor", "patch", b"patch"]) -> None: ...
|
||||
|
||||
global___CudnnVersion = CudnnVersion
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ComputeCapability(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -62,11 +63,11 @@ class ComputeCapability(google.protobuf.message.Message):
|
||||
major: builtins.int | None = ...,
|
||||
minor: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["major", b"major", "minor", b"minor"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["major", b"major", "minor", b"minor"]) -> None: ...
|
||||
|
||||
global___ComputeCapability = ComputeCapability
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AutotuneResult(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -93,7 +94,7 @@ class AutotuneResult(google.protobuf.message.Message):
|
||||
DISQUALIFIED: AutotuneResult.FailureKind.ValueType # 3
|
||||
"""Algorithm was rejected for failing to run or for known bugs."""
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class FailureResult(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -106,6 +107,7 @@ class AutotuneResult(google.protobuf.message.Message):
|
||||
BUFFER_ADDRESS_FIELD_NUMBER: builtins.int
|
||||
kind: global___AutotuneResult.FailureKind.ValueType
|
||||
msg: builtins.str
|
||||
buffer_address: builtins.int
|
||||
@property
|
||||
def reference_conv(self) -> global___AutotuneResult.ConvKey: ...
|
||||
@property
|
||||
@@ -114,7 +116,6 @@ class AutotuneResult(google.protobuf.message.Message):
|
||||
def reference_cuda_conv_plan(self) -> global___AutotuneResult.CudaConvPlanKey: ...
|
||||
@property
|
||||
def reference_algorithm(self) -> tensorflow.tsl.protobuf.dnn_pb2.AlgorithmProto: ...
|
||||
buffer_address: builtins.int
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -126,11 +127,11 @@ class AutotuneResult(google.protobuf.message.Message):
|
||||
reference_algorithm: tensorflow.tsl.protobuf.dnn_pb2.AlgorithmProto | None = ...,
|
||||
buffer_address: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["key", b"key", "reference_algorithm", b"reference_algorithm", "reference_conv", b"reference_conv", "reference_cuda_conv_plan", b"reference_cuda_conv_plan", "reference_gemm", b"reference_gemm"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["buffer_address", b"buffer_address", "key", b"key", "kind", b"kind", "msg", b"msg", "reference_algorithm", b"reference_algorithm", "reference_conv", b"reference_conv", "reference_cuda_conv_plan", b"reference_cuda_conv_plan", "reference_gemm", b"reference_gemm"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["key", b"key"]) -> typing_extensions.Literal["reference_conv", "reference_gemm", "reference_cuda_conv_plan", "reference_algorithm"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["key", b"key", "reference_algorithm", b"reference_algorithm", "reference_conv", b"reference_conv", "reference_cuda_conv_plan", b"reference_cuda_conv_plan", "reference_gemm", b"reference_gemm"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["buffer_address", b"buffer_address", "key", b"key", "kind", b"kind", "msg", b"msg", "reference_algorithm", b"reference_algorithm", "reference_conv", b"reference_conv", "reference_cuda_conv_plan", b"reference_cuda_conv_plan", "reference_gemm", b"reference_gemm"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["key", b"key"]) -> typing.Literal["reference_conv", "reference_gemm", "reference_cuda_conv_plan", "reference_algorithm"] | None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ConvKey(google.protobuf.message.Message):
|
||||
"""Legacy and unused in new data; superseded by AlgorithmProto."""
|
||||
|
||||
@@ -146,9 +147,9 @@ class AutotuneResult(google.protobuf.message.Message):
|
||||
algorithm: builtins.int | None = ...,
|
||||
tensor_ops_enabled: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["algorithm", b"algorithm", "tensor_ops_enabled", b"tensor_ops_enabled"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["algorithm", b"algorithm", "tensor_ops_enabled", b"tensor_ops_enabled"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GemmKey(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -159,9 +160,9 @@ class AutotuneResult(google.protobuf.message.Message):
|
||||
*,
|
||||
algorithm: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["algorithm", b"algorithm"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["algorithm", b"algorithm"]) -> None: ...
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CudaConvPlanKey(google.protobuf.message.Message):
|
||||
"""Legacy and unused in new data; superseded by AlgorithmProto."""
|
||||
|
||||
@@ -174,7 +175,7 @@ class AutotuneResult(google.protobuf.message.Message):
|
||||
*,
|
||||
exec_plan_id: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["exec_plan_id", b"exec_plan_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["exec_plan_id", b"exec_plan_id"]) -> None: ...
|
||||
|
||||
SCRATCH_BYTES_FIELD_NUMBER: builtins.int
|
||||
RUN_TIME_FIELD_NUMBER: builtins.int
|
||||
@@ -207,13 +208,13 @@ class AutotuneResult(google.protobuf.message.Message):
|
||||
cuda_conv_plan: global___AutotuneResult.CudaConvPlanKey | None = ...,
|
||||
algorithm: tensorflow.tsl.protobuf.dnn_pb2.AlgorithmProto | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["algorithm", b"algorithm", "conv", b"conv", "cuda_conv_plan", b"cuda_conv_plan", "failure", b"failure", "gemm", b"gemm", "key", b"key", "run_time", b"run_time"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["algorithm", b"algorithm", "conv", b"conv", "cuda_conv_plan", b"cuda_conv_plan", "failure", b"failure", "gemm", b"gemm", "key", b"key", "run_time", b"run_time", "scratch_bytes", b"scratch_bytes"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["key", b"key"]) -> typing_extensions.Literal["conv", "gemm", "cuda_conv_plan", "algorithm"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["algorithm", b"algorithm", "conv", b"conv", "cuda_conv_plan", b"cuda_conv_plan", "failure", b"failure", "gemm", b"gemm", "key", b"key", "run_time", b"run_time"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["algorithm", b"algorithm", "conv", b"conv", "cuda_conv_plan", b"cuda_conv_plan", "failure", b"failure", "gemm", b"gemm", "key", b"key", "run_time", b"run_time", "scratch_bytes", b"scratch_bytes"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["key", b"key"]) -> typing.Literal["conv", "gemm", "cuda_conv_plan", "algorithm"] | None: ...
|
||||
|
||||
global___AutotuneResult = AutotuneResult
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AutotuningLog(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -223,18 +224,19 @@ class AutotuningLog(google.protobuf.message.Message):
|
||||
COMPUTE_CAPABILITY_FIELD_NUMBER: builtins.int
|
||||
DEVICE_PCI_BUS_ID_FIELD_NUMBER: builtins.int
|
||||
BLAS_VERSION_FIELD_NUMBER: builtins.int
|
||||
device_pci_bus_id: builtins.str
|
||||
"""stream_executor::DeviceDescription::pci_bus_id."""
|
||||
blas_version: builtins.str
|
||||
@property
|
||||
def instr(self) -> google.protobuf.any_pb2.Any: ...
|
||||
@property
|
||||
def results(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___AutotuneResult]:
|
||||
"""Records all auto-tuning results per algorithm."""
|
||||
|
||||
@property
|
||||
def cudnn_version(self) -> global___CudnnVersion: ...
|
||||
@property
|
||||
def compute_capability(self) -> global___ComputeCapability: ...
|
||||
device_pci_bus_id: builtins.str
|
||||
"""stream_executor::DeviceDescription::pci_bus_id."""
|
||||
blas_version: builtins.str
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -245,7 +247,7 @@ class AutotuningLog(google.protobuf.message.Message):
|
||||
device_pci_bus_id: builtins.str | None = ...,
|
||||
blas_version: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["compute_capability", b"compute_capability", "cudnn_version", b"cudnn_version", "instr", b"instr"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["blas_version", b"blas_version", "compute_capability", b"compute_capability", "cudnn_version", b"cudnn_version", "device_pci_bus_id", b"device_pci_bus_id", "instr", b"instr", "results", b"results"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["compute_capability", b"compute_capability", "cudnn_version", b"cudnn_version", "instr", b"instr"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["blas_version", b"blas_version", "compute_capability", b"compute_capability", "cudnn_version", b"cudnn_version", "device_pci_bus_id", b"device_pci_bus_id", "instr", b"instr", "results", b"results"]) -> None: ...
|
||||
|
||||
global___AutotuningLog = AutotuningLog
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,7 +13,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemAllocatorStats(google.protobuf.message.Message):
|
||||
"""Some of the data from AllocatorStats"""
|
||||
|
||||
@@ -37,11 +38,11 @@ class MemAllocatorStats(google.protobuf.message.Message):
|
||||
largest_alloc_size: builtins.int | None = ...,
|
||||
fragmentation_metric: builtins.float | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bytes_in_use", b"bytes_in_use", "fragmentation_metric", b"fragmentation_metric", "largest_alloc_size", b"largest_alloc_size", "num_allocs", b"num_allocs", "peak_bytes_in_use", b"peak_bytes_in_use"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["bytes_in_use", b"bytes_in_use", "fragmentation_metric", b"fragmentation_metric", "largest_alloc_size", b"largest_alloc_size", "num_allocs", b"num_allocs", "peak_bytes_in_use", b"peak_bytes_in_use"]) -> None: ...
|
||||
|
||||
global___MemAllocatorStats = MemAllocatorStats
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemChunk(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -76,11 +77,11 @@ class MemChunk(google.protobuf.message.Message):
|
||||
in_use: builtins.bool | None = ...,
|
||||
step_id: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["action_count", b"action_count", "address", b"address", "bin", b"bin", "freed_at_count", b"freed_at_count", "in_use", b"in_use", "op_name", b"op_name", "requested_size", b"requested_size", "size", b"size", "step_id", b"step_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["action_count", b"action_count", "address", b"address", "bin", b"bin", "freed_at_count", b"freed_at_count", "in_use", b"in_use", "op_name", b"op_name", "requested_size", b"requested_size", "size", b"size", "step_id", b"step_id"]) -> None: ...
|
||||
|
||||
global___MemChunk = MemChunk
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BinSummary(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -103,11 +104,11 @@ class BinSummary(google.protobuf.message.Message):
|
||||
total_chunks_in_use: builtins.int | None = ...,
|
||||
total_chunks_in_bin: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bin", b"bin", "total_bytes_in_bin", b"total_bytes_in_bin", "total_bytes_in_use", b"total_bytes_in_use", "total_chunks_in_bin", b"total_chunks_in_bin", "total_chunks_in_use", b"total_chunks_in_use"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["bin", b"bin", "total_bytes_in_bin", b"total_bytes_in_bin", "total_bytes_in_use", b"total_bytes_in_use", "total_chunks_in_bin", b"total_chunks_in_bin", "total_chunks_in_use", b"total_chunks_in_use"]) -> None: ...
|
||||
|
||||
global___BinSummary = BinSummary
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class SnapShot(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -121,11 +122,11 @@ class SnapShot(google.protobuf.message.Message):
|
||||
action_count: builtins.int | None = ...,
|
||||
size: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["action_count", b"action_count", "size", b"size"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["action_count", b"action_count", "size", b"size"]) -> None: ...
|
||||
|
||||
global___SnapShot = SnapShot
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemoryDump(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -152,7 +153,7 @@ class MemoryDump(google.protobuf.message.Message):
|
||||
snap_shot: collections.abc.Iterable[global___SnapShot] | None = ...,
|
||||
stats: global___MemAllocatorStats | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["stats", b"stats"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["allocator_name", b"allocator_name", "bin_summary", b"bin_summary", "chunk", b"chunk", "snap_shot", b"snap_shot", "stats", b"stats"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["stats", b"stats"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["allocator_name", b"allocator_name", "bin_summary", b"bin_summary", "chunk", b"chunk", "snap_shot", b"snap_shot", "stats", b"stats"]) -> None: ...
|
||||
|
||||
global___MemoryDump = MemoryDump
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,7 +13,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CoordinatedJob(google.protobuf.message.Message):
|
||||
"""Represents a job type and the number of tasks under this job.
|
||||
For example, ("worker", 20) implies that there will be 20 worker tasks.
|
||||
@@ -30,11 +31,11 @@ class CoordinatedJob(google.protobuf.message.Message):
|
||||
name: builtins.str | None = ...,
|
||||
num_tasks: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "num_tasks", b"num_tasks"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["name", b"name", "num_tasks", b"num_tasks"]) -> None: ...
|
||||
|
||||
global___CoordinatedJob = CoordinatedJob
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CoordinationServiceConfig(google.protobuf.message.Message):
|
||||
"""Coordination service configuration parameters.
|
||||
The system picks appropriate values for fields that are not set.
|
||||
@@ -70,8 +71,6 @@ class CoordinationServiceConfig(google.protobuf.message.Message):
|
||||
the agent has disconnected, to account for the lag time between the service
|
||||
recording the state change and the agent stopping heartbeats.
|
||||
"""
|
||||
@property
|
||||
def coordinated_job_list(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___CoordinatedJob]: ...
|
||||
shutdown_barrier_timeout_in_ms: builtins.int
|
||||
"""Denotes how long to wait for all coordination agents to reach the barriers
|
||||
(after the first shutdown request) before disconnecting together. If
|
||||
@@ -84,12 +83,15 @@ class CoordinationServiceConfig(google.protobuf.message.Message):
|
||||
testing.
|
||||
"""
|
||||
@property
|
||||
def coordinated_job_list(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___CoordinatedJob]: ...
|
||||
@property
|
||||
def recoverable_jobs(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""The list of jobs which are recoverable. If a task in this list fails,
|
||||
it will not propagate error to other tasks.
|
||||
If empty, no jobs will be recoverable and every task failure will cause
|
||||
error propagation to other tasks.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -103,6 +105,6 @@ class CoordinationServiceConfig(google.protobuf.message.Message):
|
||||
agent_destruction_without_shutdown: builtins.bool | None = ...,
|
||||
recoverable_jobs: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["agent_destruction_without_shutdown", b"agent_destruction_without_shutdown", "cluster_register_timeout_in_ms", b"cluster_register_timeout_in_ms", "coordinated_job_list", b"coordinated_job_list", "enable_health_check", b"enable_health_check", "heartbeat_timeout_in_ms", b"heartbeat_timeout_in_ms", "recoverable_jobs", b"recoverable_jobs", "service_leader", b"service_leader", "service_type", b"service_type", "shutdown_barrier_timeout_in_ms", b"shutdown_barrier_timeout_in_ms"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["agent_destruction_without_shutdown", b"agent_destruction_without_shutdown", "cluster_register_timeout_in_ms", b"cluster_register_timeout_in_ms", "coordinated_job_list", b"coordinated_job_list", "enable_health_check", b"enable_health_check", "heartbeat_timeout_in_ms", b"heartbeat_timeout_in_ms", "recoverable_jobs", b"recoverable_jobs", "service_leader", b"service_leader", "service_type", b"service_type", "shutdown_barrier_timeout_in_ms", b"shutdown_barrier_timeout_in_ms"]) -> None: ...
|
||||
|
||||
global___CoordinationServiceConfig = CoordinationServiceConfig
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -52,7 +53,7 @@ TASKSTATE_CONNECTED: CoordinatedTaskState.ValueType # 3
|
||||
TASKSTATE_ERROR: CoordinatedTaskState.ValueType # 4
|
||||
global___CoordinatedTaskState = CoordinatedTaskState
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CoordinatedTask(google.protobuf.message.Message):
|
||||
"""Represents a remote worker task, specified by job name and task id."""
|
||||
|
||||
@@ -68,11 +69,11 @@ class CoordinatedTask(google.protobuf.message.Message):
|
||||
job_name: builtins.str | None = ...,
|
||||
task_id: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["job_name", b"job_name", "task_id", b"task_id"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["job_name", b"job_name", "task_id", b"task_id"]) -> None: ...
|
||||
|
||||
global___CoordinatedTask = CoordinatedTask
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CoordinationServiceError(google.protobuf.message.Message):
|
||||
"""Status payload for all coordination service errors.
|
||||
Note: an empty proto may be set if the error is triggered by the task's own
|
||||
@@ -92,18 +93,19 @@ class CoordinationServiceError(google.protobuf.message.Message):
|
||||
"""Denotes which task hit the error. If unset, the error originated from the
|
||||
same task that is processing this error.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
is_reported_error: builtins.bool | None = ...,
|
||||
source_task: global___CoordinatedTask | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["is_reported_error", b"is_reported_error", "source_task", b"source_task"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["is_reported_error", b"is_reported_error", "source_task", b"source_task"]) -> None: ...
|
||||
|
||||
global___CoordinationServiceError = CoordinationServiceError
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CoordinatedTaskStateInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -112,12 +114,12 @@ class CoordinatedTaskStateInfo(google.protobuf.message.Message):
|
||||
ERROR_CODE_FIELD_NUMBER: builtins.int
|
||||
ERROR_MESSAGE_FIELD_NUMBER: builtins.int
|
||||
ERROR_PAYLOAD_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def task(self) -> global___CoordinatedTask: ...
|
||||
state: global___CoordinatedTaskState.ValueType
|
||||
error_code: builtins.int
|
||||
error_message: builtins.str
|
||||
@property
|
||||
def task(self) -> global___CoordinatedTask: ...
|
||||
@property
|
||||
def error_payload(self) -> global___CoordinationServiceError: ...
|
||||
def __init__(
|
||||
self,
|
||||
@@ -128,12 +130,12 @@ class CoordinatedTaskStateInfo(google.protobuf.message.Message):
|
||||
error_message: builtins.str | None = ...,
|
||||
error_payload: global___CoordinationServiceError | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["error_payload", b"error_payload", "task", b"task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["error_code", b"error_code", "error_message", b"error_message", "error_payload", b"error_payload", "state", b"state", "task", b"task"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["error_payload", b"error_payload", "task", b"task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["error_code", b"error_code", "error_message", b"error_message", "error_payload", b"error_payload", "state", b"state", "task", b"task"]) -> None: ...
|
||||
|
||||
global___CoordinatedTaskStateInfo = CoordinatedTaskStateInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DeviceInfo(google.protobuf.message.Message):
|
||||
"""Placeholder message to be extended by other runtimes' device representations."""
|
||||
|
||||
@@ -147,11 +149,11 @@ class DeviceInfo(google.protobuf.message.Message):
|
||||
*,
|
||||
device: collections.abc.Iterable[google.protobuf.any_pb2.Any] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device", b"device"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["device", b"device"]) -> None: ...
|
||||
|
||||
global___DeviceInfo = DeviceInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RegisterTaskRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for registering a task to the cluster leader.
|
||||
A task is uniquely represented by its `job_name`, `task_id` and
|
||||
@@ -172,12 +174,12 @@ class RegisterTaskRequest(google.protobuf.message.Message):
|
||||
incarnation: builtins.int | None = ...,
|
||||
source_task: global___CoordinatedTask | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["incarnation", b"incarnation", "source_task", b"source_task"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["incarnation", b"incarnation", "source_task", b"source_task"]) -> None: ...
|
||||
|
||||
global___RegisterTaskRequest = RegisterTaskRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RegisterTaskResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -188,11 +190,11 @@ class RegisterTaskResponse(google.protobuf.message.Message):
|
||||
*,
|
||||
leader_incarnation: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["leader_incarnation", b"leader_incarnation"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["leader_incarnation", b"leader_incarnation"]) -> None: ...
|
||||
|
||||
global___RegisterTaskResponse = RegisterTaskResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HeartbeatRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for sending heartbeats."""
|
||||
|
||||
@@ -209,12 +211,12 @@ class HeartbeatRequest(google.protobuf.message.Message):
|
||||
incarnation: builtins.int | None = ...,
|
||||
source_task: global___CoordinatedTask | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["incarnation", b"incarnation", "source_task", b"source_task"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["incarnation", b"incarnation", "source_task", b"source_task"]) -> None: ...
|
||||
|
||||
global___HeartbeatRequest = HeartbeatRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HeartbeatResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -228,11 +230,11 @@ class HeartbeatResponse(google.protobuf.message.Message):
|
||||
*,
|
||||
leader_incarnation: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["leader_incarnation", b"leader_incarnation"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["leader_incarnation", b"leader_incarnation"]) -> None: ...
|
||||
|
||||
global___HeartbeatResponse = HeartbeatResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class WaitForAllTasksRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for waiting for all tasks."""
|
||||
|
||||
@@ -245,18 +247,19 @@ class WaitForAllTasksRequest(google.protobuf.message.Message):
|
||||
@property
|
||||
def device_info(self) -> global___DeviceInfo:
|
||||
"""All local device attributes on the request sender;"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
source_task: global___CoordinatedTask | None = ...,
|
||||
device_info: global___DeviceInfo | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["device_info", b"device_info", "source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device_info", b"device_info", "source_task", b"source_task"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["device_info", b"device_info", "source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["device_info", b"device_info", "source_task", b"source_task"]) -> None: ...
|
||||
|
||||
global___WaitForAllTasksRequest = WaitForAllTasksRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class WaitForAllTasksResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -266,18 +269,19 @@ class WaitForAllTasksResponse(google.protobuf.message.Message):
|
||||
@property
|
||||
def device_info(self) -> global___DeviceInfo:
|
||||
"""All devices in the cluster."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
leader_incarnation: builtins.int | None = ...,
|
||||
device_info: global___DeviceInfo | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["device_info", b"device_info"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["device_info", b"device_info", "leader_incarnation", b"leader_incarnation"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["device_info", b"device_info"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["device_info", b"device_info", "leader_incarnation", b"leader_incarnation"]) -> None: ...
|
||||
|
||||
global___WaitForAllTasksResponse = WaitForAllTasksResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ShutdownTaskRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for disconnecting a task from the service."""
|
||||
|
||||
@@ -291,12 +295,12 @@ class ShutdownTaskRequest(google.protobuf.message.Message):
|
||||
*,
|
||||
source_task: global___CoordinatedTask | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["source_task", b"source_task"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["source_task", b"source_task"]) -> None: ...
|
||||
|
||||
global___ShutdownTaskRequest = ShutdownTaskRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ShutdownTaskResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -306,7 +310,7 @@ class ShutdownTaskResponse(google.protobuf.message.Message):
|
||||
|
||||
global___ShutdownTaskResponse = ShutdownTaskResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ResetTaskRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for resetting a task state in the service."""
|
||||
|
||||
@@ -320,12 +324,12 @@ class ResetTaskRequest(google.protobuf.message.Message):
|
||||
*,
|
||||
source_task: global___CoordinatedTask | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["source_task", b"source_task"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["source_task", b"source_task"]) -> None: ...
|
||||
|
||||
global___ResetTaskRequest = ResetTaskRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ResetTaskResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -335,7 +339,7 @@ class ResetTaskResponse(google.protobuf.message.Message):
|
||||
|
||||
global___ResetTaskResponse = ResetTaskResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ReportErrorToTaskRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for reporting errors to task."""
|
||||
|
||||
@@ -355,12 +359,12 @@ class ReportErrorToTaskRequest(google.protobuf.message.Message):
|
||||
error_message: builtins.str | None = ...,
|
||||
error_payload: global___CoordinationServiceError | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["error_payload", b"error_payload"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["error_code", b"error_code", "error_message", b"error_message", "error_payload", b"error_payload"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["error_payload", b"error_payload"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["error_code", b"error_code", "error_message", b"error_message", "error_payload", b"error_payload"]) -> None: ...
|
||||
|
||||
global___ReportErrorToTaskRequest = ReportErrorToTaskRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ReportErrorToTaskResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -370,7 +374,7 @@ class ReportErrorToTaskResponse(google.protobuf.message.Message):
|
||||
|
||||
global___ReportErrorToTaskResponse = ReportErrorToTaskResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ReportErrorToServiceRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for reporting errors to service instance."""
|
||||
|
||||
@@ -390,12 +394,12 @@ class ReportErrorToServiceRequest(google.protobuf.message.Message):
|
||||
error_message: builtins.str | None = ...,
|
||||
error_origin: global___CoordinatedTask | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["error_origin", b"error_origin"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["error_code", b"error_code", "error_message", b"error_message", "error_origin", b"error_origin"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["error_origin", b"error_origin"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["error_code", b"error_code", "error_message", b"error_message", "error_origin", b"error_origin"]) -> None: ...
|
||||
|
||||
global___ReportErrorToServiceRequest = ReportErrorToServiceRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ReportErrorToServiceResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -405,7 +409,7 @@ class ReportErrorToServiceResponse(google.protobuf.message.Message):
|
||||
|
||||
global___ReportErrorToServiceResponse = ReportErrorToServiceResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GetTaskStateRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for getting state of a remote task."""
|
||||
|
||||
@@ -419,11 +423,11 @@ class GetTaskStateRequest(google.protobuf.message.Message):
|
||||
*,
|
||||
source_task: collections.abc.Iterable[global___CoordinatedTask] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["source_task", b"source_task"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["source_task", b"source_task"]) -> None: ...
|
||||
|
||||
global___GetTaskStateRequest = GetTaskStateRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GetTaskStateResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -435,11 +439,11 @@ class GetTaskStateResponse(google.protobuf.message.Message):
|
||||
*,
|
||||
task_state: collections.abc.Iterable[global___CoordinatedTaskStateInfo] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["task_state", b"task_state"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["task_state", b"task_state"]) -> None: ...
|
||||
|
||||
global___GetTaskStateResponse = GetTaskStateResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class KeyValueEntry(google.protobuf.message.Message):
|
||||
"""Message for configuration key value.
|
||||
Key is structured like Unix file system, with multiple levels of directory
|
||||
@@ -458,11 +462,11 @@ class KeyValueEntry(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.bytes | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
global___KeyValueEntry = KeyValueEntry
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class InsertKeyValueRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for inserting configuration key-value data."""
|
||||
|
||||
@@ -476,12 +480,12 @@ class InsertKeyValueRequest(google.protobuf.message.Message):
|
||||
*,
|
||||
kv: global___KeyValueEntry | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["kv", b"kv"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["kv", b"kv"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["kv", b"kv"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["kv", b"kv"]) -> None: ...
|
||||
|
||||
global___InsertKeyValueRequest = InsertKeyValueRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class InsertKeyValueResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -491,7 +495,7 @@ class InsertKeyValueResponse(google.protobuf.message.Message):
|
||||
|
||||
global___InsertKeyValueResponse = InsertKeyValueResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GetKeyValueRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for getting configuration key-value data."""
|
||||
|
||||
@@ -504,11 +508,11 @@ class GetKeyValueRequest(google.protobuf.message.Message):
|
||||
*,
|
||||
key: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key"]) -> None: ...
|
||||
|
||||
global___GetKeyValueRequest = GetKeyValueRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GetKeyValueResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -520,12 +524,12 @@ class GetKeyValueResponse(google.protobuf.message.Message):
|
||||
*,
|
||||
kv: global___KeyValueEntry | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["kv", b"kv"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["kv", b"kv"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["kv", b"kv"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["kv", b"kv"]) -> None: ...
|
||||
|
||||
global___GetKeyValueResponse = GetKeyValueResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TryGetKeyValueRequest(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -536,11 +540,11 @@ class TryGetKeyValueRequest(google.protobuf.message.Message):
|
||||
*,
|
||||
key: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key"]) -> None: ...
|
||||
|
||||
global___TryGetKeyValueRequest = TryGetKeyValueRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TryGetKeyValueResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -552,12 +556,12 @@ class TryGetKeyValueResponse(google.protobuf.message.Message):
|
||||
*,
|
||||
kv: global___KeyValueEntry | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["kv", b"kv"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["kv", b"kv"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["kv", b"kv"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["kv", b"kv"]) -> None: ...
|
||||
|
||||
global___TryGetKeyValueResponse = TryGetKeyValueResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GetKeyValueDirRequest(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -568,11 +572,11 @@ class GetKeyValueDirRequest(google.protobuf.message.Message):
|
||||
*,
|
||||
directory_key: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["directory_key", b"directory_key"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["directory_key", b"directory_key"]) -> None: ...
|
||||
|
||||
global___GetKeyValueDirRequest = GetKeyValueDirRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GetKeyValueDirResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -587,11 +591,11 @@ class GetKeyValueDirResponse(google.protobuf.message.Message):
|
||||
directory_key: builtins.str | None = ...,
|
||||
kv: collections.abc.Iterable[global___KeyValueEntry] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["directory_key", b"directory_key", "kv", b"kv"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["directory_key", b"directory_key", "kv", b"kv"]) -> None: ...
|
||||
|
||||
global___GetKeyValueDirResponse = GetKeyValueDirResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DeleteKeyValueRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for deleting configuration key-value data.
|
||||
When is_directory is true, delete key-values recursively under `key`.
|
||||
@@ -609,11 +613,11 @@ class DeleteKeyValueRequest(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
is_directory: builtins.bool | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["is_directory", b"is_directory", "key", b"key"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["is_directory", b"is_directory", "key", b"key"]) -> None: ...
|
||||
|
||||
global___DeleteKeyValueRequest = DeleteKeyValueRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class DeleteKeyValueResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -623,7 +627,7 @@ class DeleteKeyValueResponse(google.protobuf.message.Message):
|
||||
|
||||
global___DeleteKeyValueResponse = DeleteKeyValueResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BarrierRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for generic sync barriers."""
|
||||
|
||||
@@ -640,9 +644,11 @@ class BarrierRequest(google.protobuf.message.Message):
|
||||
"""Denotes list of tasks that will wait for the barrier. If unspecified, it
|
||||
implies that the entire cluster is participating in the barrier.
|
||||
"""
|
||||
|
||||
@property
|
||||
def source_task(self) -> global___CoordinatedTask:
|
||||
"""Task that is making the request."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -651,12 +657,12 @@ class BarrierRequest(google.protobuf.message.Message):
|
||||
tasks: collections.abc.Iterable[global___CoordinatedTask] | None = ...,
|
||||
source_task: global___CoordinatedTask | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["barrier_id", b"barrier_id", "barrier_timeout_in_ms", b"barrier_timeout_in_ms", "source_task", b"source_task", "tasks", b"tasks"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["barrier_id", b"barrier_id", "barrier_timeout_in_ms", b"barrier_timeout_in_ms", "source_task", b"source_task", "tasks", b"tasks"]) -> None: ...
|
||||
|
||||
global___BarrierRequest = BarrierRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BarrierResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -666,7 +672,7 @@ class BarrierResponse(google.protobuf.message.Message):
|
||||
|
||||
global___BarrierResponse = BarrierResponse
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CancelBarrierRequest(google.protobuf.message.Message):
|
||||
"""Request and response messages for cancelling generic sync barriers."""
|
||||
|
||||
@@ -678,18 +684,19 @@ class CancelBarrierRequest(google.protobuf.message.Message):
|
||||
@property
|
||||
def source_task(self) -> global___CoordinatedTask:
|
||||
"""Task that is making the request."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
barrier_id: builtins.str | None = ...,
|
||||
source_task: global___CoordinatedTask | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["barrier_id", b"barrier_id", "source_task", b"source_task"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["source_task", b"source_task"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["barrier_id", b"barrier_id", "source_task", b"source_task"]) -> None: ...
|
||||
|
||||
global___CancelBarrierRequest = CancelBarrierRequest
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CancelBarrierResponse(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,7 +13,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GrpcPayloadContainer(google.protobuf.message.Message):
|
||||
"""Used to serialize and transmit tensorflow::Status payloads through
|
||||
grpc::Status `error_details` since grpc::Status lacks payload API.
|
||||
@@ -21,7 +22,7 @@ class GrpcPayloadContainer(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class PayloadsEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -35,7 +36,7 @@ class GrpcPayloadContainer(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.bytes | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
PAYLOADS_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
@@ -45,11 +46,11 @@ class GrpcPayloadContainer(google.protobuf.message.Message):
|
||||
*,
|
||||
payloads: collections.abc.Mapping[builtins.str, builtins.bytes] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["payloads", b"payloads"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["payloads", b"payloads"]) -> None: ...
|
||||
|
||||
global___GrpcPayloadContainer = GrpcPayloadContainer
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GrpcPayloadsLost(google.protobuf.message.Message):
|
||||
"""If included as a payload, this message flags the Status to have lost payloads
|
||||
during the GRPC transmission.
|
||||
@@ -64,7 +65,7 @@ class GrpcPayloadsLost(google.protobuf.message.Message):
|
||||
|
||||
global___GrpcPayloadsLost = GrpcPayloadsLost
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class WorkerPossiblyRestarted(google.protobuf.message.Message):
|
||||
"""If included as a payload, this message flags the Status to be a possible
|
||||
outcome of a worker restart.
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
LINT: LEGACY_NAMES"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -250,7 +251,7 @@ BACKWARD_DATA: ConvolutionKind.ValueType # 3
|
||||
FORWARD_BIAS_ACTIVATION: ConvolutionKind.ValueType # 4
|
||||
global___ConvolutionKind = ConvolutionKind
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TensorDescriptorProto(google.protobuf.message.Message):
|
||||
"""Generic tensor representation."""
|
||||
|
||||
@@ -260,11 +261,11 @@ class TensorDescriptorProto(google.protobuf.message.Message):
|
||||
DATA_TYPE_FIELD_NUMBER: builtins.int
|
||||
DATA_LAYOUT_FIELD_NUMBER: builtins.int
|
||||
FILTER_LAYOUT_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
data_type: global___DataType.ValueType
|
||||
data_layout: global___DataLayout.ValueType
|
||||
filter_layout: global___FilterLayout.ValueType
|
||||
@property
|
||||
def dimensions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -273,13 +274,13 @@ class TensorDescriptorProto(google.protobuf.message.Message):
|
||||
data_layout: global___DataLayout.ValueType | None = ...,
|
||||
filter_layout: global___FilterLayout.ValueType | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["data_layout", b"data_layout", "filter_layout", b"filter_layout", "layout_oneof", b"layout_oneof"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["data_layout", b"data_layout", "data_type", b"data_type", "dimensions", b"dimensions", "filter_layout", b"filter_layout", "layout_oneof", b"layout_oneof"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["layout_oneof", b"layout_oneof"]) -> typing_extensions.Literal["data_layout", "filter_layout"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["data_layout", b"data_layout", "filter_layout", b"filter_layout", "layout_oneof", b"layout_oneof"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["data_layout", b"data_layout", "data_type", b"data_type", "dimensions", b"dimensions", "filter_layout", b"filter_layout", "layout_oneof", b"layout_oneof"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["layout_oneof", b"layout_oneof"]) -> typing.Literal["data_layout", "filter_layout"] | None: ...
|
||||
|
||||
global___TensorDescriptorProto = TensorDescriptorProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AlgorithmProto(google.protobuf.message.Message):
|
||||
"""Generic algorithm representation."""
|
||||
|
||||
@@ -304,7 +305,7 @@ class AlgorithmProto(google.protobuf.message.Message):
|
||||
See cuDNN's documentation for CUDNN_TENSOR_OP_MATH.
|
||||
"""
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TuningKnobsEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -318,7 +319,7 @@ class AlgorithmProto(google.protobuf.message.Message):
|
||||
key: builtins.int | None = ...,
|
||||
value: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
ALGO_ID_FIELD_NUMBER: builtins.int
|
||||
MATH_TYPE_FIELD_NUMBER: builtins.int
|
||||
@@ -327,8 +328,6 @@ class AlgorithmProto(google.protobuf.message.Message):
|
||||
WORKSPACE_SIZE_FIELD_NUMBER: builtins.int
|
||||
algo_id: builtins.int
|
||||
math_type: global___AlgorithmProto.MathType.ValueType
|
||||
@property
|
||||
def tuning_knobs(self) -> google.protobuf.internal.containers.ScalarMap[builtins.int, builtins.int]: ...
|
||||
is_cudnn_frontend: builtins.bool
|
||||
"""Legacy algorithm enums and cuDNN Frontend engine numbers need to coexist in
|
||||
the same proto medium-term, until we can be confident of no longer needing
|
||||
@@ -336,6 +335,8 @@ class AlgorithmProto(google.protobuf.message.Message):
|
||||
stop producing legacy algorithm enums and remove this field.
|
||||
"""
|
||||
@property
|
||||
def tuning_knobs(self) -> google.protobuf.internal.containers.ScalarMap[builtins.int, builtins.int]: ...
|
||||
@property
|
||||
def workspace_size(self) -> google.protobuf.wrappers_pb2.UInt64Value:
|
||||
"""For ROCm only, it's impossible to re-query the required workspace size
|
||||
after running the algorithm search, so we must store the workspace size
|
||||
@@ -347,6 +348,7 @@ class AlgorithmProto(google.protobuf.message.Message):
|
||||
0 workspace size from unknown workspace size in an old message, so this is
|
||||
a message field.
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -356,12 +358,12 @@ class AlgorithmProto(google.protobuf.message.Message):
|
||||
is_cudnn_frontend: builtins.bool | None = ...,
|
||||
workspace_size: google.protobuf.wrappers_pb2.UInt64Value | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["workspace_size", b"workspace_size"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["algo_id", b"algo_id", "is_cudnn_frontend", b"is_cudnn_frontend", "math_type", b"math_type", "tuning_knobs", b"tuning_knobs", "workspace_size", b"workspace_size"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["workspace_size", b"workspace_size"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["algo_id", b"algo_id", "is_cudnn_frontend", b"is_cudnn_frontend", "math_type", b"math_type", "tuning_knobs", b"tuning_knobs", "workspace_size", b"workspace_size"]) -> None: ...
|
||||
|
||||
global___AlgorithmProto = AlgorithmProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AlgorithmConfigProto(google.protobuf.message.Message):
|
||||
"""Proto definition of AlgorithmConfig in "dnn.h".
|
||||
TODO(ruochengw): After cl/380702564 is submitted, add support for algorithm
|
||||
@@ -373,11 +375,11 @@ class AlgorithmConfigProto(google.protobuf.message.Message):
|
||||
ALGORITHM_FIELD_NUMBER: builtins.int
|
||||
ALGORITHM_NO_SCRATCH_FIELD_NUMBER: builtins.int
|
||||
SCRATCH_SIZE_FIELD_NUMBER: builtins.int
|
||||
scratch_size: builtins.int
|
||||
@property
|
||||
def algorithm(self) -> global___AlgorithmProto: ...
|
||||
@property
|
||||
def algorithm_no_scratch(self) -> global___AlgorithmProto: ...
|
||||
scratch_size: builtins.int
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -385,18 +387,18 @@ class AlgorithmConfigProto(google.protobuf.message.Message):
|
||||
algorithm_no_scratch: global___AlgorithmProto | None = ...,
|
||||
scratch_size: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["algorithm", b"algorithm", "algorithm_no_scratch", b"algorithm_no_scratch", "optional_algorithm", b"optional_algorithm", "optional_algorithm_no_scratch", b"optional_algorithm_no_scratch", "optional_scratch_size", b"optional_scratch_size", "scratch_size", b"scratch_size"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["algorithm", b"algorithm", "algorithm_no_scratch", b"algorithm_no_scratch", "optional_algorithm", b"optional_algorithm", "optional_algorithm_no_scratch", b"optional_algorithm_no_scratch", "optional_scratch_size", b"optional_scratch_size", "scratch_size", b"scratch_size"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["algorithm", b"algorithm", "algorithm_no_scratch", b"algorithm_no_scratch", "optional_algorithm", b"optional_algorithm", "optional_algorithm_no_scratch", b"optional_algorithm_no_scratch", "optional_scratch_size", b"optional_scratch_size", "scratch_size", b"scratch_size"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["algorithm", b"algorithm", "algorithm_no_scratch", b"algorithm_no_scratch", "optional_algorithm", b"optional_algorithm", "optional_algorithm_no_scratch", b"optional_algorithm_no_scratch", "optional_scratch_size", b"optional_scratch_size", "scratch_size", b"scratch_size"]) -> None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_algorithm", b"optional_algorithm"]) -> typing_extensions.Literal["algorithm"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_algorithm", b"optional_algorithm"]) -> typing.Literal["algorithm"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_algorithm_no_scratch", b"optional_algorithm_no_scratch"]) -> typing_extensions.Literal["algorithm_no_scratch"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_algorithm_no_scratch", b"optional_algorithm_no_scratch"]) -> typing.Literal["algorithm_no_scratch"] | None: ...
|
||||
@typing.overload
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["optional_scratch_size", b"optional_scratch_size"]) -> typing_extensions.Literal["scratch_size"] | None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["optional_scratch_size", b"optional_scratch_size"]) -> typing.Literal["scratch_size"] | None: ...
|
||||
|
||||
global___AlgorithmConfigProto = AlgorithmConfigProto
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ConvolutionDescriptorProto(google.protobuf.message.Message):
|
||||
"""Convolution-specific parameters."""
|
||||
|
||||
@@ -409,12 +411,6 @@ class ConvolutionDescriptorProto(google.protobuf.message.Message):
|
||||
GROUP_COUNT_FIELD_NUMBER: builtins.int
|
||||
CONVOLUTION_MODE_FIELD_NUMBER: builtins.int
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
@property
|
||||
def paddings(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def strides(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def dilations(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
compute_mode: global___DataType.ValueType
|
||||
"""The "accumulator" type. For example, use F32 as an accumulator for F16
|
||||
convolutions.
|
||||
@@ -425,6 +421,12 @@ class ConvolutionDescriptorProto(google.protobuf.message.Message):
|
||||
convolution_mode: global___ConvolutionMode.ValueType
|
||||
name: builtins.str
|
||||
"""Tensorflow node name, same as in NodeDef, for debugging purposes."""
|
||||
@property
|
||||
def paddings(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def strides(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
@property
|
||||
def dilations(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -436,6 +438,6 @@ class ConvolutionDescriptorProto(google.protobuf.message.Message):
|
||||
convolution_mode: global___ConvolutionMode.ValueType | None = ...,
|
||||
name: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["compute_mode", b"compute_mode", "convolution_mode", b"convolution_mode", "dilations", b"dilations", "group_count", b"group_count", "name", b"name", "paddings", b"paddings", "strides", b"strides"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["compute_mode", b"compute_mode", "convolution_mode", b"convolution_mode", "dilations", b"dilations", "group_count", b"group_count", "name", b"name", "paddings", b"paddings", "strides", b"strides"]) -> None: ...
|
||||
|
||||
global___ConvolutionDescriptorProto = ConvolutionDescriptorProto
|
||||
|
||||
@@ -4,6 +4,7 @@ isort:skip_file
|
||||
TODO(b/247876220): Change package and java_package once we figure out how to
|
||||
migrate.
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import sys
|
||||
import typing
|
||||
|
||||
@@ -2,9 +2,10 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.internal.containers
|
||||
@@ -12,7 +13,7 @@ import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class HistogramProto(google.protobuf.message.Message):
|
||||
"""Serialization format for histogram module in
|
||||
tsl/lib/histogram/histogram.h
|
||||
@@ -40,6 +41,7 @@ class HistogramProto(google.protobuf.message.Message):
|
||||
i == 0: -DBL_MAX .. bucket_limit(0)
|
||||
i != 0: bucket_limit(i-1) .. bucket_limit(i)
|
||||
"""
|
||||
|
||||
@property
|
||||
def bucket(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.float]: ...
|
||||
def __init__(
|
||||
@@ -53,6 +55,6 @@ class HistogramProto(google.protobuf.message.Message):
|
||||
bucket_limit: collections.abc.Iterable[builtins.float] | None = ...,
|
||||
bucket: collections.abc.Iterable[builtins.float] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bucket", b"bucket", "bucket_limit", b"bucket_limit", "max", b"max", "min", b"min", "num", b"num", "sum", b"sum", "sum_squares", b"sum_squares"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["bucket", b"bucket", "bucket_limit", b"bucket_limit", "max", b"max", "min", b"min", "num", b"num", "sum", b"sum", "sum_squares", b"sum_squares"]) -> None: ...
|
||||
|
||||
global___HistogramProto = HistogramProto
|
||||
|
||||
@@ -2,15 +2,16 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
"""
|
||||
|
||||
import builtins
|
||||
import typing as typing_extensions
|
||||
import typing
|
||||
|
||||
import google.protobuf.descriptor
|
||||
import google.protobuf.message
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RPCOptions(google.protobuf.message.Message):
|
||||
"""RPC options for distributed runtime."""
|
||||
|
||||
@@ -63,6 +64,6 @@ class RPCOptions(google.protobuf.message.Message):
|
||||
disable_session_connection_sharing: builtins.bool | None = ...,
|
||||
num_channels_per_target: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cache_rpc_response", b"cache_rpc_response", "compression_algorithm", b"compression_algorithm", "compression_level", b"compression_level", "disable_session_connection_sharing", b"disable_session_connection_sharing", "num_channels_per_target", b"num_channels_per_target", "use_rpc_for_inprocess_master", b"use_rpc_for_inprocess_master"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["cache_rpc_response", b"cache_rpc_response", "compression_algorithm", b"compression_algorithm", "compression_level", b"compression_level", "disable_session_connection_sharing", b"disable_session_connection_sharing", "num_channels_per_target", b"num_channels_per_target", "use_rpc_for_inprocess_master", b"use_rpc_for_inprocess_master"]) -> None: ...
|
||||
|
||||
global___RPCOptions = RPCOptions
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
@generated by mypy-protobuf. Do not edit manually!
|
||||
isort:skip_file
|
||||
Protocol messages for describing the results of benchmarks and unit tests."""
|
||||
|
||||
import builtins
|
||||
import collections.abc
|
||||
import sys
|
||||
@@ -21,7 +22,7 @@ else:
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class EntryValue(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -35,13 +36,13 @@ class EntryValue(google.protobuf.message.Message):
|
||||
double_value: builtins.float | None = ...,
|
||||
string_value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["double_value", b"double_value", "kind", b"kind", "string_value", b"string_value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["double_value", b"double_value", "kind", b"kind", "string_value", b"string_value"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["kind", b"kind"]) -> typing_extensions.Literal["double_value", "string_value"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["double_value", b"double_value", "kind", b"kind", "string_value", b"string_value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["double_value", b"double_value", "kind", b"kind", "string_value", b"string_value"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["kind", b"kind"]) -> typing.Literal["double_value", "string_value"] | None: ...
|
||||
|
||||
global___EntryValue = EntryValue
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MetricEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -56,9 +57,11 @@ class MetricEntry(google.protobuf.message.Message):
|
||||
@property
|
||||
def min_value(self) -> google.protobuf.wrappers_pb2.DoubleValue:
|
||||
"""The minimum acceptable value for the metric if specified"""
|
||||
|
||||
@property
|
||||
def max_value(self) -> google.protobuf.wrappers_pb2.DoubleValue:
|
||||
"""The maximum acceptable value for the metric if specified"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -67,12 +70,12 @@ class MetricEntry(google.protobuf.message.Message):
|
||||
min_value: google.protobuf.wrappers_pb2.DoubleValue | None = ...,
|
||||
max_value: google.protobuf.wrappers_pb2.DoubleValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["max_value", b"max_value", "min_value", b"min_value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["max_value", b"max_value", "min_value", b"min_value", "name", b"name", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["max_value", b"max_value", "min_value", b"min_value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["max_value", b"max_value", "min_value", b"min_value", "name", b"name", "value", b"value"]) -> None: ...
|
||||
|
||||
global___MetricEntry = MetricEntry
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BenchmarkEntry(google.protobuf.message.Message):
|
||||
"""Each unit test or benchmark in a test or benchmark run provides
|
||||
some set of information. Here we provide some reasonable keys
|
||||
@@ -85,7 +88,7 @@ class BenchmarkEntry(google.protobuf.message.Message):
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class ExtrasEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -100,8 +103,8 @@ class BenchmarkEntry(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: global___EntryValue | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
NAME_FIELD_NUMBER: builtins.int
|
||||
ITERS_FIELD_NUMBER: builtins.int
|
||||
@@ -125,11 +128,13 @@ class BenchmarkEntry(google.protobuf.message.Message):
|
||||
@property
|
||||
def extras(self) -> google.protobuf.internal.containers.MessageMap[builtins.str, global___EntryValue]:
|
||||
"""Generic map from result key to value."""
|
||||
|
||||
@property
|
||||
def metrics(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___MetricEntry]:
|
||||
"""Metric name, value and expected range. This can include accuracy metrics
|
||||
typically used to determine whether the accuracy test has passed
|
||||
"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -141,11 +146,11 @@ class BenchmarkEntry(google.protobuf.message.Message):
|
||||
extras: collections.abc.Mapping[builtins.str, global___EntryValue] | None = ...,
|
||||
metrics: collections.abc.Iterable[global___MetricEntry] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cpu_time", b"cpu_time", "extras", b"extras", "iters", b"iters", "metrics", b"metrics", "name", b"name", "throughput", b"throughput", "wall_time", b"wall_time"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["cpu_time", b"cpu_time", "extras", b"extras", "iters", b"iters", "metrics", b"metrics", "name", b"name", "throughput", b"throughput", "wall_time", b"wall_time"]) -> None: ...
|
||||
|
||||
global___BenchmarkEntry = BenchmarkEntry
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BenchmarkEntries(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -157,11 +162,11 @@ class BenchmarkEntries(google.protobuf.message.Message):
|
||||
*,
|
||||
entry: collections.abc.Iterable[global___BenchmarkEntry] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["entry", b"entry"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["entry", b"entry"]) -> None: ...
|
||||
|
||||
global___BenchmarkEntries = BenchmarkEntries
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class BuildConfiguration(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -173,9 +178,11 @@ class BuildConfiguration(google.protobuf.message.Message):
|
||||
@property
|
||||
def cc_flags(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""CC compiler flags, if known"""
|
||||
|
||||
@property
|
||||
def opts(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
|
||||
"""Bazel compilation options, if known"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -183,11 +190,11 @@ class BuildConfiguration(google.protobuf.message.Message):
|
||||
cc_flags: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
opts: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cc_flags", b"cc_flags", "mode", b"mode", "opts", b"opts"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["cc_flags", b"cc_flags", "mode", b"mode", "opts", b"opts"]) -> None: ...
|
||||
|
||||
global___BuildConfiguration = BuildConfiguration
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CommitId(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -212,17 +219,17 @@ class CommitId(google.protobuf.message.Message):
|
||||
snapshot: builtins.str | None = ...,
|
||||
pending_changelist: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["changelist", b"changelist", "hash", b"hash", "kind", b"kind"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["changelist", b"changelist", "hash", b"hash", "kind", b"kind", "pending_changelist", b"pending_changelist", "snapshot", b"snapshot"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing_extensions.Literal["kind", b"kind"]) -> typing_extensions.Literal["changelist", "hash"] | None: ...
|
||||
def HasField(self, field_name: typing.Literal["changelist", b"changelist", "hash", b"hash", "kind", b"kind"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["changelist", b"changelist", "hash", b"hash", "kind", b"kind", "pending_changelist", b"pending_changelist", "snapshot", b"snapshot"]) -> None: ...
|
||||
def WhichOneof(self, oneof_group: typing.Literal["kind", b"kind"]) -> typing.Literal["changelist", "hash"] | None: ...
|
||||
|
||||
global___CommitId = CommitId
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CPUInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class CacheSizeEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -236,7 +243,7 @@ class CPUInfo(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
NUM_CORES_FIELD_NUMBER: builtins.int
|
||||
NUM_CORES_ALLOWED_FIELD_NUMBER: builtins.int
|
||||
@@ -259,6 +266,7 @@ class CPUInfo(google.protobuf.message.Message):
|
||||
@property
|
||||
def cache_size(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.int]:
|
||||
"""Cache sizes (in bytes), e.g. "L2": 262144 (for 256KB)"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -269,11 +277,11 @@ class CPUInfo(google.protobuf.message.Message):
|
||||
cpu_governor: builtins.str | None = ...,
|
||||
cache_size: collections.abc.Mapping[builtins.str, builtins.int] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["cache_size", b"cache_size", "cpu_governor", b"cpu_governor", "cpu_info", b"cpu_info", "mhz_per_cpu", b"mhz_per_cpu", "num_cores", b"num_cores", "num_cores_allowed", b"num_cores_allowed"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["cache_size", b"cache_size", "cpu_governor", b"cpu_governor", "cpu_info", b"cpu_info", "mhz_per_cpu", b"mhz_per_cpu", "num_cores", b"num_cores", "num_cores_allowed", b"num_cores_allowed"]) -> None: ...
|
||||
|
||||
global___CPUInfo = CPUInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MemoryInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -289,11 +297,11 @@ class MemoryInfo(google.protobuf.message.Message):
|
||||
total: builtins.int | None = ...,
|
||||
available: builtins.int | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["available", b"available", "total", b"total"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["available", b"available", "total", b"total"]) -> None: ...
|
||||
|
||||
global___MemoryInfo = MemoryInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class GPUInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -313,11 +321,11 @@ class GPUInfo(google.protobuf.message.Message):
|
||||
uuid: builtins.str | None = ...,
|
||||
bus_id: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bus_id", b"bus_id", "model", b"model", "uuid", b"uuid"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["bus_id", b"bus_id", "model", b"model", "uuid", b"uuid"]) -> None: ...
|
||||
|
||||
global___GPUInfo = GPUInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class PlatformInfo(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -349,11 +357,11 @@ class PlatformInfo(google.protobuf.message.Message):
|
||||
system: builtins.str | None = ...,
|
||||
version: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["bits", b"bits", "linkage", b"linkage", "machine", b"machine", "release", b"release", "system", b"system", "version", b"version"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["bits", b"bits", "linkage", b"linkage", "machine", b"machine", "release", b"release", "system", b"system", "version", b"version"]) -> None: ...
|
||||
|
||||
global___PlatformInfo = PlatformInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class AvailableDeviceInfo(google.protobuf.message.Message):
|
||||
"""Matches DeviceAttributes"""
|
||||
|
||||
@@ -379,11 +387,11 @@ class AvailableDeviceInfo(google.protobuf.message.Message):
|
||||
memory_limit: builtins.int | None = ...,
|
||||
physical_description: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["memory_limit", b"memory_limit", "name", b"name", "physical_description", b"physical_description", "type", b"type"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["memory_limit", b"memory_limit", "name", b"name", "physical_description", b"physical_description", "type", b"type"]) -> None: ...
|
||||
|
||||
global___AvailableDeviceInfo = AvailableDeviceInfo
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class MachineConfiguration(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -401,15 +409,19 @@ class MachineConfiguration(google.protobuf.message.Message):
|
||||
@property
|
||||
def platform_info(self) -> global___PlatformInfo:
|
||||
"""Additional platform information."""
|
||||
|
||||
@property
|
||||
def cpu_info(self) -> global___CPUInfo:
|
||||
"""CPU Information."""
|
||||
|
||||
@property
|
||||
def device_info(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[google.protobuf.any_pb2.Any]:
|
||||
"""Other devices that are attached and relevant (e.g. GPUInfo)."""
|
||||
|
||||
@property
|
||||
def available_device_info(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___AvailableDeviceInfo]:
|
||||
"""Devices accessible to the test (e.g. as given by list_local_devices)."""
|
||||
|
||||
@property
|
||||
def memory_info(self) -> global___MemoryInfo: ...
|
||||
def __init__(
|
||||
@@ -423,18 +435,18 @@ class MachineConfiguration(google.protobuf.message.Message):
|
||||
available_device_info: collections.abc.Iterable[global___AvailableDeviceInfo] | None = ...,
|
||||
memory_info: global___MemoryInfo | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["cpu_info", b"cpu_info", "memory_info", b"memory_info", "platform_info", b"platform_info"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["available_device_info", b"available_device_info", "cpu_info", b"cpu_info", "device_info", b"device_info", "hostname", b"hostname", "memory_info", b"memory_info", "platform_info", b"platform_info", "serial_identifier", b"serial_identifier"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["cpu_info", b"cpu_info", "memory_info", b"memory_info", "platform_info", b"platform_info"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["available_device_info", b"available_device_info", "cpu_info", b"cpu_info", "device_info", b"device_info", "hostname", b"hostname", "memory_info", b"memory_info", "platform_info", b"platform_info", "serial_identifier", b"serial_identifier"]) -> None: ...
|
||||
|
||||
global___MachineConfiguration = MachineConfiguration
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class RunConfiguration(google.protobuf.message.Message):
|
||||
"""Run-specific items such as arguments to the test / benchmark."""
|
||||
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class EnvVarsEntry(google.protobuf.message.Message):
|
||||
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
||||
|
||||
@@ -448,7 +460,7 @@ class RunConfiguration(google.protobuf.message.Message):
|
||||
key: builtins.str | None = ...,
|
||||
value: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...
|
||||
|
||||
ARGUMENT_FIELD_NUMBER: builtins.int
|
||||
ENV_VARS_FIELD_NUMBER: builtins.int
|
||||
@@ -457,17 +469,18 @@ class RunConfiguration(google.protobuf.message.Message):
|
||||
@property
|
||||
def env_vars(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]:
|
||||
"""Environment variables used to run the test/benchmark."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
argument: collections.abc.Iterable[builtins.str] | None = ...,
|
||||
env_vars: collections.abc.Mapping[builtins.str, builtins.str] | None = ...,
|
||||
) -> None: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["argument", b"argument", "env_vars", b"env_vars"]) -> None: ...
|
||||
def ClearField(self, field_name: typing.Literal["argument", b"argument", "env_vars", b"env_vars"]) -> None: ...
|
||||
|
||||
global___RunConfiguration = RunConfiguration
|
||||
|
||||
@typing_extensions.final
|
||||
@typing.final
|
||||
class TestResults(google.protobuf.message.Message):
|
||||
"""The output of one benchmark / test run. Each run contains a list of
|
||||
tests or benchmarks, stored as BenchmarkEntry messages.
|
||||
@@ -521,25 +534,10 @@ class TestResults(google.protobuf.message.Message):
|
||||
"""The target of the run, e.g.:
|
||||
//tensorflow/core:kernels_adjust_contrast_op_benchmark_test
|
||||
"""
|
||||
@property
|
||||
def entries(self) -> global___BenchmarkEntries:
|
||||
"""The list of tests or benchmarks in this run."""
|
||||
@property
|
||||
def build_configuration(self) -> global___BuildConfiguration:
|
||||
"""The configuration of the build (compiled opt? with cuda? any copts?)"""
|
||||
@property
|
||||
def commit_id(self) -> global___CommitId:
|
||||
"""The commit id (git hash or changelist)"""
|
||||
start_time: builtins.int
|
||||
"""The time the run started (in seconds of UTC time since Unix epoch)"""
|
||||
run_time: builtins.float
|
||||
"""The amount of time the total run took (wall time in seconds)"""
|
||||
@property
|
||||
def machine_configuration(self) -> global___MachineConfiguration:
|
||||
"""Machine-specific parameters (Platform and CPU info)"""
|
||||
@property
|
||||
def run_configuration(self) -> global___RunConfiguration:
|
||||
"""Run-specific parameters (arguments, etc)"""
|
||||
name: builtins.str
|
||||
"""Benchmark target identifier."""
|
||||
benchmark_type: global___TestResults.BenchmarkType.ValueType
|
||||
@@ -554,6 +552,26 @@ class TestResults(google.protobuf.message.Message):
|
||||
"""TensorFlow version this benchmark runs against.
|
||||
This can be either set to full version or just the major version.
|
||||
"""
|
||||
@property
|
||||
def entries(self) -> global___BenchmarkEntries:
|
||||
"""The list of tests or benchmarks in this run."""
|
||||
|
||||
@property
|
||||
def build_configuration(self) -> global___BuildConfiguration:
|
||||
"""The configuration of the build (compiled opt? with cuda? any copts?)"""
|
||||
|
||||
@property
|
||||
def commit_id(self) -> global___CommitId:
|
||||
"""The commit id (git hash or changelist)"""
|
||||
|
||||
@property
|
||||
def machine_configuration(self) -> global___MachineConfiguration:
|
||||
"""Machine-specific parameters (Platform and CPU info)"""
|
||||
|
||||
@property
|
||||
def run_configuration(self) -> global___RunConfiguration:
|
||||
"""Run-specific parameters (arguments, etc)"""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
@@ -570,7 +588,7 @@ class TestResults(google.protobuf.message.Message):
|
||||
run_mode: builtins.str | None = ...,
|
||||
tf_version: builtins.str | None = ...,
|
||||
) -> None: ...
|
||||
def HasField(self, field_name: typing_extensions.Literal["build_configuration", b"build_configuration", "commit_id", b"commit_id", "entries", b"entries", "machine_configuration", b"machine_configuration", "run_configuration", b"run_configuration"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing_extensions.Literal["benchmark_type", b"benchmark_type", "build_configuration", b"build_configuration", "commit_id", b"commit_id", "entries", b"entries", "machine_configuration", b"machine_configuration", "name", b"name", "run_configuration", b"run_configuration", "run_mode", b"run_mode", "run_time", b"run_time", "start_time", b"start_time", "target", b"target", "tf_version", b"tf_version"]) -> None: ...
|
||||
def HasField(self, field_name: typing.Literal["build_configuration", b"build_configuration", "commit_id", b"commit_id", "entries", b"entries", "machine_configuration", b"machine_configuration", "run_configuration", b"run_configuration"]) -> builtins.bool: ...
|
||||
def ClearField(self, field_name: typing.Literal["benchmark_type", b"benchmark_type", "build_configuration", b"build_configuration", "commit_id", b"commit_id", "entries", b"entries", "machine_configuration", b"machine_configuration", "name", b"name", "run_configuration", b"run_configuration", "run_mode", b"run_mode", "run_time", b"run_time", "start_time", b"start_time", "target", b"target", "tf_version", b"tf_version"]) -> None: ...
|
||||
|
||||
global___TestResults = TestResults
|
||||
|
||||
Reference in New Issue
Block a user