Type IGraph
Namespace tensorflow
Interfaces IPythonObjectContainer
Methods
- add_to_collection
- add_to_collections
- as_graph_def
- as_graph_element
- clear_collection
- colocate_with
- container
- create_op
- get_collection
- get_collection_ref
- get_name_scope
- get_operation_by_name
- get_tensor_by_name
- gradient_override_map
- is_feedable
- is_fetchable
- name_scope
- prevent_feeding
- unique_name
Properties
Public instance methods
object add_to_collection(object name, object value)
object add_to_collections(object names, object value)
object as_graph_def(object from_version, object add_shapes)
object as_graph_element(object obj, object allow_tensor, object allow_operation)
object clear_collection(object name)
object colocate_with(object op, object ignore_existing)
object container(object container_name)
object create_op(object op_type, object inputs, object dtypes, object input_types, object name, object attrs, object op_def, object compute_shapes, object compute_device)
object get_collection(object name, object scope)
object get_collection_ref(object name)
object get_name_scope()
Returns the current name scope.
would print the string `scope1/scope2`.
Returns
-
object
- A string representing the current name scope.
Show Example
with tf.name_scope('scope1'): with tf.name_scope('scope2'): print(tf.compat.v1.get_default_graph().get_name_scope())