Skip to content

Commit 3a05e68

Browse files
committed
update api-guides to v1.10
1 parent 25f5ee8 commit 3a05e68

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+1544
-1363
lines changed

api_guides/cc/guide.md

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,12 @@ You should, as a result, be sure you are following the
77
[`master` version of this doc](https://www.tensorflow.org/versions/master/api_guides/cc/guide),
88
in case there have been any changes.
99

10+
Note: The C++ API is only designed to work with TensorFlow `bazel build`.
11+
If you need a stand-alone option use the [C-api](../../install/lang_c.md).
12+
See [these instructions](https://docs.bazel.build/versions/master/external.html)
13+
for details on how to include TensorFlow as a subproject (instead of building
14+
your project from inside TensorFlow, as in this example).
15+
1016
[TOC]
1117

1218
TensorFlow's C++ API provides mechanisms for constructing and executing a data
@@ -92,7 +98,7 @@ We will delve into the details of each below.
9298

9399
### Scope
94100

95-
@{tensorflow::Scope} is the main data structure that holds the current state
101+
`tensorflow::Scope` is the main data structure that holds the current state
96102
of graph construction. A `Scope` acts as a handle to the graph being
97103
constructed, as well as storing TensorFlow operation properties. The `Scope`
98104
object is the first argument to operation constructors, and operations that use
@@ -102,7 +108,7 @@ explained further below.
102108

103109
Create a new `Scope` object by calling `Scope::NewRootScope`. This creates
104110
some resources such as a graph to which operations are added. It also creates a
105-
@{tensorflow::Status} object which will be used to indicate errors encountered
111+
`tensorflow::Status` object which will be used to indicate errors encountered
106112
when constructing operations. The `Scope` class has value semantics, thus, a
107113
`Scope` object can be freely copied and passed around.
108114

@@ -121,7 +127,7 @@ Here are some of the properties controlled by a `Scope` object:
121127
* Device placement for an operation
122128
* Kernel attribute for an operation
123129

124-
Please refer to @{tensorflow::Scope} for the complete list of member functions
130+
Please refer to `tensorflow::Scope` for the complete list of member functions
125131
that let you create child scopes with new properties.
126132

127133
### Operation Constructors
@@ -213,7 +219,7 @@ auto c = Concat(scope, s, 0);
213219

214220
You may pass many different types of C++ values directly to tensor
215221
constants. You may explicitly create a tensor constant by calling the
216-
@{tensorflow::ops::Const} function from various kinds of C++ values. For
222+
`tensorflow::ops::Const` function from various kinds of C++ values. For
217223
example:
218224

219225
* Scalars
@@ -257,14 +263,14 @@ auto y = Add(scope, {1, 2, 3, 4}, 10);
257263
## Graph Execution
258264
259265
When executing a graph, you will need a session. The C++ API provides a
260-
@{tensorflow::ClientSession} class that will execute ops created by the
266+
`tensorflow::ClientSession` class that will execute ops created by the
261267
operation constructors. TensorFlow will automatically determine which parts of
262268
the graph need to be executed, and what values need feeding. For example:
263269
264270
```c++
265271
Scope root = Scope::NewRootScope();
266272
auto c = Const(root, { {1, 1} });
267-
auto m = MatMul(root, c, { {42}, {1} });
273+
auto m = MatMul(root, c, { {41}, {1} });
268274
269275
ClientSession session(root);
270276
std::vector<Tensor> outputs;
@@ -291,5 +297,5 @@ session.Run({ {a, { {1, 2}, {3, 4} } } }, {c}, &outputs);
291297
// outputs[0] == [4 5; 6 7]
292298
```
293299
294-
Please see the @{tensorflow::Tensor} documentation for more information on how
300+
Please see the `tensorflow::Tensor` documentation for more information on how
295301
to use the execution output.

api_guides/python/array_ops.md

Lines changed: 60 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Tensor Transformations
22

33
Note: Functions taking `Tensor` arguments can also take anything accepted by
4-
@{tf.convert_to_tensor}.
4+
`tf.convert_to_tensor`.
55

66
[TOC]
77

@@ -10,78 +10,78 @@ Note: Functions taking `Tensor` arguments can also take anything accepted by
1010
TensorFlow provides several operations that you can use to cast tensor data
1111
types in your graph.
1212

13-
* @{tf.string_to_number}
14-
* @{tf.to_double}
15-
* @{tf.to_float}
16-
* @{tf.to_bfloat16}
17-
* @{tf.to_int32}
18-
* @{tf.to_int64}
19-
* @{tf.cast}
20-
* @{tf.bitcast}
21-
* @{tf.saturate_cast}
13+
* `tf.string_to_number`
14+
* `tf.to_double`
15+
* `tf.to_float`
16+
* `tf.to_bfloat16`
17+
* `tf.to_int32`
18+
* `tf.to_int64`
19+
* `tf.cast`
20+
* `tf.bitcast`
21+
* `tf.saturate_cast`
2222

2323
## Shapes and Shaping
2424

2525
TensorFlow provides several operations that you can use to determine the shape
2626
of a tensor and change the shape of a tensor.
2727

28-
* @{tf.broadcast_dynamic_shape}
29-
* @{tf.broadcast_static_shape}
30-
* @{tf.shape}
31-
* @{tf.shape_n}
32-
* @{tf.size}
33-
* @{tf.rank}
34-
* @{tf.reshape}
35-
* @{tf.squeeze}
36-
* @{tf.expand_dims}
37-
* @{tf.meshgrid}
28+
* `tf.broadcast_dynamic_shape`
29+
* `tf.broadcast_static_shape`
30+
* `tf.shape`
31+
* `tf.shape_n`
32+
* `tf.size`
33+
* `tf.rank`
34+
* `tf.reshape`
35+
* `tf.squeeze`
36+
* `tf.expand_dims`
37+
* `tf.meshgrid`
3838

3939
## Slicing and Joining
4040

4141
TensorFlow provides several operations to slice or extract parts of a tensor,
4242
or join multiple tensors together.
4343

44-
* @{tf.slice}
45-
* @{tf.strided_slice}
46-
* @{tf.split}
47-
* @{tf.tile}
48-
* @{tf.pad}
49-
* @{tf.concat}
50-
* @{tf.stack}
51-
* @{tf.parallel_stack}
52-
* @{tf.unstack}
53-
* @{tf.reverse_sequence}
54-
* @{tf.reverse}
55-
* @{tf.reverse_v2}
56-
* @{tf.transpose}
57-
* @{tf.extract_image_patches}
58-
* @{tf.space_to_batch_nd}
59-
* @{tf.space_to_batch}
60-
* @{tf.required_space_to_batch_paddings}
61-
* @{tf.batch_to_space_nd}
62-
* @{tf.batch_to_space}
63-
* @{tf.space_to_depth}
64-
* @{tf.depth_to_space}
65-
* @{tf.gather}
66-
* @{tf.gather_nd}
67-
* @{tf.unique_with_counts}
68-
* @{tf.scatter_nd}
69-
* @{tf.dynamic_partition}
70-
* @{tf.dynamic_stitch}
71-
* @{tf.boolean_mask}
72-
* @{tf.one_hot}
73-
* @{tf.sequence_mask}
74-
* @{tf.dequantize}
75-
* @{tf.quantize_v2}
76-
* @{tf.quantized_concat}
77-
* @{tf.setdiff1d}
44+
* `tf.slice`
45+
* `tf.strided_slice`
46+
* `tf.split`
47+
* `tf.tile`
48+
* `tf.pad`
49+
* `tf.concat`
50+
* `tf.stack`
51+
* `tf.parallel_stack`
52+
* `tf.unstack`
53+
* `tf.reverse_sequence`
54+
* `tf.reverse`
55+
* `tf.reverse_v2`
56+
* `tf.transpose`
57+
* `tf.extract_image_patches`
58+
* `tf.space_to_batch_nd`
59+
* `tf.space_to_batch`
60+
* `tf.required_space_to_batch_paddings`
61+
* `tf.batch_to_space_nd`
62+
* `tf.batch_to_space`
63+
* `tf.space_to_depth`
64+
* `tf.depth_to_space`
65+
* `tf.gather`
66+
* `tf.gather_nd`
67+
* `tf.unique_with_counts`
68+
* `tf.scatter_nd`
69+
* `tf.dynamic_partition`
70+
* `tf.dynamic_stitch`
71+
* `tf.boolean_mask`
72+
* `tf.one_hot`
73+
* `tf.sequence_mask`
74+
* `tf.dequantize`
75+
* `tf.quantize_v2`
76+
* `tf.quantized_concat`
77+
* `tf.setdiff1d`
7878

7979
## Fake quantization
8080
Operations used to help train for better quantization accuracy.
8181

82-
* @{tf.fake_quant_with_min_max_args}
83-
* @{tf.fake_quant_with_min_max_args_gradient}
84-
* @{tf.fake_quant_with_min_max_vars}
85-
* @{tf.fake_quant_with_min_max_vars_gradient}
86-
* @{tf.fake_quant_with_min_max_vars_per_channel}
87-
* @{tf.fake_quant_with_min_max_vars_per_channel_gradient}
82+
* `tf.fake_quant_with_min_max_args`
83+
* `tf.fake_quant_with_min_max_args_gradient`
84+
* `tf.fake_quant_with_min_max_vars`
85+
* `tf.fake_quant_with_min_max_vars_gradient`
86+
* `tf.fake_quant_with_min_max_vars_per_channel`
87+
* `tf.fake_quant_with_min_max_vars_per_channel_gradient`

api_guides/python/check_ops.md

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
11
# Asserts and boolean checks
22

3-
* @{tf.assert_negative}
4-
* @{tf.assert_positive}
5-
* @{tf.assert_proper_iterable}
6-
* @{tf.assert_non_negative}
7-
* @{tf.assert_non_positive}
8-
* @{tf.assert_equal}
9-
* @{tf.assert_integer}
10-
* @{tf.assert_less}
11-
* @{tf.assert_less_equal}
12-
* @{tf.assert_greater}
13-
* @{tf.assert_greater_equal}
14-
* @{tf.assert_rank}
15-
* @{tf.assert_rank_at_least}
16-
* @{tf.assert_type}
17-
* @{tf.is_non_decreasing}
18-
* @{tf.is_numeric_tensor}
19-
* @{tf.is_strictly_increasing}
3+
* `tf.assert_negative`
4+
* `tf.assert_positive`
5+
* `tf.assert_proper_iterable`
6+
* `tf.assert_non_negative`
7+
* `tf.assert_non_positive`
8+
* `tf.assert_equal`
9+
* `tf.assert_integer`
10+
* `tf.assert_less`
11+
* `tf.assert_less_equal`
12+
* `tf.assert_greater`
13+
* `tf.assert_greater_equal`
14+
* `tf.assert_rank`
15+
* `tf.assert_rank_at_least`
16+
* `tf.assert_type`
17+
* `tf.is_non_decreasing`
18+
* `tf.is_numeric_tensor`
19+
* `tf.is_strictly_increasing`

api_guides/python/client.md

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -3,34 +3,34 @@
33

44
This library contains classes for launching graphs and executing operations.
55

6-
@{$programmers_guide/low_level_intro$This guide} has examples of how a graph
7-
is launched in a @{tf.Session}.
6+
[This guide](../../guide/low_level_intro.md) has examples of how a graph
7+
is launched in a `tf.Session`.
88

99
## Session management
1010

11-
* @{tf.Session}
12-
* @{tf.InteractiveSession}
13-
* @{tf.get_default_session}
11+
* `tf.Session`
12+
* `tf.InteractiveSession`
13+
* `tf.get_default_session`
1414

1515
## Error classes and convenience functions
1616

17-
* @{tf.OpError}
18-
* @{tf.errors.CancelledError}
19-
* @{tf.errors.UnknownError}
20-
* @{tf.errors.InvalidArgumentError}
21-
* @{tf.errors.DeadlineExceededError}
22-
* @{tf.errors.NotFoundError}
23-
* @{tf.errors.AlreadyExistsError}
24-
* @{tf.errors.PermissionDeniedError}
25-
* @{tf.errors.UnauthenticatedError}
26-
* @{tf.errors.ResourceExhaustedError}
27-
* @{tf.errors.FailedPreconditionError}
28-
* @{tf.errors.AbortedError}
29-
* @{tf.errors.OutOfRangeError}
30-
* @{tf.errors.UnimplementedError}
31-
* @{tf.errors.InternalError}
32-
* @{tf.errors.UnavailableError}
33-
* @{tf.errors.DataLossError}
34-
* @{tf.errors.exception_type_from_error_code}
35-
* @{tf.errors.error_code_from_exception_type}
36-
* @{tf.errors.raise_exception_on_not_ok_status}
17+
* `tf.OpError`
18+
* `tf.errors.CancelledError`
19+
* `tf.errors.UnknownError`
20+
* `tf.errors.InvalidArgumentError`
21+
* `tf.errors.DeadlineExceededError`
22+
* `tf.errors.NotFoundError`
23+
* `tf.errors.AlreadyExistsError`
24+
* `tf.errors.PermissionDeniedError`
25+
* `tf.errors.UnauthenticatedError`
26+
* `tf.errors.ResourceExhaustedError`
27+
* `tf.errors.FailedPreconditionError`
28+
* `tf.errors.AbortedError`
29+
* `tf.errors.OutOfRangeError`
30+
* `tf.errors.UnimplementedError`
31+
* `tf.errors.InternalError`
32+
* `tf.errors.UnavailableError`
33+
* `tf.errors.DataLossError`
34+
* `tf.errors.exception_type_from_error_code`
35+
* `tf.errors.error_code_from_exception_type`
36+
* `tf.errors.raise_exception_on_not_ok_status`

api_guides/python/constant_op.md

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,25 @@
11
# Constants, Sequences, and Random Values
22

33
Note: Functions taking `Tensor` arguments can also take anything accepted by
4-
@{tf.convert_to_tensor}.
4+
`tf.convert_to_tensor`.
55

66
[TOC]
77

88
## Constant Value Tensors
99

1010
TensorFlow provides several operations that you can use to generate constants.
1111

12-
* @{tf.zeros}
13-
* @{tf.zeros_like}
14-
* @{tf.ones}
15-
* @{tf.ones_like}
16-
* @{tf.fill}
17-
* @{tf.constant}
12+
* `tf.zeros`
13+
* `tf.zeros_like`
14+
* `tf.ones`
15+
* `tf.ones_like`
16+
* `tf.fill`
17+
* `tf.constant`
1818

1919
## Sequences
2020

21-
* @{tf.linspace}
22-
* @{tf.range}
21+
* `tf.linspace`
22+
* `tf.range`
2323

2424
## Random Tensors
2525

@@ -29,11 +29,11 @@ time they are evaluated.
2929

3030
The `seed` keyword argument in these functions acts in conjunction with
3131
the graph-level random seed. Changing either the graph-level seed using
32-
@{tf.set_random_seed} or the
32+
`tf.set_random_seed` or the
3333
op-level seed will change the underlying seed of these operations. Setting
3434
neither graph-level nor op-level seed, results in a random seed for all
3535
operations.
36-
See @{tf.set_random_seed}
36+
See `tf.set_random_seed`
3737
for details on the interaction between operation-level and graph-level random
3838
seeds.
3939

@@ -64,7 +64,7 @@ print(sess.run(norm))
6464
```
6565

6666
Another common use of random values is the initialization of variables. Also see
67-
the @{$variables$Variables How To}.
67+
the [Variables How To](../../guide/variables.md).
6868

6969
```python
7070
# Use random uniform values in [0, 1) as the initializer for a variable of shape
@@ -77,11 +77,11 @@ sess.run(init)
7777
print(sess.run(var))
7878
```
7979

80-
* @{tf.random_normal}
81-
* @{tf.truncated_normal}
82-
* @{tf.random_uniform}
83-
* @{tf.random_shuffle}
84-
* @{tf.random_crop}
85-
* @{tf.multinomial}
86-
* @{tf.random_gamma}
87-
* @{tf.set_random_seed}
80+
* `tf.random_normal`
81+
* `tf.truncated_normal`
82+
* `tf.random_uniform`
83+
* `tf.random_shuffle`
84+
* `tf.random_crop`
85+
* `tf.multinomial`
86+
* `tf.random_gamma`
87+
* `tf.set_random_seed`

0 commit comments

Comments
 (0)