Skip to content

Commit b2dc60e

Browse files
committed
TensorFlow: Upstream changes to git.
Changes: - Documentation updates. - Relax numpy requirement to 1.9.2 Base CL: 107349632
1 parent 1d3874f commit b2dc60e

34 files changed

+398
-314
lines changed

tensorflow/core/ops/math_ops.cc

Lines changed: 20 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -626,7 +626,7 @@ REGISTER_OP("SegmentSum")
626626
.Doc(R"doc(
627627
Computes the sum along segments of a tensor.
628628
629-
Read [the section on Segmentation](../python/math_ops.md#segmentation)
629+
Read [the section on Segmentation](../../api_docs/python/math_ops.md#segmentation)
630630
for an explanation of segments.
631631
632632
Computes a tensor such that
@@ -653,8 +653,9 @@ REGISTER_OP("SegmentMean")
653653
.Doc(R"doc(
654654
Computes the mean along segments of a tensor.
655655
656-
Read [the section on Segmentation](../python/math_ops.md#segmentation)
657-
for an explanation of segments.
656+
Read [the section on
657+
Segmentation](../../api_docs/python/math_ops.md#segmentation) for an explanation
658+
of segments.
658659
659660
Computes a tensor such that
660661
\\(output_i = \frac{\sum_j data_j}{N}\\) where `mean` is
@@ -681,8 +682,9 @@ REGISTER_OP("SegmentProd")
681682
.Doc(R"doc(
682683
Computes the product along segments of a tensor.
683684
684-
Read [the section on Segmentation](../python/math_ops.md#segmentation)
685-
for an explanation of segments.
685+
Read [the section on
686+
Segmentation](../../api_docs/python/math_ops.md#segmentation) for an explanation
687+
of segments.
686688
687689
Computes a tensor such that
688690
\\(output_i = \prod_j data_j\\) where the product is over `j` such
@@ -708,8 +710,9 @@ REGISTER_OP("SegmentMin")
708710
.Doc(R"doc(
709711
Computes the minimum along segments of a tensor.
710712
711-
Read [the section on Segmentation](../python/math_ops.md#segmentation)
712-
for an explanation of segments.
713+
Read [the section on
714+
Segmentation](../../api_docs/python/math_ops.md#segmentation) for an explanation
715+
of segments.
713716
714717
Computes a tensor such that
715718
\\(output_i = \min_j(data_j)\\) where `min` is over `j` such
@@ -735,7 +738,7 @@ REGISTER_OP("SegmentMax")
735738
.Doc(R"doc(
736739
Computes the maximum along segments of a tensor.
737740
738-
Read [the section on Segmentation](../python/math_ops.md#segmentation)
741+
Read [the section on Segmentation](../../api_docs/python/math_ops.md#segmentation)
739742
for an explanation of segments.
740743
741744
Computes a tensor such that
@@ -763,8 +766,9 @@ REGISTER_OP("UnsortedSegmentSum")
763766
.Doc(R"doc(
764767
Computes the sum along segments of a tensor.
765768
766-
Read [the section on Segmentation](../python/math_ops.md#segmentation)
767-
for an explanation of segments.
769+
Read [the section on
770+
Segmentation](../../api_docs/python/math_ops.md#segmentation) for an explanation
771+
of segments.
768772
769773
Computes a tensor such that
770774
\\(output_i = \sum_j data_j\\) where sum is over `j` such
@@ -797,8 +801,9 @@ REGISTER_OP("SparseSegmentSum")
797801
.Doc(R"doc(
798802
Computes the sum along sparse segments of a tensor.
799803
800-
Read [the section on Segmentation](../python/math_ops.md#segmentation)
801-
for an explanation of segments.
804+
Read [the section on
805+
Segmentation](../../api_docs/python/math_ops.md#segmentation) for an explanation
806+
of segments.
802807
803808
Like `SegmentSum`, but `segment_ids` can have rank less than `data`'s first
804809
dimension, selecting a subset of dimension_0, specified by `indices`.
@@ -843,8 +848,9 @@ REGISTER_OP("SparseSegmentMean")
843848
.Doc(R"doc(
844849
Computes the mean along sparse segments of a tensor.
845850
846-
Read [the section on Segmentation](../python/math_ops.md#segmentation)
847-
for an explanation of segments.
851+
Read [the section on
852+
Segmentation](../../api_docs/python/math_ops.md#segmentation) for an explanation
853+
of segments.
848854
849855
Like `SegmentMean`, but `segment_ids` can have rank less than `data`'s first
850856
dimension, selecting a subset of dimension_0, specified by `indices`.

tensorflow/g3doc/api_docs/cc/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
TensorFlow's public C++ API includes only the API for executing graphs, as of
44
version 0.5. To control the execution of a graph from C++:
55

6-
1. Build the computation graph using the [Python API](../python/).
7-
1. Use [tf.train.write_graph()](../python/train.md#write_graph) to
6+
1. Build the computation graph using the [Python API](../../api_docs/python/).
7+
1. Use [tf.train.write_graph()](../../api_docs/python/train.md#write_graph) to
88
write the graph to a file.
99
1. Load the graph using the C++ Session API. For example:
1010

tensorflow/g3doc/api_docs/python/array_ops.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
# Tensor Transformations <a class="md-anchor" id="AUTOGENERATED-tensor-transformations"></a>
44

5-
Note: Functions taking `Tensor` arguments can also take anything
6-
accepted by [`tf.convert_to_tensor`](framework.md#convert_to_tensor).
5+
Note: Functions taking `Tensor` arguments can also take anything accepted by
6+
[`tf.convert_to_tensor`](../../api_docs/python/framework.md#convert_to_tensor).
77

88
<!-- TOC-BEGIN This section is generated by neural network: DO NOT EDIT! -->
99
## Contents

tensorflow/g3doc/api_docs/python/client.md

Lines changed: 53 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,8 @@ print sess.run(c)
6161
```
6262

6363
A session may own resources, such as
64-
[variables](state_ops.md#Variable), [queues](io_ops.md#QueueBase),
65-
and [readers](io_ops.md#ReaderBase). It is important to release
64+
[variables](../../api_docs/python/state_ops.md#Variable), [queues](../../api_docs/python/io_ops.md#QueueBase),
65+
and [readers](../../api_docs/python/io_ops.md#ReaderBase). It is important to release
6666
these resources when they are no longer required. To do this, either
6767
invoke the [`close()`](#Session.close) method on the session, or use
6868
the session as a context manager. The following two examples are
@@ -134,30 +134,31 @@ graph element, and these determine the return value of this
134134
method. A graph element can be one of the following types:
135135

136136
* If the *i*th element of `fetches` is an
137-
[`Operation`](framework.md#Operation), the *i*th return value
138-
will be `None`.
137+
[`Operation`](../../api_docs/python/framework.md#Operation), the *i*th
138+
return value will be `None`.
139139
* If the *i*th element of `fetches` is a
140-
[`Tensor`](framework.md#Tensor), the *i*th return value will
141-
be a numpy ndarray containing the value of that tensor.
140+
[`Tensor`](../../api_docs/python/framework.md#Tensor), the *i*th return
141+
value will be a numpy ndarray containing the value of that tensor.
142142
* If the *i*th element of `fetches` is a
143-
[`SparseTensor`](sparse_ops.md#SparseTensor), the *i*th
144-
return value will be a
145-
[`SparseTensorValue`](sparse_ops.md#SparseTensorValue)
143+
[`SparseTensor`](../../api_docs/python/sparse_ops.md#SparseTensor),
144+
the *i*th return value will be a
145+
[`SparseTensorValue`](../../api_docs/python/sparse_ops.md#SparseTensorValue)
146146
containing the value of that sparse tensor.
147147

148148
The optional `feed_dict` argument allows the caller to override
149149
the value of tensors in the graph. Each key in `feed_dict` can be
150150
one of the following types:
151151

152-
* If the key is a [`Tensor`](framework.md#Tensor), the
152+
* If the key is a [`Tensor`](../../api_docs/python/framework.md#Tensor), the
153153
value may be a Python scalar, string, list, or numpy ndarray
154154
that can be converted to the same `dtype` as that
155155
tensor. Additionally, if the key is a
156-
[placeholder](io_ops.md#placeholder), the shape of the value
157-
will be checked for compatibility with the placeholder.
158-
* If the key is a [`SparseTensor`](sparse_ops.md#SparseTensor),
156+
[placeholder](../../api_docs/python/io_ops.md#placeholder), the shape of
157+
the value will be checked for compatibility with the placeholder.
158+
* If the key is a
159+
[`SparseTensor`](../../api_docs/python/sparse_ops.md#SparseTensor),
159160
the value should be a
160-
[`SparseTensorValue`](sparse_ops.md#SparseTensorValue).
161+
[`SparseTensorValue`](../../api_docs/python/sparse_ops.md#SparseTensorValue).
161162

162163
##### Args: <a class="md-anchor" id="AUTOGENERATED-args-"></a>
163164

@@ -211,9 +212,9 @@ The graph that was launched in this session.
211212
Returns a context manager that makes this object the default session.
212213

213214
Use with the `with` keyword to specify that calls to
214-
[`Operation.run()`](framework.md#Operation.run) or
215-
[`Tensor.run()`](framework.md#Tensor.run) should be executed in
216-
this session.
215+
[`Operation.run()`](../../api_docs/python/framework.md#Operation.run) or
216+
[`Tensor.run()`](../../api_docs/python/framework.md#Tensor.run) should be
217+
executed in this session.
217218

218219
```python
219220
c = tf.constant(..)
@@ -267,9 +268,9 @@ A TensorFlow `Session` for use in interactive contexts, such as a shell.
267268

268269
The only difference with a regular `Session` is that an `InteractiveSession`
269270
installs itself as the default session on construction.
270-
The methods [`Tensor.eval()`](framework.md#Tensor.eval) and
271-
[`Operation.run()`](framework.md#Operation.run) will use that session
272-
to run ops.
271+
The methods [`Tensor.eval()`](../../api_docs/python/framework.md#Tensor.eval)
272+
and [`Operation.run()`](../../api_docs/python/framework.md#Operation.run)
273+
will use that session to run ops.
273274

274275
This is convenient in interactive shells and [IPython
275276
notebooks](http://ipython.org), as it avoids having to pass an explicit
@@ -371,7 +372,7 @@ The operation that failed, if known.
371372

372373
*N.B.* If the failed op was synthesized at runtime, e.g. a `Send`
373374
or `Recv` op, there will be no corresponding
374-
[`Operation`](framework.md#Operation) object. In that case, this
375+
[`Operation`](../../api_docs/python/framework.md#Operation) object. In that case, this
375376
will return `None`, and you should instead use the
376377
[`OpError.node_def`](#OpError.node_def) to discover information about the
377378
op.
@@ -423,11 +424,12 @@ The error message that describes the error.
423424
Raised when an operation or step is cancelled.
424425

425426
For example, a long-running operation (e.g.
426-
[`queue.enqueue()`](io_ops.md#QueueBase.enqueue) may be cancelled by
427-
running another operation (e.g.
428-
[`queue.close(cancel_pending_enqueues=True)`](io_ops.md#QueueBase.close),
429-
or by [closing the session](client.md#Session.close). A step that is
430-
running such a long-running operation will fail by raising `CancelledError`.
427+
[`queue.enqueue()`](../../api_docs/python/io_ops.md#QueueBase.enqueue) may be
428+
cancelled by running another operation (e.g.
429+
[`queue.close(cancel_pending_enqueues=True)`](../../api_docs/python/io_ops.md#QueueBase.close),
430+
or by [closing the session](../../api_docs/python/client.md#Session.close).
431+
A step that is running such a long-running operation will fail by raising
432+
`CancelledError`.
431433

432434
- - -
433435

@@ -465,10 +467,10 @@ Raised when an operation receives an invalid argument.
465467

466468
This may occur, for example, if an operation is receives an input
467469
tensor that has an invalid value or shape. For example, the
468-
[`tf.matmul()`](math_ops.md#matmul) op will raise this error if it
469-
receives an input that is not a matrix, and the
470-
[`tf.reshape()`](array_ops.md#reshape) op will raise this error if
471-
the new shape does not match the number of elements in the input
470+
[`tf.matmul()`](../../api_docs/python/math_ops.md#matmul) op will raise this
471+
error if it receives an input that is not a matrix, and the
472+
[`tf.reshape()`](../../api_docs/python/array_ops.md#reshape) op will raise
473+
this error if the new shape does not match the number of elements in the input
472474
tensor.
473475

474476
- - -
@@ -502,8 +504,8 @@ Creates a `DeadlineExceededError`.
502504
Raised when a requested entity (e.g., a file or directory) was not found.
503505

504506
For example, running the
505-
[`tf.WholeFileReader.read()`](io_ops.md#WholeFileReader) operation
506-
could raise `NotFoundError` if it receives the name of a file that
507+
[`tf.WholeFileReader.read()`](../../api_docs/python/io_ops.md#WholeFileReader)
508+
operation could raise `NotFoundError` if it receives the name of a file that
507509
does not exist.
508510

509511
- - -
@@ -521,8 +523,8 @@ Creates a `NotFoundError`.
521523
Raised when an entity that we attempted to create already exists.
522524

523525
For example, running an operation that saves a file
524-
(e.g. [`tf.train.Saver.save()`](train.md#Saver.save)) could
525-
potentially raise this exception if an explicit filename for an
526+
(e.g. [`tf.train.Saver.save()`](../../api_docs/python/train.md#Saver.save))
527+
could potentially raise this exception if an explicit filename for an
526528
existing file was passed.
527529

528530
- - -
@@ -540,8 +542,8 @@ Creates an `AlreadyExistsError`.
540542
Raised when the caller does not have permission to run an operation.
541543

542544
For example, running the
543-
[`tf.WholeFileReader.read()`](io_ops.md#WholeFileReader) operation
544-
could raise `PermissionDeniedError` if it receives the name of a
545+
[`tf.WholeFileReader.read()`](../../api_docs/python/io_ops.md#WholeFileReader)
546+
operation could raise `PermissionDeniedError` if it receives the name of a
545547
file for which the user does not have the read file permission.
546548

547549
- - -
@@ -592,8 +594,8 @@ Creates a `ResourceExhaustedError`.
592594
Operation was rejected because the system is not in a state to execute it.
593595

594596
This exception is most commonly raised when running an operation
595-
that reads a [`tf.Variable`](state_ops.md#Variable) before it has
596-
been initialized.
597+
that reads a [`tf.Variable`](../../api_docs/python/state_ops.md#Variable)
598+
before it has been initialized.
597599

598600
- - -
599601

@@ -609,9 +611,11 @@ Creates a `FailedPreconditionError`.
609611

610612
The operation was aborted, typically due to a concurrent action.
611613

612-
For example, running a [`queue.enqueue()`](io_ops.md#QueueBase.enqueue)
614+
For example, running a
615+
[`queue.enqueue()`](../../api_docs/python/io_ops.md#QueueBase.enqueue)
613616
operation may raise `AbortedError` if a
614-
[`queue.close()`](io_ops.md#QueueBase.close) operation previously ran.
617+
[`queue.close()`](../../api_docs/python/io_ops.md#QueueBase.close) operation
618+
previously ran.
615619

616620
- - -
617621

@@ -628,9 +632,10 @@ Creates an `AbortedError`.
628632
Raised when an operation executed past the valid range.
629633

630634
This exception is raised in "end-of-file" conditions, such as when a
631-
[`queue.dequeue()`](io_ops.md#QueueBase.dequeue) operation is
632-
blocked on an empty queue, and a
633-
[`queue.close()`](io_ops.md#QueueBase.close) operation executes.
635+
[`queue.dequeue()`](../../api_docs/python/io_ops.md#QueueBase.dequeue)
636+
operation is blocked on an empty queue, and a
637+
[`queue.close()`](../../api_docs/python/io_ops.md#QueueBase.close)
638+
operation executes.
634639

635640
- - -
636641

@@ -648,9 +653,9 @@ Raised when an operation has not been implemented.
648653

649654
Some operations may raise this error when passed otherwise-valid
650655
arguments that it does not currently support. For example, running
651-
the [`tf.nn.max_pool()`](nn.md#max_pool) operation would raise this
652-
error if pooling was requested on the batch dimension, because this
653-
is not yet supported.
656+
the [`tf.nn.max_pool()`](../../api_docs/python/nn.md#max_pool) operation
657+
would raise this error if pooling was requested on the batch dimension,
658+
because this is not yet supported.
654659

655660
- - -
656661

@@ -700,8 +705,8 @@ Creates an `UnavailableError`.
700705
Raised when unrecoverable data loss or corruption is encountered.
701706

702707
For example, this may be raised by running a
703-
[`tf.WholeFileReader.read()`](io_ops.md#WholeFileReader) operation,
704-
if the file is truncated while it is being read.
708+
[`tf.WholeFileReader.read()`](../../api_docs/python/io_ops.md#WholeFileReader)
709+
operation, if the file is truncated while it is being read.
705710

706711
- - -
707712

0 commit comments

Comments
 (0)