declearn.model.tensorflow.utils.add_indexed_slices_support
Wrap an input function to overload the handling of tf.IndexedSlices.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
tf_op |
Callable[[tf.Tensor, Any], tf.Tensor]
|
Tensor-processing operation that needs wrapping. |
required |
inplc |
bool
|
Whether to replace the second argument of |
False
|
Returns:
Name | Type | Description |
---|---|---|
func |
Callable[[TensorT, Any], TensorT]
|
Tensor-processing operation that wraps |
Source code in declearn/model/tensorflow/utils/_slices.py
110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 |
|