aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/c/python_api.cc
Commit message (Collapse)AuthorAge
* Fix bug in SetResourceHandleShapeAndType.Gravatar Skye Wanderman-Milne2018-07-12
| | | | | | | Prior to this change, captured resource variables in TF functions (or any captured resource tensors) would not have shape information. PiperOrigin-RevId: 204347306
* Make TF functions work with _USE_C_SHAPES=True.Gravatar Skye Wanderman-Milne2018-04-24
| | | | | | | | | | It turns out regular functions need to manually copy handle data in addition to eager GraphModeFunctions, so I moved the C extensions to python_api.h from eager/c_api.h. This also cleans up function_test.py to assume the C API is enabled. PiperOrigin-RevId: 194158700
* Make _USE_C_API = True and _USE_C_SHAPES = False work with handle data, take 2.Gravatar Skye Wanderman-Milne2018-03-27
| | | | | | | | This change makes _set_shapes_for_outputs_c_api fetch and set Tensor._handle_data. This is necessary for running the Python shape inference code on resource tensors. PiperOrigin-RevId: 190681459
* Automated g4 rollback of changelist 190293303Gravatar A. Unique TensorFlower2018-03-26
| | | | PiperOrigin-RevId: 190479555
* Make _USE_C_API = True and _USE_C_SHAPES = False work with handle data.Gravatar Skye Wanderman-Milne2018-03-25
| | | | | | | | This change makes _set_shapes_for_outputs_c_api fetch and set Tensor._handle_data. This is necessary for running the Python shape inference code on resource tensors. PiperOrigin-RevId: 190293303
* Fix race in C API.Gravatar Skye Wanderman-Milne2018-03-12
| | | | | | | | | | | RecordMutation could race with ExtendSessionGraphHelper, which would release the graph lock and only keep the session lock when extending the session. Also makes sure thread annotations are on declarations, not definitions (otherwise they have no effect). PiperOrigin-RevId: 188747158
* Make graph construction work while graph is being concurrently run.Gravatar Skye Wanderman-Milne2018-03-06
| | | | | | The overall approach is to use Graph._lock to synchronize Session.run calls and construction methods that rely on graph mutation. We don't want to synchronize the actual running of the graph, only the Extend call, so this change exposes an ExtendSession method to the Python API and disables extending automatically in TF_SessionRun. PiperOrigin-RevId: 188106818
* Don't require shape functions when creating ops from Python using the C API.Gravatar Skye Wanderman-Milne2018-02-21
| | | | | | | There are many ops out there without shape functions, and it's very onerous to add UnknownShape to all of them. PiperOrigin-RevId: 186524294
* Add Operation._remove_all_control_inputs and use in ControlFlowContext.Gravatar Skye Wanderman-Milne2017-12-08
| | | | | | | This allows while loop gradients to work with the C API. This change also enables the C API for control flow tests. PiperOrigin-RevId: 178438424
* Check when session cannot run because its graph was modifiedGravatar Igor Ganichev2017-11-29
| | | | | | | | | | | | | With current tensorflow code, if user modifies some operation after session.run() was called, this modification will never make it to the C++ runtime and no errors will be raised leading to silent wrong results. This change adds checks for such cases when C API is enabled. We don't change the code path for C API being disabled because C API should be enabled by default soon. PiperOrigin-RevId: 177359630
* Validate shapes when updating edges from Python.Gravatar Olivia Nordquist2017-11-13
| | | | | | Uses MergeInput from shape_inference to check if the new input is compatible with the preexisting shape. Also this changes the MergeInput method. Previously, MergeInput would only return true if the shapes differed *and* the merge was successful. Now, MergeInput returns true only if the merge is successful. PiperOrigin-RevId: 175576173
* Fix some recently introduced invalid memory accesses.Gravatar Asim Shankar2017-11-03
| | | | PiperOrigin-RevId: 174535271
* partially exposing the _set_attr and _get_attr method in pythonGravatar Olivia Nordquist2017-10-31
| | | | PiperOrigin-RevId: 174113043
* implementing _update_input for the C APIGravatar Olivia Nordquist2017-09-26
| | | | PiperOrigin-RevId: 170147211
* detecting cycles when users add a control edge to a graphGravatar Olivia Nordquist2017-09-06
| | | | PiperOrigin-RevId: 167773598
* Implementing set_device for the C APIGravatar Olivia Nordquist2017-07-18
| | | | PiperOrigin-RevId: 162379684
* Introduce Python-only extensions to the C APIGravatar Skye Wanderman-Milne2017-07-12
Implements an incomplete version of Operation._add_control_input() using a new extension to make sure the plumbing works. This also adds header guards to c_api_internal.h, which were missing. For some reason the missing guards caused problems in the cmake build even though there doesn't appear to be any #include cycles. PiperOrigin-RevId: 161705859