LostTech.TensorFlow : API Documentation

Type nest

Namespace tensorflow.python.data.util.nest

Public static methods

void assert_same_structure(PythonClassContainer nest1, PythonClassContainer nest2, bool check_types)

void assert_same_structure(PythonClassContainer nest1, PythonClassContainer nest2, string check_types)

void assert_same_structure(PythonClassContainer nest1, object nest2, bool check_types)

void assert_same_structure(PythonClassContainer nest1, object nest2, string check_types)

void assert_same_structure(object nest1, PythonClassContainer nest2, bool check_types)

void assert_same_structure(object nest1, PythonClassContainer nest2, string check_types)

void assert_same_structure(object nest1, object nest2, bool check_types)

void assert_same_structure(object nest1, object nest2, string check_types)

object assert_same_structure_dyn(object nest1, object nest2, ImplicitContainer<T> check_types)

void assert_shallow_structure(string shallow_tree, object input_tree, bool check_types)

void assert_shallow_structure(object shallow_tree, object input_tree, bool check_types)

void assert_shallow_structure(PythonClassContainer shallow_tree, object input_tree, bool check_types)

void assert_shallow_structure(int shallow_tree, object input_tree, bool check_types)

void assert_shallow_structure(DType shallow_tree, object input_tree, bool check_types)

void assert_shallow_structure(IEnumerable<object> shallow_tree, object input_tree, bool check_types)

void assert_shallow_structure(IDictionary<object, object> shallow_tree, object input_tree, bool check_types)

object assert_shallow_structure_dyn(object shallow_tree, object input_tree, ImplicitContainer<T> check_types)

IList<object> flatten_up_to(IDictionary<object, object> shallow_tree, object input_tree)

IList<object> flatten_up_to(string shallow_tree, object input_tree)

IList<object> flatten_up_to(object shallow_tree, object input_tree)

IList<object> flatten_up_to(PythonClassContainer shallow_tree, object input_tree)

IList<object> flatten_up_to(int shallow_tree, object input_tree)

IList<object> flatten_up_to(DType shallow_tree, object input_tree)

IList<object> flatten_up_to(IEnumerable<object> shallow_tree, object input_tree)

object flatten_up_to_dyn(object shallow_tree, object input_tree)

string map_structure(PythonFunctionContainer func, IDictionary<string, object> check_types_dict, Object[] structure)

Applies `func` to each entry in `structure` and returns a new structure.

Applies `func(x[0], x[1],...)` where x[i] is an entry in `structure[i]`. All structures in `structure` must have the same arity, and the return value will contain results with the same structure layout.
Parameters
PythonFunctionContainer func
A callable that accepts as many arguments as there are structures.
IDictionary<string, object> check_types_dict
Object[] structure
scalar, or tuple or list of constructed scalars and/or other tuples/lists, or scalars. Note: numpy arrays are considered as scalars.
Returns
string
A new structure with the same arity as `structure`, whose values correspond to `func(x[0], x[1],...)` where `x[i]` is a value in the corresponding location in `structure[i]`. If there are different sequence types and `check_types` is `False` the sequence types of the first structure will be used.

string map_structure(string func, Object[] structure)

Applies `func` to each entry in `structure` and returns a new structure.

Applies `func(x[0], x[1],...)` where x[i] is an entry in `structure[i]`. All structures in `structure` must have the same arity, and the return value will contain results with the same structure layout.
Parameters
string func
A callable that accepts as many arguments as there are structures.
Object[] structure
scalar, or tuple or list of constructed scalars and/or other tuples/lists, or scalars. Note: numpy arrays are considered as scalars.
Returns
string
A new structure with the same arity as `structure`, whose values correspond to `func(x[0], x[1],...)` where `x[i]` is a value in the corresponding location in `structure[i]`. If there are different sequence types and `check_types` is `False` the sequence types of the first structure will be used.

string map_structure(PythonFunctionContainer func, Object[] structure)

Applies `func` to each entry in `structure` and returns a new structure.

Applies `func(x[0], x[1],...)` where x[i] is an entry in `structure[i]`. All structures in `structure` must have the same arity, and the return value will contain results with the same structure layout.
Parameters
PythonFunctionContainer func
A callable that accepts as many arguments as there are structures.
Object[] structure
scalar, or tuple or list of constructed scalars and/or other tuples/lists, or scalars. Note: numpy arrays are considered as scalars.
Returns
string
A new structure with the same arity as `structure`, whose values correspond to `func(x[0], x[1],...)` where `x[i]` is a value in the corresponding location in `structure[i]`. If there are different sequence types and `check_types` is `False` the sequence types of the first structure will be used.

string map_structure(string func, IDictionary<string, object> check_types_dict, Object[] structure)

Applies `func` to each entry in `structure` and returns a new structure.

Applies `func(x[0], x[1],...)` where x[i] is an entry in `structure[i]`. All structures in `structure` must have the same arity, and the return value will contain results with the same structure layout.
Parameters
string func
A callable that accepts as many arguments as there are structures.
IDictionary<string, object> check_types_dict
Object[] structure
scalar, or tuple or list of constructed scalars and/or other tuples/lists, or scalars. Note: numpy arrays are considered as scalars.
Returns
string
A new structure with the same arity as `structure`, whose values correspond to `func(x[0], x[1],...)` where `x[i]` is a value in the corresponding location in `structure[i]`. If there are different sequence types and `check_types` is `False` the sequence types of the first structure will be used.

object map_structure_dyn(object func, Object[] structure)

Applies `func` to each entry in `structure` and returns a new structure.

Applies `func(x[0], x[1],...)` where x[i] is an entry in `structure[i]`. All structures in `structure` must have the same arity, and the return value will contain results with the same structure layout.
Parameters
object func
A callable that accepts as many arguments as there are structures.
Object[] structure
scalar, or tuple or list of constructed scalars and/or other tuples/lists, or scalars. Note: numpy arrays are considered as scalars.
Returns
object
A new structure with the same arity as `structure`, whose values correspond to `func(x[0], x[1],...)` where `x[i]` is a value in the corresponding location in `structure[i]`. If there are different sequence types and `check_types` is `False` the sequence types of the first structure will be used.

object map_structure_dyn(object func, IDictionary<string, object> check_types_dict, Object[] structure)

Applies `func` to each entry in `structure` and returns a new structure.

Applies `func(x[0], x[1],...)` where x[i] is an entry in `structure[i]`. All structures in `structure` must have the same arity, and the return value will contain results with the same structure layout.
Parameters
object func
A callable that accepts as many arguments as there are structures.
IDictionary<string, object> check_types_dict
Object[] structure
scalar, or tuple or list of constructed scalars and/or other tuples/lists, or scalars. Note: numpy arrays are considered as scalars.
Returns
object
A new structure with the same arity as `structure`, whose values correspond to `func(x[0], x[1],...)` where `x[i]` is a value in the corresponding location in `structure[i]`. If there are different sequence types and `check_types` is `False` the sequence types of the first structure will be used.

object map_structure_up_to(PythonClassContainer shallow_tree, object func, Object[] inputs)

object map_structure_up_to(DType shallow_tree, object func, Object[] inputs)

object map_structure_up_to(ValueTuple<string, object> shallow_tree, object func, Object[] inputs)

object map_structure_up_to(IEnumerable<object> shallow_tree, object func, Object[] inputs)

object map_structure_up_to(IDictionary<string, object> shallow_tree, object func, Object[] inputs)

object map_structure_up_to(object shallow_tree, object func, Object[] inputs)

object map_structure_up_to_dyn(object shallow_tree, object func, Object[] inputs)

string pack_sequence_as(object structure, ndarray flat_sequence)

string pack_sequence_as(object structure, string flat_sequence)

string pack_sequence_as(PythonClassContainer structure, string flat_sequence)

string pack_sequence_as(IEnumerable<Dataset> structure, ndarray flat_sequence)

string pack_sequence_as(IEnumerable<Dataset> structure, string flat_sequence)

string pack_sequence_as(PythonClassContainer structure, IEnumerable<object> flat_sequence)

string pack_sequence_as(PythonClassContainer structure, ndarray flat_sequence)

Public properties

PythonFunctionContainer assert_same_structure_fn get;

PythonFunctionContainer assert_shallow_structure_fn get;

PythonFunctionContainer flatten_up_to_fn get;

PythonFunctionContainer map_structure_fn get;

PythonFunctionContainer map_structure_up_to_fn get;

PythonFunctionContainer pack_sequence_as_fn get;