aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/c/c_api.h
diff options
context:
space:
mode:
authorGravatar Asim Shankar <ashankar@google.com>2017-05-24 14:25:41 -0700
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2017-05-24 14:29:01 -0700
commit63aa126486b7edd48a3c9b52e8d2047c17004c9f (patch)
tree0296d61d4ec0f6816ba0acba70309fd6bd47eb7d /tensorflow/c/c_api.h
parent1822073137e1ac431250ea6f89b2719aac8d4782 (diff)
C API/Windows: Export API functions that were accidentally left out.
PiperOrigin-RevId: 157037270
Diffstat (limited to 'tensorflow/c/c_api.h')
-rw-r--r--tensorflow/c/c_api.h19
1 files changed, 11 insertions, 8 deletions
diff --git a/tensorflow/c/c_api.h b/tensorflow/c/c_api.h
index ec9b01b388..c55bf70b9f 100644
--- a/tensorflow/c/c_api.h
+++ b/tensorflow/c/c_api.h
@@ -961,8 +961,9 @@ typedef struct TF_WhileParams {
// - Reference-type inputs
// - Directly referencing external tensors from the cond/body graphs (this is
// possible in the Python API)
-TF_WhileParams TF_NewWhile(TF_Graph* g, TF_Output* inputs, int ninputs,
- TF_Status* status);
+TF_CAPI_EXPORT extern TF_WhileParams TF_NewWhile(TF_Graph* g, TF_Output* inputs,
+ int ninputs,
+ TF_Status* status);
// Builds the while loop specified by `params` and returns the output tensors of
// the while loop in `outputs`. `outputs` should be allocated to size
@@ -972,13 +973,14 @@ TF_WhileParams TF_NewWhile(TF_Graph* g, TF_Output* inputs, int ninputs,
//
// Either this or TF_AbortWhile() must be called after a successful
// TF_NewWhile() call.
-void TF_FinishWhile(const TF_WhileParams* params, TF_Status* status,
- TF_Output* outputs);
+TF_CAPI_EXPORT extern void TF_FinishWhile(const TF_WhileParams* params,
+ TF_Status* status,
+ TF_Output* outputs);
// Frees `params`s resources without building a while loop. `params` is no
// longer valid after this returns. Either this or TF_FinishWhile() must be
// called after a successful TF_NewWhile() call.
-void TF_AbortWhile(const TF_WhileParams* params);
+TF_CAPI_EXPORT extern void TF_AbortWhile(const TF_WhileParams* params);
// Adds operations to compute the partial derivatives of sum of `y`s w.r.t `x`s,
// i.e., d(y_1 + y_2 + ...)/dx_1, d(y_1 + y_2 + ...)/dx_2...
@@ -994,8 +996,9 @@ void TF_AbortWhile(const TF_WhileParams* params);
// supports. See
// https://www.tensorflow.org/code/tensorflow/cc/gradients/README.md
// for instructions on how to add C++ more gradients.
-void TF_AddGradients(TF_Graph* g, TF_Output* y, int ny, TF_Output* x, int nx,
- TF_Output* dx, TF_Status* status, TF_Output* dy);
+TF_CAPI_EXPORT void TF_AddGradients(TF_Graph* g, TF_Output* y, int ny,
+ TF_Output* x, int nx, TF_Output* dx,
+ TF_Status* status, TF_Output* dy);
// TODO(josh11b): Register OpDef, available to all operations added
// to this graph.
@@ -1032,7 +1035,7 @@ TF_CAPI_EXPORT extern TF_Session* TF_NewSession(TF_Graph* graph,
//
// If successful, populates `graph` with the contents of the Graph and
// `meta_graph_def` with the MetaGraphDef of the loaded model.
-TF_Session* TF_LoadSessionFromSavedModel(
+TF_CAPI_EXPORT extern TF_Session* TF_LoadSessionFromSavedModel(
const TF_SessionOptions* session_options, const TF_Buffer* run_options,
const char* export_dir, const char* const* tags, int tags_len,
TF_Graph* graph, TF_Buffer* meta_graph_def, TF_Status* status);