aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/python/pywrap_tfe.i
diff options
context:
space:
mode:
Diffstat (limited to 'tensorflow/python/pywrap_tfe.i')
-rw-r--r--tensorflow/python/pywrap_tfe.i16
1 files changed, 16 insertions, 0 deletions
diff --git a/tensorflow/python/pywrap_tfe.i b/tensorflow/python/pywrap_tfe.i
index ffa6d10cfa..07e715ede6 100644
--- a/tensorflow/python/pywrap_tfe.i
+++ b/tensorflow/python/pywrap_tfe.i
@@ -61,6 +61,22 @@ limitations under the License.
}
}
+%typemap(in) const char* serialized_function_def {
+ $1 = TFE_GetPyThonString($input);
+}
+
+%typemap(in) const char* device_name {
+ if ($input == Py_None) {
+ $1 = nullptr;
+ } else {
+ $1 = TFE_GetPyThonString($input);
+ }
+}
+
+%typemap(in) const char* op_name {
+ $1 = TFE_GetPyThonString($input);
+}
+
%include "tensorflow/c/eager/c_api.h"
%typemap(in) TFE_InputTensorHandles* inputs (TFE_InputTensorHandles temp) {