Tensorflow Python API

Building Graphs > Core graph data structures

Members
class tf.GraphA TensorFlow computation, represented as a dataflow graph.
tf.Graph.__init__()Creates a new, empty Graph.
tf.Graph.as_default()Returns a context manager that makes this Graph the default graph.
tf.Graph.as_graph_def(from_version=None, add_shapes=False)Returns a serialized GraphDef representation of this graph.
tf.Graph.finalize()Finalizes this graph, making it read-only.
tf.Graph.finalizedTrue if this graph has been finalized.
tf.Graph.control_dependencies(control_inputs)Returns a context manager that specifies control dependencies.
tf.Graph.device(device_name_or_function)Returns a context manager that specifies the default device to use.
tf.Graph.name_scope(name)Returns a context manager that creates hierarchical names for operations.
tf.Graph.add_to_collection(name, value)Stores value in the collection with the given name.
tf.Graph.add_to_collections(names, value)Stores value in the collections given by names.
tf.Graph.get_collection(name, scope=None)Returns a list of values in the collection with the given name.
tf.Graph.get_collection_ref(name)Returns a list of values in the collection with the given name.
tf.Graph.as_graph_element(obj, allow_tensor=True, allow_operation=True)Returns the object referred to by obj, as an Operation or Tensor.
tf.Graph.get_operation_by_name(name)Returns the Operation with the given name.
tf.Graph.get_tensor_by_name(name)Returns the Tensor with the given name.
tf.Graph.get_operations()Return the list of operations in the graph.
tf.Graph.seedThe graph-level random seed of this graph.
tf.Graph.unique_name(name, mark_as_used=True)Return a unique operation name for name.
tf.Graph.versionReturns a version number that increases as ops are added to the graph.
tf.Graph.graph_def_versionsThe GraphDef version information of this graph.
tf.Graph.create_op(op_type, inputs, dtypes, input_types=None, name=None, attrs=None, op_def=None, compute_shapes=True, compute_device=True)Creates an Operation in this graph.
tf.Graph.gradient_override_map(op_type_map)EXPERIMENTAL: A context manager for overriding gradient functions.
tf.Graph.colocate_with(op, ignore_existing=False)Returns a context manager that specifies an op to colocate with.
tf.Graph.container(container_name)Returns a context manager that specifies the resource container to use.
tf.Graph.get_all_collection_keys()Returns a list of collections used in this graph.
tf.Graph.is_feedable(tensor)Returns True if and only if tensor is feedable.
tf.Graph.is_fetchable(tensor_or_op)Returns True if and only if tensor_or_op is fetchable.
tf.Graph.prevent_feeding(tensor)Marks the given tensor as unfeedable in this graph.
tf.Graph.prevent_fetching(op)Marks the given op as unfetchable in this graph.
class tf.OperationRepresents a graph node that performs computation on tensors.
tf.Operation.nameThe full name of this operation.
tf.Operation.typeThe type of the op (e.g. "MatMul").
tf.Operation.inputsThe list of Tensor objects representing the data inputs of this op.
tf.Operation.control_inputsThe Operation objects on which this op has a control dependency.
tf.Operation.outputsThe list of Tensor objects representing the outputs of this op.
tf.Operation.deviceThe name of the device to which this op has been assigned, if any.
tf.Operation.graphThe Graph that contains this operation.
tf.Operation.run(feed_dict=None, session=None)Runs this operation in a Session.
tf.Operation.get_attr(name)Returns the value of the attr of this op with the given name.
tf.Operation.tracebackReturns the call stack from when this operation was constructed.
tf.Operation.__init__(node_def, g, inputs=None, output_types=None, control_inputs=None, input_types=None, original_op=None, op_def=None)Creates an Operation.
tf.Operation.colocation_groups()Returns the list of colocation groups of the op.
tf.Operation.node_defReturns a serialized NodeDef representation of this operation.
tf.Operation.op_defReturns the OpDef proto that represents the type of this op.
tf.Operation.values()DEPRECATED: Use outputs.
class tf.TensorRepresents one of the outputs of an Operation.
tf.Tensor.dtypeThe DType of elements in this tensor.
tf.Tensor.nameThe string name of this tensor.
tf.Tensor.value_indexThe index of this tensor in the outputs of its Operation.
tf.Tensor.graphThe Graph that contains this tensor.
tf.Tensor.opThe Operation that produces this tensor as an output.
tf.Tensor.consumers()Returns a list of Operations that consume this tensor.
tf.Tensor.eval(feed_dict=None, session=None)Evaluates this tensor in a Session.
tf.Tensor.get_shape()Returns the TensorShape that represents the shape of this tensor.
tf.Tensor.set_shape(shape)Updates the shape of this tensor.
tf.Tensor.__init__(op, value_index, dtype)Creates a new Tensor.
tf.Tensor.deviceThe name of the device on which this tensor will be produced, or None.

Building Graphs > Tensor types

Members
class tf.DTypeRepresents the type of the elements in a Tensor.
tf.DType.is_compatible_with(other)Returns True if the other DType will be converted to this DType.
tf.DType.nameReturns the string name for this DType.
tf.DType.base_dtypeReturns a non-reference DType based on this DType.
tf.DType.real_dtypeReturns the dtype correspond to this dtype's real part.
tf.DType.is_ref_dtypeReturns True if this DType represents a reference type.
tf.DType.as_refReturns a reference DType based on this DType.
tf.DType.is_floatingReturns whether this is a (real) floating point type.
tf.DType.is_complexReturns whether this is a complex floating point type.
tf.DType.is_integerReturns whether this is a (non-quantized) integer type.
tf.DType.is_quantizedReturns whether this is a quantized data type.
tf.DType.is_unsignedReturns whether this type is unsigned.
tf.DType.as_numpy_dtypeReturns a numpy.dtype based on this DType.
tf.DType.as_datatype_enumReturns a types_pb2.DataType enum value based on this DType.
tf.DType.__init__(type_enum)Creates a new DataType.
tf.DType.maxReturns the maximum representable value in this data type.
tf.DType.minReturns the minimum representable value in this data type.
tf.DType.size
tf.as_dtype(type_value)Converts the given type_value to a DType.

Building Graphs > Utility functions

Members
tf.device(device_name_or_function)Wrapper for Graph.device() using the default graph.
tf.container(container_name)Wrapper for Graph.container() using the default graph.
tf.name_scope(name)Wrapper for Graph.name_scope() using the default graph.
tf.control_dependencies(control_inputs)Wrapper for Graph.control_dependencies() using the default graph.
tf.convert_to_tensor(value, dtype=None, name=None, as_ref=False)Converts the given value to a Tensor.
tf.convert_to_tensor_or_indexed_slices(value, dtype=None, name=None, as_ref=False)Converts the given object to a Tensor or an IndexedSlices.
tf.get_default_graph()Returns the default graph for the current thread.
tf.reset_default_graph()Clears the default graph stack and resets the global default graph.
tf.import_graph_def(graph_def, input_map=None, return_elements=None, name=None, op_dict=None, producer_op_list=None)Imports the TensorFlow graph in graph_def into the Python Graph.
tf.load_file_system_library(library_filename)Loads a TensorFlow plugin, containing file system implementation.
tf.load_op_library(library_filename)Loads a TensorFlow plugin, containing custom ops and kernels.

Building Graphs > Graph collections

Members
tf.add_to_collection(name, value)Wrapper for Graph.add_to_collection() using the default graph.
tf.get_collection(key, scope=None)Wrapper for Graph.get_collection() using the default graph.
tf.get_collection_ref(key)Wrapper for Graph.get_collection_ref() using the default graph.
class tf.GraphKeysStandard names to use for graph collections.

Building Graphs > Defining new operations

Members
class tf.RegisterGradientA decorator for registering the gradient function for an op type.
tf.RegisterGradient.__init__(op_type)Creates a new decorator with op_type as the Operation type.
tf.NoGradient(op_type)Specifies that ops of type op_type do not have a defined gradient.
class tf.RegisterShapeA decorator for registering the shape function for an op type.
tf.RegisterShape.__init__(op_type)Saves the op_type as the Operation type.
class tf.TensorShapeRepresents the shape of a Tensor.
tf.TensorShape.merge_with(other)Returns a TensorShape combining the information in self and other.
tf.TensorShape.concatenate(other)Returns the concatenation of the dimension in self and other.
tf.TensorShape.ndimsReturns the rank of this shape, or None if it is unspecified.
tf.TensorShape.dimsReturns a list of Dimensions, or None if the shape is unspecified.
tf.TensorShape.as_list()Returns a list of integers or None for each dimension.
tf.TensorShape.as_proto()Returns this shape as a TensorShapeProto.
tf.TensorShape.is_compatible_with(other)Returns True iff self is compatible with other.
tf.TensorShape.is_fully_defined()Returns True iff self is fully defined in every dimension.
tf.TensorShape.with_rank(rank)Returns a shape based on self with the given rank.
tf.TensorShape.with_rank_at_least(rank)Returns a shape based on self with at least the given rank.
tf.TensorShape.with_rank_at_most(rank)Returns a shape based on self with at most the given rank.
tf.TensorShape.assert_has_rank(rank)Raises an exception if self is not compatible with the given rank.
tf.TensorShape.assert_same_rank(other)Raises an exception if self and other do not have compatible ranks.
tf.TensorShape.assert_is_compatible_with(other)Raises exception if self and other do not represent the same shape.
tf.TensorShape.assert_is_fully_defined()Raises an exception if self is not fully defined in every dimension.
tf.TensorShape.__init__(dims)Creates a new TensorShape with the given dimensions.
tf.TensorShape.num_elements()Returns the total number of elements, or none for incomplete shapes.
class tf.DimensionRepresents the value of one dimension in a TensorShape.
tf.Dimension.__init__(value)Creates a new Dimension with the given value.
tf.Dimension.assert_is_compatible_with(other)Raises an exception if other is not compatible with this Dimension.
tf.Dimension.is_compatible_with(other)Returns true if other is compatible with this Dimension.
tf.Dimension.merge_with(other)Returns a Dimension that combines the information in self and other.
tf.Dimension.valueThe value of this dimension, or None if it is unknown.
tf.op_scope(values, name, default_name=None)Returns a context manager for use when defining a Python op.
tf.get_seed(op_seed)Returns the local seeds an operation should use given an op-specific seed.

Building Graphs > For libraries building on TensorFlow

Members
tf.register_tensor_conversion_function(base_type, conversion_func, priority=100)Registers a function for converting objects of base_type to Tensor.

Building Graphs > Other Functions and Classes

Members
class tf.DeviceSpecRepresents a (possibly partial) specification for a TensorFlow device.
tf.DeviceSpec.__init__(job=None, replica=None, task=None, device_type=None, device_index=None)Create a new DeviceSpec object.
tf.DeviceSpec.from_string(spec)Construct a DeviceSpec from a string.
tf.DeviceSpec.job
tf.DeviceSpec.merge_from(dev)Merge the properties of "dev" into this DeviceSpec.
tf.DeviceSpec.parse_from_string(spec)Parse a DeviceSpec name into its components.
tf.DeviceSpec.replica
tf.DeviceSpec.task
tf.DeviceSpec.to_string()Return a string representation of this DeviceSpec.
class tf.bytesstr(object='') -> string

Asserts and boolean checks. > Asserts and Boolean Checks

Members
tf.assert_negative(x, data=None, summarize=None, message=None, name=None)Assert the condition x < 0 holds element-wise.
tf.assert_positive(x, data=None, summarize=None, message=None, name=None)Assert the condition x > 0 holds element-wise.
tf.assert_proper_iterable(values)Static assert that values is a "proper" iterable.
tf.assert_non_negative(x, data=None, summarize=None, message=None, name=None)Assert the condition x >= 0 holds element-wise.
tf.assert_non_positive(x, data=None, summarize=None, message=None, name=None)Assert the condition x <= 0 holds element-wise.
tf.assert_equal(x, y, data=None, summarize=None, message=None, name=None)Assert the condition x == y holds element-wise.
tf.assert_integer(x, message=None, name=None)Assert that x is of integer dtype.
tf.assert_less(x, y, data=None, summarize=None, message=None, name=None)Assert the condition x < y holds element-wise.
tf.assert_less_equal(x, y, data=None, summarize=None, message=None, name=None)Assert the condition x <= y holds element-wise.
tf.assert_rank(x, rank, data=None, summarize=None, message=None, name=None)Assert x has rank equal to rank.
tf.assert_rank_at_least(x, rank, data=None, summarize=None, message=None, name=None)Assert x has rank equal to rank or higher.
tf.assert_type(tensor, tf_type, message=None, name=None)Statically asserts that the given Tensor is of the specified type.
tf.is_non_decreasing(x, name=None)Returns True if x is non-decreasing.
tf.is_numeric_tensor(tensor)
tf.is_strictly_increasing(x, name=None)Returns True if x is strictly increasing.

Constants, Sequences, and Random Values > Constant Value Tensors

Members
tf.zeros(shape, dtype=tf.float32, name=None)Creates a tensor with all elements set to zero.
tf.zeros_like(tensor, dtype=None, name=None)Creates a tensor with all elements set to zero.
tf.ones(shape, dtype=tf.float32, name=None)Creates a tensor with all elements set to 1.
tf.ones_like(tensor, dtype=None, name=None)Creates a tensor with all elements set to 1.
tf.fill(dims, value, name=None)Creates a tensor filled with a scalar value.
tf.constant(value, dtype=None, shape=None, name='Const')Creates a constant tensor.

Constants, Sequences, and Random Values > Sequences

Members
tf.linspace(start, stop, num, name=None)Generates values in an interval.
tf.range(start, limit=None, delta=1, name='range')Creates a sequence of integers.

Constants, Sequences, and Random Values > Random Tensors

Members
tf.random_normal(shape, mean=0.0, stddev=1.0, dtype=tf.float32, seed=None, name=None)Outputs random values from a normal distribution.
tf.truncated_normal(shape, mean=0.0, stddev=1.0, dtype=tf.float32, seed=None, name=None)Outputs random values from a truncated normal distribution.
tf.random_uniform(shape, minval=0, maxval=None, dtype=tf.float32, seed=None, name=None)Outputs random values from a uniform distribution.
tf.random_shuffle(value, seed=None, name=None)Randomly shuffles a tensor along its first dimension.
tf.random_crop(value, size, seed=None, name=None)Randomly crops a tensor to a given size.
tf.multinomial(logits, num_samples, seed=None, name=None)Draws samples from a multinomial distribution.
tf.random_gamma(shape, alpha, beta=None, dtype=tf.float32, seed=None, name=None)Draws shape samples from each of the given Gamma distribution(s).
tf.set_random_seed(seed)Sets the graph-level random seed.

Constants, Sequences, and Random Values > Other Functions and Classes

Members
tf.contrib.graph_editor.ops(*args, **kwargs)Helper to select operations.

Variables > Variables

Members
class tf.VariableSee the [Variables How To](../../how_tos/variables/index.md) for a high
tf.Variable.__init__(initial_value=None, trainable=True, collections=None, validate_shape=True, caching_device=None, name=None, variable_def=None, dtype=None)Creates a new variable with value initial_value.
tf.Variable.initialized_value()Returns the value of the initialized variable.
tf.Variable.assign(value, use_locking=False)Assigns a new value to the variable.
tf.Variable.assign_add(delta, use_locking=False)Adds a value to this variable.
tf.Variable.assign_sub(delta, use_locking=False)Subtracts a value from this variable.
tf.Variable.scatter_sub(sparse_delta, use_locking=False)Subtracts IndexedSlices from this variable.
tf.Variable.count_up_to(limit)Increments this variable until it reaches limit.
tf.Variable.eval(session=None)In a session, computes and returns the value of this variable.
tf.Variable.nameThe name of this variable.
tf.Variable.dtypeThe DType of this variable.
tf.Variable.get_shape()The TensorShape of this variable.
tf.Variable.deviceThe device of this variable.
tf.Variable.initializerThe initializer operation for this variable.
tf.Variable.graphThe Graph of this variable.
tf.Variable.opThe Operation of this variable.
tf.Variable.from_proto(variable_def)Returns a Variable object created from variable_def.
tf.Variable.initial_valueReturns the Tensor used as the initial value for the variable.
tf.Variable.ref()Returns a reference to this variable.
tf.Variable.to_proto()Converts a Variable to a VariableDef protocol buffer.
tf.Variable.value()Returns the last snapshot of this variable.

Variables > Variable helper functions

Members
tf.all_variables()Returns all variables that must be saved/restored.
tf.trainable_variables()Returns all variables created with trainable=True.
tf.local_variables()Returns all variables created with collection=[LOCAL_VARIABLES].
tf.moving_average_variables()Returns all variables that maintain their moving averages.
tf.initialize_all_variables()Returns an Op that initializes all variables.
tf.initialize_variables(var_list, name='init')Returns an Op that initializes a list of variables.
tf.initialize_local_variables()Returns an Op that initializes all local variables.
tf.is_variable_initialized(variable)Tests if a variable has been initialized.
tf.report_uninitialized_variables(var_list=None, name='report_uninitialized_variables')Adds ops to list the names of uninitialized variables.
tf.assert_variables_initialized(var_list=None)Returns an Op to check if variables are initialized.

Variables > Saving and Restoring Variables

Members
class tf.train.SaverSaves and restores variables.
tf.train.Saver.__init__(var_list=None, reshape=False, sharded=False, max_to_keep=5, keep_checkpoint_every_n_hours=10000.0, name=None, restore_sequentially=False, saver_def=None, builder=None)Creates a Saver.
tf.train.Saver.save(sess, save_path, global_step=None, latest_filename=None, meta_graph_suffix='meta', write_meta_graph=True)Saves variables.
tf.train.Saver.restore(sess, save_path)Restores previously saved variables.
tf.train.Saver.last_checkpointsList of not-yet-deleted checkpoint filenames.
tf.train.Saver.set_last_checkpoints(last_checkpoints)DEPRECATED: Use set_last_checkpoints_with_time.
tf.train.Saver.as_saver_def()Generates a SaverDef representation of this saver.
tf.train.Saver.export_meta_graph(filename=None, collection_list=None, as_text=False)Writes MetaGraphDef to save_path/filename.
tf.train.Saver.from_proto(saver_def)Returns a Saver object created from saver_def.
tf.train.Saver.set_last_checkpoints_with_time(last_checkpoints_with_time)Sets the list of old checkpoint filenames and timestamps.
tf.train.Saver.to_proto()Converts this Saver to a SaverDef protocol buffer.
tf.train.latest_checkpoint(checkpoint_dir, latest_filename=None)Finds the filename of latest saved checkpoint file.
tf.train.get_checkpoint_state(checkpoint_dir, latest_filename=None)Returns CheckpointState proto from the "checkpoint" file.
tf.train.update_checkpoint_state(save_dir, model_checkpoint_path, all_model_checkpoint_paths=None, latest_filename=None)Updates the content of the 'checkpoint' file.

Variables > Sharing Variables

Members
tf.get_variable(name, shape=None, dtype=None, initializer=None, regularizer=None, trainable=True, collections=None, caching_device=None, partitioner=None, validate_shape=True, custom_getter=None)Gets an existing variable with these parameters or create a new one.
class tf.VariableScopeVariable scope object to carry defaults to provide to get_variable.
tf.VariableScope.__init__(reuse, name='', initializer=None, regularizer=None, caching_device=None, partitioner=None, custom_getter=None, name_scope='', dtype=tf.float32)Creates a new VariableScope with the given properties.
tf.VariableScope.caching_device
tf.VariableScope.custom_getter
tf.VariableScope.dtype
tf.VariableScope.get_variable(var_store, name, shape=None, dtype=None, initializer=None, regularizer=None, trainable=True, collections=None, caching_device=None, partitioner=None, validate_shape=True, custom_getter=None)Gets an existing variable with this name or create a new one.
tf.VariableScope.initializer
tf.VariableScope.name
tf.VariableScope.original_name_scope
tf.VariableScope.partitioner
tf.VariableScope.regularizer
tf.VariableScope.reuse
tf.VariableScope.reuse_variables()Reuse variables in this scope.
tf.VariableScope.set_caching_device(caching_device)Set caching_device for this scope.
tf.VariableScope.set_custom_getter(custom_getter)Set custom getter for this scope.
tf.VariableScope.set_dtype(dtype)Set data type for this scope.
tf.VariableScope.set_initializer(initializer)Set initializer for this scope.
tf.VariableScope.set_partitioner(partitioner)Set partitioner for this scope.
tf.VariableScope.set_regularizer(regularizer)Set regularizer for this scope.
tf.variable_scope(name_or_scope, reuse=None, initializer=None, regularizer=None, caching_device=None, partitioner=None, custom_getter=None, dtype=None)Returns a context for variable scope.
tf.variable_op_scope(values, name_or_scope, default_name=None, initializer=None, regularizer=None, caching_device=None, partitioner=None, custom_getter=None, reuse=None, dtype=None)Returns a context manager for defining an op that creates variables.
tf.get_variable_scope()Returns the current variable scope.
tf.make_template(name_, func_, create_scope_now_=False, unique_name_=None, **kwargs)Given an arbitrary function, wrap it so that it does variable sharing.
tf.no_regularizer(_)Use this function to prevent regularization of variables.
tf.constant_initializer(value=0.0, dtype=tf.float32)Returns an initializer that generates tensors with a single value.
tf.random_normal_initializer(mean=0.0, stddev=1.0, seed=None, dtype=tf.float32)Returns an initializer that generates tensors with a normal distribution.
tf.truncated_normal_initializer(mean=0.0, stddev=1.0, seed=None, dtype=tf.float32)Returns an initializer that generates a truncated normal distribution.
tf.random_uniform_initializer(minval=0.0, maxval=1.0, seed=None, dtype=tf.float32)Returns an initializer that generates tensors with a uniform distribution.
tf.uniform_unit_scaling_initializer(factor=1.0, seed=None, dtype=tf.float32, full_shape=None)Returns an initializer that generates tensors without scaling variance.
tf.zeros_initializer(shape, dtype=tf.float32)An adaptor for zeros() to match the Initializer spec.
tf.ones_initializer(shape, dtype=tf.float32)An adaptor for ones() to match the Initializer spec.

Variables > Variable Partitioners for Sharding

Members
tf.variable_axis_size_partitioner(max_shard_bytes, axis=0, bytes_per_string_element=16, max_shards=None)Get a partitioner for VariableScope to keep shards below max_shard_bytes.
tf.min_max_variable_partitioner(max_partitions=1, axis=0, min_slice_size=262144, bytes_per_string_element=16)Partitioner to allocate minimum size per slice.

Variables > Sparse Variable Updates

Members
tf.scatter_update(ref, indices, updates, use_locking=None, name=None)Applies sparse updates to a variable reference.
tf.scatter_add(ref, indices, updates, use_locking=None, name=None)Adds sparse updates to a variable reference.
tf.scatter_sub(ref, indices, updates, use_locking=None, name=None)Subtracts sparse updates to a variable reference.
tf.sparse_mask(a, mask_indices, name=None)Masks elements of IndexedSlices.
class tf.IndexedSlicesA sparse representation of a set of tensor slices at given indices.
tf.IndexedSlices.__init__(values, indices, dense_shape=None)Creates an IndexedSlices.
tf.IndexedSlices.valuesA Tensor containing the values of the slices.
tf.IndexedSlices.indicesA 1-D Tensor containing the indices of the slices.
tf.IndexedSlices.dense_shapeA 1-D Tensor containing the shape of the corresponding dense tensor.
tf.IndexedSlices.nameThe name of this IndexedSlices.
tf.IndexedSlices.dtypeThe DType of elements in this tensor.
tf.IndexedSlices.deviceThe name of the device on which values will be produced, or None.
tf.IndexedSlices.opThe Operation that produces values as an output.
tf.IndexedSlices.graphThe Graph that contains the values, indices, and shape tensors.

Variables > Exporting and Importing Meta Graphs

Members
tf.train.export_meta_graph(filename=None, meta_info_def=None, graph_def=None, saver_def=None, collection_list=None, as_text=False)Returns MetaGraphDef proto. Optionally writes it to filename.
tf.train.import_meta_graph(meta_graph_or_file)Recreates a Graph saved in a MetaGraphDef proto.

Tensor Transformations > Casting

Members
tf.string_to_number(string_tensor, out_type=None, name=None)Converts each string in the input Tensor to the specified numeric type.
tf.to_double(x, name='ToDouble')Casts a tensor to type float64.
tf.to_float(x, name='ToFloat')Casts a tensor to type float32.
tf.to_bfloat16(x, name='ToBFloat16')Casts a tensor to type bfloat16.
tf.to_int32(x, name='ToInt32')Casts a tensor to type int32.
tf.to_int64(x, name='ToInt64')Casts a tensor to type int64.
tf.cast(x, dtype, name=None)Casts a tensor to a new type.
tf.saturate_cast(value, dtype, name=None)Performs a safe saturating cast of value to dtype.

Tensor Transformations > Shapes and Shaping

Members
tf.shape(input, name=None)Returns the shape of a tensor.
tf.size(input, name=None)Returns the size of a tensor.
tf.rank(input, name=None)Returns the rank of a tensor.
tf.reshape(tensor, shape, name=None)Reshapes a tensor.
tf.squeeze(input, squeeze_dims=None, name=None)Removes dimensions of size 1 from the shape of a tensor.
tf.expand_dims(input, dim, name=None)Inserts a dimension of 1 into a tensor's shape.
tf.meshgrid(*args, **kwargs)Broadcasts parameters for evaluation on an N-D grid.

Tensor Transformations > Slicing and Joining

Members
tf.slice(input_, begin, size, name=None)Extracts a slice from a tensor.
tf.strided_slice(input_, begin, end, strides, begin_mask=0, end_mask=0, ellipsis_mask=0, new_axis_mask=0, shrink_axis_mask=0, name=None)Extracts a strided slice from a tensor.
tf.split(split_dim, num_split, value, name='split')Splits a tensor into num_split tensors along one dimension.
tf.tile(input, multiples, name=None)Constructs a tensor by tiling a given tensor.
tf.pad(tensor, paddings, mode='CONSTANT', name=None)Pads a tensor.
tf.concat(concat_dim, values, name='concat')Concatenates tensors along one dimension.
tf.pack(values, axis=0, name='pack')Packs a list of rank-R tensors into one rank-(R+1) tensor.
tf.unpack(value, num=None, axis=0, name='unpack')Unpacks the given dimension of a rank-R tensor into rank-(R-1) tensors.
tf.reverse_sequence(input, seq_lengths, seq_dim, batch_dim=None, name=None)Reverses variable length slices.
tf.reverse(tensor, dims, name=None)Reverses specific dimensions of a tensor.
tf.transpose(a, perm=None, name='transpose')Transposes a. Permutes the dimensions according to perm.
tf.extract_image_patches(images, ksizes, strides, rates, padding, name=None)Extract patches from images and put them in the "depth" output dimension.
tf.space_to_batch(input, paddings, block_size, name=None)SpaceToBatch for 4-D tensors of type T.
tf.batch_to_space(input, crops, block_size, name=None)BatchToSpace for 4-D tensors of type T.
tf.space_to_depth(input, block_size, name=None)SpaceToDepth for tensors of type T.
tf.depth_to_space(input, block_size, name=None)DepthToSpace for tensors of type T.
tf.gather(params, indices, validate_indices=None, name=None)Gather slices from params according to indices.
tf.gather_nd(params, indices, name=None)Gather values or slices from params according to indices.
tf.dynamic_partition(data, partitions, num_partitions, name=None)Partitions data into num_partitions tensors using indices from partitions.
tf.dynamic_stitch(indices, data, name=None)Interleave the values from the data tensors into a single tensor.
tf.boolean_mask(tensor, mask, name='boolean_mask')Apply boolean mask to tensor. Numpy equivalent is tensor[mask].
tf.one_hot(indices, depth, on_value=None, off_value=None, axis=None, dtype=None, name=None)Returns a one-hot tensor.

Tensor Transformations > Other Functions and Classes

Members
tf.bitcast(input, type, name=None)Bitcasts a tensor from one type to another without copying data.
tf.contrib.graph_editor.copy(sgv, dst_graph=None, dst_scope='', src_scope='')Copy a subgraph.
tf.shape_n(input, name=None)Returns shape of tensors.
tf.unique_with_counts(x, name=None)Finds unique elements in a 1-D tensor.

Math > Arithmetic Operators

Members
tf.add(x, y, name=None)Returns x + y element-wise.
tf.sub(x, y, name=None)Returns x - y element-wise.
tf.mul(x, y, name=None)Returns x * y element-wise.
tf.div(x, y, name=None)Returns x / y element-wise.
tf.truediv(x, y, name=None)Divides x / y elementwise, always producing floating point results.
tf.floordiv(x, y, name=None)Divides x / y elementwise, rounding down for floating point.
tf.mod(x, y, name=None)Returns element-wise remainder of division.
tf.cross(a, b, name=None)Compute the pairwise cross product.

Math > Basic Math Functions

Members
tf.add_n(inputs, name=None)Adds all input tensors element-wise.
tf.abs(x, name=None)Computes the absolute value of a tensor.
tf.neg(x, name=None)Computes numerical negative value element-wise.
tf.sign(x, name=None)Returns an element-wise indication of the sign of a number.
tf.inv(x, name=None)Computes the reciprocal of x element-wise.
tf.square(x, name=None)Computes square of x element-wise.
tf.round(x, name=None)Rounds the values of a tensor to the nearest integer, element-wise.
tf.sqrt(x, name=None)Computes square root of x element-wise.
tf.rsqrt(x, name=None)Computes reciprocal of square root of x element-wise.
tf.pow(x, y, name=None)Computes the power of one value to another.
tf.exp(x, name=None)Computes exponential of x element-wise. \\(y = e^x\\).
tf.log(x, name=None)Computes natural logarithm of x element-wise.
tf.ceil(x, name=None)Returns element-wise smallest integer in not less than x.
tf.floor(x, name=None)Returns element-wise largest integer not greater than x.
tf.maximum(x, y, name=None)Returns the max of x and y (i.e. x > y ? x : y) element-wise.
tf.minimum(x, y, name=None)Returns the min of x and y (i.e. x < y ? x : y) element-wise.
tf.cos(x, name=None)Computes cos of x element-wise.
tf.sin(x, name=None)Computes sin of x element-wise.
tf.lbeta(x, name='lbeta')Computes ln(|Beta(x)|), reducing along the last dimension.
tf.tan(x, name=None)Computes tan of x element-wise.
tf.acos(x, name=None)Computes acos of x element-wise.
tf.asin(x, name=None)Computes asin of x element-wise.
tf.atan(x, name=None)Computes atan of x element-wise.
tf.lgamma(x, name=None)Computes the log of the absolute value of Gamma(x) element-wise.
tf.digamma(x, name=None)Computes Psi, the derivative of Lgamma (the log of the absolute value of
tf.erf(x, name=None)Computes the Gauss error function of x element-wise.
tf.erfc(x, name=None)Computes the complementary error function of x element-wise.
tf.squared_difference(x, y, name=None)Returns (x - y)(x - y) element-wise.
tf.igamma(a, x, name=None)Compute the lower regularized incomplete Gamma function Q(a, x).
tf.igammac(a, x, name=None)Compute the upper regularized incomplete Gamma function Q(a, x).
tf.zeta(x, q, name=None)Compute the Hurwitz zeta function \\(\zeta(x, q)\\).
tf.polygamma(a, x, name=None)Compute the polygamma function \\(\psi^{(n)}(x)\\).

Math > Matrix Math Functions

Members
tf.batch_matrix_diag(diagonal, name=None)Returns a batched diagonal tensor with a given batched diagonal values.
tf.batch_matrix_diag_part(input, name=None)Returns the batched diagonal part of a batched tensor.
tf.batch_matrix_band_part(input, num_lower, num_upper, name=None)Copy a tensor setting everything outside a central band in each innermost matrix
tf.batch_matrix_set_diag(input, diagonal, name=None)Returns a batched matrix tensor with new batched diagonal values.
tf.diag(diagonal, name=None)Returns a diagonal tensor with a given diagonal values.
tf.diag_part(input, name=None)Returns the diagonal part of the tensor.
tf.trace(x, name=None)Compute the trace of a tensor x.
tf.transpose(a, perm=None, name='transpose')Transposes a. Permutes the dimensions according to perm.
tf.batch_matrix_transpose(a, name='batch_matrix_transpose')Transposes last two dimensions of batch matrix a.
tf.matmul(a, b, transpose_a=False, transpose_b=False, a_is_sparse=False, b_is_sparse=False, name=None)Multiplies matrix a by matrix b, producing a * b.
tf.batch_matmul(x, y, adj_x=None, adj_y=None, name=None)Multiplies slices of two tensors in batches.
tf.matrix_determinant(input, name=None)Computes the determinant of a square matrix.
tf.batch_matrix_determinant(input, name=None)Computes the determinants for a batch of square matrices.
tf.matrix_inverse(input, adjoint=None, name=None)Computes the inverse of a square invertible matrix or its adjoint (conjugate
tf.batch_matrix_inverse(input, adjoint=None, name=None)Computes the inverse of square invertible matrices or their adjoints
tf.cholesky(input, name=None)Computes the Cholesky decomposition of a square matrix.
tf.batch_cholesky(input, name=None)Computes the Cholesky decomposition of a batch of square matrices.
tf.cholesky_solve(chol, rhs, name=None)Solve linear equations A X = RHS, given Cholesky factorization of A.
tf.batch_cholesky_solve(chol, rhs, name=None)Solve batches of linear eqns A X = RHS, given Cholesky factorizations.
tf.matrix_solve(matrix, rhs, adjoint=None, name=None)Solves a system of linear equations. Checks for invertibility.
tf.batch_matrix_solve(matrix, rhs, adjoint=None, name=None)Solves systems of linear equations. Checks for invertibility.
tf.matrix_triangular_solve(matrix, rhs, lower=None, adjoint=None, name=None)Solves a system of linear equations with an upper or lower triangular matrix by
tf.batch_matrix_triangular_solve(matrix, rhs, lower=None, adjoint=None, name=None)Solves systems of linear equations with upper or lower triangular matrices by
tf.matrix_solve_ls(matrix, rhs, l2_regularizer=0.0, fast=True, name=None)Solves a linear least-squares problem.
tf.batch_matrix_solve_ls(matrix, rhs, l2_regularizer=0.0, fast=True, name=None)Solves multiple linear least-squares problems.
tf.self_adjoint_eig(matrix, name=None)Computes the eigen decomposition of a self-adjoint matrix.
tf.batch_self_adjoint_eig(tensor, name=None)Computes the eigen decomposition of a batch of self-adjoint matrices.
tf.self_adjoint_eigvals(matrix, name=None)Computes the eigenvalues a self-adjoint matrix.
tf.batch_self_adjoint_eigvals(tensor, name=None)Computes the eigenvalues of a batch of self-adjoint matrices.
tf.svd(matrix, compute_uv=True, full_matrices=False, name=None)Computes the singular value decomposition of a matrix.
tf.batch_svd(tensor, compute_uv=True, full_matrices=False, name=None)Computes the singular value decompositions of a batch of matrices.

Math > Complex Number Functions

Members
tf.complex(real, imag, name=None)Converts two real numbers to a complex number.
tf.complex_abs(x, name=None)Computes the complex absolute value of a tensor.
tf.conj(input, name=None)Returns the complex conjugate of a complex number.
tf.imag(input, name=None)Returns the imaginary part of a complex number.
tf.real(input, name=None)Returns the real part of a complex number.
tf.fft(input, name=None)Compute the 1-dimensional discrete Fourier Transform.
tf.ifft(input, name=None).Doc(R"doc(
tf.fft2d(input, name=None)Compute the 2-dimensional discrete Fourier Transform.
tf.ifft2d(input, name=None)Compute the inverse 2-dimensional discrete Fourier Transform.
tf.fft3d(input, name=None)Compute the 3-dimensional discrete Fourier Transform.
tf.ifft3d(input, name=None)Compute the inverse 3-dimensional discrete Fourier Transform.
tf.batch_fft(input, name=None)Compute the 1-dimensional discrete Fourier Transform over the inner-most
tf.batch_ifft(input, name=None)Compute the inverse 1-dimensional discrete Fourier Transform over the inner-most
tf.batch_fft2d(input, name=None)Compute the 2-dimensional discrete Fourier Transform over the inner-most
tf.batch_ifft2d(input, name=None)Compute the inverse 2-dimensional discrete Fourier Transform over the inner-most
tf.batch_fft3d(input, name=None)Compute the 3-dimensional discrete Fourier Transform over the inner-most 3
tf.batch_ifft3d(input, name=None)Compute the inverse 3-dimensional discrete Fourier Transform over the inner-most

Math > Reduction

Members
tf.reduce_sum(input_tensor, reduction_indices=None, keep_dims=False, name=None)Computes the sum of elements across dimensions of a tensor.
tf.reduce_prod(input_tensor, reduction_indices=None, keep_dims=False, name=None)Computes the product of elements across dimensions of a tensor.
tf.reduce_min(input_tensor, reduction_indices=None, keep_dims=False, name=None)Computes the minimum of elements across dimensions of a tensor.
tf.reduce_max(input_tensor, reduction_indices=None, keep_dims=False, name=None)Computes the maximum of elements across dimensions of a tensor.
tf.reduce_mean(input_tensor, reduction_indices=None, keep_dims=False, name=None)Computes the mean of elements across dimensions of a tensor.
tf.reduce_all(input_tensor, reduction_indices=None, keep_dims=False, name=None)Computes the "logical and" of elements across dimensions of a tensor.
tf.reduce_any(input_tensor, reduction_indices=None, keep_dims=False, name=None)Computes the "logical or" of elements across dimensions of a tensor.
tf.accumulate_n(inputs, shape=None, tensor_dtype=None, name=None)Returns the element-wise sum of a list of tensors.

Math > Scan

Members
tf.cumsum(x, axis=0, exclusive=False, reverse=False, name=None)Compute the cumulative sum of the tensor x along axis.
tf.cumprod(x, axis=0, exclusive=False, reverse=False, name=None)Compute the cumulative product of the tensor x along axis.

Math > Segmentation

Members
tf.segment_sum(data, segment_ids, name=None)Computes the sum along segments of a tensor.
tf.segment_prod(data, segment_ids, name=None)Computes the product along segments of a tensor.
tf.segment_min(data, segment_ids, name=None)Computes the minimum along segments of a tensor.
tf.segment_max(data, segment_ids, name=None)Computes the maximum along segments of a tensor.
tf.segment_mean(data, segment_ids, name=None)Computes the mean along segments of a tensor.
tf.unsorted_segment_sum(data, segment_ids, num_segments, name=None)Computes the sum along segments of a tensor.
tf.sparse_segment_sum(data, indices, segment_ids, name=None)Computes the sum along sparse segments of a tensor.
tf.sparse_segment_mean(data, indices, segment_ids, name=None)Computes the mean along sparse segments of a tensor.
tf.sparse_segment_sqrt_n(data, indices, segment_ids, name=None)Computes the sum along sparse segments of a tensor divided by the sqrt of N.

Math > Sequence Comparison and Indexing

Members
tf.argmin(input, dimension, name=None)Returns the index with the smallest value across dimensions of a tensor.
tf.argmax(input, dimension, name=None)Returns the index with the largest value across dimensions of a tensor.
tf.listdiff(x, y, name=None)Computes the difference between two lists of numbers or strings.
tf.where(input, name=None)Returns locations of true values in a boolean tensor.
tf.unique(x, name=None)Finds unique elements in a 1-D tensor.
tf.edit_distance(hypothesis, truth, normalize=True, name='edit_distance')Computes the Levenshtein distance between sequences.
tf.invert_permutation(x, name=None)Computes the inverse permutation of a tensor.

Math > Other Functions and Classes

Members
tf.scalar_mul(scalar, x)Multiplies a scalar times a Tensor or IndexedSlices object.
tf.sparse_segment_sqrt_n_grad(grad, indices, segment_ids, output_dim0, name=None)Computes gradients for SparseSegmentSqrtN.

Strings > Hashing

Members
tf.string_to_hash_bucket_fast(input, num_buckets, name=None)Converts each string in the input Tensor to its hash mod by a number of buckets.
tf.string_to_hash_bucket_strong(input, num_buckets, key, name=None)Converts each string in the input Tensor to its hash mod by a number of buckets.
tf.string_to_hash_bucket(string_tensor, num_buckets, name=None)Converts each string in the input Tensor to its hash mod by a number of buckets.

Strings > Joining

Members
tf.reduce_join(inputs, reduction_indices, keep_dims=None, separator=None, name=None)Joins a string Tensor across the given dimensions.
tf.string_join(inputs, separator=None, name=None)Joins the strings in the given list of string tensors into one tensor;

Strings > Conversion

Members
tf.as_string(input, precision=None, scientific=None, shortest=None, width=None, fill=None, name=None)Converts each entry in the given tensor to strings. Supports many numeric

Histograms > Histograms

Members
tf.histogram_fixed_width(values, value_range, nbins=100, dtype=tf.int32, name=None)Return histogram of values.

Control Flow > Control Flow Operations

Members
tf.identity(input, name=None)Return a tensor with the same shape and contents as the input tensor or value.
tf.tuple(tensors, name=None, control_inputs=None)Group tensors together.
tf.group(*inputs, **kwargs)Create an op that groups multiple operations.
tf.no_op(name=None)Does nothing. Only useful as a placeholder for control edges.
tf.count_up_to(ref, limit, name=None)Increments 'ref' until it reaches 'limit'.
tf.cond(pred, fn1, fn2, name=None)Return either fn1() or fn2() based on the boolean predicate pred.
tf.case(pred_fn_pairs, default, exclusive=False, name='case')Create a case operation.
tf.while_loop(cond, body, loop_vars, parallel_iterations=10, back_prop=True, swap_memory=False, name=None)Repeat body while the condition cond is true.

Control Flow > Logical Operators

Members
tf.logical_and(x, y, name=None)Returns the truth value of x AND y element-wise.
tf.logical_not(x, name=None)Returns the truth value of NOT x element-wise.
tf.logical_or(x, y, name=None)Returns the truth value of x OR y element-wise.
tf.logical_xor(x, y, name='LogicalXor')x ^ y = (x | y) & ~(x & y).

Control Flow > Comparison Operators

Members
tf.equal(x, y, name=None)Returns the truth value of (x == y) element-wise.
tf.not_equal(x, y, name=None)Returns the truth value of (x != y) element-wise.
tf.less(x, y, name=None)Returns the truth value of (x < y) element-wise.
tf.less_equal(x, y, name=None)Returns the truth value of (x <= y) element-wise.
tf.greater(x, y, name=None)Returns the truth value of (x > y) element-wise.
tf.greater_equal(x, y, name=None)Returns the truth value of (x >= y) element-wise.
tf.select(condition, t, e, name=None)Selects elements from t or e, depending on condition.
tf.where(input, name=None)Returns locations of true values in a boolean tensor.

Control Flow > Debugging Operations

Members
tf.is_finite(x, name=None)Returns which elements of x are finite.
tf.is_inf(x, name=None)Returns which elements of x are Inf.
tf.is_nan(x, name=None)Returns which elements of x are NaN.
tf.verify_tensor_all_finite(t, msg, name=None)Assert that the tensor does not contain any NaN's or Inf's.
tf.check_numerics(tensor, message, name=None)Checks a tensor for NaN and Inf values.
tf.add_check_numerics_ops()Connect a check_numerics to every floating point tensor.
tf.Assert(condition, data, summarize=None, name=None)Asserts that the given condition is true.
tf.Print(input_, data, message=None, first_n=None, summarize=None, name=None)Prints a list of tensors.

Higher Order Functions > Higher Order Operators

Members
tf.map_fn(fn, elems, dtype=None, parallel_iterations=10, back_prop=True, swap_memory=False, infer_shape=True, name=None)map on the list of tensors unpacked from elems on dimension 0.
tf.foldl(fn, elems, initializer=None, parallel_iterations=10, back_prop=True, swap_memory=False, name=None)foldl on the list of tensors unpacked from elems on dimension 0.
tf.foldr(fn, elems, initializer=None, parallel_iterations=10, back_prop=True, swap_memory=False, name=None)foldr on the list of tensors unpacked from elems on dimension 0.
tf.scan(fn, elems, initializer=None, parallel_iterations=10, back_prop=True, swap_memory=False, infer_shape=True, name=None)scan on the list of tensors unpacked from elems on dimension 0.

TensorArray Operations > Classes containing dynamically sized arrays of Tensors.

Members
class tf.TensorArrayClass wrapping dynamic-sized, per-time-step, write-once Tensor arrays.
tf.TensorArray.handleThe reference to the TensorArray.
tf.TensorArray.flowThe flow Tensor forcing ops leading to this TensorArray state.
tf.TensorArray.read(index, name=None)Read the value at location index in the TensorArray.
tf.TensorArray.unpack(value, name=None)Pack the values of a Tensor in the TensorArray.
tf.TensorArray.split(value, lengths, name=None)Split the values of a Tensor into the TensorArray.
tf.TensorArray.write(index, value, name=None)Write value into index index of the TensorArray.
tf.TensorArray.pack(name=None)Return the values in the TensorArray as a packed Tensor.
tf.TensorArray.concat(name=None)Return the values in the TensorArray as a concatenated Tensor.
tf.TensorArray.grad(source, flow=None, name=None)
tf.TensorArray.__init__(dtype, size=None, dynamic_size=None, clear_after_read=None, tensor_array_name=None, handle=None, flow=None, infer_shape=True, name=None)Construct a new TensorArray or wrap an existing TensorArray handle.
tf.TensorArray.close(name=None)Close the current TensorArray.
tf.TensorArray.dtypeThe data type of this TensorArray.
tf.TensorArray.size(name=None)Return the size of the TensorArray.

Tensor Handle Operations > Tensor Handle Operations.

Members
tf.get_session_handle(data, name=None)Return the handle of data.
tf.get_session_tensor(handle, dtype, name=None)Get the tensor of type dtype by feeding a tensor handle.
tf.delete_session_tensor(handle, name=None)Delete the tensor for the given tensor handle.

Images > Encoding and Decoding

Members
tf.image.decode_jpeg(contents, channels=None, ratio=None, fancy_upscaling=None, try_recover_truncated=None, acceptable_fraction=None, name=None)Decode a JPEG-encoded image to a uint8 tensor.
tf.image.encode_jpeg(image, format=None, quality=None, progressive=None, optimize_size=None, chroma_downsampling=None, density_unit=None, x_density=None, y_density=None, xmp_metadata=None, name=None)JPEG-encode an image.
tf.image.decode_png(contents, channels=None, dtype=None, name=None)Decode a PNG-encoded image to a uint8 or uint16 tensor.
tf.image.encode_png(image, compression=None, name=None)PNG-encode an image.

Images > Resizing

Members
tf.image.resize_images(images, new_height, new_width, method=0, align_corners=False)Resize images to new_width, new_height using the specified method.
tf.image.resize_area(images, size, align_corners=None, name=None)Resize images to size using area interpolation.
tf.image.resize_bicubic(images, size, align_corners=None, name=None)Resize images to size using bicubic interpolation.
tf.image.resize_bilinear(images, size, align_corners=None, name=None)Resize images to size using bilinear interpolation.
tf.image.resize_nearest_neighbor(images, size, align_corners=None, name=None)Resize images to size using nearest neighbor interpolation.

Images > Cropping

Members
tf.image.resize_image_with_crop_or_pad(image, target_height, target_width)Crops and/or pads an image to a target width and height.
tf.image.central_crop(image, central_fraction)Crop the central region of the image.
tf.image.pad_to_bounding_box(image, offset_height, offset_width, target_height, target_width)Pad image with zeros to the specified height and width.
tf.image.crop_to_bounding_box(image, offset_height, offset_width, target_height, target_width)Crops an image to a specified bounding box.
tf.image.extract_glimpse(input, size, offsets, centered=None, normalized=None, uniform_noise=None, name=None)Extracts a glimpse from the input tensor.
tf.image.crop_and_resize(image, boxes, box_ind, crop_size, method=None, extrapolation_value=None, name=None)Extracts crops from the input image tensor and bilinearly resizes them (possibly

Images > Flipping Rotating and Transposing

Members
tf.image.flip_up_down(image)Flip an image horizontally (upside down).
tf.image.random_flip_up_down(image, seed=None)Randomly flips an image vertically (upside down).
tf.image.flip_left_right(image)Flip an image horizontally (left to right).
tf.image.random_flip_left_right(image, seed=None)Randomly flip an image horizontally (left to right).
tf.image.transpose_image(image)Transpose an image by swapping the first and second dimension.
tf.image.rot90(image, k=1)Rotate an image counter-clockwise by 90 degrees.

Images > Converting Between Colorspaces.

Members
tf.image.rgb_to_grayscale(images, name=None)Converts one or more images from RGB to Grayscale.
tf.image.grayscale_to_rgb(images, name=None)Converts one or more images from Grayscale to RGB.
tf.image.hsv_to_rgb(images, name=None)Convert one or more images from HSV to RGB.
tf.image.rgb_to_hsv(images, name=None)Converts one or more images from RGB to HSV.
tf.image.convert_image_dtype(image, dtype, saturate=False, name=None)Convert image to dtype, scaling its values if needed.

Images > Image Adjustments

Members
tf.image.adjust_brightness(image, delta)Adjust the brightness of RGB or Grayscale images.
tf.image.random_brightness(image, max_delta, seed=None)Adjust the brightness of images by a random factor.
tf.image.adjust_contrast(images, contrast_factor)Adjust contrast of RGB or grayscale images.
tf.image.random_contrast(image, lower, upper, seed=None)Adjust the contrast of an image by a random factor.
tf.image.adjust_hue(image, delta, name=None)Adjust hue of an RGB image.
tf.image.random_hue(image, max_delta, seed=None)Adjust the hue of an RGB image by a random factor.
tf.image.adjust_saturation(image, saturation_factor, name=None)Adjust saturation of an RGB image.
tf.image.random_saturation(image, lower, upper, seed=None)Adjust the saturation of an RGB image by a random factor.
tf.image.per_image_whitening(image)Linearly scales image to have zero mean and unit norm.

Images > Working with Bounding Boxes

Members
tf.image.draw_bounding_boxes(images, boxes, name=None)Draw bounding boxes on a batch of images.
tf.image.non_max_suppression(boxes, scores, max_output_size, iou_threshold=None, name=None)Greedily selects a subset of bounding boxes in descending order of score,
tf.image.sample_distorted_bounding_box(image_size, bounding_boxes, seed=None, seed2=None, min_object_covered=None, aspect_ratio_range=None, area_range=None, max_attempts=None, use_image_if_no_bounding_boxes=None, name=None)Generate a single randomly distorted bounding box for an image.

Sparse Tensors > Sparse Tensor Representation

Members
class tf.SparseTensorRepresents a sparse tensor.
tf.SparseTensor.__init__(indices, values, shape)Creates a SparseTensor.
tf.SparseTensor.indicesThe indices of non-zero values in the represented dense tensor.
tf.SparseTensor.valuesThe non-zero values in the represented dense tensor.
tf.SparseTensor.shapeA 1-D Tensor of int64 representing the shape of the dense tensor.
tf.SparseTensor.dtypeThe DType of elements in this tensor.
tf.SparseTensor.opThe Operation that produces values as an output.
tf.SparseTensor.graphThe Graph that contains the index, value, and shape tensors.
tf.SparseTensor.eval(feed_dict=None, session=None)Evaluates this sparse tensor in a Session.
tf.SparseTensor.from_value(cls, sparse_tensor_value)
class tf.SparseTensorValueSparseTensorValue(indices, values, shape)
tf.SparseTensorValue.indicesAlias for field number 0
tf.SparseTensorValue.shapeAlias for field number 2
tf.SparseTensorValue.valuesAlias for field number 1

Sparse Tensors > Conversion

Members
tf.sparse_to_dense(sparse_indices, output_shape, sparse_values, default_value=0, validate_indices=True, name=None)Converts a sparse representation into a dense tensor.
tf.sparse_tensor_to_dense(sp_input, default_value=0, validate_indices=True, name=None)Converts a SparseTensor into a dense tensor.
tf.sparse_to_indicator(sp_input, vocab_size, name=None)Converts a SparseTensor of ids into a dense bool indicator tensor.
tf.sparse_merge(sp_ids, sp_values, vocab_size, name=None, already_sorted=False)Combines a batch of feature ids and values into a single SparseTensor.

Sparse Tensors > Manipulation

Members
tf.sparse_concat(concat_dim, sp_inputs, name=None, expand_nonconcat_dim=False)Concatenates a list of SparseTensor along the specified dimension.
tf.sparse_reorder(sp_input, name=None)Reorders a SparseTensor into the canonical, row-major ordering.
tf.sparse_reshape(sp_input, shape, name=None)Reshapes a SparseTensor to represent values in a new dense shape.
tf.sparse_split(split_dim, num_split, sp_input, name=None)Split a SparseTensor into num_split tensors along split_dim.
tf.sparse_retain(sp_input, to_retain)Retains specified non-empty values within a SparseTensor.
tf.sparse_reset_shape(sp_input, new_shape=None)Resets the shape of a SparseTensor with indices and values unchanged.
tf.sparse_fill_empty_rows(sp_input, default_value, name=None)Fills empty rows in the input 2-D SparseTensor with a default value.

Sparse Tensors > Reduction

Members
tf.sparse_reduce_sum(sp_input, reduction_axes=None, keep_dims=False)Computes the sum of elements across dimensions of a SparseTensor.

Sparse Tensors > Math Operations

Members
tf.sparse_add(a, b, thresh=0)Adds two tensors, at least one of each is a SparseTensor.
tf.sparse_softmax(sp_input, name=None)Applies softmax to a batched N-D SparseTensor.
tf.sparse_tensor_dense_matmul(sp_a, b, adjoint_a=False, adjoint_b=False, name=None)Multiply SparseTensor (of rank 2) "A" by dense matrix "B".
tf.sparse_maximum(sp_a, sp_b, name=None)Returns the element-wise max of two SparseTensors.
tf.sparse_minimum(sp_a, sp_b, name=None)Returns the element-wise min of two SparseTensors.

Inputs and Readers > Placeholders

Members
tf.placeholder(dtype, shape=None, name=None)Inserts a placeholder for a tensor that will be always fed.
tf.placeholder_with_default(input, shape, name=None)A placeholder op that passes though input when its output is not fed.
tf.sparse_placeholder(dtype, shape=None, name=None)Inserts a placeholder for a sparse tensor that will be always fed.

Inputs and Readers > Readers

Members
class tf.ReaderBaseBase class for different Reader types, that produce a record every step.
tf.ReaderBase.__init__(reader_ref, supports_serialize=False)Creates a new ReaderBase.
tf.ReaderBase.num_records_produced(name=None)Returns the number of records this reader has produced.
tf.ReaderBase.num_work_units_completed(name=None)Returns the number of work units this reader has finished processing.
tf.ReaderBase.read(queue, name=None)Returns the next record (key, value pair) produced by a reader.
tf.ReaderBase.read_up_to(queue, num_records, name=None)Returns up to num_records (key, value pairs) produced by a reader.
tf.ReaderBase.reader_refOp that implements the reader.
tf.ReaderBase.reset(name=None)Restore a reader to its initial clean state.
tf.ReaderBase.restore_state(state, name=None)Restore a reader to a previously saved state.
tf.ReaderBase.serialize_state(name=None)Produce a string tensor that encodes the state of a reader.
tf.ReaderBase.supports_serializeWhether the Reader implementation can serialize its state.
class tf.TextLineReaderA Reader that outputs the lines of a file delimited by newlines.
tf.TextLineReader.__init__(skip_header_lines=None, name=None)Create a TextLineReader.
tf.TextLineReader.num_records_produced(name=None)Returns the number of records this reader has produced.
tf.TextLineReader.num_work_units_completed(name=None)Returns the number of work units this reader has finished processing.
tf.TextLineReader.read(queue, name=None)Returns the next record (key, value pair) produced by a reader.
tf.TextLineReader.read_up_to(queue, num_records, name=None)Returns up to num_records (key, value pairs) produced by a reader.
tf.TextLineReader.reader_refOp that implements the reader.
tf.TextLineReader.reset(name=None)Restore a reader to its initial clean state.
tf.TextLineReader.restore_state(state, name=None)Restore a reader to a previously saved state.
tf.TextLineReader.serialize_state(name=None)Produce a string tensor that encodes the state of a reader.
tf.TextLineReader.supports_serializeWhether the Reader implementation can serialize its state.
class tf.WholeFileReaderA Reader that outputs the entire contents of a file as a value.
tf.WholeFileReader.__init__(name=None)Create a WholeFileReader.
tf.WholeFileReader.num_records_produced(name=None)Returns the number of records this reader has produced.
tf.WholeFileReader.num_work_units_completed(name=None)Returns the number of work units this reader has finished processing.
tf.WholeFileReader.read(queue, name=None)Returns the next record (key, value pair) produced by a reader.
tf.WholeFileReader.read_up_to(queue, num_records, name=None)Returns up to num_records (key, value pairs) produced by a reader.
tf.WholeFileReader.reader_refOp that implements the reader.
tf.WholeFileReader.reset(name=None)Restore a reader to its initial clean state.
tf.WholeFileReader.restore_state(state, name=None)Restore a reader to a previously saved state.
tf.WholeFileReader.serialize_state(name=None)Produce a string tensor that encodes the state of a reader.
tf.WholeFileReader.supports_serializeWhether the Reader implementation can serialize its state.
class tf.IdentityReaderA Reader that outputs the queued work as both the key and value.
tf.IdentityReader.__init__(name=None)Create a IdentityReader.
tf.IdentityReader.num_records_produced(name=None)Returns the number of records this reader has produced.
tf.IdentityReader.num_work_units_completed(name=None)Returns the number of work units this reader has finished processing.
tf.IdentityReader.read(queue, name=None)Returns the next record (key, value pair) produced by a reader.
tf.IdentityReader.read_up_to(queue, num_records, name=None)Returns up to num_records (key, value pairs) produced by a reader.
tf.IdentityReader.reader_refOp that implements the reader.
tf.IdentityReader.reset(name=None)Restore a reader to its initial clean state.
tf.IdentityReader.restore_state(state, name=None)Restore a reader to a previously saved state.
tf.IdentityReader.serialize_state(name=None)Produce a string tensor that encodes the state of a reader.
tf.IdentityReader.supports_serializeWhether the Reader implementation can serialize its state.
class tf.TFRecordReaderA Reader that outputs the records from a TFRecords file.
tf.TFRecordReader.__init__(name=None, options=None)Create a TFRecordReader.
tf.TFRecordReader.num_records_produced(name=None)Returns the number of records this reader has produced.
tf.TFRecordReader.num_work_units_completed(name=None)Returns the number of work units this reader has finished processing.
tf.TFRecordReader.read(queue, name=None)Returns the next record (key, value pair) produced by a reader.
tf.TFRecordReader.read_up_to(queue, num_records, name=None)Returns up to num_records (key, value pairs) produced by a reader.
tf.TFRecordReader.reader_refOp that implements the reader.
tf.TFRecordReader.reset(name=None)Restore a reader to its initial clean state.
tf.TFRecordReader.restore_state(state, name=None)Restore a reader to a previously saved state.
tf.TFRecordReader.serialize_state(name=None)Produce a string tensor that encodes the state of a reader.
tf.TFRecordReader.supports_serializeWhether the Reader implementation can serialize its state.
class tf.FixedLengthRecordReaderA Reader that outputs fixed-length records from a file.
tf.FixedLengthRecordReader.__init__(record_bytes, header_bytes=None, footer_bytes=None, name=None)Create a FixedLengthRecordReader.
tf.FixedLengthRecordReader.num_records_produced(name=None)Returns the number of records this reader has produced.
tf.FixedLengthRecordReader.num_work_units_completed(name=None)Returns the number of work units this reader has finished processing.
tf.FixedLengthRecordReader.read(queue, name=None)Returns the next record (key, value pair) produced by a reader.
tf.FixedLengthRecordReader.read_up_to(queue, num_records, name=None)Returns up to num_records (key, value pairs) produced by a reader.
tf.FixedLengthRecordReader.reader_refOp that implements the reader.
tf.FixedLengthRecordReader.reset(name=None)Restore a reader to its initial clean state.
tf.FixedLengthRecordReader.restore_state(state, name=None)Restore a reader to a previously saved state.
tf.FixedLengthRecordReader.serialize_state(name=None)Produce a string tensor that encodes the state of a reader.
tf.FixedLengthRecordReader.supports_serializeWhether the Reader implementation can serialize its state.

Inputs and Readers > Converting

Members
tf.decode_csv(records, record_defaults, field_delim=None, name=None)Convert CSV records to tensors. Each column maps to one tensor.
tf.decode_raw(bytes, out_type, little_endian=None, name=None)Reinterpret the bytes of a string as a vector of numbers.
class tf.VarLenFeatureConfiguration for parsing a variable-length input feature.
tf.VarLenFeature.dtypeAlias for field number 0
class tf.FixedLenFeatureConfiguration for parsing a fixed-length input feature.
tf.FixedLenFeature.default_valueAlias for field number 2
tf.FixedLenFeature.dtypeAlias for field number 1
tf.FixedLenFeature.shapeAlias for field number 0
class tf.FixedLenSequenceFeatureConfiguration for a dense input feature in a sequence item.
tf.FixedLenSequenceFeature.allow_missingAlias for field number 2
tf.FixedLenSequenceFeature.dtypeAlias for field number 1
tf.FixedLenSequenceFeature.shapeAlias for field number 0
tf.parse_example(serialized, features, name=None, example_names=None)Parses Example protos into a dict of tensors.
tf.parse_single_example(serialized, features, name=None, example_names=None)Parses a single Example proto.
tf.decode_json_example(json_examples, name=None)Convert JSON-encoded Example records to binary protocol buffer strings.

Inputs and Readers > Queues

Members
class tf.QueueBaseBase class for queue implementations.
tf.QueueBase.enqueue(vals, name=None)Enqueues one element to this queue.
tf.QueueBase.enqueue_many(vals, name=None)Enqueues zero or more elements to this queue.
tf.QueueBase.dequeue(name=None)Dequeues one element from this queue.
tf.QueueBase.dequeue_many(n, name=None)Dequeues and concatenates n elements from this queue.
tf.QueueBase.size(name=None)Compute the number of elements in this queue.
tf.QueueBase.close(cancel_pending_enqueues=False, name=None)Closes this queue.
tf.QueueBase.__init__(dtypes, shapes, names, queue_ref)Constructs a queue object from a queue reference.
tf.QueueBase.dequeue_up_to(n, name=None)Dequeues and concatenates n elements from this queue.
tf.QueueBase.dtypesThe list of dtypes for each component of a queue element.
tf.QueueBase.from_list(index, queues)Create a queue using the queue reference from queues[index].
tf.QueueBase.nameThe name of the underlying queue.
tf.QueueBase.namesThe list of names for each component of a queue element.
tf.QueueBase.queue_refThe underlying queue reference.
class tf.FIFOQueueA queue implementation that dequeues elements in first-in-first out order.
tf.FIFOQueue.__init__(capacity, dtypes, shapes=None, names=None, shared_name=None, name='fifo_queue')Creates a queue that dequeues elements in a first-in first-out order.
class tf.PaddingFIFOQueueA FIFOQueue that supports batching variable-sized tensors by padding.
tf.PaddingFIFOQueue.__init__(capacity, dtypes, shapes, names=None, shared_name=None, name='padding_fifo_queue')Creates a queue that dequeues elements in a first-in first-out order.
class tf.RandomShuffleQueueA queue implementation that dequeues elements in a random order.
tf.RandomShuffleQueue.__init__(capacity, min_after_dequeue, dtypes, shapes=None, names=None, seed=None, shared_name=None, name='random_shuffle_queue')Create a queue that dequeues elements in a random order.

Inputs and Readers > Dealing with the filesystem

Members
tf.matching_files(pattern, name=None)Returns the set of files matching a pattern.
tf.read_file(filename, name=None)Reads and outputs the entire contents of the input filename.

Inputs and Readers > Input pipeline

Members
tf.train.match_filenames_once(pattern, name=None)Save the list of files matching pattern, so it is only computed once.
tf.train.limit_epochs(tensor, num_epochs=None, name=None)Returns tensor num_epochs times and then raises an OutOfRange error.
tf.train.input_producer(input_tensor, element_shape=None, num_epochs=None, shuffle=True, seed=None, capacity=32, shared_name=None, summary_name=None, name=None)Output the rows of input_tensor to a queue for an input pipeline.
tf.train.range_input_producer(limit, num_epochs=None, shuffle=True, seed=None, capacity=32, shared_name=None, name=None)Produces the integers from 0 to limit-1 in a queue.
tf.train.slice_input_producer(tensor_list, num_epochs=None, shuffle=True, seed=None, capacity=32, shared_name=None, name=None)Produces a slice of each Tensor in tensor_list.
tf.train.string_input_producer(string_tensor, num_epochs=None, shuffle=True, seed=None, capacity=32, shared_name=None, name=None)Output strings (e.g. filenames) to a queue for an input pipeline.
tf.train.batch(tensors, batch_size, num_threads=1, capacity=32, enqueue_many=False, shapes=None, dynamic_pad=False, allow_smaller_final_batch=False, shared_name=None, name=None)Creates batches of tensors in tensors.
tf.train.batch_join(tensors_list, batch_size, capacity=32, enqueue_many=False, shapes=None, dynamic_pad=False, allow_smaller_final_batch=False, shared_name=None, name=None)Runs a list of tensors to fill a queue to create batches of examples.
tf.train.shuffle_batch(tensors, batch_size, capacity, min_after_dequeue, num_threads=1, seed=None, enqueue_many=False, shapes=None, allow_smaller_final_batch=False, shared_name=None, name=None)Creates batches by randomly shuffling tensors.
tf.train.shuffle_batch_join(tensors_list, batch_size, capacity, min_after_dequeue, seed=None, enqueue_many=False, shapes=None, allow_smaller_final_batch=False, shared_name=None, name=None)Create batches by randomly shuffling tensors.

Data IO (Python functions) > Data IO (Python Functions)

Members
class tf.python_io.TFRecordWriterA class to write records to a TFRecords file.
tf.python_io.TFRecordWriter.__init__(path, options=None)Opens file path and creates a TFRecordWriter writing to it.
tf.python_io.TFRecordWriter.write(record)Write a string record to the file.
tf.python_io.TFRecordWriter.close()Close the file.
tf.python_io.tf_record_iterator(path, options=None)An iterator that read the records from a TFRecords file.

Neural Network > Activation Functions.

Members
tf.nn.relu(features, name=None)Computes rectified linear: max(features, 0).
tf.nn.relu6(features, name=None)Computes Rectified Linear 6: min(max(features, 0), 6).
tf.nn.elu(features, name=None)Computes exponential linear: exp(features) - 1 if < 0, features otherwise.
tf.nn.softplus(features, name=None)Computes softplus: log(exp(features) + 1).
tf.nn.softsign(features, name=None)Computes softsign: features / (abs(features) + 1).
tf.nn.dropout(x, keep_prob, noise_shape=None, seed=None, name=None)Computes dropout.
tf.nn.bias_add(value, bias, data_format=None, name=None)Adds bias to value.
tf.sigmoid(x, name=None)Computes sigmoid of x element-wise.
tf.tanh(x, name=None)Computes hyperbolic tangent of x element-wise.

Neural Network > Convolution

Members
tf.nn.conv2d(input, filter, strides, padding, use_cudnn_on_gpu=None, data_format=None, name=None)Computes a 2-D convolution given 4-D input and filter tensors.
tf.nn.depthwise_conv2d(input, filter, strides, padding, name=None)Depthwise 2-D convolution.
tf.nn.separable_conv2d(input, depthwise_filter, pointwise_filter, strides, padding, name=None)2-D convolution with separable filters.
tf.nn.atrous_conv2d(value, filters, rate, padding, name=None)Atrous convolution (a.k.a. convolution with holes or dilated convolution).
tf.nn.conv2d_transpose(value, filter, output_shape, strides, padding='SAME', name=None)The transpose of conv2d.
tf.nn.conv3d(input, filter, strides, padding, name=None)Computes a 3-D convolution given 5-D input and filter tensors.

Neural Network > Pooling

Members
tf.nn.avg_pool(value, ksize, strides, padding, data_format='NHWC', name=None)Performs the average pooling on the input.
tf.nn.max_pool(value, ksize, strides, padding, data_format='NHWC', name=None)Performs the max pooling on the input.
tf.nn.max_pool_with_argmax(input, ksize, strides, padding, Targmax=None, name=None)Performs max pooling on the input and outputs both max values and indices.
tf.nn.avg_pool3d(input, ksize, strides, padding, name=None)Performs 3D average pooling on the input.
tf.nn.max_pool3d(input, ksize, strides, padding, name=None)Performs 3D max pooling on the input.

Neural Network > Morphological filtering

Members
tf.nn.dilation2d(input, filter, strides, rates, padding, name=None)Computes the grayscale dilation of 4-D input and 3-D filter tensors.
tf.nn.erosion2d(value, kernel, strides, rates, padding, name=None)Computes the grayscale erosion of 4-D value and 3-D kernel tensors.

Neural Network > Normalization

Members
tf.nn.l2_normalize(x, dim, epsilon=1e-12, name=None)Normalizes along dimension dim using an L2 norm.
tf.nn.local_response_normalization(input, depth_radius=None, bias=None, alpha=None, beta=None, name=None)Local Response Normalization.
tf.nn.sufficient_statistics(x, axes, shift=None, keep_dims=False, name=None)Calculate the sufficient statistics for the mean and variance of x.
tf.nn.normalize_moments(counts, mean_ss, variance_ss, shift, name=None)Calculate the mean and variance of based on the sufficient statistics.
tf.nn.moments(x, axes, shift=None, name=None, keep_dims=False)Calculate the mean and variance of x.

Neural Network > Losses

Members
tf.nn.l2_loss(t, name=None)L2 Loss.
tf.nn.log_poisson_loss(log_input, targets, compute_full_loss=False, name=None)Computes log poisson loss given log_input.

Neural Network > Classification

Members
tf.nn.sigmoid_cross_entropy_with_logits(logits, targets, name=None)Computes sigmoid cross entropy given logits.
tf.nn.softmax(logits, name=None)Computes softmax activations.
tf.nn.log_softmax(logits, name=None)Computes log softmax activations.
tf.nn.softmax_cross_entropy_with_logits(logits, labels, name=None)Computes softmax cross entropy between logits and labels.
tf.nn.sparse_softmax_cross_entropy_with_logits(logits, labels, name=None)Computes sparse softmax cross entropy between logits and labels.
tf.nn.weighted_cross_entropy_with_logits(logits, targets, pos_weight, name=None)Computes a weighted cross entropy.

Neural Network > Embeddings

Members
tf.nn.embedding_lookup(params, ids, partition_strategy='mod', name=None, validate_indices=True)Looks up ids in a list of embedding tensors.
tf.nn.embedding_lookup_sparse(params, sp_ids, sp_weights, partition_strategy='mod', name=None, combiner='mean')Computes embeddings for the given ids and weights.

Neural Network > Recurrent Neural Networks

Members
tf.nn.dynamic_rnn(cell, inputs, sequence_length=None, initial_state=None, dtype=None, parallel_iterations=None, swap_memory=False, time_major=False, scope=None)Creates a recurrent neural network specified by RNNCell cell.
tf.nn.rnn(cell, inputs, initial_state=None, dtype=None, sequence_length=None, scope=None)Creates a recurrent neural network specified by RNNCell cell.
tf.nn.state_saving_rnn(cell, inputs, state_saver, state_name, sequence_length=None, scope=None)RNN that accepts a state saver for time-truncated RNN calculation.
tf.nn.bidirectional_rnn(cell_fw, cell_bw, inputs, initial_state_fw=None, initial_state_bw=None, dtype=None, sequence_length=None, scope=None)Creates a bidirectional recurrent neural network.

Neural Network > Conectionist Temporal Classification (CTC)

Members
tf.nn.ctc_loss(inputs, labels, sequence_length, preprocess_collapse_repeated=False, ctc_merge_repeated=True)Computes the CTC (Connectionist Temporal Classification) Loss.
tf.nn.ctc_greedy_decoder(inputs, sequence_length, merge_repeated=True)Performs greedy decoding on the logits given in input (best path).
tf.nn.ctc_beam_search_decoder(inputs, sequence_length, beam_width=100, top_paths=1, merge_repeated=True)Performs beam search decoding on the logits given in input.

Neural Network > Evaluation

Members
tf.nn.top_k(input, k=1, sorted=True, name=None)Finds values and indices of the k largest entries for the last dimension.
tf.nn.in_top_k(predictions, targets, k, name=None)Says whether the targets are in the top K predictions.

Neural Network > Candidate Sampling

Members
tf.nn.nce_loss(weights, biases, inputs, labels, num_sampled, num_classes, num_true=1, sampled_values=None, remove_accidental_hits=False, partition_strategy='mod', name='nce_loss')Computes and returns the noise-contrastive estimation training loss.
tf.nn.sampled_softmax_loss(weights, biases, inputs, labels, num_sampled, num_classes, num_true=1, sampled_values=None, remove_accidental_hits=True, partition_strategy='mod', name='sampled_softmax_loss')Computes and returns the sampled softmax training loss.
tf.nn.uniform_candidate_sampler(true_classes, num_true, num_sampled, unique, range_max, seed=None, name=None)Samples a set of classes using a uniform base distribution.
tf.nn.log_uniform_candidate_sampler(true_classes, num_true, num_sampled, unique, range_max, seed=None, name=None)Samples a set of classes using a log-uniform (Zipfian) base distribution.
tf.nn.learned_unigram_candidate_sampler(true_classes, num_true, num_sampled, unique, range_max, seed=None, name=None)Samples a set of classes from a distribution learned during training.
tf.nn.fixed_unigram_candidate_sampler(true_classes, num_true, num_sampled, unique, range_max, vocab_file='', distortion=1.0, num_reserved_ids=0, num_shards=1, shard=0, unigrams=(), seed=None, name=None)Samples a set of classes using the provided (fixed) base distribution.
tf.nn.compute_accidental_hits(true_classes, sampled_candidates, num_true, seed=None, name=None)Compute the position ids in sampled_candidates matching true_classes.

Neural Network > Other Functions and Classes

Members
tf.nn.batch_normalization(x, mean, variance, offset, scale, variance_epsilon, name=None)Batch normalization.
tf.nn.depthwise_conv2d_native(input, filter, strides, padding, name=None)Computes a 2-D depthwise convolution given 4-D input and filter tensors.

Neural Network RNN Cells > Base interface for all RNN Cells

Members
class tf.nn.rnn_cell.RNNCellAbstract object representing an RNN cell.
tf.nn.rnn_cell.RNNCell.output_sizeInteger or TensorShape: size of outputs produced by this cell.
tf.nn.rnn_cell.RNNCell.state_sizesize(s) of state(s) used by this cell.
tf.nn.rnn_cell.RNNCell.zero_state(batch_size, dtype)Return zero-filled state tensor(s).

Neural Network RNN Cells > RNN Cells for use with TensorFlow's core RNN methods

Members
class tf.nn.rnn_cell.BasicRNNCellThe most basic RNN cell.
tf.nn.rnn_cell.BasicRNNCell.__init__(num_units, input_size=None, activation=tanh)
tf.nn.rnn_cell.BasicRNNCell.output_size
tf.nn.rnn_cell.BasicRNNCell.state_size
tf.nn.rnn_cell.BasicRNNCell.zero_state(batch_size, dtype)Return zero-filled state tensor(s).
class tf.nn.rnn_cell.BasicLSTMCellBasic LSTM recurrent network cell.
tf.nn.rnn_cell.BasicLSTMCell.__init__(num_units, forget_bias=1.0, input_size=None, state_is_tuple=False, activation=tanh)Initialize the basic LSTM cell.
tf.nn.rnn_cell.BasicLSTMCell.output_size
tf.nn.rnn_cell.BasicLSTMCell.state_size
tf.nn.rnn_cell.BasicLSTMCell.zero_state(batch_size, dtype)Return zero-filled state tensor(s).
class tf.nn.rnn_cell.GRUCellGated Recurrent Unit cell (cf. http://arxiv.org/abs/1406.1078).
tf.nn.rnn_cell.GRUCell.__init__(num_units, input_size=None, activation=tanh)
tf.nn.rnn_cell.GRUCell.output_size
tf.nn.rnn_cell.GRUCell.state_size
tf.nn.rnn_cell.GRUCell.zero_state(batch_size, dtype)Return zero-filled state tensor(s).
class tf.nn.rnn_cell.LSTMCellLong short-term memory unit (LSTM) recurrent network cell.
tf.nn.rnn_cell.LSTMCell.__init__(num_units, input_size=None, use_peepholes=False, cell_clip=None, initializer=None, num_proj=None, proj_clip=None, num_unit_shards=1, num_proj_shards=1, forget_bias=1.0, state_is_tuple=False, activation=tanh)Initialize the parameters for an LSTM cell.
tf.nn.rnn_cell.LSTMCell.output_size
tf.nn.rnn_cell.LSTMCell.state_size
tf.nn.rnn_cell.LSTMCell.zero_state(batch_size, dtype)Return zero-filled state tensor(s).

Neural Network RNN Cells > Classes storing split RNNCell state

Members
class tf.nn.rnn_cell.LSTMStateTupleTuple used by LSTM Cells for state_size, zero_state, and output state.
tf.nn.rnn_cell.LSTMStateTuple.cAlias for field number 0
tf.nn.rnn_cell.LSTMStateTuple.dtype
tf.nn.rnn_cell.LSTMStateTuple.hAlias for field number 1

Neural Network RNN Cells > RNN Cell wrappers (RNNCells that wrap other RNNCells)

Members
class tf.nn.rnn_cell.MultiRNNCellRNN cell composed sequentially of multiple simple cells.
tf.nn.rnn_cell.MultiRNNCell.__init__(cells, state_is_tuple=False)Create a RNN cell composed sequentially of a number of RNNCells.
tf.nn.rnn_cell.MultiRNNCell.output_size
tf.nn.rnn_cell.MultiRNNCell.state_size
tf.nn.rnn_cell.MultiRNNCell.zero_state(batch_size, dtype)Return zero-filled state tensor(s).
class tf.nn.rnn_cell.DropoutWrapperOperator adding dropout to inputs and outputs of the given cell.
tf.nn.rnn_cell.DropoutWrapper.__init__(cell, input_keep_prob=1.0, output_keep_prob=1.0, seed=None)Create a cell with added input and/or output dropout.
tf.nn.rnn_cell.DropoutWrapper.output_size
tf.nn.rnn_cell.DropoutWrapper.state_size
tf.nn.rnn_cell.DropoutWrapper.zero_state(batch_size, dtype)Return zero-filled state tensor(s).
class tf.nn.rnn_cell.EmbeddingWrapperOperator adding input embedding to the given cell.
tf.nn.rnn_cell.EmbeddingWrapper.__init__(cell, embedding_classes, embedding_size, initializer=None)Create a cell with an added input embedding.
tf.nn.rnn_cell.EmbeddingWrapper.output_size
tf.nn.rnn_cell.EmbeddingWrapper.state_size
tf.nn.rnn_cell.EmbeddingWrapper.zero_state(batch_size, dtype)Return zero-filled state tensor(s).
class tf.nn.rnn_cell.InputProjectionWrapperOperator adding an input projection to the given cell.
tf.nn.rnn_cell.InputProjectionWrapper.__init__(cell, num_proj, input_size=None)Create a cell with input projection.
tf.nn.rnn_cell.InputProjectionWrapper.output_size
tf.nn.rnn_cell.InputProjectionWrapper.state_size
tf.nn.rnn_cell.InputProjectionWrapper.zero_state(batch_size, dtype)Return zero-filled state tensor(s).
class tf.nn.rnn_cell.OutputProjectionWrapperOperator adding an output projection to the given cell.
tf.nn.rnn_cell.OutputProjectionWrapper.__init__(cell, output_size)Create a cell with output projection.
tf.nn.rnn_cell.OutputProjectionWrapper.output_size
tf.nn.rnn_cell.OutputProjectionWrapper.state_size
tf.nn.rnn_cell.OutputProjectionWrapper.zero_state(batch_size, dtype)Return zero-filled state tensor(s).

Running Graphs > Session management

Members
class tf.SessionA class for running TensorFlow operations.
tf.Session.__init__(target='', graph=None, config=None)Creates a new TensorFlow session.
tf.Session.run(fetches, feed_dict=None, options=None, run_metadata=None)Runs operations and evaluates tensors in fetches.
tf.Session.close()Closes this session.
tf.Session.graphThe graph that was launched in this session.
tf.Session.as_default()Returns a context manager that makes this object the default session.
tf.Session.reset(target, containers=None, config=None)Resets resource containers on target, and close all connected sessions.
class tf.InteractiveSessionA TensorFlow Session for use in interactive contexts, such as a shell.
tf.InteractiveSession.__init__(target='', graph=None, config=None)Creates a new interactive TensorFlow session.
tf.InteractiveSession.close()Closes an InteractiveSession.
tf.get_default_session()Returns the default session for the current thread.

Running Graphs > Error classes

Members
class tf.OpErrorA generic error that is raised when TensorFlow execution fails.
tf.OpError.opThe operation that failed, if known.
tf.OpError.node_defThe NodeDef proto representing the op that failed.
tf.OpError.__init__(node_def, op, message, error_code)Creates a new OpError indicating that a particular op failed.
tf.OpError.error_codeThe integer error code that describes the error.
tf.OpError.messageThe error message that describes the error.
class tf.errors.CancelledErrorRaised when an operation or step is cancelled.
tf.errors.CancelledError.__init__(node_def, op, message)Creates a CancelledError.
class tf.errors.UnknownErrorUnknown error.
tf.errors.UnknownError.__init__(node_def, op, message, error_code=2)Creates an UnknownError.
class tf.errors.InvalidArgumentErrorRaised when an operation receives an invalid argument.
tf.errors.InvalidArgumentError.__init__(node_def, op, message)Creates an InvalidArgumentError.
class tf.errors.DeadlineExceededErrorRaised when a deadline expires before an operation could complete.
tf.errors.DeadlineExceededError.__init__(node_def, op, message)Creates a DeadlineExceededError.
class tf.errors.NotFoundErrorRaised when a requested entity (e.g., a file or directory) was not found.
tf.errors.NotFoundError.__init__(node_def, op, message)Creates a NotFoundError.
class tf.errors.AlreadyExistsErrorRaised when an entity that we attempted to create already exists.
tf.errors.AlreadyExistsError.__init__(node_def, op, message)Creates an AlreadyExistsError.
class tf.errors.PermissionDeniedErrorRaised when the caller does not have permission to run an operation.
tf.errors.PermissionDeniedError.__init__(node_def, op, message)Creates a PermissionDeniedError.
class tf.errors.UnauthenticatedErrorThe request does not have valid authentication credentials.
tf.errors.UnauthenticatedError.__init__(node_def, op, message)Creates an UnauthenticatedError.
class tf.errors.ResourceExhaustedErrorSome resource has been exhausted.
tf.errors.ResourceExhaustedError.__init__(node_def, op, message)Creates a ResourceExhaustedError.
class tf.errors.FailedPreconditionErrorOperation was rejected because the system is not in a state to execute it.
tf.errors.FailedPreconditionError.__init__(node_def, op, message)Creates a FailedPreconditionError.
class tf.errors.AbortedErrorThe operation was aborted, typically due to a concurrent action.
tf.errors.AbortedError.__init__(node_def, op, message)Creates an AbortedError.
class tf.errors.OutOfRangeErrorRaised when an operation iterates past the valid input range.
tf.errors.OutOfRangeError.__init__(node_def, op, message)Creates an OutOfRangeError.
class tf.errors.UnimplementedErrorRaised when an operation has not been implemented.
tf.errors.UnimplementedError.__init__(node_def, op, message)Creates an UnimplementedError.
class tf.errors.InternalErrorRaised when the system experiences an internal error.
tf.errors.InternalError.__init__(node_def, op, message)Creates an InternalError.
class tf.errors.UnavailableErrorRaised when the runtime is currently unavailable.
tf.errors.UnavailableError.__init__(node_def, op, message)Creates an UnavailableError.
class tf.errors.DataLossErrorRaised when unrecoverable data loss or corruption is encountered.
tf.errors.DataLossError.__init__(node_def, op, message)Creates a DataLossError.

Training > Optimizers

Members
class tf.train.OptimizerBase class for optimizers.
tf.train.Optimizer.__init__(use_locking, name)Create a new Optimizer.
tf.train.Optimizer.minimize(loss, global_step=None, var_list=None, gate_gradients=1, aggregation_method=None, colocate_gradients_with_ops=False, name=None, grad_loss=None)Add operations to minimize loss by updating var_list.
tf.train.Optimizer.compute_gradients(loss, var_list=None, gate_gradients=1, aggregation_method=None, colocate_gradients_with_ops=False, grad_loss=None)Compute gradients of loss for the variables in var_list.
tf.train.Optimizer.apply_gradients(grads_and_vars, global_step=None, name=None)Apply gradients to variables.
tf.train.Optimizer.get_slot_names()Return a list of the names of slots created by the Optimizer.
tf.train.Optimizer.get_slot(var, name)Return a slot named name created for var by the Optimizer.
tf.train.Optimizer.get_name()
class tf.train.GradientDescentOptimizerOptimizer that implements the gradient descent algorithm.
tf.train.GradientDescentOptimizer.__init__(learning_rate, use_locking=False, name='GradientDescent')Construct a new gradient descent optimizer.
class tf.train.AdadeltaOptimizerOptimizer that implements the Adadelta algorithm.
tf.train.AdadeltaOptimizer.__init__(learning_rate=0.001, rho=0.95, epsilon=1e-08, use_locking=False, name='Adadelta')Construct a new Adadelta optimizer.
class tf.train.AdagradOptimizerOptimizer that implements the Adagrad algorithm.
tf.train.AdagradOptimizer.__init__(learning_rate, initial_accumulator_value=0.1, use_locking=False, name='Adagrad')Construct a new Adagrad optimizer.
class tf.train.MomentumOptimizerOptimizer that implements the Momentum algorithm.
tf.train.MomentumOptimizer.__init__(learning_rate, momentum, use_locking=False, name='Momentum', use_nesterov=False)Construct a new Momentum optimizer.
class tf.train.AdamOptimizerOptimizer that implements the Adam algorithm.
tf.train.AdamOptimizer.__init__(learning_rate=0.001, beta1=0.9, beta2=0.999, epsilon=1e-08, use_locking=False, name='Adam')Construct a new Adam optimizer.
class tf.train.FtrlOptimizerOptimizer that implements the FTRL algorithm.
tf.train.FtrlOptimizer.__init__(learning_rate, learning_rate_power=-0.5, initial_accumulator_value=0.1, l1_regularization_strength=0.0, l2_regularization_strength=0.0, use_locking=False, name='Ftrl')Construct a new FTRL optimizer.
class tf.train.RMSPropOptimizerOptimizer that implements the RMSProp algorithm.
tf.train.RMSPropOptimizer.__init__(learning_rate, decay=0.9, momentum=0.0, epsilon=1e-10, use_locking=False, name='RMSProp')Construct a new RMSProp optimizer.

Training > Gradient Computation

Members
tf.gradients(ys, xs, grad_ys=None, name='gradients', colocate_gradients_with_ops=False, gate_gradients=False, aggregation_method=None)Constructs symbolic partial derivatives of sum of ys w.r.t. x in xs.
class tf.AggregationMethodA class listing aggregation methods used to combine gradients.
tf.stop_gradient(input, name=None)Stops gradient computation.

Training > Gradient Clipping

Members
tf.clip_by_value(t, clip_value_min, clip_value_max, name=None)Clips tensor values to a specified min and max.
tf.clip_by_norm(t, clip_norm, axes=None, name=None)Clips tensor values to a maximum L2-norm.
tf.clip_by_average_norm(t, clip_norm, name=None)Clips tensor values to a maximum average L2-norm.
tf.clip_by_global_norm(t_list, clip_norm, use_norm=None, name=None)Clips values of multiple tensors by the ratio of the sum of their norms.
tf.global_norm(t_list, name=None)Computes the global norm of multiple tensors.

Training > Decaying the learning rate

Members
tf.train.exponential_decay(learning_rate, global_step, decay_steps, decay_rate, staircase=False, name=None)Applies exponential decay to the learning rate.

Training > Moving Averages

Members
class tf.train.ExponentialMovingAverageMaintains moving averages of variables by employing an exponential decay.
tf.train.ExponentialMovingAverage.__init__(decay, num_updates=None, name='ExponentialMovingAverage')Creates a new ExponentialMovingAverage object.
tf.train.ExponentialMovingAverage.apply(var_list=None)Maintains moving averages of variables.
tf.train.ExponentialMovingAverage.average_name(var)Returns the name of the Variable holding the average for var.
tf.train.ExponentialMovingAverage.average(var)Returns the Variable holding the average of var.
tf.train.ExponentialMovingAverage.variables_to_restore(moving_avg_variables=None)Returns a map of names to Variables to restore.

Training > Coordinator and QueueRunner

Members
class tf.train.CoordinatorA coordinator for threads.
tf.train.Coordinator.__init__(clean_stop_exception_types=None)Create a new Coordinator.
tf.train.Coordinator.clear_stop()Clears the stop flag.
tf.train.Coordinator.join(threads=None, stop_grace_period_secs=120)Wait for threads to terminate.
tf.train.Coordinator.joined
tf.train.Coordinator.register_thread(thread)Register a thread to join.
tf.train.Coordinator.request_stop(ex=None)Request that the threads stop.
tf.train.Coordinator.should_stop()Check if stop was requested.
tf.train.Coordinator.stop_on_exception()Context manager to request stop when an Exception is raised.
tf.train.Coordinator.wait_for_stop(timeout=None)Wait till the Coordinator is told to stop.
class tf.train.QueueRunnerHolds a list of enqueue operations for a queue, each to be run in a thread.
tf.train.QueueRunner.__init__(queue=None, enqueue_ops=None, close_op=None, cancel_op=None, queue_runner_def=None)Create a QueueRunner.
tf.train.QueueRunner.cancel_op
tf.train.QueueRunner.close_op
tf.train.QueueRunner.create_threads(sess, coord=None, daemon=False, start=False)Create threads to run the enqueue ops.
tf.train.QueueRunner.enqueue_ops
tf.train.QueueRunner.exceptions_raisedExceptions raised but not handled by the QueueRunner threads.
tf.train.QueueRunner.from_proto(queue_runner_def)Returns a QueueRunner object created from queue_runner_def.
tf.train.QueueRunner.nameThe string name of the underlying Queue.
tf.train.QueueRunner.queue
tf.train.QueueRunner.to_proto()Converts this QueueRunner to a QueueRunnerDef protocol buffer.
tf.train.add_queue_runner(qr, collection='queue_runners')Adds a QueueRunner to a collection in the graph.
tf.train.start_queue_runners(sess=None, coord=None, daemon=True, start=True, collection='queue_runners')Starts all queue runners collected in the graph.

Training > Distributed execution

Members
class tf.train.ServerAn in-process TensorFlow server, for use in distributed training.
tf.train.Server.__init__(server_or_cluster_def, job_name=None, task_index=None, protocol=None, config=None, start=True)Creates a new server with the given definition.
tf.train.Server.create_local_server(config=None, start=True)Creates a new single-process cluster running on the local host.
tf.train.Server.targetReturns the target for a tf.Session to connect to this server.
tf.train.Server.server_defReturns the tf.train.ServerDef for this server.
tf.train.Server.start()Starts this server.
tf.train.Server.join()Blocks until the server has shut down.
class tf.train.SupervisorA training helper that checkpoints models and computes summaries.
tf.train.Supervisor.__init__(graph=None, ready_op=0, is_chief=True, init_op=0, init_feed_dict=None, local_init_op=0, logdir=None, summary_op=0, saver=0, global_step=0, save_summaries_secs=120, save_model_secs=600, recovery_wait_secs=30, stop_grace_secs=120, checkpoint_basename='model.ckpt', session_manager=None, summary_writer=0, init_fn=None)Create a Supervisor.
tf.train.Supervisor.managed_session(master='', config=None, start_standard_services=True, close_summary_writer=True)Returns a context manager for a managed session.
tf.train.Supervisor.prepare_or_wait_for_session(master='', config=None, wait_for_checkpoint=False, max_wait_secs=7200, start_standard_services=True)Make sure the model is ready to be used.
tf.train.Supervisor.start_standard_services(sess)Start the standard services for 'sess'.
tf.train.Supervisor.start_queue_runners(sess, queue_runners=None)Start threads for QueueRunners.
tf.train.Supervisor.summary_computed(sess, summary, global_step=None)Indicate that a summary was computed.
tf.train.Supervisor.stop(threads=None, close_summary_writer=True)Stop the services and the coordinator.
tf.train.Supervisor.request_stop(ex=None)Request that the coordinator stop the threads.
tf.train.Supervisor.should_stop()Check if the coordinator was told to stop.
tf.train.Supervisor.stop_on_exception()Context handler to stop the supervisor when an exception is raised.
tf.train.Supervisor.wait_for_stop()Block waiting for the coordinator to stop.
tf.train.Supervisor.Loop(timer_interval_secs, target, args=None, kwargs=None)Start a LooperThread that calls a function periodically.
tf.train.Supervisor.PrepareSession(master='', config=None, wait_for_checkpoint=False, max_wait_secs=7200, start_standard_services=True)Make sure the model is ready to be used.
tf.train.Supervisor.RequestStop(ex=None)Request that the coordinator stop the threads.
tf.train.Supervisor.ShouldStop()Check if the coordinator was told to stop.
tf.train.Supervisor.StartQueueRunners(sess, queue_runners=None)Start threads for QueueRunners.
tf.train.Supervisor.StartStandardServices(sess)Start the standard services for 'sess'.
tf.train.Supervisor.Stop(threads=None, close_summary_writer=True)Stop the services and the coordinator.
tf.train.Supervisor.StopOnException()Context handler to stop the supervisor when an exception is raised.
tf.train.Supervisor.SummaryComputed(sess, summary, global_step=None)Indicate that a summary was computed.
tf.train.Supervisor.WaitForStop()Block waiting for the coordinator to stop.
tf.train.Supervisor.coordReturn the Coordinator used by the Supervisor.
tf.train.Supervisor.global_stepReturn the global_step Tensor used by the supervisor.
tf.train.Supervisor.init_feed_dictReturn the feed dictionary used when evaluating the init_op.
tf.train.Supervisor.init_opReturn the Init Op used by the supervisor.
tf.train.Supervisor.is_chiefReturn True if this is a chief supervisor.
tf.train.Supervisor.loop(timer_interval_secs, target, args=None, kwargs=None)Start a LooperThread that calls a function periodically.
tf.train.Supervisor.ready_opReturn the Ready Op used by the supervisor.
tf.train.Supervisor.save_model_secsReturn the delay between checkpoints.
tf.train.Supervisor.save_pathReturn the save path used by the supervisor.
tf.train.Supervisor.save_summaries_secsReturn the delay between summary computations.
tf.train.Supervisor.saverReturn the Saver used by the supervisor.
tf.train.Supervisor.session_managerReturn the SessionManager used by the Supervisor.
tf.train.Supervisor.summary_opReturn the Summary Tensor used by the chief supervisor.
tf.train.Supervisor.summary_writerReturn the SummaryWriter used by the chief supervisor.
class tf.train.SessionManagerTraining helper that restores from checkpoint and creates session.
tf.train.SessionManager.__init__(local_init_op=None, ready_op=None, graph=None, recovery_wait_secs=30)Creates a SessionManager.
tf.train.SessionManager.prepare_session(master, init_op=None, saver=None, checkpoint_dir=None, wait_for_checkpoint=False, max_wait_secs=7200, config=None, init_feed_dict=None, init_fn=None)Creates a Session. Makes sure the model is ready to be used.
tf.train.SessionManager.recover_session(master, saver=None, checkpoint_dir=None, wait_for_checkpoint=False, max_wait_secs=7200, config=None)Creates a Session, recovering if possible.
tf.train.SessionManager.wait_for_session(master, config=None, max_wait_secs=inf)Creates a new Session and waits for model to be ready.
class tf.train.ClusterSpecRepresents a cluster as a set of "tasks", organized into "jobs".
tf.train.ClusterSpec.as_cluster_def()Returns a tf.train.ClusterDef protocol buffer based on this cluster.
tf.train.ClusterSpec.as_dict()Returns a dictionary from job names to lists of network addresses.
tf.train.ClusterSpec.__init__(cluster)Creates a ClusterSpec.
tf.train.ClusterSpec.job_tasks(job_name)Returns a list of tasks in the given job.
tf.train.ClusterSpec.jobsReturns a list of job names in this cluster.
tf.train.replica_device_setter(ps_tasks=0, ps_device='/job:ps', worker_device='/job:worker', merge_devices=True, cluster=None, ps_ops=None)Return a device function to use when building a Graph for replicas.

Training > Summary Operations

Members
tf.scalar_summary(tags, values, collections=None, name=None)Outputs a Summary protocol buffer with scalar values.
tf.image_summary(tag, tensor, max_images=3, collections=None, name=None)Outputs a Summary protocol buffer with images.
tf.audio_summary(tag, tensor, sample_rate, max_outputs=3, collections=None, name=None)Outputs a Summary protocol buffer with audio.
tf.histogram_summary(tag, values, collections=None, name=None)Outputs a Summary protocol buffer with a histogram.
tf.nn.zero_fraction(value, name=None)Returns the fraction of zeros in value.
tf.merge_summary(inputs, collections=None, name=None)Merges summaries.
tf.merge_all_summaries(key='summaries')Merges all summaries collected in the default graph.

Training > Adding Summaries to Event Files

Members
class tf.train.SummaryWriterWrites Summary protocol buffers to event files.
tf.train.SummaryWriter.__init__(logdir, graph=None, max_queue=10, flush_secs=120, graph_def=None)Creates a SummaryWriter and an event file.
tf.train.SummaryWriter.add_summary(summary, global_step=None)Adds a Summary protocol buffer to the event file.
tf.train.SummaryWriter.add_session_log(session_log, global_step=None)Adds a SessionLog protocol buffer to the event file.
tf.train.SummaryWriter.add_event(event)Adds an event to the event file.
tf.train.SummaryWriter.add_graph(graph, global_step=None, graph_def=None)Adds a Graph to the event file.
tf.train.SummaryWriter.add_run_metadata(run_metadata, tag, global_step=None)Adds a metadata information for a single session.run() call.
tf.train.SummaryWriter.flush()Flushes the event file to disk.
tf.train.SummaryWriter.close()Flushes the event file to disk and close the file.
tf.train.SummaryWriter.reopen()Reopens the summary writer.
tf.train.summary_iterator(path)An iterator for reading Event protocol buffers from an event file.

Training > Training utilities

Members
tf.train.global_step(sess, global_step_tensor)Small helper to get the global step.
tf.train.write_graph(graph_def, logdir, name, as_text=True)Writes a graph proto to a file.

Training > Other Functions and Classes

Members
class tf.train.LooperThreadA thread that runs code repeatedly, optionally on a timer.
tf.train.LooperThread.__init__(coord, timer_interval_secs, target=None, args=None, kwargs=None)Create a LooperThread.
tf.train.LooperThread.daemonA boolean value indicating whether this thread is a daemon thread (True) or not (False).
tf.train.LooperThread.getName()
tf.train.LooperThread.identThread identifier of this thread or None if it has not been started.
tf.train.LooperThread.isAlive()Return whether the thread is alive.
tf.train.LooperThread.isDaemon()
tf.train.LooperThread.is_alive()Return whether the thread is alive.
tf.train.LooperThread.join(timeout=None)Wait until the thread terminates.
tf.train.LooperThread.loop(coord, timer_interval_secs, target, args=None, kwargs=None)Start a LooperThread that calls a function periodically.
tf.train.LooperThread.nameA string used for identification purposes only.
tf.train.LooperThread.run()
tf.train.LooperThread.run_loop()Called at 'timer_interval_secs' boundaries.
tf.train.LooperThread.setDaemon(daemonic)
tf.train.LooperThread.setName(name)
tf.train.LooperThread.start()Start the thread's activity.
tf.train.LooperThread.start_loop()Called when the thread starts.
tf.train.LooperThread.stop_loop()Called when the thread stops.
tf.train.do_quantize_training_on_graphdef(input_graph, num_bits)
tf.train.generate_checkpoint_state_proto(save_dir, model_checkpoint_path, all_model_checkpoint_paths=None)Generates a checkpoint state proto.

Wraps python functions > Script Language Operators.

Members

Wraps python functions > Other Functions and Classes

Members
tf.py_func(func, inp, Tout, stateful=True, name=None)Wraps a python function and uses it as a tensorflow op.

Summary Operations > Summary Ops

Members
tf.summary.tensor_summary(display_name, tensor, description='', labels=None, collections=None, name=None)Outputs a Summary protocol buffer with a serialized tensor.proto.

Testing > Unit tests

Members
tf.test.main()Runs all unit tests.

Testing > Utilities

Members
tf.test.assert_equal_graph_def(actual, expected)Asserts that two GraphDefs are (mostly) the same.
tf.test.get_temp_dir()Returns a temporary directory for use during tests.
tf.test.is_built_with_cuda()Returns whether TensorFlow was built with CUDA (GPU) support.

Testing > Gradient checking

Members
tf.test.compute_gradient(x, x_shape, y, y_shape, x_init_value=None, delta=0.001, init_targets=None)Computes and returns the theoretical and numerical Jacobian.
tf.test.compute_gradient_error(x, x_shape, y, y_shape, x_init_value=None, delta=0.001, init_targets=None)Computes the gradient error.

BayesFlow Stochastic Graph (contrib) > Stochastic Computation Graph Classes

Members
class tf.contrib.bayesflow.stochastic_graph.StochasticTensorBase Class for Tensor-like objects that emit stochastic values.
tf.contrib.bayesflow.stochastic_graph.StochasticTensor.__init__()
tf.contrib.bayesflow.stochastic_graph.StochasticTensor.dtype
tf.contrib.bayesflow.stochastic_graph.StochasticTensor.graph
tf.contrib.bayesflow.stochastic_graph.StochasticTensor.input_dict
tf.contrib.bayesflow.stochastic_graph.StochasticTensor.loss(sample_losses)Returns the term to add to the surrogate loss.
tf.contrib.bayesflow.stochastic_graph.StochasticTensor.name
tf.contrib.bayesflow.stochastic_graph.StochasticTensor.value(name=None)
class tf.contrib.bayesflow.stochastic_graph.DistributionTensorDistributionTensor is a StochasticTensor backed by a distribution.
tf.contrib.bayesflow.stochastic_graph.DistributionTensor.__init__(dist_cls, name=None, dist_value_type=None, loss_fn=score_function, **dist_args)Construct a DistributionTensor.
tf.contrib.bayesflow.stochastic_graph.DistributionTensor.clone(name=None, **dist_args)
tf.contrib.bayesflow.stochastic_graph.DistributionTensor.distribution
tf.contrib.bayesflow.stochastic_graph.DistributionTensor.dtype
tf.contrib.bayesflow.stochastic_graph.DistributionTensor.entropy(name='entropy')
tf.contrib.bayesflow.stochastic_graph.DistributionTensor.graph
tf.contrib.bayesflow.stochastic_graph.DistributionTensor.input_dict
tf.contrib.bayesflow.stochastic_graph.DistributionTensor.loss(final_losses, name='Loss')
tf.contrib.bayesflow.stochastic_graph.DistributionTensor.mean(name='mean')
tf.contrib.bayesflow.stochastic_graph.DistributionTensor.name
tf.contrib.bayesflow.stochastic_graph.DistributionTensor.value(name='value')
tf.contrib.bayesflow.stochastic_graph.DistributionTensor.value_type

BayesFlow Stochastic Graph (contrib) > Stochastic Computation Value Types

Members
class tf.contrib.bayesflow.stochastic_graph.MeanValue
tf.contrib.bayesflow.stochastic_graph.MeanValue.__init__(stop_gradient=False)
tf.contrib.bayesflow.stochastic_graph.MeanValue.declare_inputs(unused_stochastic_tensor, unused_inputs_dict)
tf.contrib.bayesflow.stochastic_graph.MeanValue.popped_above(unused_value_type)
tf.contrib.bayesflow.stochastic_graph.MeanValue.pushed_above(unused_value_type)
tf.contrib.bayesflow.stochastic_graph.MeanValue.stop_gradient
class tf.contrib.bayesflow.stochastic_graph.SampleValueDraw n samples along a new outer dimension.
tf.contrib.bayesflow.stochastic_graph.SampleValue.__init__(n=1, stop_gradient=False)Sample n times and concatenate along a new outer dimension.
tf.contrib.bayesflow.stochastic_graph.SampleValue.declare_inputs(unused_stochastic_tensor, unused_inputs_dict)
tf.contrib.bayesflow.stochastic_graph.SampleValue.n
tf.contrib.bayesflow.stochastic_graph.SampleValue.popped_above(unused_value_type)
tf.contrib.bayesflow.stochastic_graph.SampleValue.pushed_above(unused_value_type)
tf.contrib.bayesflow.stochastic_graph.SampleValue.stop_gradient
class tf.contrib.bayesflow.stochastic_graph.SampleAndReshapeValueAsk the StochasticTensor for n samples and reshape the result.
tf.contrib.bayesflow.stochastic_graph.SampleAndReshapeValue.__init__(n=1, stop_gradient=False)Sample n times and reshape the outer 2 axes so rank does not change.
tf.contrib.bayesflow.stochastic_graph.SampleAndReshapeValue.declare_inputs(unused_stochastic_tensor, unused_inputs_dict)
tf.contrib.bayesflow.stochastic_graph.SampleAndReshapeValue.n
tf.contrib.bayesflow.stochastic_graph.SampleAndReshapeValue.popped_above(unused_value_type)
tf.contrib.bayesflow.stochastic_graph.SampleAndReshapeValue.pushed_above(unused_value_type)
tf.contrib.bayesflow.stochastic_graph.SampleAndReshapeValue.stop_gradient
tf.contrib.bayesflow.stochastic_graph.value_type(dist_value_type)Creates a value type context for any StochasticTensor created within.
tf.contrib.bayesflow.stochastic_graph.get_current_value_type()

BayesFlow Stochastic Graph (contrib) > Stochastic Computation Surrogate Loss Functions

Members
tf.contrib.bayesflow.stochastic_graph.score_function(dist_tensor, value, losses)
tf.contrib.bayesflow.stochastic_graph.get_score_function_with_baseline(baseline)

BayesFlow Stochastic Graph (contrib) > Stochastic Computation Graph Helper Functions

Members
tf.contrib.bayesflow.stochastic_graph.surrogate_loss(sample_losses, stochastic_tensors=None, name='SurrogateLoss')Surrogate loss for stochastic graphs.

BayesFlow Stochastic Graph (contrib) > Other Functions and Classes

Members
class tf.contrib.bayesflow.stochastic_graph.NoValueTypeSetError

Statistical distributions (contrib) > Classes for statistical distributions.

Members
class tf.contrib.distributions.DistributionFully-featured abstract base class for probability distributions.
tf.contrib.distributions.Distribution.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Distribution.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.Distribution.cdf(value, name='cdf')Cumulative distribution function.
tf.contrib.distributions.Distribution.dtypedtype of samples from this distribution.
tf.contrib.distributions.Distribution.entropy(name='entropy')Entropy of the distribution in nats.
tf.contrib.distributions.Distribution.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.Distribution.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Distribution.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Distribution.is_continuous
tf.contrib.distributions.Distribution.is_reparameterized
tf.contrib.distributions.Distribution.log_cdf(value, name='log_cdf')Log CDF.
tf.contrib.distributions.Distribution.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Distribution.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Distribution.log_prob(value, name='log_prob')Log of the probability density/mass function.
tf.contrib.distributions.Distribution.mean(name='mean')Mean of the distribution.
tf.contrib.distributions.Distribution.mode(name='mode')Mode of the distribution.
tf.contrib.distributions.Distribution.nameName to prepend to all ops.
tf.contrib.distributions.Distribution.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Distribution.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Distribution.prob(value, name='prob')Probability density/mass function.
tf.contrib.distributions.Distribution.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Distribution.sample_n(n, seed=None, name='sample_n')Generate n samples.
tf.contrib.distributions.Distribution.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.Distribution.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Distribution.variance(name='variance')Variance of the distribution.
class tf.contrib.distributions.BinomialBinomial distribution.
tf.contrib.distributions.Binomial.__init__(n, logits=None, p=None, validate_args=True, allow_nan_stats=False, name='Binomial')Initialize a batch of Binomial distributions.
tf.contrib.distributions.Binomial.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Binomial.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.Binomial.cdf(value, name='cdf')Cumulative distribution function.
tf.contrib.distributions.Binomial.dtypedtype of samples from this distribution.
tf.contrib.distributions.Binomial.entropy(name='entropy')Entropy of the distribution in nats.
tf.contrib.distributions.Binomial.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.Binomial.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Binomial.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Binomial.is_continuous
tf.contrib.distributions.Binomial.is_reparameterized
tf.contrib.distributions.Binomial.log_cdf(value, name='log_cdf')Log CDF.
tf.contrib.distributions.Binomial.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Binomial.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Binomial.log_prob(counts, name='log_prob')Log(P[counts]), computed for every batch member.
tf.contrib.distributions.Binomial.logitsLog-odds.
tf.contrib.distributions.Binomial.mean(name='mean')Mean of the distribution.
tf.contrib.distributions.Binomial.mode(name='mode')Mode of the distribution.
tf.contrib.distributions.Binomial.nNumber of trials.
tf.contrib.distributions.Binomial.nameName to prepend to all ops.
tf.contrib.distributions.Binomial.pProbability of success.
tf.contrib.distributions.Binomial.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Binomial.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Binomial.prob(counts, name='prob')P[counts], computed for every batch member.
tf.contrib.distributions.Binomial.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Binomial.sample_n(n, seed=None, name='sample_n')Generate n samples.
tf.contrib.distributions.Binomial.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.Binomial.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Binomial.variance(name='variance')Variance of the distribution.
class tf.contrib.distributions.BernoulliBernoulli distribution.
tf.contrib.distributions.Bernoulli.__init__(logits=None, p=None, dtype=tf.int32, validate_args=True, allow_nan_stats=False, name='Bernoulli')Construct Bernoulli distributions.
tf.contrib.distributions.Bernoulli.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Bernoulli.batch_shape(name='batch_shape')
tf.contrib.distributions.Bernoulli.cdf(value, name='cdf')Cumulative distribution function.
tf.contrib.distributions.Bernoulli.dtype
tf.contrib.distributions.Bernoulli.entropy(name='entropy')Entropy of the distribution.
tf.contrib.distributions.Bernoulli.event_shape(name='event_shape')
tf.contrib.distributions.Bernoulli.get_batch_shape()
tf.contrib.distributions.Bernoulli.get_event_shape()
tf.contrib.distributions.Bernoulli.is_continuous
tf.contrib.distributions.Bernoulli.is_reparameterized
tf.contrib.distributions.Bernoulli.log_cdf(value, name='log_cdf')Log CDF.
tf.contrib.distributions.Bernoulli.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Bernoulli.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Bernoulli.log_prob(event, name='log_prob')Log of the probability mass function.
tf.contrib.distributions.Bernoulli.logits
tf.contrib.distributions.Bernoulli.mean(name='mean')Mean of the distribution.
tf.contrib.distributions.Bernoulli.mode(name='mode')Mode of the distribution.
tf.contrib.distributions.Bernoulli.name
tf.contrib.distributions.Bernoulli.p
tf.contrib.distributions.Bernoulli.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Bernoulli.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Bernoulli.prob(event, name='prob')Probability mass function.
tf.contrib.distributions.Bernoulli.q1-p.
tf.contrib.distributions.Bernoulli.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Bernoulli.sample_n(n, seed=None, name='sample_n')Generate n samples.
tf.contrib.distributions.Bernoulli.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.Bernoulli.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Bernoulli.variance(name='variance')Variance of the distribution.
class tf.contrib.distributions.BetaBeta distribution.
tf.contrib.distributions.Beta.__init__(a, b, validate_args=True, allow_nan_stats=False, name='Beta')Initialize a batch of Beta distributions.
tf.contrib.distributions.Beta.aShape parameter.
tf.contrib.distributions.Beta.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Beta.bShape parameter.
tf.contrib.distributions.Beta.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.Beta.cdf(x, name='cdf')Cumulative distribution function.
tf.contrib.distributions.Beta.dtypedtype of samples from this distribution.
tf.contrib.distributions.Beta.entropy(name='entropy')Entropy of the distribution in nats.
tf.contrib.distributions.Beta.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.Beta.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Beta.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Beta.is_continuous
tf.contrib.distributions.Beta.is_reparameterized
tf.contrib.distributions.Beta.log_cdf(x, name='log_cdf')Log CDF.
tf.contrib.distributions.Beta.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Beta.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Beta.log_prob(x, name='log_prob')Log(P[counts]), computed for every batch member.
tf.contrib.distributions.Beta.mean(name='mean')Mean of the distribution.
tf.contrib.distributions.Beta.mode(name='mode')Mode of the distribution.
tf.contrib.distributions.Beta.nameName to prepend to all ops.
tf.contrib.distributions.Beta.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Beta.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Beta.prob(x, name='prob')P[x], computed for every batch member.
tf.contrib.distributions.Beta.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Beta.sample_n(n, seed=None, name='sample_n')Sample n observations from the Beta Distributions.
tf.contrib.distributions.Beta.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.Beta.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Beta.variance(name='variance')Variance of the distribution.
class tf.contrib.distributions.CategoricalCategorical distribution.
tf.contrib.distributions.Categorical.__init__(logits, dtype=tf.int32, validate_args=True, allow_nan_stats=False, name='Categorical')Initialize Categorical distributions using class log-probabilities.
tf.contrib.distributions.Categorical.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Categorical.batch_shape(name='batch_shape')
tf.contrib.distributions.Categorical.cdf(value, name='cdf')Cumulative distribution function.
tf.contrib.distributions.Categorical.dtype
tf.contrib.distributions.Categorical.entropy(name='sample')
tf.contrib.distributions.Categorical.event_shape(name='event_shape')
tf.contrib.distributions.Categorical.get_batch_shape()
tf.contrib.distributions.Categorical.get_event_shape()
tf.contrib.distributions.Categorical.is_continuous
tf.contrib.distributions.Categorical.is_reparameterized
tf.contrib.distributions.Categorical.log_cdf(value, name='log_cdf')Log CDF.
tf.contrib.distributions.Categorical.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Categorical.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Categorical.log_prob(k, name='log_prob')Log-probability of class k.
tf.contrib.distributions.Categorical.logits
tf.contrib.distributions.Categorical.mean(name='mean')Mean of the distribution.
tf.contrib.distributions.Categorical.mode(name='mode')
tf.contrib.distributions.Categorical.name
tf.contrib.distributions.Categorical.num_classes
tf.contrib.distributions.Categorical.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Categorical.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Categorical.prob(k, name='prob')Probability of class k.
tf.contrib.distributions.Categorical.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Categorical.sample_n(n, seed=None, name='sample_n')Sample n observations from the Categorical distribution.
tf.contrib.distributions.Categorical.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.Categorical.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Categorical.variance(name='variance')Variance of the distribution.
class tf.contrib.distributions.Chi2The Chi2 distribution with degrees of freedom df.
tf.contrib.distributions.Chi2.__init__(df, validate_args=True, allow_nan_stats=False, name='Chi2')Construct Chi2 distributions with parameter df.
tf.contrib.distributions.Chi2.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Chi2.alphaShape parameter.
tf.contrib.distributions.Chi2.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.Chi2.betaInverse scale parameter.
tf.contrib.distributions.Chi2.cdf(x, name='cdf')CDF of observations x under these Gamma distribution(s).
tf.contrib.distributions.Chi2.df
tf.contrib.distributions.Chi2.dtypedtype of samples from this distribution.
tf.contrib.distributions.Chi2.entropy(name='entropy')The entropy of Gamma distribution(s).
tf.contrib.distributions.Chi2.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.Chi2.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Chi2.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Chi2.is_continuous
tf.contrib.distributions.Chi2.is_reparameterized
tf.contrib.distributions.Chi2.log_cdf(x, name='log_cdf')Log CDF of observations x under these Gamma distribution(s).
tf.contrib.distributions.Chi2.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Chi2.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Chi2.log_prob(x, name='log_prob')Log prob of observations in x under these Gamma distribution(s).
tf.contrib.distributions.Chi2.mean(name='mean')Mean of each batch member.
tf.contrib.distributions.Chi2.mode(name='mode')Mode of each batch member.
tf.contrib.distributions.Chi2.nameName to prepend to all ops.
tf.contrib.distributions.Chi2.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Chi2.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Chi2.prob(x, name='prob')Pdf of observations in x under these Gamma distribution(s).
tf.contrib.distributions.Chi2.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Chi2.sample_n(n, seed=None, name='sample_n')Draws n samples from the Gamma distribution(s).
tf.contrib.distributions.Chi2.std(name='std')Standard deviation of this distribution.
tf.contrib.distributions.Chi2.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Chi2.variance(name='variance')Variance of each batch member.
class tf.contrib.distributions.ExponentialThe Exponential distribution with rate parameter lam.
tf.contrib.distributions.Exponential.__init__(lam, validate_args=True, allow_nan_stats=False, name='Exponential')Construct Exponential distribution with parameter lam.
tf.contrib.distributions.Exponential.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Exponential.alphaShape parameter.
tf.contrib.distributions.Exponential.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.Exponential.betaInverse scale parameter.
tf.contrib.distributions.Exponential.cdf(x, name='cdf')CDF of observations x under these Gamma distribution(s).
tf.contrib.distributions.Exponential.dtypedtype of samples from this distribution.
tf.contrib.distributions.Exponential.entropy(name='entropy')The entropy of Gamma distribution(s).
tf.contrib.distributions.Exponential.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.Exponential.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Exponential.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Exponential.is_continuous
tf.contrib.distributions.Exponential.is_reparameterized
tf.contrib.distributions.Exponential.lam
tf.contrib.distributions.Exponential.log_cdf(x, name='log_cdf')Log CDF of observations x under these Gamma distribution(s).
tf.contrib.distributions.Exponential.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Exponential.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Exponential.log_prob(x, name='log_prob')Log prob of observations in x under these Gamma distribution(s).
tf.contrib.distributions.Exponential.mean(name='mean')Mean of each batch member.
tf.contrib.distributions.Exponential.mode(name='mode')Mode of each batch member.
tf.contrib.distributions.Exponential.nameName to prepend to all ops.
tf.contrib.distributions.Exponential.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Exponential.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Exponential.prob(x, name='prob')Pdf of observations in x under these Gamma distribution(s).
tf.contrib.distributions.Exponential.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Exponential.sample_n(n, seed=None, name='sample_n')Sample n observations from the Exponential Distributions.
tf.contrib.distributions.Exponential.std(name='std')Standard deviation of this distribution.
tf.contrib.distributions.Exponential.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Exponential.variance(name='variance')Variance of each batch member.
class tf.contrib.distributions.GammaThe Gamma distribution with parameter alpha and beta.
tf.contrib.distributions.Gamma.__init__(alpha, beta, validate_args=True, allow_nan_stats=False, name='Gamma')Construct Gamma distributions with parameters alpha and beta.
tf.contrib.distributions.Gamma.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Gamma.alphaShape parameter.
tf.contrib.distributions.Gamma.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.Gamma.betaInverse scale parameter.
tf.contrib.distributions.Gamma.cdf(x, name='cdf')CDF of observations x under these Gamma distribution(s).
tf.contrib.distributions.Gamma.dtypedtype of samples from this distribution.
tf.contrib.distributions.Gamma.entropy(name='entropy')The entropy of Gamma distribution(s).
tf.contrib.distributions.Gamma.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.Gamma.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Gamma.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Gamma.is_continuous
tf.contrib.distributions.Gamma.is_reparameterized
tf.contrib.distributions.Gamma.log_cdf(x, name='log_cdf')Log CDF of observations x under these Gamma distribution(s).
tf.contrib.distributions.Gamma.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Gamma.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Gamma.log_prob(x, name='log_prob')Log prob of observations in x under these Gamma distribution(s).
tf.contrib.distributions.Gamma.mean(name='mean')Mean of each batch member.
tf.contrib.distributions.Gamma.mode(name='mode')Mode of each batch member.
tf.contrib.distributions.Gamma.nameName to prepend to all ops.
tf.contrib.distributions.Gamma.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Gamma.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Gamma.prob(x, name='prob')Pdf of observations in x under these Gamma distribution(s).
tf.contrib.distributions.Gamma.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Gamma.sample_n(n, seed=None, name='sample_n')Draws n samples from the Gamma distribution(s).
tf.contrib.distributions.Gamma.std(name='std')Standard deviation of this distribution.
tf.contrib.distributions.Gamma.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Gamma.variance(name='variance')Variance of each batch member.
class tf.contrib.distributions.InverseGammaThe InverseGamma distribution with parameter alpha and beta.
tf.contrib.distributions.InverseGamma.__init__(alpha, beta, validate_args=True, allow_nan_stats=False, name='InverseGamma')Construct InverseGamma distributions with parameters alpha and beta.
tf.contrib.distributions.InverseGamma.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.InverseGamma.alphaShape parameter.
tf.contrib.distributions.InverseGamma.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.InverseGamma.betaScale parameter.
tf.contrib.distributions.InverseGamma.cdf(x, name='cdf')CDF of observations x under these InverseGamma distribution(s).
tf.contrib.distributions.InverseGamma.dtypedtype of samples from this distribution.
tf.contrib.distributions.InverseGamma.entropy(name='entropy')The entropy of these InverseGamma distribution(s).
tf.contrib.distributions.InverseGamma.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.InverseGamma.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.InverseGamma.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.InverseGamma.is_continuous
tf.contrib.distributions.InverseGamma.is_reparameterized
tf.contrib.distributions.InverseGamma.log_cdf(x, name='log_cdf')Log CDF of observations x under these InverseGamma distribution(s).
tf.contrib.distributions.InverseGamma.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.InverseGamma.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.InverseGamma.log_prob(x, name='log_prob')Log prob of observations in x under these InverseGamma distribution(s).
tf.contrib.distributions.InverseGamma.mean(name='mean')Mean of each batch member.
tf.contrib.distributions.InverseGamma.mode(name='mode')Mode of each batch member.
tf.contrib.distributions.InverseGamma.nameName to prepend to all ops.
tf.contrib.distributions.InverseGamma.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.InverseGamma.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.InverseGamma.prob(x, name='prob')Pdf of observations in x under these Gamma distribution(s).
tf.contrib.distributions.InverseGamma.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.InverseGamma.sample_n(n, seed=None, name='sample_n')Draws n samples from these InverseGamma distribution(s).
tf.contrib.distributions.InverseGamma.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.InverseGamma.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.InverseGamma.variance(name='variance')Variance of each batch member.
class tf.contrib.distributions.LaplaceThe Laplace distribution with location and scale > 0 parameters.
tf.contrib.distributions.Laplace.__init__(loc, scale, validate_args=True, allow_nan_stats=False, name='Laplace')Construct Laplace distribution with parameters loc and scale.
tf.contrib.distributions.Laplace.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Laplace.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.Laplace.cdf(x, name='cdf')CDF of observations in x under the Laplace distribution(s).
tf.contrib.distributions.Laplace.dtype
tf.contrib.distributions.Laplace.entropy(name='entropy')The entropy of Laplace distribution(s).
tf.contrib.distributions.Laplace.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.Laplace.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Laplace.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Laplace.is_continuous
tf.contrib.distributions.Laplace.is_reparameterized
tf.contrib.distributions.Laplace.locDistribution parameter for the location.
tf.contrib.distributions.Laplace.log_cdf(x, name='log_cdf')Log CDF of observations x under the Laplace distribution(s).
tf.contrib.distributions.Laplace.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Laplace.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Laplace.log_prob(x, name='log_prob')Log prob of observations in x under these Laplace distribution(s).
tf.contrib.distributions.Laplace.mean(name='mean')Mean of this distribution.
tf.contrib.distributions.Laplace.median(name='median')Median of this distribution.
tf.contrib.distributions.Laplace.mode(name='mode')Mode of this distribution.
tf.contrib.distributions.Laplace.name
tf.contrib.distributions.Laplace.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Laplace.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Laplace.prob(x, name='pdf')The prob of observations in x under the Laplace distribution(s).
tf.contrib.distributions.Laplace.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Laplace.sample_n(n, seed=None, name='sample_n')Sample n observations from the Laplace Distributions.
tf.contrib.distributions.Laplace.scaleDistribution parameter for scale.
tf.contrib.distributions.Laplace.std(name='std')Standard deviation of this distribution.
tf.contrib.distributions.Laplace.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Laplace.variance(name='variance')Variance of this distribution.
class tf.contrib.distributions.NormalThe scalar Normal distribution with mean and stddev parameters mu, sigma.
tf.contrib.distributions.Normal.__init__(mu, sigma, validate_args=True, allow_nan_stats=False, name='Normal')Construct Normal distributions with mean and stddev mu and sigma.
tf.contrib.distributions.Normal.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Normal.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.Normal.cdf(x, name='cdf')CDF of observations in x under these Normal distribution(s).
tf.contrib.distributions.Normal.dtype
tf.contrib.distributions.Normal.entropy(name='entropy')The entropy of Normal distribution(s).
tf.contrib.distributions.Normal.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.Normal.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Normal.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Normal.is_continuous
tf.contrib.distributions.Normal.is_reparameterized
tf.contrib.distributions.Normal.log_cdf(x, name='log_cdf')Log CDF of observations x under these Normal distribution(s).
tf.contrib.distributions.Normal.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Normal.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Normal.log_prob(x, name='log_prob')Log prob of observations in x under these Normal distribution(s).
tf.contrib.distributions.Normal.mean(name='mean')Mean of this distribution.
tf.contrib.distributions.Normal.mode(name='mode')Mode of this distribution.
tf.contrib.distributions.Normal.muDistribution parameter for the mean.
tf.contrib.distributions.Normal.name
tf.contrib.distributions.Normal.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Normal.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Normal.prob(x, name='prob')The PDF of observations in x under these Normal distribution(s).
tf.contrib.distributions.Normal.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Normal.sample_n(n, seed=None, name='sample_n')Sample n observations from the Normal Distributions.
tf.contrib.distributions.Normal.sigmaDistribution parameter for standard deviation.
tf.contrib.distributions.Normal.std(name='std')Standard deviation of this distribution.
tf.contrib.distributions.Normal.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Normal.variance(name='variance')Variance of this distribution.
class tf.contrib.distributions.StudentTStudent's t distribution with degree-of-freedom parameter df.
tf.contrib.distributions.StudentT.__init__(df, mu, sigma, validate_args=True, allow_nan_stats=False, name='StudentT')Construct Student's t distributions.
tf.contrib.distributions.StudentT.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.StudentT.batch_shape(name='batch_shape')
tf.contrib.distributions.StudentT.cdf(value, name='cdf')Cumulative distribution function.
tf.contrib.distributions.StudentT.dfDegrees of freedom in these Student's t distribution(s).
tf.contrib.distributions.StudentT.dtype
tf.contrib.distributions.StudentT.entropy(name='entropy')The entropy of Student t distribution(s).
tf.contrib.distributions.StudentT.event_shape(name='event_shape')
tf.contrib.distributions.StudentT.get_batch_shape()
tf.contrib.distributions.StudentT.get_event_shape()
tf.contrib.distributions.StudentT.is_continuous
tf.contrib.distributions.StudentT.is_reparameterized
tf.contrib.distributions.StudentT.log_cdf(value, name='log_cdf')Log CDF.
tf.contrib.distributions.StudentT.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.StudentT.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.StudentT.log_prob(x, name='log_prob')Log prob of observations in x under these Student's t-distribution(s).
tf.contrib.distributions.StudentT.mean(name='mean')Mean of the distribution.
tf.contrib.distributions.StudentT.mode(name='mode')
tf.contrib.distributions.StudentT.muLocations of these Student's t distribution(s).
tf.contrib.distributions.StudentT.name
tf.contrib.distributions.StudentT.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.StudentT.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.StudentT.prob(x, name='prob')The PDF of observations in x under these Student's t distribution(s).
tf.contrib.distributions.StudentT.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.StudentT.sample_n(n, seed=None, name='sample_n')Sample n observations from the Student t Distributions.
tf.contrib.distributions.StudentT.sigmaScaling factors of these Student's t distribution(s).
tf.contrib.distributions.StudentT.std(name='std')
tf.contrib.distributions.StudentT.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.StudentT.variance(name='variance')Variance of the distribution.
class tf.contrib.distributions.UniformUniform distribution with a and b parameters.
tf.contrib.distributions.Uniform.__init__(a=0.0, b=1.0, validate_args=True, allow_nan_stats=False, name='Uniform')Construct Uniform distributions with a and b.
tf.contrib.distributions.Uniform.a
tf.contrib.distributions.Uniform.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Uniform.b
tf.contrib.distributions.Uniform.batch_shape(name='batch_shape')
tf.contrib.distributions.Uniform.cdf(x, name='cdf')CDF of observations in x under these Uniform distribution(s).
tf.contrib.distributions.Uniform.dtype
tf.contrib.distributions.Uniform.entropy(name='entropy')The entropy of Uniform distribution(s).
tf.contrib.distributions.Uniform.event_shape(name='event_shape')
tf.contrib.distributions.Uniform.get_batch_shape()
tf.contrib.distributions.Uniform.get_event_shape()
tf.contrib.distributions.Uniform.is_continuous
tf.contrib.distributions.Uniform.is_reparameterized
tf.contrib.distributions.Uniform.log_cdf(x, name='log_cdf')
tf.contrib.distributions.Uniform.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Uniform.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Uniform.log_prob(x, name='log_prob')
tf.contrib.distributions.Uniform.mean(name='mean')
tf.contrib.distributions.Uniform.mode(name='mode')Mode of the distribution.
tf.contrib.distributions.Uniform.name
tf.contrib.distributions.Uniform.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Uniform.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Uniform.prob(x, name='prob')The PDF of observations in x under these Uniform distribution(s).
tf.contrib.distributions.Uniform.range(name='range')b - a.
tf.contrib.distributions.Uniform.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Uniform.sample_n(n, seed=None, name='sample_n')Sample n observations from the Uniform Distributions.
tf.contrib.distributions.Uniform.std(name='std')
tf.contrib.distributions.Uniform.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Uniform.variance(name='variance')
class tf.contrib.distributions.MultivariateNormalDiagThe multivariate normal distribution on R^k.
tf.contrib.distributions.MultivariateNormalDiag.__init__(mu, diag_stdev, validate_args=True, allow_nan_stats=False, name='MultivariateNormalDiag')Multivariate Normal distributions on R^k.
tf.contrib.distributions.MultivariateNormalDiag.allow_nan_statsBoolean describing behavior when stats are undefined.
tf.contrib.distributions.MultivariateNormalDiag.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.MultivariateNormalDiag.cdf(value, name='cdf')Cumulative distribution function.
tf.contrib.distributions.MultivariateNormalDiag.dtype
tf.contrib.distributions.MultivariateNormalDiag.entropy(name='entropy')The entropies of these Multivariate Normals.
tf.contrib.distributions.MultivariateNormalDiag.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.MultivariateNormalDiag.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.MultivariateNormalDiag.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.MultivariateNormalDiag.is_continuous
tf.contrib.distributions.MultivariateNormalDiag.is_reparameterized
tf.contrib.distributions.MultivariateNormalDiag.log_cdf(value, name='log_cdf')Log CDF.
tf.contrib.distributions.MultivariateNormalDiag.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.MultivariateNormalDiag.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.MultivariateNormalDiag.log_prob(x, name='log_prob')Log prob of observations x given these Multivariate Normals.
tf.contrib.distributions.MultivariateNormalDiag.log_sigma_det(name='log_sigma_det')Log of determinant of covariance matrix.
tf.contrib.distributions.MultivariateNormalDiag.mean(name='mean')Mean of each batch member.
tf.contrib.distributions.MultivariateNormalDiag.mode(name='mode')Mode of each batch member.
tf.contrib.distributions.MultivariateNormalDiag.mu
tf.contrib.distributions.MultivariateNormalDiag.name
tf.contrib.distributions.MultivariateNormalDiag.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.MultivariateNormalDiag.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.MultivariateNormalDiag.prob(x, name='prob')The PDF of observations x under these Multivariate Normals.
tf.contrib.distributions.MultivariateNormalDiag.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.MultivariateNormalDiag.sample_n(n, seed=None, name='sample_n')Sample n observations from the Multivariate Normal Distributions.
tf.contrib.distributions.MultivariateNormalDiag.sigmaDense (batch) covariance matrix, if available.
tf.contrib.distributions.MultivariateNormalDiag.sigma_det(name='sigma_det')Determinant of covariance matrix.
tf.contrib.distributions.MultivariateNormalDiag.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.MultivariateNormalDiag.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.MultivariateNormalDiag.variance(name='variance')Variance of each batch member.
class tf.contrib.distributions.MultivariateNormalFullThe multivariate normal distribution on R^k.
tf.contrib.distributions.MultivariateNormalFull.__init__(mu, sigma, validate_args=True, allow_nan_stats=False, name='MultivariateNormalFull')Multivariate Normal distributions on R^k.
tf.contrib.distributions.MultivariateNormalFull.allow_nan_statsBoolean describing behavior when stats are undefined.
tf.contrib.distributions.MultivariateNormalFull.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.MultivariateNormalFull.cdf(value, name='cdf')Cumulative distribution function.
tf.contrib.distributions.MultivariateNormalFull.dtype
tf.contrib.distributions.MultivariateNormalFull.entropy(name='entropy')The entropies of these Multivariate Normals.
tf.contrib.distributions.MultivariateNormalFull.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.MultivariateNormalFull.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.MultivariateNormalFull.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.MultivariateNormalFull.is_continuous
tf.contrib.distributions.MultivariateNormalFull.is_reparameterized
tf.contrib.distributions.MultivariateNormalFull.log_cdf(value, name='log_cdf')Log CDF.
tf.contrib.distributions.MultivariateNormalFull.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.MultivariateNormalFull.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.MultivariateNormalFull.log_prob(x, name='log_prob')Log prob of observations x given these Multivariate Normals.
tf.contrib.distributions.MultivariateNormalFull.log_sigma_det(name='log_sigma_det')Log of determinant of covariance matrix.
tf.contrib.distributions.MultivariateNormalFull.mean(name='mean')Mean of each batch member.
tf.contrib.distributions.MultivariateNormalFull.mode(name='mode')Mode of each batch member.
tf.contrib.distributions.MultivariateNormalFull.mu
tf.contrib.distributions.MultivariateNormalFull.name
tf.contrib.distributions.MultivariateNormalFull.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.MultivariateNormalFull.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.MultivariateNormalFull.prob(x, name='prob')The PDF of observations x under these Multivariate Normals.
tf.contrib.distributions.MultivariateNormalFull.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.MultivariateNormalFull.sample_n(n, seed=None, name='sample_n')Sample n observations from the Multivariate Normal Distributions.
tf.contrib.distributions.MultivariateNormalFull.sigmaDense (batch) covariance matrix, if available.
tf.contrib.distributions.MultivariateNormalFull.sigma_det(name='sigma_det')Determinant of covariance matrix.
tf.contrib.distributions.MultivariateNormalFull.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.MultivariateNormalFull.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.MultivariateNormalFull.variance(name='variance')Variance of each batch member.
class tf.contrib.distributions.MultivariateNormalCholeskyThe multivariate normal distribution on R^k.
tf.contrib.distributions.MultivariateNormalCholesky.__init__(mu, chol, validate_args=True, allow_nan_stats=False, name='MultivariateNormalCholesky')Multivariate Normal distributions on R^k.
tf.contrib.distributions.MultivariateNormalCholesky.allow_nan_statsBoolean describing behavior when stats are undefined.
tf.contrib.distributions.MultivariateNormalCholesky.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.MultivariateNormalCholesky.cdf(value, name='cdf')Cumulative distribution function.
tf.contrib.distributions.MultivariateNormalCholesky.dtype
tf.contrib.distributions.MultivariateNormalCholesky.entropy(name='entropy')The entropies of these Multivariate Normals.
tf.contrib.distributions.MultivariateNormalCholesky.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.MultivariateNormalCholesky.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.MultivariateNormalCholesky.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.MultivariateNormalCholesky.is_continuous
tf.contrib.distributions.MultivariateNormalCholesky.is_reparameterized
tf.contrib.distributions.MultivariateNormalCholesky.log_cdf(value, name='log_cdf')Log CDF.
tf.contrib.distributions.MultivariateNormalCholesky.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.MultivariateNormalCholesky.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.MultivariateNormalCholesky.log_prob(x, name='log_prob')Log prob of observations x given these Multivariate Normals.
tf.contrib.distributions.MultivariateNormalCholesky.log_sigma_det(name='log_sigma_det')Log of determinant of covariance matrix.
tf.contrib.distributions.MultivariateNormalCholesky.mean(name='mean')Mean of each batch member.
tf.contrib.distributions.MultivariateNormalCholesky.mode(name='mode')Mode of each batch member.
tf.contrib.distributions.MultivariateNormalCholesky.mu
tf.contrib.distributions.MultivariateNormalCholesky.name
tf.contrib.distributions.MultivariateNormalCholesky.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.MultivariateNormalCholesky.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.MultivariateNormalCholesky.prob(x, name='prob')The PDF of observations x under these Multivariate Normals.
tf.contrib.distributions.MultivariateNormalCholesky.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.MultivariateNormalCholesky.sample_n(n, seed=None, name='sample_n')Sample n observations from the Multivariate Normal Distributions.
tf.contrib.distributions.MultivariateNormalCholesky.sigmaDense (batch) covariance matrix, if available.
tf.contrib.distributions.MultivariateNormalCholesky.sigma_det(name='sigma_det')Determinant of covariance matrix.
tf.contrib.distributions.MultivariateNormalCholesky.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.MultivariateNormalCholesky.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.MultivariateNormalCholesky.variance(name='variance')Variance of each batch member.
tf.contrib.distributions.batch_matrix_diag_transform(matrix, transform=None, name=None)Transform diagonal of [batch-]matrix, leave rest of matrix unchanged.
class tf.contrib.distributions.DirichletDirichlet distribution.
tf.contrib.distributions.Dirichlet.__init__(alpha, validate_args=True, allow_nan_stats=False, name='Dirichlet')Initialize a batch of Dirichlet distributions.
tf.contrib.distributions.Dirichlet.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Dirichlet.alphaShape parameter.
tf.contrib.distributions.Dirichlet.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.Dirichlet.cdf(x, name='cdf')Cumulative distribution function.
tf.contrib.distributions.Dirichlet.dtypedtype of samples from this distribution.
tf.contrib.distributions.Dirichlet.entropy(name='entropy')Entropy of the distribution in nats.
tf.contrib.distributions.Dirichlet.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.Dirichlet.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Dirichlet.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Dirichlet.is_continuous
tf.contrib.distributions.Dirichlet.is_reparameterized
tf.contrib.distributions.Dirichlet.log_cdf(x, name='log_cdf')Log CDF.
tf.contrib.distributions.Dirichlet.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Dirichlet.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Dirichlet.log_prob(x, name='log_prob')Log(P[counts]), computed for every batch member.
tf.contrib.distributions.Dirichlet.mean(name='mean')Mean of the distribution.
tf.contrib.distributions.Dirichlet.mode(name='mode')Mode of the distribution.
tf.contrib.distributions.Dirichlet.nameName to prepend to all ops.
tf.contrib.distributions.Dirichlet.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Dirichlet.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Dirichlet.prob(x, name='prob')P[x], computed for every batch member.
tf.contrib.distributions.Dirichlet.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Dirichlet.sample_n(n, seed=None, name='sample_n')Sample n observations from the distributions.
tf.contrib.distributions.Dirichlet.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.Dirichlet.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Dirichlet.variance(name='variance')Variance of the distribution.
class tf.contrib.distributions.DirichletMultinomialDirichletMultinomial mixture distribution.
tf.contrib.distributions.DirichletMultinomial.__init__(n, alpha, validate_args=True, allow_nan_stats=False, name='DirichletMultinomial')Initialize a batch of DirichletMultinomial distributions.
tf.contrib.distributions.DirichletMultinomial.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.DirichletMultinomial.alphaParameter defining this distribution.
tf.contrib.distributions.DirichletMultinomial.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.DirichletMultinomial.cdf(x, name='cdf')
tf.contrib.distributions.DirichletMultinomial.dtypedtype of samples from this distribution.
tf.contrib.distributions.DirichletMultinomial.entropy(name='entropy')Entropy of the distribution in nats.
tf.contrib.distributions.DirichletMultinomial.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.DirichletMultinomial.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.DirichletMultinomial.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.DirichletMultinomial.is_continuous
tf.contrib.distributions.DirichletMultinomial.is_reparameterized
tf.contrib.distributions.DirichletMultinomial.log_cdf(x, name='log_cdf')
tf.contrib.distributions.DirichletMultinomial.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.DirichletMultinomial.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.DirichletMultinomial.log_prob(counts, name='log_prob')Log(P[counts]), computed for every batch member.
tf.contrib.distributions.DirichletMultinomial.mean(name='mean')Class means for every batch member.
tf.contrib.distributions.DirichletMultinomial.mode(name='mode')Mode of the distribution.
tf.contrib.distributions.DirichletMultinomial.nParameter defining this distribution.
tf.contrib.distributions.DirichletMultinomial.nameName to prepend to all ops.
tf.contrib.distributions.DirichletMultinomial.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.DirichletMultinomial.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.DirichletMultinomial.prob(counts, name='prob')P[counts], computed for every batch member.
tf.contrib.distributions.DirichletMultinomial.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.DirichletMultinomial.sample_n(n, seed=None, name='sample_n')Generate n samples.
tf.contrib.distributions.DirichletMultinomial.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.DirichletMultinomial.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.DirichletMultinomial.variance(name='mean')Class variances for every batch member.
class tf.contrib.distributions.MultinomialMultinomial distribution.
tf.contrib.distributions.Multinomial.__init__(n, logits=None, p=None, validate_args=True, allow_nan_stats=False, name='Multinomial')Initialize a batch of Multinomial distributions.
tf.contrib.distributions.Multinomial.allow_nan_statsBoolean describing behavior when a stat is undefined for batch member.
tf.contrib.distributions.Multinomial.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.Multinomial.cdf(value, name='cdf')Cumulative distribution function.
tf.contrib.distributions.Multinomial.dtypedtype of samples from this distribution.
tf.contrib.distributions.Multinomial.entropy(name='entropy')Entropy of the distribution in nats.
tf.contrib.distributions.Multinomial.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.Multinomial.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Multinomial.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.Multinomial.is_continuous
tf.contrib.distributions.Multinomial.is_reparameterized
tf.contrib.distributions.Multinomial.log_cdf(value, name='log_cdf')Log CDF.
tf.contrib.distributions.Multinomial.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.Multinomial.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.Multinomial.log_prob(counts, name='log_prob')Log(P[counts]), computed for every batch member.
tf.contrib.distributions.Multinomial.logitsLog-odds.
tf.contrib.distributions.Multinomial.mean(name='mean')Mean of the distribution.
tf.contrib.distributions.Multinomial.mode(name='mode')Mode of the distribution.
tf.contrib.distributions.Multinomial.nNumber of trials.
tf.contrib.distributions.Multinomial.nameName to prepend to all ops.
tf.contrib.distributions.Multinomial.pEvent probabilities.
tf.contrib.distributions.Multinomial.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.Multinomial.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.Multinomial.prob(counts, name='prob')P[counts], computed for every batch member.
tf.contrib.distributions.Multinomial.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.Multinomial.sample_n(n, seed=None, name='sample_n')Generate n samples.
tf.contrib.distributions.Multinomial.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.Multinomial.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.Multinomial.variance(name='variance')Variance of the distribution.
class tf.contrib.distributions.TransformedDistributionA Transformed Distribution.
tf.contrib.distributions.TransformedDistribution.__init__(base_dist_cls, transform, inverse, log_det_jacobian, name='TransformedDistribution', **base_dist_args)Construct a Transformed Distribution.
tf.contrib.distributions.TransformedDistribution.allow_nan_stats
tf.contrib.distributions.TransformedDistribution.base_distributionBase distribution, p(x).
tf.contrib.distributions.TransformedDistribution.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.TransformedDistribution.cdf(value, name='cdf')Cumulative distribution function.
tf.contrib.distributions.TransformedDistribution.dtype
tf.contrib.distributions.TransformedDistribution.entropy(name='entropy')Entropy of the distribution in nats.
tf.contrib.distributions.TransformedDistribution.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.TransformedDistribution.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.TransformedDistribution.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.TransformedDistribution.inverseInverse function of transform, y => x.
tf.contrib.distributions.TransformedDistribution.is_continuous
tf.contrib.distributions.TransformedDistribution.is_reparameterized
tf.contrib.distributions.TransformedDistribution.log_cdf(value, name='log_cdf')Log CDF.
tf.contrib.distributions.TransformedDistribution.log_det_jacobianFunction computing the log determinant of the Jacobian of transform.
tf.contrib.distributions.TransformedDistribution.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.TransformedDistribution.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.TransformedDistribution.log_prob(y, name='log_prob')Log prob of observations in y.
tf.contrib.distributions.TransformedDistribution.mean(name='mean')Mean of the distribution.
tf.contrib.distributions.TransformedDistribution.mode(name='mode')Mode of the distribution.
tf.contrib.distributions.TransformedDistribution.name
tf.contrib.distributions.TransformedDistribution.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.TransformedDistribution.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.TransformedDistribution.prob(y, name='prob')The prob of observations in y.
tf.contrib.distributions.TransformedDistribution.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.TransformedDistribution.sample_n(n, seed=None, name='sample_n')Sample n observations.
tf.contrib.distributions.TransformedDistribution.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.TransformedDistribution.transformFunction transforming x => y.
tf.contrib.distributions.TransformedDistribution.validate_args
tf.contrib.distributions.TransformedDistribution.variance(name='variance')Variance of the distribution.

Statistical distributions (contrib) > Posterior inference with conjugate priors.

Members
tf.contrib.distributions.normal_conjugates_known_sigma_posterior(prior, sigma, s, n)Posterior Normal distribution with conjugate prior on the mean.
tf.contrib.distributions.normal_congugates_known_sigma_predictive(prior, sigma, s, n)Posterior predictive Normal distribution w. conjugate prior on the mean.

Statistical distributions (contrib) > Kullback Leibler Divergence

Members
tf.contrib.distributions.kl(dist_a, dist_b, allow_nan=False, name=None)Get the KL-divergence KL(dist_a || dist_b).
class tf.contrib.distributions.RegisterKLDecorator to register a KL divergence implementation function.
tf.contrib.distributions.RegisterKL.__init__(dist_cls_a, dist_cls_b)Initialize the KL registrar.

Statistical distributions (contrib) > Other Functions and Classes

Members
class tf.contrib.distributions.BaseDistributionSimple abstract base class for probability distributions.
tf.contrib.distributions.BaseDistribution.log_prob(value, name='log_prob')Log of the probability density/mass function.
tf.contrib.distributions.BaseDistribution.nameName to prepend to all ops.
tf.contrib.distributions.BaseDistribution.prob(value, name='prob')Probability density/mass function.
tf.contrib.distributions.BaseDistribution.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape.
tf.contrib.distributions.BaseDistribution.sample_n(n, seed=None, name='sample_n')Generate n samples.
class tf.contrib.distributions.MultivariateNormalDiagPlusVDVTThe multivariate normal distribution on R^k.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.__init__(mu, diag_large, v, diag_small=None, validate_args=True, allow_nan_stats=False, name='MultivariateNormalDiagPlusVDVT')Multivariate Normal distributions on R^k.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.allow_nan_statsBoolean describing behavior when stats are undefined.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.batch_shape(name='batch_shape')Batch dimensions of this instance as a 1-D int32 Tensor.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.cdf(value, name='cdf')Cumulative distribution function.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.dtype
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.entropy(name='entropy')The entropies of these Multivariate Normals.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.event_shape(name='event_shape')Shape of a sample from a single distribution as a 1-D int32 Tensor.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.get_batch_shape()TensorShape available at graph construction time.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.get_event_shape()TensorShape available at graph construction time.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.is_continuous
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.is_reparameterized
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.log_cdf(value, name='log_cdf')Log CDF.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.log_pdf(value, name='log_pdf')Log of the probability density function.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.log_pmf(value, name='log_pmf')Log of the probability mass function.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.log_prob(x, name='log_prob')Log prob of observations x given these Multivariate Normals.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.log_sigma_det(name='log_sigma_det')Log of determinant of covariance matrix.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.mean(name='mean')Mean of each batch member.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.mode(name='mode')Mode of each batch member.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.mu
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.name
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.pdf(value, name='pdf')The probability density function.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.pmf(value, name='pmf')The probability mass function.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.prob(x, name='prob')The PDF of observations x under these Multivariate Normals.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.sample(sample_shape=(), seed=None, name='sample')Generate samples of the specified shape for each batched distribution.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.sample_n(n, seed=None, name='sample_n')Sample n observations from the Multivariate Normal Distributions.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.sigmaDense (batch) covariance matrix, if available.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.sigma_det(name='sigma_det')Determinant of covariance matrix.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.std(name='std')Standard deviation of the distribution.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.validate_argsBoolean describing behavior on invalid input.
tf.contrib.distributions.MultivariateNormalDiagPlusVDVT.variance(name='variance')Variance of each batch member.

FFmpeg (contrib) > Encoding and decoding audio using FFmpeg

Members
tf.contrib.ffmpeg.decode_audio(contents, file_format=None, samples_per_second=None, channel_count=None)Create an op that decodes the contents of an audio file.
tf.contrib.ffmpeg.encode_audio(audio, file_format=None, samples_per_second=None)Creates an op that encodes an audio file using sampled audio from a tensor.
tf.contrib.framework.assert_same_float_dtype(tensors=None, dtype=None)Validate and return float type based on tensors and dtype.
tf.contrib.framework.assert_scalar_int(tensor)Assert tensor is 0-D, of type tf.int32 or tf.int64.
tf.contrib.framework.convert_to_tensor_or_sparse_tensor(value, dtype=None, name=None, as_ref=False)Converts value to a SparseTensor or Tensor.
tf.contrib.framework.get_graph_from_inputs(op_input_list, graph=None)Returns the appropriate graph to use for the given inputs.
tf.is_numeric_tensor(tensor)
tf.is_non_decreasing(x, name=None)Returns True if x is non-decreasing.
tf.is_strictly_increasing(x, name=None)Returns True if x is strictly increasing.
tf.contrib.framework.is_tensor(x)Check for tensor types.
tf.contrib.framework.reduce_sum_n(tensors, name=None)Reduce tensors to a scalar sum.
tf.contrib.framework.safe_embedding_lookup_sparse(*args, **kwargs)Lookup embedding results, accounting for invalid IDs and empty features. (deprecated)
tf.contrib.framework.with_shape(expected_shape, tensor)Asserts tensor has expected shape.
tf.contrib.framework.with_same_shape(expected_tensor, tensor)Assert tensors are the same shape, from the same graph.

Framework (contrib) > Deprecation

Members
tf.contrib.framework.deprecated(date, instructions)Decorator for marking functions or methods deprecated.
tf.contrib.framework.deprecated_arg_values(date, instructions, **deprecated_kwargs)Decorator for marking specific function argument values as deprecated.

Framework (contrib) > Arg_Scope

Members
tf.contrib.framework.arg_scope(list_ops_or_scope, **kwargs)Stores the default arguments for the given set of list_ops.
tf.contrib.framework.add_arg_scope(func)Decorates a function with args so it can be used within an arg_scope.
tf.contrib.framework.has_arg_scope(func)Checks whether a func has been decorated with @add_arg_scope or not.
tf.contrib.framework.arg_scoped_arguments(func)Returns the list kwargs that arg_scope can set for a func.

Framework (contrib) > Variables

Members
tf.contrib.framework.add_model_variable(var)Adds a variable to the GraphKeys.MODEL_VARIABLES collection.
tf.contrib.framework.assert_global_step(global_step_tensor)Asserts global_step_tensor is a scalar int Variable or Tensor.
tf.contrib.framework.assert_or_get_global_step(graph=None, global_step_tensor=None)Verifies that a global step tensor is valid or gets one if None is given.
tf.contrib.framework.create_global_step(graph=None)Create global step tensor in graph.
tf.contrib.framework.get_global_step(graph=None)Get the global step tensor.
tf.contrib.framework.get_or_create_global_step(graph=None)Returns and create (if necessary) the global step variable.
tf.contrib.framework.get_local_variables(scope=None, suffix=None)Gets the list of model variables, filtered by scope and/or suffix.
tf.contrib.framework.get_model_variables(scope=None, suffix=None)Gets the list of model variables, filtered by scope and/or suffix.
tf.contrib.framework.get_unique_variable(var_op_name)Gets the variable uniquely identified by that var_op_name.
tf.contrib.framework.get_variables_by_name(given_name, scope=None)Gets the list of variables that were given that name.
tf.contrib.framework.get_variables_by_suffix(suffix, scope=None)Gets the list of variables that end with the given suffix.
tf.contrib.framework.get_variables_to_restore(include=None, exclude=None)Gets the list of the variables to restore.
tf.contrib.framework.get_variables(scope=None, suffix=None, collection='variables')Gets the list of variables, filtered by scope and/or suffix.
tf.contrib.framework.local_variable(initial_value, validate_shape=True, name=None)Create variable and add it to GraphKeys.LOCAL_VARIABLES collection.
tf.contrib.framework.model_variable(*args, **kwargs)Gets an existing model variable with these parameters or creates a new one.
tf.contrib.framework.variable(*args, **kwargs)Gets an existing variable with these parameters or creates a new one.
class tf.contrib.framework.VariableDeviceChooserDevice chooser for variables.
tf.contrib.framework.VariableDeviceChooser.__init__(num_tasks=0, job_name='ps', device_type='CPU', device_index=0)Initialize VariableDeviceChooser.

Graph Editor (contrib) > Other Functions and Classes

Members
class tf.contrib.graph_editor.SubGraphViewA subgraph view on an existing tf.Graph.
tf.contrib.graph_editor.SubGraphView.__init__(inside_ops=(), passthrough_ts=())Create a subgraph containing the given ops and the "passthrough" tensors.
tf.contrib.graph_editor.SubGraphView.connected_inputsThe connected input tensors of this subgraph view.
tf.contrib.graph_editor.SubGraphView.connected_outputsThe connected output tensors of this subgraph view.
tf.contrib.graph_editor.SubGraphView.consumers()Return a Python set of all the consumers of this subgraph view.
tf.contrib.graph_editor.SubGraphView.copy()Return a copy of itself.
tf.contrib.graph_editor.SubGraphView.find_op_by_name(op_name)Return the op named op_name.
tf.contrib.graph_editor.SubGraphView.graphThe underlying tf.Graph.
tf.contrib.graph_editor.SubGraphView.input_index(t)Find the input index corresponding to the given input tensor t.
tf.contrib.graph_editor.SubGraphView.inputsThe input tensors of this subgraph view.
tf.contrib.graph_editor.SubGraphView.is_passthrough(t)Check whether a tensor is passthrough.
tf.contrib.graph_editor.SubGraphView.op(op_id)Get an op by its index.
tf.contrib.graph_editor.SubGraphView.opsThe operations in this subgraph view.
tf.contrib.graph_editor.SubGraphView.output_index(t)Find the output index corresponding to given output tensor t.
tf.contrib.graph_editor.SubGraphView.outputsThe output tensors of this subgraph view.
tf.contrib.graph_editor.SubGraphView.passthroughsThe passthrough tensors, going straight from input to output.
tf.contrib.graph_editor.SubGraphView.remap(new_input_indices=None, new_output_indices=None)Remap the inputs and outputs of the subgraph.
tf.contrib.graph_editor.SubGraphView.remap_default(remove_input_map=True, remove_output_map=True)Remap the inputs and/or outputs to the default mapping.
tf.contrib.graph_editor.SubGraphView.remap_inputs(new_input_indices)Remap the inputs of the subgraph.
tf.contrib.graph_editor.SubGraphView.remap_outputs(new_output_indices)Remap the output of the subgraph.
tf.contrib.graph_editor.SubGraphView.remap_outputs_make_unique()Remap the outputs so that all the tensors appears only once.
tf.contrib.graph_editor.SubGraphView.remap_outputs_to_consumers()Remap the outputs to match the number of consumers.
tf.contrib.graph_editor.SubGraphView.remove_unused_ops(control_inputs=True)Remove unused ops.
class tf.contrib.graph_editor.TransformerTransform a subgraph into another one.
tf.contrib.graph_editor.Transformer.__init__()Transformer constructor.
tf.contrib.graph_editor.Transformer.new_name(name)Compute a destination name from a source name.
tf.contrib.graph_editor.bypass(sgv)Bypass the given subgraph by connecting its inputs to its outputs.
tf.contrib.graph_editor.connect(sgv0, sgv1, disconnect_first=False)Connect the outputs of sgv0 to the inputs of sgv1.
tf.contrib.graph_editor.detach(sgv, control_inputs=False, control_outputs=None, control_ios=None)Detach both the inputs and the outputs of a subgraph view.
tf.contrib.graph_editor.detach_inputs(sgv, control_inputs=False)Detach the inputs of a subgraph view.
tf.contrib.graph_editor.detach_outputs(sgv, control_outputs=None)Detach the outputa of a subgraph view.
class tf.contrib.graph_editor.matcherGraph match class.
tf.contrib.graph_editor.matcher.__init__(positive_filter)Graph match constructor.
tf.contrib.graph_editor.matcher.control_input_ops(*args)Add input matches.
tf.contrib.graph_editor.matcher.input_ops(*args)Add input matches.
tf.contrib.graph_editor.matcher.output_ops(*args)Add output matches.
tf.contrib.graph_editor.ph(dtype, shape=None, scope=None)Create a tf.placeholder for the Graph Editor.
tf.contrib.graph_editor.reroute_a2b(sgv0, sgv1)Re-route the inputs and outputs of sgv0 to sgv1 (see _reroute).
tf.contrib.graph_editor.reroute_a2b_inputs(sgv0, sgv1)Re-route all the inputs of sgv0 to sgv1 (see reroute_inputs).
tf.contrib.graph_editor.reroute_a2b_outputs(sgv0, sgv1)Re-route all the outputs of sgv0 to sgv1 (see _reroute_outputs).
tf.contrib.graph_editor.reroute_b2a(sgv0, sgv1)Re-route the inputs and outputs of sgv1 to sgv0 (see _reroute).
tf.contrib.graph_editor.reroute_b2a_inputs(sgv0, sgv1)Re-route all the inputs of sgv1 to sgv0 (see reroute_inputs).
tf.contrib.graph_editor.reroute_b2a_outputs(sgv0, sgv1)Re-route all the outputs of sgv1 to sgv0 (see _reroute_outputs).
tf.contrib.graph_editor.select_ops(*args, **kwargs)Helper to select operations.
tf.contrib.graph_editor.select_ts(*args, **kwargs)Helper to select tensors.
tf.contrib.graph_editor.sgv(*args, **kwargs)Create a SubGraphView from selected operations and passthrough tensors.
tf.contrib.graph_editor.sgv_scope(scope, graph)Make a subgraph from a name scope.
tf.contrib.graph_editor.swap(sgv0, sgv1)Swap the inputs and outputs of sgv1 to sgv0 (see _reroute).
tf.contrib.graph_editor.swap_inputs(sgv0, sgv1)Swap all the inputs of sgv0 and sgv1 (see reroute_inputs).
tf.contrib.graph_editor.swap_outputs(sgv0, sgv1)Swap all the outputs of sgv0 and sgv1 (see _reroute_outputs).
tf.contrib.graph_editor.ts(*args, **kwargs)Helper to select tensors.

Layers (contrib) > Higher level ops for building neural network layers.

Members
tf.contrib.layers.avg_pool2d(*args, **kwargs)Adds a 2D average pooling op.
tf.contrib.layers.batch_norm(*args, **kwargs)Adds a Batch Normalization layer from http://arxiv.org/abs/1502.03167.
tf.contrib.layers.convolution2d(*args, **kwargs)Adds a 2D convolution followed by an optional batch_norm layer.
tf.contrib.layers.convolution2d_in_plane(*args, **kwargs)Performs the same in-plane convolution to each channel independently.
tf.contrib.layers.convolution2d_transpose(*args, **kwargs)Adds a convolution2d_transpose with an optional batch normalization layer.
tf.contrib.layers.flatten(*args, **kwargs)Flattens the input while maintaining the batch_size.
tf.contrib.layers.fully_connected(*args, **kwargs)Adds a fully connected layer.
tf.contrib.layers.max_pool2d(*args, **kwargs)Adds a 2D Max Pooling op.
tf.contrib.layers.one_hot_encoding(*args, **kwargs)Transform numeric labels into onehot_labels using tf.one_hot.
tf.contrib.layers.repeat(inputs, repetitions, layer, *args, **kwargs)Applies the same layer with the same arguments repeatedly.
tf.contrib.layers.separable_convolution2d(*args, **kwargs)Adds a depth-separable 2D convolution with optional batch_norm layer.
tf.contrib.layers.stack(inputs, layer, stack_args, **kwargs)Builds a stack of layers by applying layer repeatedly using stack_args.
tf.contrib.layers.unit_norm(*args, **kwargs)Normalizes the given input across the specified dimension to unit length.

Layers (contrib) > Regularizers

Members
tf.contrib.layers.apply_regularization(regularizer, weights_list=None)Returns the summed penalty by applying regularizer to the weights_list.
tf.contrib.layers.l1_regularizer(scale, scope=None)Returns a function that can be used to apply L1 regularization to weights.
tf.contrib.layers.l2_regularizer(scale, scope=None)Returns a function that can be used to apply L2 regularization to weights.
tf.contrib.layers.sum_regularizer(regularizer_list, scope=None)Returns a function that applies the sum of multiple regularizers.

Layers (contrib) > Initializers

Members
tf.contrib.layers.xavier_initializer(uniform=True, seed=None, dtype=tf.float32)Returns an initializer performing "Xavier" initialization for weights.
tf.contrib.layers.xavier_initializer_conv2d(uniform=True, seed=None, dtype=tf.float32)Returns an initializer performing "Xavier" initialization for weights.
tf.contrib.layers.variance_scaling_initializer(factor=2.0, mode='FAN_IN', uniform=False, seed=None, dtype=tf.float32)Returns an initializer that generates tensors without scaling variance.

Layers (contrib) > Optimization

Members
tf.contrib.layers.optimize_loss(loss, global_step, learning_rate, optimizer, gradient_noise_scale=None, gradient_multipliers=None, clip_gradients=None, moving_average_decay=None, learning_rate_decay_fn=None, update_ops=None, variables=None, name=None, summaries=None)Given loss and parameters for optimizer, returns a training op.

Layers (contrib) > Summaries

Members
tf.contrib.layers.summarize_activation(op)Summarize an activation.
tf.contrib.layers.summarize_tensor(tensor, tag=None)Summarize a tensor using a suitable summary type.
tf.contrib.layers.summarize_tensors(tensors, summarizer=summarize_tensor)Summarize a set of tensors.
tf.contrib.layers.summarize_collection(collection, name_filter=None, summarizer=summarize_tensor)Summarize a graph collection of tensors, possibly filtered by name.
tf.contrib.layers.summarize_activations(name_filter=None, summarizer=summarize_activation)Summarize activations, using summarize_activation to summarize.

Learn (contrib) > Estimators

Members
class tf.contrib.learn.BaseEstimatorAbstract BaseEstimator class to train and evaluate TensorFlow models.
tf.contrib.learn.BaseEstimator.__init__(model_dir=None, config=None)Initializes a BaseEstimator instance.
tf.contrib.learn.BaseEstimator.evaluate(x=None, y=None, input_fn=None, feed_fn=None, batch_size=None, steps=None, metrics=None, name=None)See Evaluable.
tf.contrib.learn.BaseEstimator.fit(x=None, y=None, input_fn=None, steps=None, batch_size=None, monitors=None, max_steps=None)See Trainable.
tf.contrib.learn.BaseEstimator.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.BaseEstimator.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.BaseEstimator.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.BaseEstimator.model_dir
tf.contrib.learn.BaseEstimator.partial_fit(x=None, y=None, input_fn=None, steps=1, batch_size=None, monitors=None)Incremental fit on a batch of samples.
tf.contrib.learn.BaseEstimator.predict(x=None, input_fn=None, batch_size=None, outputs=None, as_iterable=False)Returns predictions for given features.
tf.contrib.learn.BaseEstimator.set_params(**params)Set the parameters of this estimator.
class tf.contrib.learn.EstimatorEstimator class is the basic TensorFlow model trainer/evaluator.
tf.contrib.learn.Estimator.__init__(model_fn=None, model_dir=None, config=None, params=None)Constructs an Estimator instance.
tf.contrib.learn.Estimator.evaluate(x=None, y=None, input_fn=None, feed_fn=None, batch_size=None, steps=None, metrics=None, name=None)See Evaluable.
tf.contrib.learn.Estimator.fit(x=None, y=None, input_fn=None, steps=None, batch_size=None, monitors=None, max_steps=None)See Trainable.
tf.contrib.learn.Estimator.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.Estimator.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.Estimator.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.Estimator.model_dir
tf.contrib.learn.Estimator.partial_fit(x=None, y=None, input_fn=None, steps=1, batch_size=None, monitors=None)Incremental fit on a batch of samples.
tf.contrib.learn.Estimator.predict(x=None, input_fn=None, batch_size=None, outputs=None, as_iterable=False)Returns predictions for given features.
tf.contrib.learn.Estimator.set_params(**params)Set the parameters of this estimator.
class tf.contrib.learn.ModeKeysStandard names for model modes.
class tf.contrib.learn.TensorFlowClassifier
tf.contrib.learn.TensorFlowClassifier.__init__(*args, **kwargs)
tf.contrib.learn.TensorFlowClassifier.bias_
tf.contrib.learn.TensorFlowClassifier.dnn_bias_Returns bias of deep neural network part.
tf.contrib.learn.TensorFlowClassifier.dnn_weights_Returns weights of deep neural network part.
tf.contrib.learn.TensorFlowClassifier.evaluate(x=None, y=None, input_fn=None, feed_fn=None, batch_size=None, steps=None, metrics=None, name=None)See Evaluable.
tf.contrib.learn.TensorFlowClassifier.fit(x, y, steps=None, batch_size=None, monitors=None, logdir=None)
tf.contrib.learn.TensorFlowClassifier.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.TensorFlowClassifier.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.TensorFlowClassifier.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.TensorFlowClassifier.linear_bias_Returns bias of the linear part.
tf.contrib.learn.TensorFlowClassifier.linear_weights_Returns weights per feature of the linear part.
tf.contrib.learn.TensorFlowClassifier.model_dir
tf.contrib.learn.TensorFlowClassifier.partial_fit(x=None, y=None, input_fn=None, steps=1, batch_size=None, monitors=None)Incremental fit on a batch of samples.
tf.contrib.learn.TensorFlowClassifier.predict(x=None, input_fn=None, batch_size=None, outputs=None, axis=1)Predict class or regression for x.
tf.contrib.learn.TensorFlowClassifier.predict_proba(x=None, input_fn=None, batch_size=None, outputs=None)
tf.contrib.learn.TensorFlowClassifier.save(path)Saves checkpoints and graph to given path.
tf.contrib.learn.TensorFlowClassifier.set_params(**params)Set the parameters of this estimator.
tf.contrib.learn.TensorFlowClassifier.weights_
class tf.contrib.learn.DNNClassifierA classifier for TensorFlow DNN models.
tf.contrib.learn.DNNClassifier.__init__(hidden_units, feature_columns=None, model_dir=None, n_classes=2, weight_column_name=None, optimizer=None, activation_fn=relu, dropout=None, gradient_clip_norm=None, enable_centered_bias=True, config=None)Initializes a DNNClassifier instance.
tf.contrib.learn.DNNClassifier.bias_
tf.contrib.learn.DNNClassifier.dnn_bias_Returns bias of deep neural network part.
tf.contrib.learn.DNNClassifier.dnn_weights_Returns weights of deep neural network part.
tf.contrib.learn.DNNClassifier.evaluate(x=None, y=None, input_fn=None, feed_fn=None, batch_size=None, steps=None, metrics=None, name=None)See Evaluable.
tf.contrib.learn.DNNClassifier.fit(x=None, y=None, input_fn=None, steps=None, batch_size=None, monitors=None, max_steps=None)See Trainable.
tf.contrib.learn.DNNClassifier.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.DNNClassifier.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.DNNClassifier.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.DNNClassifier.linear_bias_Returns bias of the linear part.
tf.contrib.learn.DNNClassifier.linear_weights_Returns weights per feature of the linear part.
tf.contrib.learn.DNNClassifier.model_dir
tf.contrib.learn.DNNClassifier.partial_fit(x=None, y=None, input_fn=None, steps=1, batch_size=None, monitors=None)Incremental fit on a batch of samples.
tf.contrib.learn.DNNClassifier.predict(x=None, input_fn=None, batch_size=None, as_iterable=False)Returns predicted classes for given features.
tf.contrib.learn.DNNClassifier.predict_proba(x=None, input_fn=None, batch_size=None, as_iterable=False)Returns prediction probabilities for given features.
tf.contrib.learn.DNNClassifier.set_params(**params)Set the parameters of this estimator.
tf.contrib.learn.DNNClassifier.weights_
class tf.contrib.learn.DNNRegressorA regressor for TensorFlow DNN models.
tf.contrib.learn.DNNRegressor.__init__(hidden_units, feature_columns=None, model_dir=None, weight_column_name=None, optimizer=None, activation_fn=relu, dropout=None, gradient_clip_norm=None, enable_centered_bias=True, config=None)Initializes a DNNRegressor instance.
tf.contrib.learn.DNNRegressor.bias_
tf.contrib.learn.DNNRegressor.dnn_bias_Returns bias of deep neural network part.
tf.contrib.learn.DNNRegressor.dnn_weights_Returns weights of deep neural network part.
tf.contrib.learn.DNNRegressor.evaluate(x=None, y=None, input_fn=None, feed_fn=None, batch_size=None, steps=None, metrics=None, name=None)See Evaluable.
tf.contrib.learn.DNNRegressor.fit(x=None, y=None, input_fn=None, steps=None, batch_size=None, monitors=None, max_steps=None)See Trainable.
tf.contrib.learn.DNNRegressor.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.DNNRegressor.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.DNNRegressor.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.DNNRegressor.linear_bias_Returns bias of the linear part.
tf.contrib.learn.DNNRegressor.linear_weights_Returns weights per feature of the linear part.
tf.contrib.learn.DNNRegressor.model_dir
tf.contrib.learn.DNNRegressor.partial_fit(x=None, y=None, input_fn=None, steps=1, batch_size=None, monitors=None)Incremental fit on a batch of samples.
tf.contrib.learn.DNNRegressor.predict(x=None, input_fn=None, batch_size=None, outputs=None, as_iterable=False)Returns predictions for given features.
tf.contrib.learn.DNNRegressor.set_params(**params)Set the parameters of this estimator.
tf.contrib.learn.DNNRegressor.weights_
class tf.contrib.learn.TensorFlowDNNClassifier
tf.contrib.learn.TensorFlowDNNClassifier.__init__(*args, **kwargs)
tf.contrib.learn.TensorFlowDNNClassifier.bias_
tf.contrib.learn.TensorFlowDNNClassifier.dnn_bias_Returns bias of deep neural network part.
tf.contrib.learn.TensorFlowDNNClassifier.dnn_weights_Returns weights of deep neural network part.
tf.contrib.learn.TensorFlowDNNClassifier.evaluate(x=None, y=None, input_fn=None, feed_fn=None, batch_size=None, steps=None, metrics=None, name=None)See Evaluable.
tf.contrib.learn.TensorFlowDNNClassifier.fit(x, y, steps=None, batch_size=None, monitors=None, logdir=None)
tf.contrib.learn.TensorFlowDNNClassifier.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.TensorFlowDNNClassifier.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.TensorFlowDNNClassifier.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.TensorFlowDNNClassifier.linear_bias_Returns bias of the linear part.
tf.contrib.learn.TensorFlowDNNClassifier.linear_weights_Returns weights per feature of the linear part.
tf.contrib.learn.TensorFlowDNNClassifier.model_dir
tf.contrib.learn.TensorFlowDNNClassifier.partial_fit(x=None, y=None, input_fn=None, steps=1, batch_size=None, monitors=None)Incremental fit on a batch of samples.
tf.contrib.learn.TensorFlowDNNClassifier.predict(x=None, input_fn=None, batch_size=None, outputs=None, axis=1)Predict class or regression for x.
tf.contrib.learn.TensorFlowDNNClassifier.predict_proba(x=None, input_fn=None, batch_size=None, outputs=None)
tf.contrib.learn.TensorFlowDNNClassifier.save(path)Saves checkpoints and graph to given path.
tf.contrib.learn.TensorFlowDNNClassifier.set_params(**params)Set the parameters of this estimator.
tf.contrib.learn.TensorFlowDNNClassifier.weights_
class tf.contrib.learn.TensorFlowDNNRegressor
tf.contrib.learn.TensorFlowDNNRegressor.__init__(*args, **kwargs)
tf.contrib.learn.TensorFlowDNNRegressor.bias_
tf.contrib.learn.TensorFlowDNNRegressor.dnn_bias_Returns bias of deep neural network part.
tf.contrib.learn.TensorFlowDNNRegressor.dnn_weights_Returns weights of deep neural network part.
tf.contrib.learn.TensorFlowDNNRegressor.evaluate(x=None, y=None, input_fn=None, feed_fn=None, batch_size=None, steps=None, metrics=None, name=None)See Evaluable.
tf.contrib.learn.TensorFlowDNNRegressor.fit(x, y, steps=None, batch_size=None, monitors=None, logdir=None)
tf.contrib.learn.TensorFlowDNNRegressor.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.TensorFlowDNNRegressor.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.TensorFlowDNNRegressor.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.TensorFlowDNNRegressor.linear_bias_Returns bias of the linear part.
tf.contrib.learn.TensorFlowDNNRegressor.linear_weights_Returns weights per feature of the linear part.
tf.contrib.learn.TensorFlowDNNRegressor.model_dir
tf.contrib.learn.TensorFlowDNNRegressor.partial_fit(x=None, y=None, input_fn=None, steps=1, batch_size=None, monitors=None)Incremental fit on a batch of samples.
tf.contrib.learn.TensorFlowDNNRegressor.predict(x=None, input_fn=None, batch_size=None, outputs=None, axis=1)Predict class or regression for x.
tf.contrib.learn.TensorFlowDNNRegressor.predict_proba(x=None, input_fn=None, batch_size=None, outputs=None)
tf.contrib.learn.TensorFlowDNNRegressor.save(path)Saves checkpoints and graph to given path.
tf.contrib.learn.TensorFlowDNNRegressor.set_params(**params)Set the parameters of this estimator.
tf.contrib.learn.TensorFlowDNNRegressor.weights_
class tf.contrib.learn.TensorFlowEstimatorBase class for all TensorFlow estimators.
tf.contrib.learn.TensorFlowEstimator.__init__(model_fn, n_classes, batch_size=32, steps=200, optimizer='Adagrad', learning_rate=0.1, clip_gradients=5.0, class_weight=None, continue_training=False, config=None, verbose=1)Initializes a TensorFlowEstimator instance.
tf.contrib.learn.TensorFlowEstimator.evaluate(x=None, y=None, input_fn=None, steps=None)See base class.
tf.contrib.learn.TensorFlowEstimator.fit(x, y, steps=None, monitors=None, logdir=None)Neural network model from provided model_fn and training data.
tf.contrib.learn.TensorFlowEstimator.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.TensorFlowEstimator.get_tensor(name)Returns tensor by name.
tf.contrib.learn.TensorFlowEstimator.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.TensorFlowEstimator.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.TensorFlowEstimator.model_dir
tf.contrib.learn.TensorFlowEstimator.partial_fit(x, y)Incremental fit on a batch of samples.
tf.contrib.learn.TensorFlowEstimator.predict(x, axis=1, batch_size=None)Predict class or regression for x.
tf.contrib.learn.TensorFlowEstimator.predict_proba(x, batch_size=None)Predict class probability of the input samples x.
tf.contrib.learn.TensorFlowEstimator.restore(cls, path, config=None)Restores model from give path.
tf.contrib.learn.TensorFlowEstimator.save(path)Saves checkpoints and graph to given path.
tf.contrib.learn.TensorFlowEstimator.set_params(**params)Set the parameters of this estimator.
class tf.contrib.learn.LinearClassifierLinear classifier model.
tf.contrib.learn.LinearClassifier.__init__(feature_columns=None, model_dir=None, n_classes=2, weight_column_name=None, optimizer=None, gradient_clip_norm=None, enable_centered_bias=True, config=None)Construct a LinearClassifier estimator object.
tf.contrib.learn.LinearClassifier.bias_
tf.contrib.learn.LinearClassifier.dnn_bias_Returns bias of deep neural network part.
tf.contrib.learn.LinearClassifier.dnn_weights_Returns weights of deep neural network part.
tf.contrib.learn.LinearClassifier.evaluate(x=None, y=None, input_fn=None, feed_fn=None, batch_size=None, steps=None, metrics=None, name=None)See Evaluable.
tf.contrib.learn.LinearClassifier.fit(x=None, y=None, input_fn=None, steps=None, batch_size=None, monitors=None, max_steps=None)See Trainable.
tf.contrib.learn.LinearClassifier.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.LinearClassifier.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.LinearClassifier.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.LinearClassifier.linear_bias_Returns bias of the linear part.
tf.contrib.learn.LinearClassifier.linear_weights_Returns weights per feature of the linear part.
tf.contrib.learn.LinearClassifier.model_dir
tf.contrib.learn.LinearClassifier.partial_fit(x=None, y=None, input_fn=None, steps=1, batch_size=None, monitors=None)Incremental fit on a batch of samples.
tf.contrib.learn.LinearClassifier.predict(x=None, input_fn=None, batch_size=None, as_iterable=False)Returns predicted classes for given features.
tf.contrib.learn.LinearClassifier.predict_proba(x=None, input_fn=None, batch_size=None, as_iterable=False)Returns prediction probabilities for given features.
tf.contrib.learn.LinearClassifier.set_params(**params)Set the parameters of this estimator.
tf.contrib.learn.LinearClassifier.weights_
class tf.contrib.learn.LinearRegressorLinear regressor model.
tf.contrib.learn.LinearRegressor.__init__(feature_columns=None, model_dir=None, weight_column_name=None, optimizer=None, gradient_clip_norm=None, enable_centered_bias=True, target_dimension=1, config=None)Construct a LinearRegressor estimator object.
tf.contrib.learn.LinearRegressor.bias_
tf.contrib.learn.LinearRegressor.dnn_bias_Returns bias of deep neural network part.
tf.contrib.learn.LinearRegressor.dnn_weights_Returns weights of deep neural network part.
tf.contrib.learn.LinearRegressor.evaluate(x=None, y=None, input_fn=None, feed_fn=None, batch_size=None, steps=None, metrics=None, name=None)See Evaluable.
tf.contrib.learn.LinearRegressor.fit(x=None, y=None, input_fn=None, steps=None, batch_size=None, monitors=None, max_steps=None)See Trainable.
tf.contrib.learn.LinearRegressor.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.LinearRegressor.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.LinearRegressor.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.LinearRegressor.linear_bias_Returns bias of the linear part.
tf.contrib.learn.LinearRegressor.linear_weights_Returns weights per feature of the linear part.
tf.contrib.learn.LinearRegressor.model_dir
tf.contrib.learn.LinearRegressor.partial_fit(x=None, y=None, input_fn=None, steps=1, batch_size=None, monitors=None)Incremental fit on a batch of samples.
tf.contrib.learn.LinearRegressor.predict(x=None, input_fn=None, batch_size=None, outputs=None, as_iterable=False)Returns predictions for given features.
tf.contrib.learn.LinearRegressor.set_params(**params)Set the parameters of this estimator.
tf.contrib.learn.LinearRegressor.weights_
class tf.contrib.learn.TensorFlowLinearClassifier
tf.contrib.learn.TensorFlowLinearClassifier.__init__(*args, **kwargs)
tf.contrib.learn.TensorFlowLinearClassifier.bias_
tf.contrib.learn.TensorFlowLinearClassifier.dnn_bias_Returns bias of deep neural network part.
tf.contrib.learn.TensorFlowLinearClassifier.dnn_weights_Returns weights of deep neural network part.
tf.contrib.learn.TensorFlowLinearClassifier.evaluate(x=None, y=None, input_fn=None, feed_fn=None, batch_size=None, steps=None, metrics=None, name=None)See Evaluable.
tf.contrib.learn.TensorFlowLinearClassifier.fit(x, y, steps=None, batch_size=None, monitors=None, logdir=None)
tf.contrib.learn.TensorFlowLinearClassifier.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.TensorFlowLinearClassifier.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.TensorFlowLinearClassifier.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.TensorFlowLinearClassifier.linear_bias_Returns bias of the linear part.
tf.contrib.learn.TensorFlowLinearClassifier.linear_weights_Returns weights per feature of the linear part.
tf.contrib.learn.TensorFlowLinearClassifier.model_dir
tf.contrib.learn.TensorFlowLinearClassifier.partial_fit(x=None, y=None, input_fn=None, steps=1, batch_size=None, monitors=None)Incremental fit on a batch of samples.
tf.contrib.learn.TensorFlowLinearClassifier.predict(x=None, input_fn=None, batch_size=None, outputs=None, axis=1)Predict class or regression for x.
tf.contrib.learn.TensorFlowLinearClassifier.predict_proba(x=None, input_fn=None, batch_size=None, outputs=None)
tf.contrib.learn.TensorFlowLinearClassifier.save(path)Saves checkpoints and graph to given path.
tf.contrib.learn.TensorFlowLinearClassifier.set_params(**params)Set the parameters of this estimator.
tf.contrib.learn.TensorFlowLinearClassifier.weights_
class tf.contrib.learn.TensorFlowLinearRegressor
tf.contrib.learn.TensorFlowLinearRegressor.__init__(*args, **kwargs)
tf.contrib.learn.TensorFlowLinearRegressor.bias_
tf.contrib.learn.TensorFlowLinearRegressor.dnn_bias_Returns bias of deep neural network part.
tf.contrib.learn.TensorFlowLinearRegressor.dnn_weights_Returns weights of deep neural network part.
tf.contrib.learn.TensorFlowLinearRegressor.evaluate(x=None, y=None, input_fn=None, feed_fn=None, batch_size=None, steps=None, metrics=None, name=None)See Evaluable.
tf.contrib.learn.TensorFlowLinearRegressor.fit(x, y, steps=None, batch_size=None, monitors=None, logdir=None)
tf.contrib.learn.TensorFlowLinearRegressor.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.TensorFlowLinearRegressor.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.TensorFlowLinearRegressor.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.TensorFlowLinearRegressor.linear_bias_Returns bias of the linear part.
tf.contrib.learn.TensorFlowLinearRegressor.linear_weights_Returns weights per feature of the linear part.
tf.contrib.learn.TensorFlowLinearRegressor.model_dir
tf.contrib.learn.TensorFlowLinearRegressor.partial_fit(x=None, y=None, input_fn=None, steps=1, batch_size=None, monitors=None)Incremental fit on a batch of samples.
tf.contrib.learn.TensorFlowLinearRegressor.predict(x=None, input_fn=None, batch_size=None, outputs=None, axis=1)Predict class or regression for x.
tf.contrib.learn.TensorFlowLinearRegressor.predict_proba(x=None, input_fn=None, batch_size=None, outputs=None)
tf.contrib.learn.TensorFlowLinearRegressor.save(path)Saves checkpoints and graph to given path.
tf.contrib.learn.TensorFlowLinearRegressor.set_params(**params)Set the parameters of this estimator.
tf.contrib.learn.TensorFlowLinearRegressor.weights_
class tf.contrib.learn.TensorFlowRNNClassifierTensorFlow RNN Classifier model.
tf.contrib.learn.TensorFlowRNNClassifier.__init__(rnn_size, n_classes, cell_type='gru', num_layers=1, input_op_fn=null_input_op_fn, initial_state=None, bidirectional=False, sequence_length=None, attn_length=None, attn_size=None, attn_vec_size=None, batch_size=32, steps=50, optimizer='Adagrad', learning_rate=0.1, class_weight=None, clip_gradients=5.0, continue_training=False, config=None, verbose=1)Initializes a TensorFlowRNNClassifier instance.
tf.contrib.learn.TensorFlowRNNClassifier.bias_Returns bias of the rnn layer.
tf.contrib.learn.TensorFlowRNNClassifier.evaluate(x=None, y=None, input_fn=None, steps=None)See base class.
tf.contrib.learn.TensorFlowRNNClassifier.fit(x, y, steps=None, monitors=None, logdir=None)Neural network model from provided model_fn and training data.
tf.contrib.learn.TensorFlowRNNClassifier.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.TensorFlowRNNClassifier.get_tensor(name)Returns tensor by name.
tf.contrib.learn.TensorFlowRNNClassifier.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.TensorFlowRNNClassifier.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.TensorFlowRNNClassifier.model_dir
tf.contrib.learn.TensorFlowRNNClassifier.partial_fit(x, y)Incremental fit on a batch of samples.
tf.contrib.learn.TensorFlowRNNClassifier.predict(x, axis=1, batch_size=None)Predict class or regression for x.
tf.contrib.learn.TensorFlowRNNClassifier.predict_proba(x, batch_size=None)Predict class probability of the input samples x.
tf.contrib.learn.TensorFlowRNNClassifier.restore(cls, path, config=None)Restores model from give path.
tf.contrib.learn.TensorFlowRNNClassifier.save(path)Saves checkpoints and graph to given path.
tf.contrib.learn.TensorFlowRNNClassifier.set_params(**params)Set the parameters of this estimator.
tf.contrib.learn.TensorFlowRNNClassifier.weights_Returns weights of the rnn layer.
class tf.contrib.learn.TensorFlowRNNRegressorTensorFlow RNN Regressor model.
tf.contrib.learn.TensorFlowRNNRegressor.__init__(rnn_size, cell_type='gru', num_layers=1, input_op_fn=null_input_op_fn, initial_state=None, bidirectional=False, sequence_length=None, attn_length=None, attn_size=None, attn_vec_size=None, n_classes=0, batch_size=32, steps=50, optimizer='Adagrad', learning_rate=0.1, clip_gradients=5.0, continue_training=False, config=None, verbose=1)Initializes a TensorFlowRNNRegressor instance.
tf.contrib.learn.TensorFlowRNNRegressor.bias_Returns bias of the rnn layer.
tf.contrib.learn.TensorFlowRNNRegressor.evaluate(x=None, y=None, input_fn=None, steps=None)See base class.
tf.contrib.learn.TensorFlowRNNRegressor.fit(x, y, steps=None, monitors=None, logdir=None)Neural network model from provided model_fn and training data.
tf.contrib.learn.TensorFlowRNNRegressor.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.TensorFlowRNNRegressor.get_tensor(name)Returns tensor by name.
tf.contrib.learn.TensorFlowRNNRegressor.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.TensorFlowRNNRegressor.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.TensorFlowRNNRegressor.model_dir
tf.contrib.learn.TensorFlowRNNRegressor.partial_fit(x, y)Incremental fit on a batch of samples.
tf.contrib.learn.TensorFlowRNNRegressor.predict(x, axis=1, batch_size=None)Predict class or regression for x.
tf.contrib.learn.TensorFlowRNNRegressor.predict_proba(x, batch_size=None)Predict class probability of the input samples x.
tf.contrib.learn.TensorFlowRNNRegressor.restore(cls, path, config=None)Restores model from give path.
tf.contrib.learn.TensorFlowRNNRegressor.save(path)Saves checkpoints and graph to given path.
tf.contrib.learn.TensorFlowRNNRegressor.set_params(**params)Set the parameters of this estimator.
tf.contrib.learn.TensorFlowRNNRegressor.weights_Returns weights of the rnn layer.
class tf.contrib.learn.TensorFlowRegressor
tf.contrib.learn.TensorFlowRegressor.__init__(*args, **kwargs)
tf.contrib.learn.TensorFlowRegressor.bias_
tf.contrib.learn.TensorFlowRegressor.dnn_bias_Returns bias of deep neural network part.
tf.contrib.learn.TensorFlowRegressor.dnn_weights_Returns weights of deep neural network part.
tf.contrib.learn.TensorFlowRegressor.evaluate(x=None, y=None, input_fn=None, feed_fn=None, batch_size=None, steps=None, metrics=None, name=None)See Evaluable.
tf.contrib.learn.TensorFlowRegressor.fit(x, y, steps=None, batch_size=None, monitors=None, logdir=None)
tf.contrib.learn.TensorFlowRegressor.get_params(deep=True)Get parameters for this estimator.
tf.contrib.learn.TensorFlowRegressor.get_variable_names()Returns list of all variable names in this model.
tf.contrib.learn.TensorFlowRegressor.get_variable_value(name)Returns value of the variable given by name.
tf.contrib.learn.TensorFlowRegressor.linear_bias_Returns bias of the linear part.
tf.contrib.learn.TensorFlowRegressor.linear_weights_Returns weights per feature of the linear part.
tf.contrib.learn.TensorFlowRegressor.model_dir
tf.contrib.learn.TensorFlowRegressor.partial_fit(x=None, y=None, input_fn=None, steps=1, batch_size=None, monitors=None)Incremental fit on a batch of samples.
tf.contrib.learn.TensorFlowRegressor.predict(x=None, input_fn=None, batch_size=None, outputs=None, axis=1)Predict class or regression for x.
tf.contrib.learn.TensorFlowRegressor.predict_proba(x=None, input_fn=None, batch_size=None, outputs=None)
tf.contrib.learn.TensorFlowRegressor.save(path)Saves checkpoints and graph to given path.
tf.contrib.learn.TensorFlowRegressor.set_params(**params)Set the parameters of this estimator.
tf.contrib.learn.TensorFlowRegressor.weights_

Learn (contrib) > Graph actions

Members
class tf.contrib.learn.NanLossDuringTrainingError
class tf.contrib.learn.RunConfigThis class specifies the specific configurations for the run.
tf.contrib.learn.RunConfig.__init__(master='', task=0, num_ps_replicas=0, num_cores=4, log_device_placement=False, gpu_memory_fraction=1, tf_random_seed=42, save_summary_steps=100, save_checkpoints_secs=60, keep_checkpoint_max=5, keep_checkpoint_every_n_hours=10000)Constructor.
tf.contrib.learn.evaluate(graph, output_dir, checkpoint_path, eval_dict, update_op=None, global_step_tensor=None, supervisor_master='', log_every_steps=10, feed_fn=None, max_steps=None)Evaluate a model loaded from a checkpoint.
tf.contrib.learn.infer(restore_checkpoint_path, output_dict, feed_dict=None)Restore graph from restore_checkpoint_path and run output_dict tensors.
tf.contrib.learn.run_feeds(*args, **kwargs)See run_feeds_iter(). Returns a list instead of an iterator.
tf.contrib.learn.run_n(output_dict, feed_dict=None, restore_checkpoint_path=None, n=1)Run output_dict tensors n times, with the same feed_dict each run.
tf.contrib.learn.train(graph, output_dir, train_op, loss_op, global_step_tensor=None, init_op=None, init_feed_dict=None, init_fn=None, log_every_steps=10, supervisor_is_chief=True, supervisor_master='', supervisor_save_model_secs=600, keep_checkpoint_max=5, supervisor_save_summaries_steps=100, feed_fn=None, steps=None, fail_on_nan_loss=True, monitors=None, max_steps=None)Train a model.

Learn (contrib) > Input processing

Members
tf.contrib.learn.extract_dask_data(data)Extract data from dask.Series or dask.DataFrame for predictors.
tf.contrib.learn.extract_dask_labels(labels)Extract data from dask.Series for labels.
tf.contrib.learn.extract_pandas_data(data)Extract data from pandas.DataFrame for predictors.
tf.contrib.learn.extract_pandas_labels(labels)Extract data from pandas.DataFrame for labels.
tf.contrib.learn.extract_pandas_matrix(data)Extracts numpy matrix from pandas DataFrame.
tf.contrib.learn.read_batch_examples(file_pattern, batch_size, reader, randomize_input=True, num_epochs=None, queue_capacity=10000, num_threads=1, read_batch_size=1, parse_fn=None, name=None)Adds operations to read, queue, batch Example protos.
tf.contrib.learn.read_batch_features(file_pattern, batch_size, features, reader, randomize_input=True, num_epochs=None, queue_capacity=10000, reader_num_threads=1, parser_num_threads=1, name=None)Adds operations to read, queue, batch and parse Example protos.
tf.contrib.learn.read_batch_record_features(file_pattern, batch_size, features, randomize_input=True, num_epochs=None, queue_capacity=10000, reader_num_threads=1, parser_num_threads=1, name='dequeue_record_examples')Reads TFRecord, queues, batches and parses Example proto.
tf.contrib.learn.monitors.get_default_monitors(loss_op=None, summary_op=None, save_summary_steps=100, output_dir=None, summary_writer=None)Returns a default set of typically-used monitors.
class tf.contrib.learn.monitors.BaseMonitorBase class for Monitors.
tf.contrib.learn.monitors.BaseMonitor.__init__()
tf.contrib.learn.monitors.BaseMonitor.begin(max_steps=None)Called at the beginning of training.
tf.contrib.learn.monitors.BaseMonitor.end(session=None)Callback at the end of training/evaluation.
tf.contrib.learn.monitors.BaseMonitor.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.BaseMonitor.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.BaseMonitor.post_step(step, session)Callback after the step is finished.
tf.contrib.learn.monitors.BaseMonitor.run_on_all_workers
tf.contrib.learn.monitors.BaseMonitor.set_estimator(estimator)A setter called automatically by the target estimator.
tf.contrib.learn.monitors.BaseMonitor.step_begin(step)Callback before training step begins.
tf.contrib.learn.monitors.BaseMonitor.step_end(step, output)Callback after training step finished.
class tf.contrib.learn.monitors.CaptureVariableCaptures a variable's values into a collection.
tf.contrib.learn.monitors.CaptureVariable.__init__(var_name, every_n=100, first_n=1)Initializes a CaptureVariable monitor.
tf.contrib.learn.monitors.CaptureVariable.begin(max_steps=None)Called at the beginning of training.
tf.contrib.learn.monitors.CaptureVariable.end(session=None)
tf.contrib.learn.monitors.CaptureVariable.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.CaptureVariable.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.CaptureVariable.every_n_post_step(step, session)Callback after a step is finished or end() is called.
tf.contrib.learn.monitors.CaptureVariable.every_n_step_begin(step)
tf.contrib.learn.monitors.CaptureVariable.every_n_step_end(step, outputs)
tf.contrib.learn.monitors.CaptureVariable.post_step(step, session)
tf.contrib.learn.monitors.CaptureVariable.run_on_all_workers
tf.contrib.learn.monitors.CaptureVariable.set_estimator(estimator)A setter called automatically by the target estimator.
tf.contrib.learn.monitors.CaptureVariable.step_begin(step)Overrides BaseMonitor.step_begin.
tf.contrib.learn.monitors.CaptureVariable.step_end(step, output)Overrides BaseMonitor.step_end.
tf.contrib.learn.monitors.CaptureVariable.valuesReturns the values captured so far.
class tf.contrib.learn.monitors.CheckpointSaverSaves checkpoints every N steps.
tf.contrib.learn.monitors.CheckpointSaver.__init__(checkpoint_dir, save_secs=None, save_steps=None, saver=None, checkpoint_basename='model.ckpt', scaffold=None)Initialize CheckpointSaver monitor.
tf.contrib.learn.monitors.CheckpointSaver.begin(max_steps=None)
tf.contrib.learn.monitors.CheckpointSaver.end(session=None)
tf.contrib.learn.monitors.CheckpointSaver.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.CheckpointSaver.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.CheckpointSaver.post_step(step, session)
tf.contrib.learn.monitors.CheckpointSaver.run_on_all_workers
tf.contrib.learn.monitors.CheckpointSaver.set_estimator(estimator)A setter called automatically by the target estimator.
tf.contrib.learn.monitors.CheckpointSaver.step_begin(step)
tf.contrib.learn.monitors.CheckpointSaver.step_end(step, output)Callback after training step finished.
class tf.contrib.learn.monitors.EveryNBase class for monitors that execute callbacks every N steps.
tf.contrib.learn.monitors.EveryN.__init__(every_n_steps=100, first_n_steps=1)Initializes an EveryN monitor.
tf.contrib.learn.monitors.EveryN.begin(max_steps=None)Called at the beginning of training.
tf.contrib.learn.monitors.EveryN.end(session=None)
tf.contrib.learn.monitors.EveryN.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.EveryN.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.EveryN.every_n_post_step(step, session)Callback after a step is finished or end() is called.
tf.contrib.learn.monitors.EveryN.every_n_step_begin(step)Callback before every n'th step begins.
tf.contrib.learn.monitors.EveryN.every_n_step_end(step, outputs)Callback after every n'th step finished.
tf.contrib.learn.monitors.EveryN.post_step(step, session)
tf.contrib.learn.monitors.EveryN.run_on_all_workers
tf.contrib.learn.monitors.EveryN.set_estimator(estimator)A setter called automatically by the target estimator.
tf.contrib.learn.monitors.EveryN.step_begin(step)Overrides BaseMonitor.step_begin.
tf.contrib.learn.monitors.EveryN.step_end(step, output)Overrides BaseMonitor.step_end.
class tf.contrib.learn.monitors.ExportMonitorMonitor that exports Estimator every N steps.
tf.contrib.learn.monitors.ExportMonitor.__init__(every_n_steps, export_dir, exports_to_keep=5, signature_fn=None, default_batch_size=1)Initializes ExportMonitor.
tf.contrib.learn.monitors.ExportMonitor.begin(max_steps=None)Called at the beginning of training.
tf.contrib.learn.monitors.ExportMonitor.end(session=None)
tf.contrib.learn.monitors.ExportMonitor.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.ExportMonitor.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.ExportMonitor.every_n_post_step(step, session)Callback after a step is finished or end() is called.
tf.contrib.learn.monitors.ExportMonitor.every_n_step_begin(step)Callback before every n'th step begins.
tf.contrib.learn.monitors.ExportMonitor.every_n_step_end(step, outputs)
tf.contrib.learn.monitors.ExportMonitor.post_step(step, session)
tf.contrib.learn.monitors.ExportMonitor.run_on_all_workers
tf.contrib.learn.monitors.ExportMonitor.set_estimator(estimator)A setter called automatically by the target estimator.
tf.contrib.learn.monitors.ExportMonitor.step_begin(step)Overrides BaseMonitor.step_begin.
tf.contrib.learn.monitors.ExportMonitor.step_end(step, output)Overrides BaseMonitor.step_end.
class tf.contrib.learn.monitors.GraphDumpDumps almost all tensors in the graph at every step.
tf.contrib.learn.monitors.GraphDump.__init__(ignore_ops=None)Initializes GraphDump monitor.
tf.contrib.learn.monitors.GraphDump.begin(max_steps=None)
tf.contrib.learn.monitors.GraphDump.compare(other_dump, step, atol=1e-06)Compares two GraphDump monitors and returns differences.
tf.contrib.learn.monitors.GraphDump.data
tf.contrib.learn.monitors.GraphDump.end(session=None)Callback at the end of training/evaluation.
tf.contrib.learn.monitors.GraphDump.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.GraphDump.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.GraphDump.post_step(step, session)Callback after the step is finished.
tf.contrib.learn.monitors.GraphDump.run_on_all_workers
tf.contrib.learn.monitors.GraphDump.set_estimator(estimator)A setter called automatically by the target estimator.
tf.contrib.learn.monitors.GraphDump.step_begin(step)
tf.contrib.learn.monitors.GraphDump.step_end(step, output)
class tf.contrib.learn.monitors.LoggingTrainableWrites trainable variable values into log every N steps.
tf.contrib.learn.monitors.LoggingTrainable.__init__(scope=None, every_n=100, first_n=1)Initializes LoggingTrainable monitor.
tf.contrib.learn.monitors.LoggingTrainable.begin(max_steps=None)Called at the beginning of training.
tf.contrib.learn.monitors.LoggingTrainable.end(session=None)
tf.contrib.learn.monitors.LoggingTrainable.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.LoggingTrainable.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.LoggingTrainable.every_n_post_step(step, session)Callback after a step is finished or end() is called.
tf.contrib.learn.monitors.LoggingTrainable.every_n_step_begin(step)
tf.contrib.learn.monitors.LoggingTrainable.every_n_step_end(step, outputs)
tf.contrib.learn.monitors.LoggingTrainable.post_step(step, session)
tf.contrib.learn.monitors.LoggingTrainable.run_on_all_workers
tf.contrib.learn.monitors.LoggingTrainable.set_estimator(estimator)A setter called automatically by the target estimator.
tf.contrib.learn.monitors.LoggingTrainable.step_begin(step)Overrides BaseMonitor.step_begin.
tf.contrib.learn.monitors.LoggingTrainable.step_end(step, output)Overrides BaseMonitor.step_end.
class tf.contrib.learn.monitors.NanLossNaN Loss monitor.
tf.contrib.learn.monitors.NanLoss.__init__(loss_tensor, every_n_steps=100, fail_on_nan_loss=True)Initializes NanLoss monitor.
tf.contrib.learn.monitors.NanLoss.begin(max_steps=None)Called at the beginning of training.
tf.contrib.learn.monitors.NanLoss.end(session=None)
tf.contrib.learn.monitors.NanLoss.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.NanLoss.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.NanLoss.every_n_post_step(step, session)Callback after a step is finished or end() is called.
tf.contrib.learn.monitors.NanLoss.every_n_step_begin(step)
tf.contrib.learn.monitors.NanLoss.every_n_step_end(step, outputs)
tf.contrib.learn.monitors.NanLoss.post_step(step, session)
tf.contrib.learn.monitors.NanLoss.run_on_all_workers
tf.contrib.learn.monitors.NanLoss.set_estimator(estimator)A setter called automatically by the target estimator.
tf.contrib.learn.monitors.NanLoss.step_begin(step)Overrides BaseMonitor.step_begin.
tf.contrib.learn.monitors.NanLoss.step_end(step, output)Overrides BaseMonitor.step_end.
class tf.contrib.learn.monitors.PrintTensorPrints given tensors every N steps.
tf.contrib.learn.monitors.PrintTensor.__init__(tensor_names, every_n=100, first_n=1)Initializes a PrintTensor monitor.
tf.contrib.learn.monitors.PrintTensor.begin(max_steps=None)Called at the beginning of training.
tf.contrib.learn.monitors.PrintTensor.end(session=None)
tf.contrib.learn.monitors.PrintTensor.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.PrintTensor.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.PrintTensor.every_n_post_step(step, session)Callback after a step is finished or end() is called.
tf.contrib.learn.monitors.PrintTensor.every_n_step_begin(step)
tf.contrib.learn.monitors.PrintTensor.every_n_step_end(step, outputs)
tf.contrib.learn.monitors.PrintTensor.post_step(step, session)
tf.contrib.learn.monitors.PrintTensor.run_on_all_workers
tf.contrib.learn.monitors.PrintTensor.set_estimator(estimator)A setter called automatically by the target estimator.
tf.contrib.learn.monitors.PrintTensor.step_begin(step)Overrides BaseMonitor.step_begin.
tf.contrib.learn.monitors.PrintTensor.step_end(step, output)Overrides BaseMonitor.step_end.
class tf.contrib.learn.monitors.StepCounterSteps per second monitor.
tf.contrib.learn.monitors.StepCounter.__init__(every_n_steps=100, output_dir=None, summary_writer=None)
tf.contrib.learn.monitors.StepCounter.begin(max_steps=None)Called at the beginning of training.
tf.contrib.learn.monitors.StepCounter.end(session=None)
tf.contrib.learn.monitors.StepCounter.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.StepCounter.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.StepCounter.every_n_post_step(step, session)Callback after a step is finished or end() is called.
tf.contrib.learn.monitors.StepCounter.every_n_step_begin(step)Callback before every n'th step begins.
tf.contrib.learn.monitors.StepCounter.every_n_step_end(current_step, outputs)
tf.contrib.learn.monitors.StepCounter.post_step(step, session)
tf.contrib.learn.monitors.StepCounter.run_on_all_workers
tf.contrib.learn.monitors.StepCounter.set_estimator(estimator)
tf.contrib.learn.monitors.StepCounter.step_begin(step)Overrides BaseMonitor.step_begin.
tf.contrib.learn.monitors.StepCounter.step_end(step, output)Overrides BaseMonitor.step_end.
class tf.contrib.learn.monitors.StopAtStepMonitor to request stop at a specified step.
tf.contrib.learn.monitors.StopAtStep.__init__(num_steps=None, last_step=None)Create a StopAtStep monitor.
tf.contrib.learn.monitors.StopAtStep.begin(max_steps=None)Called at the beginning of training.
tf.contrib.learn.monitors.StopAtStep.end(session=None)Callback at the end of training/evaluation.
tf.contrib.learn.monitors.StopAtStep.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.StopAtStep.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.StopAtStep.post_step(step, session)Callback after the step is finished.
tf.contrib.learn.monitors.StopAtStep.run_on_all_workers
tf.contrib.learn.monitors.StopAtStep.set_estimator(estimator)A setter called automatically by the target estimator.
tf.contrib.learn.monitors.StopAtStep.step_begin(step)
tf.contrib.learn.monitors.StopAtStep.step_end(step, output)
class tf.contrib.learn.monitors.SummarySaverSaves summaries every N steps.
tf.contrib.learn.monitors.SummarySaver.__init__(summary_op, save_steps=100, output_dir=None, summary_writer=None, scaffold=None)Initializes a SummarySaver monitor.
tf.contrib.learn.monitors.SummarySaver.begin(max_steps=None)Called at the beginning of training.
tf.contrib.learn.monitors.SummarySaver.end(session=None)
tf.contrib.learn.monitors.SummarySaver.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.SummarySaver.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.SummarySaver.every_n_post_step(step, session)Callback after a step is finished or end() is called.
tf.contrib.learn.monitors.SummarySaver.every_n_step_begin(step)
tf.contrib.learn.monitors.SummarySaver.every_n_step_end(step, outputs)
tf.contrib.learn.monitors.SummarySaver.post_step(step, session)
tf.contrib.learn.monitors.SummarySaver.run_on_all_workers
tf.contrib.learn.monitors.SummarySaver.set_estimator(estimator)
tf.contrib.learn.monitors.SummarySaver.step_begin(step)Overrides BaseMonitor.step_begin.
tf.contrib.learn.monitors.SummarySaver.step_end(step, output)Overrides BaseMonitor.step_end.
class tf.contrib.learn.monitors.ValidationMonitorRuns evaluation of a given estimator, at most every N steps.
tf.contrib.learn.monitors.ValidationMonitor.__init__(x=None, y=None, input_fn=None, batch_size=None, eval_steps=None, every_n_steps=100, metrics=None, early_stopping_rounds=None, early_stopping_metric='loss', early_stopping_metric_minimize=True, name=None)Initializes a ValidationMonitor.
tf.contrib.learn.monitors.ValidationMonitor.begin(max_steps=None)Called at the beginning of training.
tf.contrib.learn.monitors.ValidationMonitor.best_stepReturns the step at which the best early stopping metric was found.
tf.contrib.learn.monitors.ValidationMonitor.best_valueReturns the best early stopping metric value found so far.
tf.contrib.learn.monitors.ValidationMonitor.early_stoppedReturns True if this monitor caused an early stop.
tf.contrib.learn.monitors.ValidationMonitor.end(session=None)
tf.contrib.learn.monitors.ValidationMonitor.epoch_begin(epoch)Begin epoch.
tf.contrib.learn.monitors.ValidationMonitor.epoch_end(epoch)End epoch.
tf.contrib.learn.monitors.ValidationMonitor.every_n_post_step(step, session)Callback after a step is finished or end() is called.
tf.contrib.learn.monitors.ValidationMonitor.every_n_step_begin(step)Callback before every n'th step begins.
tf.contrib.learn.monitors.ValidationMonitor.every_n_step_end(step, outputs)
tf.contrib.learn.monitors.ValidationMonitor.post_step(step, session)
tf.contrib.learn.monitors.ValidationMonitor.run_on_all_workers
tf.contrib.learn.monitors.ValidationMonitor.set_estimator(estimator)A setter called automatically by the target estimator.
tf.contrib.learn.monitors.ValidationMonitor.step_begin(step)Overrides BaseMonitor.step_begin.
tf.contrib.learn.monitors.ValidationMonitor.step_end(step, output)Overrides BaseMonitor.step_end.

Monitors (contrib) > Other Functions and Classes

Members
class tf.contrib.learn.monitors.SummaryWriterCacheCache for summary writers.
tf.contrib.learn.monitors.SummaryWriterCache.clear()Clear cached summary writers. Currently only used for unit tests.
tf.contrib.learn.monitors.SummaryWriterCache.get(logdir)Returns the SummaryWriter for the specified directory.

Losses (contrib) > Other Functions and Classes

Members
tf.contrib.losses.absolute_difference(predictions, targets, weight=1.0, scope=None)Adds an Absolute Difference loss to the training procedure.
tf.contrib.losses.add_loss(loss)Adds a externally defined loss to collection of losses.
tf.contrib.losses.cosine_distance(predictions, targets, dim, weight=1.0, scope=None)Adds a cosine-distance loss to the training procedure.
tf.contrib.losses.get_losses(scope=None)Gets the list of loss variables.
tf.contrib.losses.get_regularization_losses(scope=None)Gets the regularization losses.
tf.contrib.losses.get_total_loss(add_regularization_losses=True, name='total_loss')Returns a tensor whose value represents the total loss.
tf.contrib.losses.hinge_loss(logits, target, scope=None)Method that returns the loss tensor for hinge loss.
tf.contrib.losses.log_loss(predictions, targets, weight=1.0, epsilon=1e-07, scope=None)Adds a Log Loss term to the training procedure.
tf.contrib.losses.sigmoid_cross_entropy(logits, multi_class_labels, weight=1.0, label_smoothing=0, scope=None)Creates a cross-entropy loss using tf.nn.sigmoid_cross_entropy_with_logits.
tf.contrib.losses.softmax_cross_entropy(logits, onehot_labels, weight=1.0, label_smoothing=0, scope=None)Creates a cross-entropy loss using tf.nn.softmax_cross_entropy_with_logits.
tf.contrib.losses.sum_of_pairwise_squares(predictions, targets, weight=1.0, scope=None)Adds a pairwise-errors-squared loss to the training procedure.
tf.contrib.losses.sum_of_squares(predictions, targets, weight=1.0, scope=None)Adds a Sum-of-Squares loss to the training procedure.

RNN (contrib) > This package provides additional contributed RNNCells.

Members
class tf.contrib.rnn.LSTMFusedCellBasic LSTM recurrent network cell.
tf.contrib.rnn.LSTMFusedCell.__init__(num_units, forget_bias=1.0, use_peephole=False)Initialize the basic LSTM cell.
tf.contrib.rnn.LSTMFusedCell.output_size
tf.contrib.rnn.LSTMFusedCell.state_size
tf.contrib.rnn.LSTMFusedCell.zero_state(batch_size, dtype)Return zero-filled state tensor(s).
class tf.contrib.rnn.CoupledInputForgetGateLSTMCellLong short-term memory unit (LSTM) recurrent network cell.
tf.contrib.rnn.CoupledInputForgetGateLSTMCell.__init__(num_units, use_peepholes=False, initializer=None, num_proj=None, proj_clip=None, num_unit_shards=1, num_proj_shards=1, forget_bias=1.0, state_is_tuple=False, activation=tanh)Initialize the parameters for an LSTM cell.
tf.contrib.rnn.CoupledInputForgetGateLSTMCell.output_size
tf.contrib.rnn.CoupledInputForgetGateLSTMCell.state_size
tf.contrib.rnn.CoupledInputForgetGateLSTMCell.zero_state(batch_size, dtype)Return zero-filled state tensor(s).
class tf.contrib.rnn.TimeFreqLSTMCellTime-Frequency Long short-term memory unit (LSTM) recurrent network cell.
tf.contrib.rnn.TimeFreqLSTMCell.__init__(num_units, use_peepholes=False, cell_clip=None, initializer=None, num_unit_shards=1, forget_bias=1.0, feature_size=None, frequency_skip=None)Initialize the parameters for an LSTM cell.
tf.contrib.rnn.TimeFreqLSTMCell.output_size
tf.contrib.rnn.TimeFreqLSTMCell.state_size
tf.contrib.rnn.TimeFreqLSTMCell.zero_state(batch_size, dtype)Return zero-filled state tensor(s).
class tf.contrib.rnn.GridLSTMCellGrid Long short-term memory unit (LSTM) recurrent network cell.
tf.contrib.rnn.GridLSTMCell.__init__(num_units, use_peepholes=False, share_time_frequency_weights=False, cell_clip=None, initializer=None, num_unit_shards=1, forget_bias=1.0, feature_size=None, frequency_skip=None)Initialize the parameters for an LSTM cell.
tf.contrib.rnn.GridLSTMCell.output_size
tf.contrib.rnn.GridLSTMCell.state_size
tf.contrib.rnn.GridLSTMCell.zero_state(batch_size, dtype)Return zero-filled state tensor(s).
class tf.contrib.rnn.AttentionCellWrapperBasic attention cell wrapper.
tf.contrib.rnn.AttentionCellWrapper.__init__(cell, attn_length, attn_size=None, attn_vec_size=None, input_size=None, state_is_tuple=False)Create a cell with attention.
tf.contrib.rnn.AttentionCellWrapper.output_size
tf.contrib.rnn.AttentionCellWrapper.state_size
tf.contrib.rnn.AttentionCellWrapper.zero_state(batch_size, dtype)Return zero-filled state tensor(s).

Metrics (contrib) > Metric Ops

Members
tf.contrib.metrics.streaming_accuracy(predictions, labels, weights=None, metrics_collections=None, updates_collections=None, name=None)Calculates how often predictions matches labels.
tf.contrib.metrics.streaming_mean(values, weights=None, metrics_collections=None, updates_collections=None, name=None)Computes the (weighted) mean of the given values.
tf.contrib.metrics.streaming_recall(predictions, labels, ignore_mask=None, metrics_collections=None, updates_collections=None, name=None)Computes the recall of the predictions with respect to the labels.
tf.contrib.metrics.streaming_precision(predictions, labels, ignore_mask=None, metrics_collections=None, updates_collections=None, name=None)Computes the precision of the predictions with respect to the labels.
tf.contrib.metrics.streaming_auc(predictions, labels, ignore_mask=None, num_thresholds=200, metrics_collections=None, updates_collections=None, curve='ROC', name=None)Computes the approximate AUC via a Riemann sum.
tf.contrib.metrics.streaming_recall_at_k(predictions, labels, k, ignore_mask=None, metrics_collections=None, updates_collections=None, name=None)Computes the recall@k of the predictions with respect to dense labels.
tf.contrib.metrics.streaming_mean_absolute_error(predictions, labels, weights=None, metrics_collections=None, updates_collections=None, name=None)Computes the mean absolute error between the labels and predictions.
tf.contrib.metrics.streaming_mean_iou(predictions, labels, num_classes, ignore_mask=None, metrics_collections=None, updates_collections=None, name=None)Calculate per-step mean Intersection-Over-Union (mIOU).
tf.contrib.metrics.streaming_mean_relative_error(predictions, labels, normalizer, weights=None, metrics_collections=None, updates_collections=None, name=None)Computes the mean relative error by normalizing with the given values.
tf.contrib.metrics.streaming_mean_squared_error(predictions, labels, weights=None, metrics_collections=None, updates_collections=None, name=None)Computes the mean squared error between the labels and predictions.
tf.contrib.metrics.streaming_root_mean_squared_error(predictions, labels, weights=None, metrics_collections=None, updates_collections=None, name=None)Computes the root mean squared error between the labels and predictions.
tf.contrib.metrics.streaming_mean_cosine_distance(predictions, labels, dim, weights=None, metrics_collections=None, updates_collections=None, name=None)Computes the cosine distance between the labels and predictions.
tf.contrib.metrics.streaming_percentage_less(values, threshold, ignore_mask=None, metrics_collections=None, updates_collections=None, name=None)Computes the percentage of values less than the given threshold.
tf.contrib.metrics.streaming_sparse_precision_at_k(predictions, labels, k, class_id=None, ignore_mask=None, metrics_collections=None, updates_collections=None, name=None)Computes precision@k of the predictions with respect to sparse labels.
tf.contrib.metrics.streaming_sparse_recall_at_k(predictions, labels, k, class_id=None, ignore_mask=None, metrics_collections=None, updates_collections=None, name=None)Computes recall@k of the predictions with respect to sparse labels.
tf.contrib.metrics.auc_using_histogram(boolean_labels, scores, score_range, nbins=100, collections=None, check_shape=True, name=None)AUC computed by maintaining histograms.
tf.contrib.metrics.accuracy(predictions, labels, weights=None)Computes the percentage of times that predictions matches labels.
tf.contrib.metrics.confusion_matrix(predictions, labels, num_classes=None, dtype=tf.int32, name=None)Computes the confusion matrix from predictions and labels.
tf.contrib.metrics.aggregate_metrics(*value_update_tuples)Aggregates the metric value tensors and update ops into two lists.
tf.contrib.metrics.aggregate_metric_map(names_to_tuples)Aggregates the metric names to tuple dictionary.

Metrics (contrib) > Set Ops

Members
tf.contrib.metrics.set_difference(a, b, aminusb=True, validate_indices=True)Compute set difference of elements in last dimension of a and b.
tf.contrib.metrics.set_intersection(a, b, validate_indices=True)Compute set intersection of elements in last dimension of a and b.
tf.contrib.metrics.set_size(a, validate_indices=True)Compute number of unique elements along last dimension of a.
tf.contrib.metrics.set_union(a, b, validate_indices=True)Compute set union of elements in last dimension of a and b.

Utilities (contrib) > Miscellaneous Utility Functions

Members
tf.contrib.util.constant_value(tensor)Returns the constant value of the given tensor, if efficiently calculable.
tf.contrib.util.make_tensor_proto(values, dtype=None, shape=None)Create a TensorProto.
tf.contrib.util.make_ndarray(tensor)Create a numpy ndarray from a tensor.
tf.contrib.util.ops_used_by_graph_def(graph_def)Collect the list of ops used by a graph.
tf.contrib.util.stripped_op_list_for_graph(graph_def)Collect the stripped OpDefs for ops used by a graph.
tf.contrib.copy_graph.copy_op_to_graph(org_instance, to_graph, variables, scope='')Given an Operation 'org_instance from one Graph,
tf.contrib.copy_graph.copy_variable_to_graph(org_instance, to_graph, scope='')Given a Variable instance from one Graph, initializes and returns
tf.contrib.copy_graph.get_copied_op(org_instance, graph, scope='')Given an Operation instance from some Graph, returns