tf.IndexedSlicesSpec
| Просмотреть исходный код на GitHub |
Спецификация типа для tf.IndexedSlices.
Наследуется от: TypeSpec
tf.IndexedSlicesSpec(
shape=None, dtype=tf.dtypes.float32, indices_dtype=tf.dtypes.int64,
dense_shape_dtype=None, indices_shape=None
)
| Аргументы | |
|---|---|
shape | Плотную форму IndexedSlices, или None для разрешения любой плотной формы. |
dtype | tf.DType значений в IndexedSlices. |
indices_dtype | tf.DType индексов в indices в IndexedSlices. Один из tf.int32 или tf.int64. |
dense_shape_dtype | tf.DType разрезов в dense_shape в IndexedSlices. Один из tf.int32, tf.int64 или None (если у IndexedSlices нет тензора dense_shape). |
indices_shape | Форма компонента indices, которая указывает, сколько разрезов в IndexedSlices. |
| Атрибуты | |
|---|---|
value_type | |
Методы
is_compatible_with
is_compatible_with(
spec_or_value
)
Возвращает true, если spec_or_value совместим с этим TypeSpec.
most_specific_compatible_type
most_specific_compatible_type(
other
)
Возвращает самый специфичный TypeSpec, совместимый с self и other.
| Аргументы | |
|---|---|
other | Тип TypeSpec. |
| Исключения | |
|---|---|
ValueError | Если нет TypeSpec, совместимого с self и other. |
__eq__
__eq__(
other
)
Возвращает self==value.
__ne__
__ne__(
other
)
Возвращает self!=value.
© 2020 The TensorFlow Authors. All rights reserved.
Licensed under the Creative Commons Attribution License 3.0.
Code samples licensed under the Apache 2.0 License.
https://www.tensorflow.org/versions/r1.15/api_docs/python/tf/IndexedSlicesSpec